Web development part 3 - Creating Community with MyBB - part 3 (Security) Basic Security

Creating Community with MyBB - part 3 (Security) Basic Security



මචන්ලා. අද thread එකෙන් කියලා දෙන්න ඔයාගෙ  MyBB forum එක ආරක්ශා කරගන්නෙ කොහොමද කියලා. (Basic Security Methods)
MyBB forum Software එක ගත්තොත් Security පැත්තෙන් බැලුවමනම් දුර්වලයි. මෙ වගෙ පොඩි ක්‍රම පාවිච්චි කරලාවත් එක මගහැර ගන්න බලමු  ;)


MyBB Software Update

මුලින්ම කියන්න ඔනෙ MyBB එකෙ BUGs / Vulnerable තියනවා. එවා මග හැරගන්න Virsion Update කර ගන්න එකනම් අනිවාර්යයි. MyBB update කරන හැටි කලින් tut එකේ කතා කරා. Creating Community with MyBB - Part 2 (Update Guide)
Last Virson නම් තියෙන්නෙ එන්න තියෙන Attack වලින් පොඩ්ඩ පොඩ්ඩ හරි ආරක්ෂා වෙන්න පුලුවන්.


Hide MyBB Virson 

ඔයා පාවිච්චි කරන Virsion එක Hack කරන්න හොයන්න බැරිවෙන්න Forum එකේ Display වෙන එක නවත්තන්න ඔනේ. මොකද Virsion එකෙ හැටියටනේ ගෙම දෙන්න වෙන්නෙ

Virsion number එක Hide කරන්න මෙහෙම කරන්න.

Admin CP > Configuration > Settings > Site Details > Show Version Numbers > Off


Secret Pin for ACP

මෙකයි seen එක. කව්රැහරි එකෙක් Guest කරලා හරි වෙන විදියකට එහෙම Password එක හොයා ගත්තනම් උට log වෙන්න බැරිවෙන්න තව PIN එකක් දාලා තියන එක හොදයි.මෙක MyBB 1.8 තියෙන එකක්.

ඔයාගෙ root folder එකට ගිහින්
inc වල config.php එක open කරගන්න

දැන් මෙහෙ code එක ගහලා save කර ගන්න

$config['secret_pin'] = 'මෙතන PIN එක';


Dissallow Remote Adress

Private host හා ip adress වගෙ දෙවල් නවත්තන්න මෙහෙම කරන්න..
Root folder එකෙ inc වල config.php එකට මෙක දිලා save කරන්න.


/**
* Disallowed Remote Hosts
*  List of hosts the fetch_remote_file() function will not
*  perform requests to.
*  It is recommended that you enter hosts resolving to the
*  forum server here to prevent Server Side Request
*  Forgery attacks.
*/

$config['disallowed_remote_hosts'] = array(
'localhost',
);

/**
* Disallowed Remote Addresses
*  List of IPv4 addresses the fetch_remote_file() function
*  will not perform requests to.
*  It is recommended that you enter addresses resolving to
*  the forum server here to prevent Server Side Request
*  Forgery attacks.
*  Removing all values disables resolving hosts in that
*  function.
*/

$config['disallowed_remote_addresses'] = array(
'127.0.0.1',
'10.0.0.0/8',
'172.16.0.0/12',
'192.168.0.0/16',
'වෙනත්;
);

ඔයාට ඔනේ එවත් දාලා save කරන්න.


Security Acess Config.php


ඔයාගෙ config php එකට යන්න permisson තිබ්බට එවා හැම එකටම ඔරොත්තු දෙන්නෙ නැ. එක අනිත් අ⁣යගෙන් deny කරන්න ඔයාගෙ root folder එකෙ inc එක ඇතුලේ .htaccess එක open/creat කරලා මෙම දෙන්න.


# Protect the config.php file
Order deny,allow 
deny from all 

{/code}

දැන් save කරන්න.


හරි අපි මෙ කතා කරෙ MyBB forum එකක Basic Security ගැන. තව හුගක් දෙවල් තියෙනවා security නම්.මෙවා නම් අනිවාරෙන් දැනගෙන ඉන්න ඔනා දෙවල් තමයි.. ඊගාවට අපි බලමු Admin controll panel එක Security කර ගන්න හැටි.

එහෙනම් මම කැපෙනවා. Jaya|Sri..!!!

Comments