FRIHOST FORUMS SEARCH FAQ TOS BLOGS COMPETITIONS
You are invited to Log in or Register a free Frihost Account!


Little Filter [ANTI-HACKER]





Xendromn
This filter will doubtfuly do any good to forum systems.
However, if you have a custom website and you want to feel a little more safe you should use it:

Inside your index.php or even config.php add this line somewhere at the top:
Code:
require('filter.php');


Afterwards make a new file named filter.php with the following code:
Code:
<?php

$request = $_SERVER['REQUEST_URI'];

if (ereg('%00', $request)) {
exit('<center>(%00) - NULL BYTE Detected.<br>
</center>');
}

if (eregi('http://|https://|ftp://', $request)) {
exit('<center>Remote File Inclusion Attack Detected.<br>
</center>');
}

///This is aa somewhat sensetive filter. Make sure none of your files or options are named "union" or "table". Or else remove this block of code.
if (eregi('union|table', $request)) {
exit('<center>Your Request Contained Charcter(s) Which Will Trigger This Message.<br>
This Was Done To Ensure Better Security.<br>
If You Think That You Have Done Nothing Wrong, Please Report This Issue To The Admins.<br>
Thank You.</center>');
}
?>


Now, stupid script kiddies won't bother you.
However it can't save you from real hackers, nothing can Sad
Good luck.
Related topics
Do this little to protect your MS Windows.
Help with Firewall and Antivirus
Quel antivirus utilisez vous ?
Nvidia Firewall.. Any good??
Help for antispyware...
Cybot's Work
[soft] Cual es el mejor Antivirus ?
How to Protect ur windows System
Kaspersky Internet Security 2006 (Beta)
Quel firewall (pare-feu) utilisez-vous ?
Frihost web hosting features you wish in the second year
about network program
What Grapics Card to Get
To be a hacker is a great career!
Reply to topic    Frihost Forum Index -> Scripting -> Php and MySQL

FRIHOST HOME | FAQ | TOS | ABOUT US | CONTACT US | SITE MAP
© 2005-2011 Frihost, forums powered by phpBB.