{"id":17,"date":"2023-03-30T00:04:31","date_gmt":"2023-03-30T00:04:31","guid":{"rendered":"https:\/\/mediadrive.ca\/docs\/?page_id=17"},"modified":"2023-10-19T20:55:51","modified_gmt":"2023-10-19T20:55:51","slug":"securing-wordpress","status":"publish","type":"post","link":"https:\/\/mediadrive.ca\/docs\/securing-wordpress\/","title":{"rendered":"Securing WordPress"},"content":{"rendered":"\n<p>These configuration options will block some of the more primitive brute force attacks on WordPress.<\/p>\n\n\n\n<p>Place them in an&nbsp;<code>.htaccess<\/code>&nbsp;file in the root of your website (<code>domains\/yourdomain.com\/public_html<\/code>).<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code># Block all access to `xmlrpc.php`.\n&lt;If \"%{REQUEST_URI} == '\/xmlrpc.php'\"&gt;\n    Require all denied\n&lt;\/If&gt;<\/code><\/pre>\n\n\n\n<pre class=\"wp-block-code\"><code># Block access form submissions to `wp-login.php` with an empty `Referer` header.\n&lt;If \"%{REQUEST_METHOD} == 'POST' &amp;&amp; %{REQUEST_URI} == '\/wp-login.php' &amp;&amp; %{HTTP_REFERER} == ''\"&gt;\n    Require all denied\n&lt;\/If&gt;<\/code><\/pre>\n\n\n\n<h2 class=\"wp-block-heading\">Denying Author Scans<\/h2>\n\n\n\n<p>Author scans are frequently a mechanism for determining a username to start bruce-forcing the password. Avoid this by blocking author scans.<\/p>\n\n\n\n<p>Place this inside a <code>.htaccess<\/code> file at the root of your website (domains\/yourdomain.com\/public_html).<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code># Block author scans\n&lt;IfModule mod_rewrite.c>\nRewriteEngine on\nRewriteBase \/\nRewriteCond %{QUERY_STRING} author=\\d+ &#91;NC]\nRewriteRule ^(.*)$ - &#91;F]\n&lt;\/IfModule><\/code><\/pre>\n","protected":false},"excerpt":{"rendered":"<p>These configuration options will block some of the more primitive brute force attacks on WordPress. Place them in an&nbsp;.htaccess&nbsp;file in the root of your website (domains\/yourdomain.com\/public_html). Denying Author Scans Author scans are frequently a mechanism for determining a username to start bruce-forcing the password. Avoid this by blocking author scans. Place this inside a .htaccess [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[9],"tags":[],"class_list":["post-17","post","type-post","status-publish","format-standard","hentry","category-other"],"_links":{"self":[{"href":"https:\/\/mediadrive.ca\/docs\/wp-json\/wp\/v2\/posts\/17","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/mediadrive.ca\/docs\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/mediadrive.ca\/docs\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/mediadrive.ca\/docs\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/mediadrive.ca\/docs\/wp-json\/wp\/v2\/comments?post=17"}],"version-history":[{"count":5,"href":"https:\/\/mediadrive.ca\/docs\/wp-json\/wp\/v2\/posts\/17\/revisions"}],"predecessor-version":[{"id":335,"href":"https:\/\/mediadrive.ca\/docs\/wp-json\/wp\/v2\/posts\/17\/revisions\/335"}],"wp:attachment":[{"href":"https:\/\/mediadrive.ca\/docs\/wp-json\/wp\/v2\/media?parent=17"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/mediadrive.ca\/docs\/wp-json\/wp\/v2\/categories?post=17"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/mediadrive.ca\/docs\/wp-json\/wp\/v2\/tags?post=17"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}