{"id":12226,"date":"2021-10-30T13:07:27","date_gmt":"2021-10-30T13:07:27","guid":{"rendered":"https:\/\/www.milesweb.co.uk\/hosting-faqs\/?p=12226"},"modified":"2024-04-23T12:16:39","modified_gmt":"2024-04-23T11:16:39","slug":"disable-php-functions-whm-panel","status":"publish","type":"post","link":"https:\/\/www.milesweb.co.uk\/hosting-faqs\/disable-php-functions-whm-panel\/","title":{"rendered":"How to Disable PHP Functions from WHM Panel?"},"content":{"rendered":"<p>With the WHM panel, you can disable PHP functions for your hosting server.<\/p>\n<p>Some PHP functions on your web hosting servers pose a risk as hackers use them for malicious purposes. Although they are not hazardous by design, it is better to disable these functions to improve security.<\/p>\n<h2>To Disable PHP Functions<\/h2>\n<p>1. Log in to your root account of WHM.<\/p>\n<p>2. Select the <strong>Software<\/strong> option from the navigation menu.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-13609\" src=\"https:\/\/www.milesweb.co.uk\/hosting-faqs\/wp-content\/uploads\/2021\/10\/whm_software.png\" alt=\"\" width=\"1599\" height=\"700\" \/><\/p>\n<p>3. Click on <strong>MultiPHP INI Editor<\/strong>.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-13738\" src=\"https:\/\/www.milesweb.co.uk\/hosting-faqs\/wp-content\/uploads\/2021\/10\/whm_multiphp_ini_editor.png\" alt=\"\" width=\"1083\" height=\"271\" \/><\/p>\n<p>The\u00a0<em>MultiPHP INI Editor<\/em>\u00a0panel will open.<\/p>\n<p>4. Open the <strong>Editor Mode<\/strong>.<\/p>\n<p>5. Select the PHP version from the dropdown list of <strong>Edit the INI settings of a PHP version<\/strong>.<\/p>\n<p>The directives consisting of the INI settings for the PHP version will appear.<\/p>\n<p>6. Press <strong>Ctrl+f<\/strong> to bring up the &#8220;<em>find-box<\/em>&#8221; and type <strong>disable_functions<\/strong>.<\/p>\n<p>It will show you the directive to disable the PHP functions.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-13739\" src=\"https:\/\/www.milesweb.co.uk\/hosting-faqs\/wp-content\/uploads\/2021\/10\/whm_multiphp_ini_editor_find_disable_functions.png\" alt=\"\" width=\"1066\" height=\"668\" \/><\/p>\n<p>7. Enter\/copy the PHP functions to disable in the given syntax:<\/p>\n<p class=\"font-size:15 line-height:20 lang:default decode:true \">disable_functions = &#8220;apache_child_terminate,apache_get_modules,apache_note,apache_setenv,define_syslog_variables,disk_free_space,disk_total_space,diskfreespace,dl,escapeshellarg,escapeshellcmd,exec,extract,get_cfg_var,get_current_user,getcwd,getenv,getlastmo,getmygid,getmyinode,getmypid,getmyuid,ini_restore,ini_set,passthru,pcntl_alarm,pcntl_exec,pcntl_fork,pcntl_get_last_error,pcntl_getpriority,pcntl_setpriority,pcntl_signal,pcntl_signal_dispatch,pcntl_sigprocmask,pcntl_sigtimedwait,pcntl_sigwaitinfo,pcntl_strerrorp,pcntl_wait,pcntl_waitpid,pcntl_wexitstatus,pcntl_wifexited,pcntl_wifsignaled,pcntl_wifstopped,pcntl_wstopsig,pcntl_wtermsig,php_uname,phpinfo,popen,posix_getlogin,posix_getpwuid,posix_kill,posix_mkfifo,posix_setpgid,posix_setsid,posix_setuid,posix_ttyname,posix_uname,posixc,proc_close,proc_get_status,proc_nice,proc_open,proc_terminate,ps_aux,putenv,readlink,runkit_function_rename,shell_exec,show_source,symlink,syslog,system&#8221;<\/p>\n<p>It will look something like this:<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-13740\" src=\"https:\/\/www.milesweb.co.uk\/hosting-faqs\/wp-content\/uploads\/2021\/10\/whm_multiphp_ini_editor_disable_functions.png\" alt=\"\" width=\"951\" height=\"489\" \/><\/p>\n<p>8. Click <strong>Save<\/strong>.<\/p>\n<p>WHM will display a message saying it has disabled the PHP functions.<\/p>\n<p>Here are some of the potentially unsafe PHP functions you should disable for your WHM\/cPanel server:<\/p>\n<div class=\"kb-box-focus kb-box-focus-rounded kb-box-focus-red\">apache_child_terminate<br \/>\napache_get_modules<br \/>\napache_note<br \/>\napache_setenv<br \/>\ndefine_syslog_variables<br \/>\ndisk_free_space<br \/>\ndisk_total_space<br \/>\ndiskfreespace<br \/>\ndl<br \/>\nescapeshellarg<br \/>\nescapeshellcmd<br \/>\nexec<br \/>\nextract<br \/>\nget_cfg_var<br \/>\nget_current_user<br \/>\ngetcwd<br \/>\ngetenv<br \/>\ngetlastmo<br \/>\ngetmygid<br \/>\ngetmyinode<br \/>\ngetmypid<br \/>\ngetmyuid<br \/>\nini_restore<br \/>\nini_set<br \/>\npassthru<br \/>\npcntl_alarm<br \/>\npcntl_exec<br \/>\npcntl_fork<br \/>\npcntl_get_last_error<br \/>\npcntl_getpriority<br \/>\npcntl_setpriority<br \/>\npcntl_signal<br \/>\npcntl_signal_dispatch<br \/>\npcntl_sigprocmask<br \/>\npcntl_sigtimedwait<br \/>\npcntl_sigwaitinfo<br \/>\npcntl_strerrorp<br \/>\npcntl_wait<br \/>\npcntl_waitpid<br \/>\npcntl_wexitstatus<br \/>\npcntl_wifexited<br \/>\npcntl_wifsignaled<br \/>\npcntl_wifstopped<br \/>\npcntl_wstopsig<br \/>\npcntl_wtermsig<br \/>\nphp_uname<br \/>\nphpinfo<br \/>\npopen<br \/>\nposix_getlogin<br \/>\nposix_getpwuid<br \/>\nposix_kill<br \/>\nposix_mkfifo<br \/>\nposix_setpgid<br \/>\nposix_setsid<br \/>\nposix_setuid<br \/>\nposix_ttyname<br \/>\nposix_uname<br \/>\nposixc<br \/>\nproc_close<br \/>\nproc_get_status<br \/>\nproc_nice<br \/>\nproc_open<br \/>\nproc_terminate<br \/>\nps_aux<br \/>\nputenv<br \/>\nreadlink<br \/>\nrunkit_function_rename<br \/>\nshell_exec<br \/>\nshow_source<br \/>\nsymlink<br \/>\nsyslog<br \/>\nsystem<\/div>\n<p>To know more about these PHP functions, refer to the PHP site at <a href=\"http:\/\/php.net\/\" target=\"_blank\" rel=\"nofollow noopener\">http:\/\/php.net\/<\/a><\/p>\n","protected":false},"excerpt":{"rendered":"<p>With the WHM panel, you can disable PHP functions for your hosting server. Some PHP functions on your web hosting servers pose a risk as hackers use them for malicious purposes. Although they are not hazardous by design, it is better to disable these functions to improve security. To Disable PHP Functions 1. Log in [&hellip;]<\/p>\n","protected":false},"author":27,"featured_media":0,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[41,229,4],"tags":[682,2626,683,2273,2058],"class_list":["post-12226","post","type-post","status-publish","format-standard","placeholder-for-hentry","category-howtos","category-whm","category-web-hosting-faq","tag-disable-php-functions","tag-disable-php-functions-whm","tag-php-functions","tag-php-settings","tag-php-settings-with-multiphp-ini-editor"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v25.2 - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<title>Disable PHP Functions from WHM - Web Hosting FAQs by MilesWeb<\/title>\n<meta name=\"description\" content=\"This article will help you understand what PHP functions are unsafe to your server and how you can disable them via the WHM panel.\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/www.milesweb.co.uk\/hosting-faqs\/disable-php-functions-whm-panel\/\" \/>\n<meta property=\"og:locale\" content=\"en_GB\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Disable PHP Functions from WHM - Web Hosting FAQs by MilesWeb\" \/>\n<meta property=\"og:description\" content=\"This article will help you understand what PHP functions are unsafe to your server and how you can disable them via the WHM panel.\" \/>\n<meta property=\"og:url\" content=\"https:\/\/www.milesweb.co.uk\/hosting-faqs\/disable-php-functions-whm-panel\/\" \/>\n<meta property=\"og:site_name\" content=\"Web Hosting FAQs by MilesWeb\" \/>\n<meta property=\"article:published_time\" content=\"2021-10-30T13:07:27+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2024-04-23T11:16:39+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/www.milesweb.co.uk\/hosting-faqs\/wp-content\/uploads\/2021\/10\/whm_software.png\" \/>\n<meta name=\"author\" content=\"Prasad Khartadkar\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"Prasad Khartadkar\" \/>\n\t<meta name=\"twitter:label2\" content=\"Estimated reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"3 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"WebPage\",\"@id\":\"https:\/\/www.milesweb.co.uk\/hosting-faqs\/disable-php-functions-whm-panel\/\",\"url\":\"https:\/\/www.milesweb.co.uk\/hosting-faqs\/disable-php-functions-whm-panel\/\",\"name\":\"Disable PHP Functions from WHM - Web Hosting FAQs by MilesWeb\",\"isPartOf\":{\"@id\":\"https:\/\/www.milesweb.co.uk\/hosting-faqs\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\/\/www.milesweb.co.uk\/hosting-faqs\/disable-php-functions-whm-panel\/#primaryimage\"},\"image\":{\"@id\":\"https:\/\/www.milesweb.co.uk\/hosting-faqs\/disable-php-functions-whm-panel\/#primaryimage\"},\"thumbnailUrl\":\"https:\/\/www.milesweb.co.uk\/hosting-faqs\/wp-content\/uploads\/2021\/10\/whm_software.png\",\"datePublished\":\"2021-10-30T13:07:27+00:00\",\"dateModified\":\"2024-04-23T11:16:39+00:00\",\"author\":{\"@id\":\"https:\/\/www.milesweb.co.uk\/hosting-faqs\/#\/schema\/person\/c9138a9488172a8d0aa2d4f40878d83e\"},\"description\":\"This article will help you understand what PHP functions are unsafe to your server and how you can disable them via the WHM panel.\",\"breadcrumb\":{\"@id\":\"https:\/\/www.milesweb.co.uk\/hosting-faqs\/disable-php-functions-whm-panel\/#breadcrumb\"},\"inLanguage\":\"en-GB\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/www.milesweb.co.uk\/hosting-faqs\/disable-php-functions-whm-panel\/\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"en-GB\",\"@id\":\"https:\/\/www.milesweb.co.uk\/hosting-faqs\/disable-php-functions-whm-panel\/#primaryimage\",\"url\":\"https:\/\/www.milesweb.co.uk\/hosting-faqs\/wp-content\/uploads\/2021\/10\/whm_software.png\",\"contentUrl\":\"https:\/\/www.milesweb.co.uk\/hosting-faqs\/wp-content\/uploads\/2021\/10\/whm_software.png\",\"width\":1599,\"height\":700},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/www.milesweb.co.uk\/hosting-faqs\/disable-php-functions-whm-panel\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\/\/www.milesweb.co.uk\/hosting-faqs\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"How to Disable PHP Functions from WHM Panel?\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/www.milesweb.co.uk\/hosting-faqs\/#website\",\"url\":\"https:\/\/www.milesweb.co.uk\/hosting-faqs\/\",\"name\":\"Web Hosting FAQs by MilesWeb\",\"description\":\"\",\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/www.milesweb.co.uk\/hosting-faqs\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-GB\"},{\"@type\":\"Person\",\"@id\":\"https:\/\/www.milesweb.co.uk\/hosting-faqs\/#\/schema\/person\/c9138a9488172a8d0aa2d4f40878d83e\",\"name\":\"Prasad Khartadkar\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-GB\",\"@id\":\"https:\/\/www.milesweb.co.uk\/hosting-faqs\/#\/schema\/person\/image\/\",\"url\":\"https:\/\/secure.gravatar.com\/avatar\/fafb102a39aa8f8d38a11f3e2dcfa746?s=96&d=blank&r=g\",\"contentUrl\":\"https:\/\/secure.gravatar.com\/avatar\/fafb102a39aa8f8d38a11f3e2dcfa746?s=96&d=blank&r=g\",\"caption\":\"Prasad Khartadkar\"},\"description\":\"Prasad is a business grad specialized in Marketing. He has garnered experience as a technical content writer and a digital marketer that he brings out in his work. He likes reading classics and travel in his free time.\",\"url\":\"https:\/\/www.milesweb.co.uk\/hosting-faqs\/author\/prasad-khartadkar\/\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"Disable PHP Functions from WHM - Web Hosting FAQs by MilesWeb","description":"This article will help you understand what PHP functions are unsafe to your server and how you can disable them via the WHM panel.","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/www.milesweb.co.uk\/hosting-faqs\/disable-php-functions-whm-panel\/","og_locale":"en_GB","og_type":"article","og_title":"Disable PHP Functions from WHM - Web Hosting FAQs by MilesWeb","og_description":"This article will help you understand what PHP functions are unsafe to your server and how you can disable them via the WHM panel.","og_url":"https:\/\/www.milesweb.co.uk\/hosting-faqs\/disable-php-functions-whm-panel\/","og_site_name":"Web Hosting FAQs by MilesWeb","article_published_time":"2021-10-30T13:07:27+00:00","article_modified_time":"2024-04-23T11:16:39+00:00","og_image":[{"url":"https:\/\/www.milesweb.co.uk\/hosting-faqs\/wp-content\/uploads\/2021\/10\/whm_software.png","type":"","width":"","height":""}],"author":"Prasad Khartadkar","twitter_misc":{"Written by":"Prasad Khartadkar","Estimated reading time":"3 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"WebPage","@id":"https:\/\/www.milesweb.co.uk\/hosting-faqs\/disable-php-functions-whm-panel\/","url":"https:\/\/www.milesweb.co.uk\/hosting-faqs\/disable-php-functions-whm-panel\/","name":"Disable PHP Functions from WHM - Web Hosting FAQs by MilesWeb","isPartOf":{"@id":"https:\/\/www.milesweb.co.uk\/hosting-faqs\/#website"},"primaryImageOfPage":{"@id":"https:\/\/www.milesweb.co.uk\/hosting-faqs\/disable-php-functions-whm-panel\/#primaryimage"},"image":{"@id":"https:\/\/www.milesweb.co.uk\/hosting-faqs\/disable-php-functions-whm-panel\/#primaryimage"},"thumbnailUrl":"https:\/\/www.milesweb.co.uk\/hosting-faqs\/wp-content\/uploads\/2021\/10\/whm_software.png","datePublished":"2021-10-30T13:07:27+00:00","dateModified":"2024-04-23T11:16:39+00:00","author":{"@id":"https:\/\/www.milesweb.co.uk\/hosting-faqs\/#\/schema\/person\/c9138a9488172a8d0aa2d4f40878d83e"},"description":"This article will help you understand what PHP functions are unsafe to your server and how you can disable them via the WHM panel.","breadcrumb":{"@id":"https:\/\/www.milesweb.co.uk\/hosting-faqs\/disable-php-functions-whm-panel\/#breadcrumb"},"inLanguage":"en-GB","potentialAction":[{"@type":"ReadAction","target":["https:\/\/www.milesweb.co.uk\/hosting-faqs\/disable-php-functions-whm-panel\/"]}]},{"@type":"ImageObject","inLanguage":"en-GB","@id":"https:\/\/www.milesweb.co.uk\/hosting-faqs\/disable-php-functions-whm-panel\/#primaryimage","url":"https:\/\/www.milesweb.co.uk\/hosting-faqs\/wp-content\/uploads\/2021\/10\/whm_software.png","contentUrl":"https:\/\/www.milesweb.co.uk\/hosting-faqs\/wp-content\/uploads\/2021\/10\/whm_software.png","width":1599,"height":700},{"@type":"BreadcrumbList","@id":"https:\/\/www.milesweb.co.uk\/hosting-faqs\/disable-php-functions-whm-panel\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/www.milesweb.co.uk\/hosting-faqs\/"},{"@type":"ListItem","position":2,"name":"How to Disable PHP Functions from WHM Panel?"}]},{"@type":"WebSite","@id":"https:\/\/www.milesweb.co.uk\/hosting-faqs\/#website","url":"https:\/\/www.milesweb.co.uk\/hosting-faqs\/","name":"Web Hosting FAQs by MilesWeb","description":"","potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/www.milesweb.co.uk\/hosting-faqs\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-GB"},{"@type":"Person","@id":"https:\/\/www.milesweb.co.uk\/hosting-faqs\/#\/schema\/person\/c9138a9488172a8d0aa2d4f40878d83e","name":"Prasad Khartadkar","image":{"@type":"ImageObject","inLanguage":"en-GB","@id":"https:\/\/www.milesweb.co.uk\/hosting-faqs\/#\/schema\/person\/image\/","url":"https:\/\/secure.gravatar.com\/avatar\/fafb102a39aa8f8d38a11f3e2dcfa746?s=96&d=blank&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/fafb102a39aa8f8d38a11f3e2dcfa746?s=96&d=blank&r=g","caption":"Prasad Khartadkar"},"description":"Prasad is a business grad specialized in Marketing. He has garnered experience as a technical content writer and a digital marketer that he brings out in his work. He likes reading classics and travel in his free time.","url":"https:\/\/www.milesweb.co.uk\/hosting-faqs\/author\/prasad-khartadkar\/"}]}},"views":357,"_links":{"self":[{"href":"https:\/\/www.milesweb.co.uk\/hosting-faqs\/wp-json\/wp\/v2\/posts\/12226","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.milesweb.co.uk\/hosting-faqs\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.milesweb.co.uk\/hosting-faqs\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.milesweb.co.uk\/hosting-faqs\/wp-json\/wp\/v2\/users\/27"}],"replies":[{"embeddable":true,"href":"https:\/\/www.milesweb.co.uk\/hosting-faqs\/wp-json\/wp\/v2\/comments?post=12226"}],"version-history":[{"count":6,"href":"https:\/\/www.milesweb.co.uk\/hosting-faqs\/wp-json\/wp\/v2\/posts\/12226\/revisions"}],"predecessor-version":[{"id":15385,"href":"https:\/\/www.milesweb.co.uk\/hosting-faqs\/wp-json\/wp\/v2\/posts\/12226\/revisions\/15385"}],"wp:attachment":[{"href":"https:\/\/www.milesweb.co.uk\/hosting-faqs\/wp-json\/wp\/v2\/media?parent=12226"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.milesweb.co.uk\/hosting-faqs\/wp-json\/wp\/v2\/categories?post=12226"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.milesweb.co.uk\/hosting-faqs\/wp-json\/wp\/v2\/tags?post=12226"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}