kazeuraki

iThemes Security

Nov 19th, 2017
206
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 12.59 KB | None | 0 0
  1. # BEGIN iThemes Security - Do not modify or remove this line
  2. # iThemes Security Config Details: 2
  3. # Enable HackRepair.com's blacklist feature - Security > Settings > Banned Users > Default Blacklist
  4. # Start HackRepair.com Blacklist
  5. # Start Abuse Agent Blocking
  6. if ($http_user_agent ~* "^Mozilla.*Indy"){return 403;}
  7. if ($http_user_agent ~* "^Mozilla.*NEWT"){return 403;}
  8. if ($http_user_agent ~* "^$"){return 403;}
  9. if ($http_user_agent ~* "^Maxthon$"){return 403;}
  10. if ($http_user_agent ~* "^SeaMonkey$"){return 403;}
  11. if ($http_user_agent ~* "^Acunetix"){return 403;}
  12. if ($http_user_agent ~* "^binlar"){return 403;}
  13. if ($http_user_agent ~* "^BlackWidow"){return 403;}
  14. if ($http_user_agent ~* "^Bolt 0"){return 403;}
  15. if ($http_user_agent ~* "^BOT for JCE"){return 403;}
  16. if ($http_user_agent ~* "^Bot mailto\:craftbot@yahoo\.com"){return 403;}
  17. if ($http_user_agent ~* "^casper"){return 403;}
  18. if ($http_user_agent ~* "^checkprivacy"){return 403;}
  19. if ($http_user_agent ~* "^ChinaClaw"){return 403;}
  20. if ($http_user_agent ~* "^clshttp"){return 403;}
  21. if ($http_user_agent ~* "^cmsworldmap"){return 403;}
  22. if ($http_user_agent ~* "^Custo"){return 403;}
  23. if ($http_user_agent ~* "^Default Browser 0"){return 403;}
  24. if ($http_user_agent ~* "^diavol"){return 403;}
  25. if ($http_user_agent ~* "^DIIbot"){return 403;}
  26. if ($http_user_agent ~* "^DISCo"){return 403;}
  27. if ($http_user_agent ~* "^dotbot"){return 403;}
  28. if ($http_user_agent ~* "^Download Demon"){return 403;}
  29. if ($http_user_agent ~* "^eCatch"){return 403;}
  30. if ($http_user_agent ~* "^EirGrabber"){return 403;}
  31. if ($http_user_agent ~* "^EmailCollector"){return 403;}
  32. if ($http_user_agent ~* "^EmailSiphon"){return 403;}
  33. if ($http_user_agent ~* "^EmailWolf"){return 403;}
  34. if ($http_user_agent ~* "^Express WebPictures"){return 403;}
  35. if ($http_user_agent ~* "^extract"){return 403;}
  36. if ($http_user_agent ~* "^ExtractorPro"){return 403;}
  37. if ($http_user_agent ~* "^EyeNetIE"){return 403;}
  38. if ($http_user_agent ~* "^feedfinder"){return 403;}
  39. if ($http_user_agent ~* "^FHscan"){return 403;}
  40. if ($http_user_agent ~* "^FlashGet"){return 403;}
  41. if ($http_user_agent ~* "^flicky"){return 403;}
  42. if ($http_user_agent ~* "^g00g1e"){return 403;}
  43. if ($http_user_agent ~* "^GetRight"){return 403;}
  44. if ($http_user_agent ~* "^GetWeb\!"){return 403;}
  45. if ($http_user_agent ~* "^Go\!Zilla"){return 403;}
  46. if ($http_user_agent ~* "^Go\-Ahead\-Got\-It"){return 403;}
  47. if ($http_user_agent ~* "^grab"){return 403;}
  48. if ($http_user_agent ~* "^GrabNet"){return 403;}
  49. if ($http_user_agent ~* "^Grafula"){return 403;}
  50. if ($http_user_agent ~* "^harvest"){return 403;}
  51. if ($http_user_agent ~* "^HMView"){return 403;}
  52. if ($http_user_agent ~* "^Image Stripper"){return 403;}
  53. if ($http_user_agent ~* "^Image Sucker"){return 403;}
  54. if ($http_user_agent ~* "^InterGET"){return 403;}
  55. if ($http_user_agent ~* "^Internet Ninja"){return 403;}
  56. if ($http_user_agent ~* "^InternetSeer\.com"){return 403;}
  57. if ($http_user_agent ~* "^jakarta"){return 403;}
  58. if ($http_user_agent ~* "^Java"){return 403;}
  59. if ($http_user_agent ~* "^JetCar"){return 403;}
  60. if ($http_user_agent ~* "^JOC Web Spider"){return 403;}
  61. if ($http_user_agent ~* "^kanagawa"){return 403;}
  62. if ($http_user_agent ~* "^kmccrew"){return 403;}
  63. if ($http_user_agent ~* "^larbin"){return 403;}
  64. if ($http_user_agent ~* "^LeechFTP"){return 403;}
  65. if ($http_user_agent ~* "^libwww"){return 403;}
  66. if ($http_user_agent ~* "^Mass Downloader"){return 403;}
  67. if ($http_user_agent ~* "^microsoft\.url"){return 403;}
  68. if ($http_user_agent ~* "^MIDown tool"){return 403;}
  69. if ($http_user_agent ~* "^miner"){return 403;}
  70. if ($http_user_agent ~* "^Mister PiX"){return 403;}
  71. if ($http_user_agent ~* "^MSFrontPage"){return 403;}
  72. if ($http_user_agent ~* "^Navroad"){return 403;}
  73. if ($http_user_agent ~* "^NearSite"){return 403;}
  74. if ($http_user_agent ~* "^Net Vampire"){return 403;}
  75. if ($http_user_agent ~* "^NetAnts"){return 403;}
  76. if ($http_user_agent ~* "^NetSpider"){return 403;}
  77. if ($http_user_agent ~* "^NetZIP"){return 403;}
  78. if ($http_user_agent ~* "^nutch"){return 403;}
  79. if ($http_user_agent ~* "^Octopus"){return 403;}
  80. if ($http_user_agent ~* "^Offline Explorer"){return 403;}
  81. if ($http_user_agent ~* "^Offline Navigator"){return 403;}
  82. if ($http_user_agent ~* "^PageGrabber"){return 403;}
  83. if ($http_user_agent ~* "^Papa Foto"){return 403;}
  84. if ($http_user_agent ~* "^pavuk"){return 403;}
  85. if ($http_user_agent ~* "^pcBrowser"){return 403;}
  86. if ($http_user_agent ~* "^PeoplePal"){return 403;}
  87. if ($http_user_agent ~* "^planetwork"){return 403;}
  88. if ($http_user_agent ~* "^psbot"){return 403;}
  89. if ($http_user_agent ~* "^purebot"){return 403;}
  90. if ($http_user_agent ~* "^pycurl"){return 403;}
  91. if ($http_user_agent ~* "^RealDownload"){return 403;}
  92. if ($http_user_agent ~* "^ReGet"){return 403;}
  93. if ($http_user_agent ~* "^Rippers 0"){return 403;}
  94. if ($http_user_agent ~* "^sitecheck\.internetseer\.com"){return 403;}
  95. if ($http_user_agent ~* "^SiteSnagger"){return 403;}
  96. if ($http_user_agent ~* "^skygrid"){return 403;}
  97. if ($http_user_agent ~* "^SmartDownload"){return 403;}
  98. if ($http_user_agent ~* "^sucker"){return 403;}
  99. if ($http_user_agent ~* "^SuperBot"){return 403;}
  100. if ($http_user_agent ~* "^SuperHTTP"){return 403;}
  101. if ($http_user_agent ~* "^Surfbot"){return 403;}
  102. if ($http_user_agent ~* "^tAkeOut"){return 403;}
  103. if ($http_user_agent ~* "^Teleport Pro"){return 403;}
  104. if ($http_user_agent ~* "^Toata dragostea mea pentru diavola"){return 403;}
  105. if ($http_user_agent ~* "^turnit"){return 403;}
  106. if ($http_user_agent ~* "^vikspider"){return 403;}
  107. if ($http_user_agent ~* "^VoidEYE"){return 403;}
  108. if ($http_user_agent ~* "^Web Image Collector"){return 403;}
  109. if ($http_user_agent ~* "^WebAuto"){return 403;}
  110. if ($http_user_agent ~* "^WebBandit"){return 403;}
  111. if ($http_user_agent ~* "^WebCopier"){return 403;}
  112. if ($http_user_agent ~* "^WebFetch"){return 403;}
  113. if ($http_user_agent ~* "^WebGo IS"){return 403;}
  114. if ($http_user_agent ~* "^WebLeacher"){return 403;}
  115. if ($http_user_agent ~* "^WebReaper"){return 403;}
  116. if ($http_user_agent ~* "^WebSauger"){return 403;}
  117. if ($http_user_agent ~* "^Website eXtractor"){return 403;}
  118. if ($http_user_agent ~* "^Website Quester"){return 403;}
  119. if ($http_user_agent ~* "^WebStripper"){return 403;}
  120. if ($http_user_agent ~* "^WebWhacker"){return 403;}
  121. if ($http_user_agent ~* "^WebZIP"){return 403;}
  122. if ($http_user_agent ~* "^Widow"){return 403;}
  123. if ($http_user_agent ~* "^WPScan"){return 403;}
  124. if ($http_user_agent ~* "^WWW\-Mechanize"){return 403;}
  125. if ($http_user_agent ~* "^WWWOFFLE"){return 403;}
  126. if ($http_user_agent ~* "^Xaldon WebSpider"){return 403;}
  127. if ($http_user_agent ~* "^Zeus"){return 403;}
  128. if ($http_user_agent ~* "^zmeu"){return 403;}
  129. if ($http_user_agent ~* "360Spider"){return 403;}
  130. if ($http_user_agent ~* "CazoodleBot"){return 403;}
  131. if ($http_user_agent ~* "discobot"){return 403;}
  132. if ($http_user_agent ~* "EasouSpider"){return 403;}
  133. if ($http_user_agent ~* "ecxi"){return 403;}
  134. if ($http_user_agent ~* "GT\:\:WWW"){return 403;}
  135. if ($http_user_agent ~* "heritrix"){return 403;}
  136. if ($http_user_agent ~* "HTTP\:\:Lite"){return 403;}
  137. if ($http_user_agent ~* "HTTrack"){return 403;}
  138. if ($http_user_agent ~* "ia_archiver"){return 403;}
  139. if ($http_user_agent ~* "id\-search"){return 403;}
  140. if ($http_user_agent ~* "IDBot"){return 403;}
  141. if ($http_user_agent ~* "Indy Library"){return 403;}
  142. if ($http_user_agent ~* "IRLbot"){return 403;}
  143. if ($http_user_agent ~* "ISC Systems iRc Search 2\.1"){return 403;}
  144. if ($http_user_agent ~* "LinksCrawler"){return 403;}
  145. if ($http_user_agent ~* "LinksManager\.com_bot"){return 403;}
  146. if ($http_user_agent ~* "linkwalker"){return 403;}
  147. if ($http_user_agent ~* "lwp\-trivial"){return 403;}
  148. if ($http_user_agent ~* "MFC_Tear_Sample"){return 403;}
  149. if ($http_user_agent ~* "Microsoft URL Control"){return 403;}
  150. if ($http_user_agent ~* "Missigua Locator"){return 403;}
  151. if ($http_user_agent ~* "MJ12bot"){return 403;}
  152. if ($http_user_agent ~* "panscient\.com"){return 403;}
  153. if ($http_user_agent ~* "PECL\:\:HTTP"){return 403;}
  154. if ($http_user_agent ~* "PHPCrawl"){return 403;}
  155. if ($http_user_agent ~* "PleaseCrawl"){return 403;}
  156. if ($http_user_agent ~* "SBIder"){return 403;}
  157. if ($http_user_agent ~* "SearchmetricsBot"){return 403;}
  158. if ($http_user_agent ~* "SeznamBot"){return 403;}
  159. if ($http_user_agent ~* "Snoopy"){return 403;}
  160. if ($http_user_agent ~* "Steeler"){return 403;}
  161. if ($http_user_agent ~* "URI\:\:Fetch"){return 403;}
  162. if ($http_user_agent ~* "urllib"){return 403;}
  163. if ($http_user_agent ~* "Web Sucker"){return 403;}
  164. if ($http_user_agent ~* "webalta"){return 403;}
  165. if ($http_user_agent ~* "WebCollage"){return 403;}
  166. if ($http_user_agent ~* "Wells Search II"){return 403;}
  167. if ($http_user_agent ~* "WEP Search"){return 403;}
  168. if ($http_user_agent ~* "XoviBot"){return 403;}
  169. if ($http_user_agent ~* "YisouSpider"){return 403;}
  170. if ($http_user_agent ~* "zermelo"){return 403;}
  171. if ($http_user_agent ~* "ZyBorg"){return 403;}
  172. # End Abuse Agent Blocking
  173. # Start Abuse HTTP Referrer Blocking
  174. if ($http_referer ~* "^https?://(?:[^/]+\.)?semalt\.com"){return 403;}
  175. if ($http_referer ~* "^https?://(?:[^/]+\.)?kambasoft\.com"){return 403;}
  176. if ($http_referer ~* "^https?://(?:[^/]+\.)?savetubevideo\.com"){return 403;}
  177. # End Abuse HTTP Referrer Blocking
  178. # End HackRepair.com Blacklist, http://pastebin.com/u/hackrepair
  179.  
  180. # Disable XML-RPC - Security > Settings > WordPress Tweaks > XML-RPC
  181. location ~ xmlrpc.php { deny all; }
  182.  
  183. # Protect System Files - Security > Settings > System Tweaks > System Files
  184. location = /wp-admin/install.php { deny all; }
  185. location = /nginx.conf { deny all; }
  186. location ~ /\.htaccess$ { deny all; }
  187. location ~ /readme\.html$ { deny all; }
  188. location ~ /readme\.txt$ { deny all; }
  189. location ~ /wp-config.php$ { deny all; }
  190. location ~ ^/wp-admin/includes/ { deny all; }
  191. location ~ ^/wp-includes/[^/]+\.php$ { deny all; }
  192. location ~ ^/wp-includes/js/tinymce/langs/.+\.php$ { deny all; }
  193. location ~ ^/wp-includes/theme-compat/ { deny all; }
  194.  
  195. # Disable PHP in Uploads - Security > Settings > System Tweaks > PHP in Uploads
  196. location ~ ^/wp\-content/uploads/.*\.(?:php[1-7]?|pht|phtml?|phps)$ { deny all; }
  197.  
  198. # Filter Request Methods - Security > Settings > System Tweaks > Request Methods
  199. if ( $request_method ~* ^(TRACE|DELETE|TRACK)$ ) { return 403; }
  200.  
  201. # Filter Suspicious Query Strings in the URL - Security > Settings > System Tweaks > Suspicious Query Strings
  202. set $susquery 0;
  203. if ( $args ~* "\.\./" ) { set $susquery 1; }
  204. if ( $args ~* "\.(bash|git|hg|log|svn|swp|cvs)" ) { set $susquery 1; }
  205. if ( $args ~* "etc/passwd" ) { set $susquery 1; }
  206. if ( $args ~* "boot\.ini" ) { set $susquery 1; }
  207. if ( $args ~* "ftp:" ) { set $susquery 1; }
  208. if ( $args ~* "https?:" ) { set $susquery 1; }
  209. if ( $args ~* "(<|%3C)script(>|%3E)" ) { set $susquery 1; }
  210. if ( $args ~* "mosConfig_[a-zA-Z_]{1,21}(=|%3D)" ) { set $susquery 1; }
  211. if ( $args ~* "base64_decode\(" ) { set $susquery 1; }
  212. if ( $args ~* "%24&x" ) { set $susquery 1; }
  213. if ( $args ~* "127\.0" ) { set $susquery 1; }
  214. if ( $args ~* "(globals|encode|localhost|loopback)" ) { set $susquery 1; }
  215. if ( $args ~* "(request|insert|concat|union|declare)" ) { set $susquery 1; }
  216. if ( $args ~* "%[01][0-9A-F]" ) { set $susquery 1; }
  217. if ( $args ~ "^loggedout=true" ) { set $susquery 0; }
  218. if ( $args ~ "^action=jetpack-sso" ) { set $susquery 0; }
  219. if ( $args ~ "^action=rp" ) { set $susquery 0; }
  220. if ( $http_cookie ~ "wordpress_logged_in_" ) { set $susquery 0; }
  221. if ( $http_referer ~* "^https?://maps\.googleapis\.com/" ) { set $susquery 0; }
  222. if ( $susquery = 1 ) { return 403; }
  223. # END iThemes Security - Do not modify or remove this line
  224.  
  225. # BEGIN W3TC Browser Cache
  226. gzip on;
  227. gzip_types text/css text/x-component application/x-javascript application/javascript text/javascript text/x-js text/richtext image/svg+xml text/plain text/xsd text/xsl text/xml image/bmp application/java application/msword application/vnd.ms-fontobject application/x-msdownload image/x-icon image/webp application/json application/vnd.ms-access application/vnd.ms-project application/x-font-otf application/vnd.ms-opentype application/vnd.oasis.opendocument.database application/vnd.oasis.opendocument.chart application/vnd.oasis.opendocument.formula application/vnd.oasis.opendocument.graphics application/vnd.oasis.opendocument.spreadsheet application/vnd.oasis.opendocument.text audio/ogg application/pdf application/vnd.ms-powerpoint application/x-shockwave-flash image/tiff application/x-font-ttf audio/wav application/vnd.ms-write application/font-woff application/font-woff2 application/vnd.ms-excel;
  228. # END W3TC Browser Cache
Add Comment
Please, Sign In to add comment