![]() |
|
|||||||
| Register | FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
![]() |
|
|
Thread Tools | Display Modes |
|
|
|
#1
|
|||
|
|||
|
following from this thread: http://www.indexscript.com/forum/showthread.php?t=2260 - i'm posting a consolidated fix in this thread for the sql injection security hole exploited today:
if you are using v2.8 and have not modified your utils.php file found in the include folder: 1. you can simply download the utils.php attached in this post for v2.8 and replace your existing one with it if you are using v2.7 and have not modified your utils.php file found in the include folder: 1. you can simply download the utils.php attached in this post for v2.7 and replace your existing one with it if you want to perform a manual replace: 1. open up your utils.php in the include folder 2. look for: Code:
function fnpreparesql($field) {
if(!get_magic_quotes_gpc()) {
return mysql_real_escape_string($field);
}
else {
return $field;
}
}
Code:
function fnpreparesql($field) {
if(get_magic_quotes_gpc()) {
$temp = stripslashes($field);
}
else {
$temp = $field;
}
if(stristr($temp, "dir_login")) {
$temp = "";
}
return mysql_real_escape_string($temp);
}
Code:
= " . $cat_id Code:
= " . fnpreparesql($cat_id) Code:
= " . $start_id Code:
= " . fnpreparesql($start_id) Code:
= " . $row['parent_id'] Code:
= " . fnpreparesql($row['parent_id']) Code:
= " . $row['cat_id'] Code:
= " . fnpreparesql($row['cat_id'])
__________________
Get your IndexScript skins HERE Some other interesting sites: Pneumococcal Diseases | Learn about Colic | Pregnancy Articles | Humor Portal Last edited by hakon : 07-26-2007 at 05:38 PM. Reason: consolidate fix into a single thread |
|
#2
|
|||
|
|||
|
Hi hakon, unfortunately this fix did not work for me has it made my sub categories unviewable....invalid fetch array argument in sql...
any suggestions? ![]() |
|
#3
|
||||
|
||||
|
Thanks Hakon. I have not been hacked but have replaced the new util file.
and all seems fineIs there anyway you can check if my directory is ok now The directory is The Web Directory Thanks
__________________
|
|
#4
|
||||
|
||||
|
Its working for me
![]() Rankappeal, i think that u have a older version of the script running as i have the same problem in one of my indexscript dirs Upgrading it right away
__________________
blog directory | business directory | free web directory ------------------------------------------------------ ~courtesy - IndexScript & IndexScript Support ~ suzuki bikes free online games directory blog |
|
#5
|
|||
|
|||
|
I found some info while searching about this exploit
Quote:
It was found on this page Quote:
I hope it could be of some help. I was trying to find "This site is powered by IndexScript" in google and got this. |
|
#6
|
||||
|
||||
|
Mine was hacked too....over 2000 urls gone, and 100+ categories..gone.
--<Hacked by y0n4s >-- Is what it says in the title header ![]() And I couldn't log in. Thanks for this fix Hakon
__________________
My sites: ~iWebzen Web Directory~~Watch Movies and TV episodes Free online~~ShadowLegacy~~[/url] |
|
#7
|
|||
|
|||
|
kiviniar ,
I am using V2.8 And I Just Got Hacked Again....Good job I Backed Up.. The Sod Made A Right Mess...Lol... I have changed databases and all passwords now ![]() |
|
#8
|
|||
|
|||
|
Quote:
Try reinstalling the cats table only from backup and see if the data is still there. Make a backup of the corrupt DB before you start, just in case. Of course they could have done anything the admin could do from the admin panel. Just depends on how much time they wanted to spend doing it.
__________________
Colbyt |
![]() |
| Thread Tools | |
| Display Modes | |
|
|