Mar 27, 2015 08:56 AM
(This post was last modified: Mar 28, 2015 06:53 AM by Private Network.)
Information: http://community.mybb.com/thread-44977.html
Extra Secure: http://community.mybb.com/thread-131553.html
MyBB is ofcourse very secure, but it can still be hacked because of laziness...
This will teach you BASIC MyBB protection.
1. Admin Directory
Anyone should know that it is very important to rename the administator directory...
If they can't find it how should they hack it.
Go to your filehost and then find the folder called "admin" and change the name to something else not obvious like "administrator"...
Then, search for the config.php file in the "inc" directory.
Look for this code:
And change the 'admin' part to the name you changed the directory to.
2. .htaccess
Renaming the directory is not enough to fully stop it.
This code will check the users IP that is trying to acces the admin page.
Create a .htaccess file in your administrator folder and add this code:
Change the "12\.345\.678\.9" to your IP address with the format and change the "http://www.mybbwebhost.com" to the URL you want them to be redirected.
If you have more admin's then add this code instead:
Change the "123.45.67.899" and "998.76.54.321" to your IP addresses, if you have more add more lines.
And ofcourse change the "http://www.mybbwebhost.com" to the URL you want them to be redirected.
3. Deny externall config access
Create a .htacces file in your "inc" folder and add this code:
This will deny any EXTERNALL access, the forums will still run normally.
Extra Secure: http://community.mybb.com/thread-131553.html
MyBB is ofcourse very secure, but it can still be hacked because of laziness...
This will teach you BASIC MyBB protection.
1. Admin Directory
Anyone should know that it is very important to rename the administator directory...
If they can't find it how should they hack it.
Go to your filehost and then find the folder called "admin" and change the name to something else not obvious like "administrator"...
Then, search for the config.php file in the "inc" directory.
Look for this code:
Code
/**
* Admin CP directory
* For security reasons, it is recommended you
* rename your Admin CP directory. You then need
* to adjust the value below to point to the
* new directory.
*/
$config['admin_dir'] = 'admin';And change the 'admin' part to the name you changed the directory to.
2. .htaccess
Renaming the directory is not enough to fully stop it.
This code will check the users IP that is trying to acces the admin page.
Create a .htaccess file in your administrator folder and add this code:
Code
RewriteEngine On
RewriteBase /
RewriteCond %{REMOTE_HOST} !^12\.345\.678\.9
RewriteRule .* http://www.mybbwebhost.com [R=301,L]Change the "12\.345\.678\.9" to your IP address with the format and change the "http://www.mybbwebhost.com" to the URL you want them to be redirected.
If you have more admin's then add this code instead:
Code
ErrorDocument 403 http://www.mybbwebhost.com
Order deny,allow
Deny from all
Allow from 123.45.67.899
Allow from 998.76.54.321Change the "123.45.67.899" and "998.76.54.321" to your IP addresses, if you have more add more lines.
And ofcourse change the "http://www.mybbwebhost.com" to the URL you want them to be redirected.
3. Deny externall config access
Create a .htacces file in your "inc" folder and add this code:
Code
<files config.php>
Order deny,allow
deny from all
</files>This will deny any EXTERNALL access, the forums will still run normally.





![[Image: ux8AIrU.png]](https://i.imgur.com/ux8AIrU.png)
![[Image: Go9NL9v.png]](https://i.imgur.com/Go9NL9v.png)