This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
### Start Security Rules | |
# Stop spam attack logins and comments | |
<IfModule mod_rewrite.c> | |
RewriteEngine On | |
RewriteCond %{REQUEST_METHOD} POST | |
RewriteCond %{REQUEST_URI} .(wp-comments-post|wp-login)\.php* | |
RewriteCond %{HTTP_REFERER} !.*(example.ubc.ca|.ubc.ca).* [OR] | |
RewriteCond %{HTTP_USER_AGENT} ^$ | |
RewriteRule (.*) http://0.0.0.0/$ [R=301,L] | |
</ifModule> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
mysqldump -u root -pPASSWORD DATABASENAME `echo "show tables like 'TABLEPREFIX_%';" | mysql -u root -pPASSWORD DATABASENAME | sed '/Tables_in/d'` > db.dump |