Post Pacific  

Go Back   Post Pacific > Восстановленный архив > Темы без сохранившегося раздела
FAQ Community Calendar Today's Posts Search

Notices

 
 
Thread Tools Search this Thread Display Modes
Old 24.12.2006, 16:19   #1
Phantom2005
Архивный участник
 
Join Date: Aug 2005
Posts: 394
Default L2CP Reborn.

Hello it's been a while since i last helped PP out.
And since there's some new exploit out for L2CP i'd like to share a new type of L2CP. I re-did L2CP in a better and optimized way.
And i'll even add more features later on.
Thanks to Doraemon or whoever started with this project.

And thanks to testdude for the injection fix + checkhash idea

Feel free to post bugs/questions/problems/suggestions, have fun.

v1.05
- Added a security code and added hash check.

v1.00
- New Style/New Way of fixing SQL Injection Exploit and some new features.

Preview:


Вложения из исходного сообщения (сами файлы в копии отсутствуют):
l2cpreborn.rar — 84146 байт
Phantom2005 is offline  
Old 24.12.2006, 16:29   #2
testdude
Архивный участник
 
Join Date: Nov 2005
Posts: 504
Default

lawl w/e i might aswell be the person to say this

you didnt fix the sql injection
Code:
function checkcookie($where, $cookieuser, $cookiepass, $dbname, $sqladdress, $sqluser, $sqlpass) {
	$cookieuser=antiinjection($cookieuser);
	$cookiepass=antiinjection($cookiepass);
	connectdb($dbname,$sqladdress, $sqluser, $sqlpass);
	if($where==0) {
		$result = mssql_query(sprintf(SELECT_USER_PASS, $cookieuser));
		$rows=mssql_num_rows($result);
		if ($rows>0) {
			$rows=mssql_fetch_assoc($result); 
			extract($rows);
			$password = '0x' . bin2hex($password);
			if(md5($password)==$cookiepass) {
				quickrefresh('home.php');
			} else {
				resetcookies();
			}
		} else {
		resetcookies();
		}
	} elseif($where==1) {
		$result = mssql_query(sprintf(SELECT_USER_PASS, $cookieuser));
		$rows=mssql_num_rows($result);
		if ($rows>0) {
			$rows=mssql_fetch_assoc($result); 
			extract($rows);
			$password = '0x' . bin2hex($password);
			if(md5($password)!=$cookiepass) {
				notloggedin();
			}
		} else {
			notloggedin();
		}
	}
}
that fixes the sql injection kthnx

<3 from l2e the practically ONLY server to have secured l2cp >.>
testdude is offline  
Old 24.12.2006, 16:32   #3
testdude
Архивный участник
 
Join Date: Nov 2005
Posts: 504
Default

and also... u might wanna add password hash size checking... if the length of the hash > 34 then that means that pw is corrupt, and cant be used, might wanna add it to register and changepassword
testdude is offline  
Old 25.12.2006, 08:11   #4
testdude
Архивный участник
 
Join Date: Nov 2005
Posts: 504
Default

27 downloads not a single reply... Welcome to Post Pacific.

I hope you leechers get a fucking letter bomb for christmas.
testdude is offline  
Old 25.12.2006, 08:28   #5
mcrabben7
Архивный участник
 
Join Date: Apr 2006
Posts: 461
Default

Thanks for sharing and welcome back Phantom

P.S. testdude, better watch your blood pressure xD
mcrabben7 is offline  
Old 25.12.2006, 08:42   #6
testdude
Архивный участник
 
Join Date: Nov 2005
Posts: 504
Default

Quote:
Originally Posted by mcrabben7 View Post
P.S. testdude, better watch your blood pressure xD
tho hey i guess the good thing is the leechers dont know how the fuck to put my code into l2cp xD
testdude is offline  
Old 25.12.2006, 10:51   #7
m4rk
Архивный участник
 
Join Date: Jan 2006
Posts: 607
Default

Quote:
tho hey i guess the good thing is the leechers dont know how the fuck to put my code into l2cp xD
you gave them the whole function, they'd have to be idiots not to know how to add it xD.

By the way thanks testude for pointing that out, I realised that the only way to be injected was through cookies but i didn't know shit about how they were handled by l2cp. After hacking my own server yesterday (for testing purposes xD) I finally understand almost everything. And thanks Phantom for your effort, I will surely study your l2cp reborn ^^
m4rk is offline  
Old 25.12.2006, 11:22   #8
ismael66
Архивный участник
 
Join Date: Sep 2006
Posts: 122
Default

thank dude (reffering to phantom) and thanks testdude for the function
Merry Christmas!
ismael66 is offline  
Old 25.12.2006, 15:09   #9
dirkr
Архивный участник
 
Join Date: Nov 2006
Posts: 204
Default

i know its a nice panel and all but wouldnt it be easier ( and less exploitable ) to just leave cookies out of it and just check all the input given thru inputfields?
k you wont have a login function and all but just 3 pages with reg/change pw/recover pw
but isnt this more secure?

( feel free to flame me or to point out my dumbness )
dirkr is offline  
Old 25.12.2006, 15:38   #10
m4rk
Архивный участник
 
Join Date: Jan 2006
Posts: 607
Default

Well, right now if you check cookies and you have restricted user in sql there should be no problem at all. They can't drop tables, they can't exec cmdshells... they can't do shit xD...
m4rk is offline  
Old 25.12.2006, 16:29   #11
testdude
Архивный участник
 
Join Date: Nov 2005
Posts: 504
Default

actually right now if u use my function there is NO sql injection, PERIOD.

and btw cookies are used for logging in... theres not really a way to do it without cookies
testdude is offline  
Old 25.12.2006, 20:23   #12
Phantom2005
Архивный участник
 
Join Date: Aug 2005
Posts: 394
Default

v1.05
- Added a security code.


just change $CONFIG['securitycode'] = "0";
[0 (disabled), 1: enabled for all, 2: enabled for all except login]
$CONFIG['securitycode'] = "0";

(it's added for lostpassword, register, login)

Phantom2005 is offline  
Old 25.12.2006, 21:35   #13
nish
Архивный участник
 
Join Date: May 2006
Posts: 237
Default

damn nice share to bad somethin like this was not out before i got injected 2 months ago lol

im using a custom reg right now so i cant use this but great share man and merry xmas
nish is offline  
Old 26.12.2006, 08:14   #14
testdude
Архивный участник
 
Join Date: Nov 2005
Posts: 504
Default

dont thank or credit me for fixing ur sql hole and the hash check idea or anything phantom...
testdude is offline  
Old 26.12.2006, 11:19   #15
Phantom2005
Архивный участник
 
Join Date: Aug 2005
Posts: 394
Default

Thanks testdude.
It's just a release for people that do not know how to do it themselfs.
The people that download it should thank you.
I don't really care about it anyway, I'm just finishing the work of the one who started this, im doing it for fun, i dont need any credits.
Phantom2005 is offline  
Old 27.12.2006, 02:07   #16
AsterisKSM
Архивный участник
 
Join Date: Jun 2006
Posts: 163
Default

well... why it doesent work to make an account?all is good... user pass etc...
Every time i make an account i get this (Email length must be 7 to 50 characters long.)

i put even 40 caracters email.... lol but no effect... and account is not made...
AsterisKSM is offline  
Old 27.12.2006, 20:12   #17
kin
Архивный участник
 
Join Date: Sep 2006
Posts: 882
Default

nish
On every page where user enter any data (login, change pass, register, etc), I have this kind of protection! I never put the site on internet without it! It's too easy to implement You are a hero that put your site without it.
kin is offline  
Old 28.12.2006, 02:27   #18
KOC2000
Архивный участник
 
Join Date: Jun 2006
Posts: 100
Default

Thank you.
I've the same problem as "AsterisKSM" plus I can't even login I always get a msgbox "You are not logged in".. also what does "Reser" at "Forgot your password?" do ?

Thanx.
KOC2000 is offline  
Old 28.12.2006, 08:58   #19
AsterisKSM
Архивный участник
 
Join Date: Jun 2006
Posts: 163
Default

Yea Exactly!!!
AsterisKSM is offline  
Old 28.12.2006, 10:44   #20
valsha
Архивный участник
 
Join Date: Jun 2005
Posts: 60
Default

Quote:
Originally Posted by KOC2000 View Post
Thank you.
I've the same problem as "AsterisKSM" plus I can't even login I always get a msgbox "You are not logged in".. also what does "Reser" at "Forgot your password?" do ?

Thanx.
same problems
valsha is offline  
Old 28.12.2006, 16:45   #21
URANUS
Архивный участник
 
Join Date: Jul 2006
Posts: 69
Default

Quote:
Originally Posted by valsha View Post
same problems
same problems
URANUS is offline  
Old 28.12.2006, 17:57   #22
SlayerX
Архивный участник
 
Join Date: Dec 2005
Posts: 82
Default

Ffs Nooob Admin
SlayerX is offline  
Old 28.12.2006, 18:41   #23
URANUS
Архивный участник
 
Join Date: Jul 2006
Posts: 69
Default

Quote:
Originally Posted by SlayerX View Post
Ffs Nooob Admin
)))) But yours post - great solution this problem )))))
URANUS is offline  
Old 29.12.2006, 02:26   #24
AsterisKSM
Архивный участник
 
Join Date: Jun 2006
Posts: 163
Default

someone can fix this? (i`m not a php coder..)
AsterisKSM is offline  
Old 29.12.2006, 10:39   #25
cs991964
Архивный участник
 
Join Date: Dec 2006
Posts: 1
Default

in functions.php file at function checkhash instead of 34 u must put 32.

THANK YOU FOR THIS SCRIPT and HAPPY NEW YEAR !
cs991964 is offline  
 


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT. The time now is 16:18.