{"id":3275,"date":"2015-12-22T07:56:25","date_gmt":"2015-12-22T07:56:25","guid":{"rendered":"https:\/\/cpanelplesk.com\/wp62\/?p=3275"},"modified":"2021-02-06T10:58:27","modified_gmt":"2021-02-06T10:58:27","slug":"how-to-stop-wordpress-wp-login-php-brute-force-attack-on-a-cpanel-server","status":"publish","type":"post","link":"https:\/\/cpanelplesk.com\/wp62\/how-to-stop-wordpress-wp-login-php-brute-force-attack-on-a-cpanel-server\/","title":{"rendered":"How to Stop WordPress wp-login.php Brute Force Attack on a cPanel Server"},"content":{"rendered":"<p><span style=\"color: #000000;\">We are\u00a0seeing a lot of WordPress wp-login.php brute force attack these days. In this tutorial I will explain how to stop wp-login.php attack on a cPanel server.You can also simply install any WordPress<\/span> <a href=\"https:\/\/cpanelplesk.com\/wp62\/tips-for-wordpress-website-security\/\">security plugin<\/a>\u00a0<span style=\"color: #000000;\">to stop brute force attack.<\/span><!--more--><\/p>\n<p><span style=\"color: #000000;\">If your server hosts numerous WordPress websites, then in some cases its not possible to install a WordPress security plugins on every WordPress website. Here is how you can protect your server from wp-login.php brute force attack.<\/span><\/p>\n<ol>\n<li><strong><a href=\"https:\/\/cpanelplesk.com\/wp62\/install-modsecurity-and-get-it-running-in-linux-centosrhel-with-apache\/\">Mod Security<\/a> Apache Module<\/strong>: If you do not have mod_security Apache module installed on the server, run Easy Apache from WHM with mod_security selected.<\/li>\n<li>Installed <a href=\"https:\/\/cpanelplesk.com\/wp62\/how-to-install-csf-firewall-on-cpanel-server\/\">ConfigServer Firewall<\/a> on the server.<\/li>\n<\/ol>\n<p><strong>Mod Security Configuration:<\/strong><\/p>\n<p>Login to your WHM server as an\u00a0root user.<\/p>\n<p>Navigate to:<\/p>\n<div class=\"command-sh\">\n<pre class=\"lang:default decode:true \">WHM Home &gt;&gt; Plugins &gt;&gt; Mod Security<\/pre>\n<\/div>\n<p>Click <strong>Edit Config<\/strong> button located at top. This will open Mod_Security configuration page.<\/p>\n<p>Add below code at the bottom of page and click <strong>Save Configuration<\/strong> button.<\/p>\n<div class=\"command-sh\">\n<pre class=\"lang:default decode:true\"># Start wp-login.php brute attack\r\nSecUploadDir \/tmp\r\nSecTmpDir \/tmp\r\nSecDataDir \/tmp\r\n \r\nSecRequestBodyAccess On\r\n\r\nSecAction phase:1,nolog,pass,initcol:ip=%{REMOTE_ADDR},initcol:\r\nuser=%{REMOTE_ADDR},id:5000134\r\n&lt;Locationmatch \"\/wp-login.php\"&gt;\r\n    SecRule user:bf_block \"@gt 0\" \"deny,status:401,log,id:5000135,msg:\r\n'IP address blocked for 20 minutes, more than 3 login attempts in 10 \r\nminutes.'\"\r\n        \r\n    SecRule RESPONSE_STATUS \"^302\" \"phase:5,t:none,nolog,pass,setvar:\r\nip.bf_counter=0,id:5000136\"\r\n        \r\n    SecRule RESPONSE_STATUS \"^200\" \"phase:5,chain,t:none,nolog,pass,\r\nsetvar:ip.bf_counter=+1,deprecatevar:ip.bf_counter=1\/600,id:5000137\"\r\n        \r\n    SecRule ip:bf_counter \"@gt 3\" \"t:none,setvar:user.bf_block=1,\r\nexpirevar:user.bf_block=1200,setvar:ip.bf_counter=0\"\r\n&lt;\/locationmatch&gt;\r\nErrorDocument 401 default\r\n# End wp-login.php brute attack<\/pre>\n<\/div>\n<p>Now Navigate to:<\/p>\n<div class=\"command-sh\">\n<pre class=\"lang:default decode:true \">WHM Home &gt;&gt; Plugins &gt;&gt; ConfigServer Security &amp; Firewall<\/pre>\n<\/div>\n<p>Click <strong>Firewall Configuration<\/strong> button. Now in configuration page set value of <strong>LF_MODSEC<\/strong> to <strong>5<\/strong><\/p>\n<p>Restart CSF Firewall.<\/p>\n<p>Done!<\/p>\n","protected":false},"excerpt":{"rendered":"<p>We are\u00a0seeing a lot of WordPress wp-login.php brute force attack these days. In this tutorial I will explain how to stop wp-login.php attack on a cPanel server.You can also simply install any WordPress security plugin\u00a0to stop brute force attack. [&#8230;]<\/p>\n<p><a class=\"understrap-read-more-link\" href=\"https:\/\/cpanelplesk.com\/wp62\/how-to-stop-wordpress-wp-login-php-brute-force-attack-on-a-cpanel-server\/\">Continue Reading&#8230;<\/a><\/p>\n","protected":false},"author":1,"featured_media":2368,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1,13],"tags":[],"class_list":["post-3275","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-cpanel","category-wordpress"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v24.1 - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<title>How to Stop WordPress wp-login.php Brute Force Attack on a cPanel Server - cPanel Plesk<\/title>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/cpanelplesk.com\/wp62\/how-to-stop-wordpress-wp-login-php-brute-force-attack-on-a-cpanel-server\/\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:title\" content=\"How to Stop WordPress wp-login.php Brute Force Attack on a cPanel Server - cPanel Plesk\" \/>\n<meta name=\"twitter:description\" content=\"We are\u00a0seeing a lot of WordPress wp-login.php brute force attack these days. In this tutorial I will explain how to stop wp-login.php attack on a cPanel server.You can also simply install any WordPress security plugin\u00a0to stop brute force attack. [...]Continue Reading...\" \/>\n<meta name=\"twitter:image\" content=\"https:\/\/cpanelplesk.com\/wp62\/wp-content\/uploads\/2015\/06\/wordpress-e1449568977205.jpg\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"Farooq Omer\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"2 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\/\/cpanelplesk.com\/wp62\/how-to-stop-wordpress-wp-login-php-brute-force-attack-on-a-cpanel-server\/#article\",\"isPartOf\":{\"@id\":\"https:\/\/cpanelplesk.com\/wp62\/how-to-stop-wordpress-wp-login-php-brute-force-attack-on-a-cpanel-server\/\"},\"author\":{\"name\":\"Farooq Omer\",\"@id\":\"https:\/\/cpanelplesk.com\/wp62\/#\/schema\/person\/c78ae1cf9451a09592fb9697d69c0c13\"},\"headline\":\"How to Stop WordPress wp-login.php Brute Force Attack on a cPanel Server\",\"datePublished\":\"2015-12-22T07:56:25+00:00\",\"dateModified\":\"2021-02-06T10:58:27+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\/\/cpanelplesk.com\/wp62\/how-to-stop-wordpress-wp-login-php-brute-force-attack-on-a-cpanel-server\/\"},\"wordCount\":189,\"commentCount\":2,\"publisher\":{\"@id\":\"https:\/\/cpanelplesk.com\/wp62\/#\/schema\/person\/c78ae1cf9451a09592fb9697d69c0c13\"},\"image\":{\"@id\":\"https:\/\/cpanelplesk.com\/wp62\/how-to-stop-wordpress-wp-login-php-brute-force-attack-on-a-cpanel-server\/#primaryimage\"},\"thumbnailUrl\":\"https:\/\/cpanelplesk.com\/wp62\/wp-content\/uploads\/2015\/06\/wordpress-e1449568977205.jpg\",\"articleSection\":[\"Cpanel\",\"WordPress\"],\"inLanguage\":\"en-US\"},{\"@type\":\"WebPage\",\"@id\":\"https:\/\/cpanelplesk.com\/wp62\/how-to-stop-wordpress-wp-login-php-brute-force-attack-on-a-cpanel-server\/\",\"url\":\"https:\/\/cpanelplesk.com\/wp62\/how-to-stop-wordpress-wp-login-php-brute-force-attack-on-a-cpanel-server\/\",\"name\":\"How to Stop WordPress wp-login.php Brute Force Attack on a cPanel Server - cPanel Plesk\",\"isPartOf\":{\"@id\":\"https:\/\/cpanelplesk.com\/wp62\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\/\/cpanelplesk.com\/wp62\/how-to-stop-wordpress-wp-login-php-brute-force-attack-on-a-cpanel-server\/#primaryimage\"},\"image\":{\"@id\":\"https:\/\/cpanelplesk.com\/wp62\/how-to-stop-wordpress-wp-login-php-brute-force-attack-on-a-cpanel-server\/#primaryimage\"},\"thumbnailUrl\":\"https:\/\/cpanelplesk.com\/wp62\/wp-content\/uploads\/2015\/06\/wordpress-e1449568977205.jpg\",\"datePublished\":\"2015-12-22T07:56:25+00:00\",\"dateModified\":\"2021-02-06T10:58:27+00:00\",\"breadcrumb\":{\"@id\":\"https:\/\/cpanelplesk.com\/wp62\/how-to-stop-wordpress-wp-login-php-brute-force-attack-on-a-cpanel-server\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/cpanelplesk.com\/wp62\/how-to-stop-wordpress-wp-login-php-brute-force-attack-on-a-cpanel-server\/\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/cpanelplesk.com\/wp62\/how-to-stop-wordpress-wp-login-php-brute-force-attack-on-a-cpanel-server\/#primaryimage\",\"url\":\"https:\/\/cpanelplesk.com\/wp62\/wp-content\/uploads\/2015\/06\/wordpress-e1449568977205.jpg\",\"contentUrl\":\"https:\/\/cpanelplesk.com\/wp62\/wp-content\/uploads\/2015\/06\/wordpress-e1449568977205.jpg\",\"width\":200,\"height\":200},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/cpanelplesk.com\/wp62\/how-to-stop-wordpress-wp-login-php-brute-force-attack-on-a-cpanel-server\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\/\/cpanelplesk.com\/wp62\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"How to Stop WordPress wp-login.php Brute Force Attack on a cPanel Server\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/cpanelplesk.com\/wp62\/#website\",\"url\":\"https:\/\/cpanelplesk.com\/wp62\/\",\"name\":\"cPanel Plesk\",\"description\":\"Blog on famous hosting control panels\",\"publisher\":{\"@id\":\"https:\/\/cpanelplesk.com\/wp62\/#\/schema\/person\/c78ae1cf9451a09592fb9697d69c0c13\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/cpanelplesk.com\/wp62\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":[\"Person\",\"Organization\"],\"@id\":\"https:\/\/cpanelplesk.com\/wp62\/#\/schema\/person\/c78ae1cf9451a09592fb9697d69c0c13\",\"name\":\"Farooq Omer\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/cpanelplesk.com\/wp62\/#\/schema\/person\/image\/\",\"url\":\"https:\/\/cpanelplesk.com\/wp62\/wp-content\/uploads\/2020\/11\/cpanelplesk.png\",\"contentUrl\":\"https:\/\/cpanelplesk.com\/wp62\/wp-content\/uploads\/2020\/11\/cpanelplesk.png\",\"width\":300,\"height\":44,\"caption\":\"Farooq Omer\"},\"logo\":{\"@id\":\"https:\/\/cpanelplesk.com\/wp62\/#\/schema\/person\/image\/\"},\"url\":\"https:\/\/cpanelplesk.com\/wp62\/author\/fokado\/\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"How to Stop WordPress wp-login.php Brute Force Attack on a cPanel Server - cPanel Plesk","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:\/\/cpanelplesk.com\/wp62\/how-to-stop-wordpress-wp-login-php-brute-force-attack-on-a-cpanel-server\/","twitter_card":"summary_large_image","twitter_title":"How to Stop WordPress wp-login.php Brute Force Attack on a cPanel Server - cPanel Plesk","twitter_description":"We are\u00a0seeing a lot of WordPress wp-login.php brute force attack these days. In this tutorial I will explain how to stop wp-login.php attack on a cPanel server.You can also simply install any WordPress security plugin\u00a0to stop brute force attack. [...]Continue Reading...","twitter_image":"https:\/\/cpanelplesk.com\/wp62\/wp-content\/uploads\/2015\/06\/wordpress-e1449568977205.jpg","twitter_misc":{"Written by":"Farooq Omer","Est. reading time":"2 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/cpanelplesk.com\/wp62\/how-to-stop-wordpress-wp-login-php-brute-force-attack-on-a-cpanel-server\/#article","isPartOf":{"@id":"https:\/\/cpanelplesk.com\/wp62\/how-to-stop-wordpress-wp-login-php-brute-force-attack-on-a-cpanel-server\/"},"author":{"name":"Farooq Omer","@id":"https:\/\/cpanelplesk.com\/wp62\/#\/schema\/person\/c78ae1cf9451a09592fb9697d69c0c13"},"headline":"How to Stop WordPress wp-login.php Brute Force Attack on a cPanel Server","datePublished":"2015-12-22T07:56:25+00:00","dateModified":"2021-02-06T10:58:27+00:00","mainEntityOfPage":{"@id":"https:\/\/cpanelplesk.com\/wp62\/how-to-stop-wordpress-wp-login-php-brute-force-attack-on-a-cpanel-server\/"},"wordCount":189,"commentCount":2,"publisher":{"@id":"https:\/\/cpanelplesk.com\/wp62\/#\/schema\/person\/c78ae1cf9451a09592fb9697d69c0c13"},"image":{"@id":"https:\/\/cpanelplesk.com\/wp62\/how-to-stop-wordpress-wp-login-php-brute-force-attack-on-a-cpanel-server\/#primaryimage"},"thumbnailUrl":"https:\/\/cpanelplesk.com\/wp62\/wp-content\/uploads\/2015\/06\/wordpress-e1449568977205.jpg","articleSection":["Cpanel","WordPress"],"inLanguage":"en-US"},{"@type":"WebPage","@id":"https:\/\/cpanelplesk.com\/wp62\/how-to-stop-wordpress-wp-login-php-brute-force-attack-on-a-cpanel-server\/","url":"https:\/\/cpanelplesk.com\/wp62\/how-to-stop-wordpress-wp-login-php-brute-force-attack-on-a-cpanel-server\/","name":"How to Stop WordPress wp-login.php Brute Force Attack on a cPanel Server - cPanel Plesk","isPartOf":{"@id":"https:\/\/cpanelplesk.com\/wp62\/#website"},"primaryImageOfPage":{"@id":"https:\/\/cpanelplesk.com\/wp62\/how-to-stop-wordpress-wp-login-php-brute-force-attack-on-a-cpanel-server\/#primaryimage"},"image":{"@id":"https:\/\/cpanelplesk.com\/wp62\/how-to-stop-wordpress-wp-login-php-brute-force-attack-on-a-cpanel-server\/#primaryimage"},"thumbnailUrl":"https:\/\/cpanelplesk.com\/wp62\/wp-content\/uploads\/2015\/06\/wordpress-e1449568977205.jpg","datePublished":"2015-12-22T07:56:25+00:00","dateModified":"2021-02-06T10:58:27+00:00","breadcrumb":{"@id":"https:\/\/cpanelplesk.com\/wp62\/how-to-stop-wordpress-wp-login-php-brute-force-attack-on-a-cpanel-server\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/cpanelplesk.com\/wp62\/how-to-stop-wordpress-wp-login-php-brute-force-attack-on-a-cpanel-server\/"]}]},{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/cpanelplesk.com\/wp62\/how-to-stop-wordpress-wp-login-php-brute-force-attack-on-a-cpanel-server\/#primaryimage","url":"https:\/\/cpanelplesk.com\/wp62\/wp-content\/uploads\/2015\/06\/wordpress-e1449568977205.jpg","contentUrl":"https:\/\/cpanelplesk.com\/wp62\/wp-content\/uploads\/2015\/06\/wordpress-e1449568977205.jpg","width":200,"height":200},{"@type":"BreadcrumbList","@id":"https:\/\/cpanelplesk.com\/wp62\/how-to-stop-wordpress-wp-login-php-brute-force-attack-on-a-cpanel-server\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/cpanelplesk.com\/wp62\/"},{"@type":"ListItem","position":2,"name":"How to Stop WordPress wp-login.php Brute Force Attack on a cPanel Server"}]},{"@type":"WebSite","@id":"https:\/\/cpanelplesk.com\/wp62\/#website","url":"https:\/\/cpanelplesk.com\/wp62\/","name":"cPanel Plesk","description":"Blog on famous hosting control panels","publisher":{"@id":"https:\/\/cpanelplesk.com\/wp62\/#\/schema\/person\/c78ae1cf9451a09592fb9697d69c0c13"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/cpanelplesk.com\/wp62\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":["Person","Organization"],"@id":"https:\/\/cpanelplesk.com\/wp62\/#\/schema\/person\/c78ae1cf9451a09592fb9697d69c0c13","name":"Farooq Omer","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/cpanelplesk.com\/wp62\/#\/schema\/person\/image\/","url":"https:\/\/cpanelplesk.com\/wp62\/wp-content\/uploads\/2020\/11\/cpanelplesk.png","contentUrl":"https:\/\/cpanelplesk.com\/wp62\/wp-content\/uploads\/2020\/11\/cpanelplesk.png","width":300,"height":44,"caption":"Farooq Omer"},"logo":{"@id":"https:\/\/cpanelplesk.com\/wp62\/#\/schema\/person\/image\/"},"url":"https:\/\/cpanelplesk.com\/wp62\/author\/fokado\/"}]}},"_links":{"self":[{"href":"https:\/\/cpanelplesk.com\/wp62\/wp-json\/wp\/v2\/posts\/3275","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/cpanelplesk.com\/wp62\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/cpanelplesk.com\/wp62\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/cpanelplesk.com\/wp62\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/cpanelplesk.com\/wp62\/wp-json\/wp\/v2\/comments?post=3275"}],"version-history":[{"count":0,"href":"https:\/\/cpanelplesk.com\/wp62\/wp-json\/wp\/v2\/posts\/3275\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/cpanelplesk.com\/wp62\/wp-json\/wp\/v2\/media\/2368"}],"wp:attachment":[{"href":"https:\/\/cpanelplesk.com\/wp62\/wp-json\/wp\/v2\/media?parent=3275"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/cpanelplesk.com\/wp62\/wp-json\/wp\/v2\/categories?post=3275"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/cpanelplesk.com\/wp62\/wp-json\/wp\/v2\/tags?post=3275"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}