Register for your free account! | Forgot your password?

Go Back   elitepvpers > MMORPGs > Flyff
You last visited: Today at 11:35

  • Please register to post and access all features, it's quick, easy and FREE!

Advertisement



SQL Injecting FlyFF MMO

Discussion on SQL Injecting FlyFF MMO within the Flyff forum part of the MMORPGs category.

Closed Thread
 
Old   #1
 
Seedlord's Avatar
 
elite*gold: 20
Join Date: Oct 2007
Posts: 1,069
Received Thanks: 2,150
SQL Injecting FlyFF MMO

I just read an article about SQL Injecting in Flyff. I never really played FlyFF but this seems pretty interesting.
I dont know if this is still possible, seems to be fixxed on the official servers, but on some (old) Pservers it might work.

Seedlord is offline  
Old 04/18/2020, 02:57   #2
 
cookie69's Avatar
 
elite*gold: 0
Join Date: Nov 2009
Posts: 627
Received Thanks: 683
Quote:
Originally Posted by Seedlord View Post
I just read an article about SQL Injecting in Flyff. I never really played FlyFF but this seems pretty interesting.
I dont know if this is still possible, seems to be fixxed on the official servers, but on some (old) Pservers it might work.

Looooooool! who leaked that info, last 2 weeks I was doing this in some pservers and the offi.
No, it seems fixed in most pservers. It only worked on my v15 local server.
cookie69 is offline  
Thanks
3 Users
Old 04/18/2020, 03:09   #3

 
netHoxInc's Avatar
 
elite*gold: 465
Join Date: Jan 2008
Posts: 775
Received Thanks: 975
Quote:
Originally Posted by Seedlord View Post
I just read an article about SQL Injecting in Flyff. I never really played FlyFF but this seems pretty interesting.
I dont know if this is still possible, seems to be fixxed on the official servers, but on some (old) Pservers it might work.

Lol at first i thought, who the heck digs out that kinda old stuff, then realizing it been posted not very long ago.

Still weird to see a documentation for something thats fixed on almost every server, specially those where it would actually be useful, taking apart those pinoy-ripoff servers lol....

You might be a little late to join the SQL injection squad haha, recently alot of stuff got patched up as some rude people had some fun on the xblubbs page, which apparently, 98% of server's are using, atleast in a variant.

Feel free to check out the fix for it, it might give you an idea how to perform it. It's probably going to work on fresh servers, and some pinoy ones which arent reading epvp lol

Quote:
Originally Posted by cookie69 View Post
Looooooool! who leaked that info, last 2 weeks I was doing this in some pservers and the offi.
No, it seems fixed in most pservers. It only worked on my v15 local server.
Lol Cookie, go to bed its late :'D
netHoxInc is offline  
Thanks
1 User
Old 04/18/2020, 03:15   #4
 
cookie69's Avatar
 
elite*gold: 0
Join Date: Nov 2009
Posts: 627
Received Thanks: 683
Main issue comes from this ****** code where unhandled packet will be sent directly to the database server.
=> g_dpDBClient.SendToServer( idFrom, lpMsg, dwMsgSize );

Code:
void CDPLoginSrvr::UserMessageHandler( LPDPMSG_GENERIC lpMsg, DWORD dwMsgSize, DPID idFrom )
{
	static size_t	nSize	= sizeof(DPID);
	CAr ar( (LPBYTE)lpMsg + nSize, dwMsgSize - nSize );		// Skip dpid

	if( dwMsgSize < 8 )		// INVALID PACKET
	{
		FLERROR_LOG( PROGRAM_NAME, _T( "PACKET//0" ) );
		return;
	}

	GETTYPE( ar );
	PACKET_HANDLER_FUNC pfn	=	GetHandler( dw );
	
	if( pfn )
	{
		( this->*( pfn ) )( ar, idFrom );
	}
	else
	{
		g_dpDBClient.SendToServer( idFrom, lpMsg, dwMsgSize );
	}
As a fix you can for example check the account_name the same way as for checking the player_name (IsInvalidName) in the function:
Code:
void CDbManager::CreatePlayer( CQuery *qry, LPDB_OVERLAPPED_PLUS lpDbOverlappedPlus )
Code:
	

	if( prj.IsInvalidName( lpDbOverlappedPlus->AccountInfo.szPlayer ) 
		|| prj.IsAllowedLetter( lpDbOverlappedPlus->AccountInfo.szPlayer ) == FALSE 
		|| prj.IsInvalidName(lpDbOverlappedPlus->AccountInfo.szAccount)
		|| prj.IsAllowedLetter(lpDbOverlappedPlus->AccountInfo.szAccount) == FALSE
		)
	{
		FreeRequest( lpDbOverlappedPlus );
		return;
	}
cookie69 is offline  
Old 04/18/2020, 16:43   #5

 
elite*gold: 28
Join Date: Feb 2010
Posts: 499
Received Thanks: 274
Quote:
Originally Posted by cookie69 View Post
Main issue comes from this shitty code where unhandled packet will be sent directly to the database server.
=> g_dpDBClient.SendToServer( idFrom, lpMsg, dwMsgSize );

Code:
void CDPLoginSrvr::UserMessageHandler( LPDPMSG_GENERIC lpMsg, DWORD dwMsgSize, DPID idFrom )
{
	static size_t	nSize	= sizeof(DPID);
	CAr ar( (LPBYTE)lpMsg + nSize, dwMsgSize - nSize );		// Skip dpid

	if( dwMsgSize < 8 )		// INVALID PACKET
	{
		FLERROR_LOG( PROGRAM_NAME, _T( "PACKET//0" ) );
		return;
	}

	GETTYPE( ar );
	PACKET_HANDLER_FUNC pfn	=	GetHandler( dw );
	
	if( pfn )
	{
		( this->*( pfn ) )( ar, idFrom );
	}
	else
	{
		g_dpDBClient.SendToServer( idFrom, lpMsg, dwMsgSize );
	}
As a fix you can for example check the account_name the same way as for checking the player_name (IsInvalidName) in the function:
Code:
void CDbManager::CreatePlayer( CQuery *qry, LPDB_OVERLAPPED_PLUS lpDbOverlappedPlus )
Code:
	if( prj.IsInvalidName( lpDbOverlappedPlus->AccountInfo.szPlayer ) || prj.IsAllowedLetter( lpDbOverlappedPlus->AccountInfo.szPlayer ) == FALSE )
	{
		return;
	}
You check 2 time szPlayer, think you forgot to change the second one to szPassword.
ZeroTwo02 is offline  
Old 04/18/2020, 21:56   #6
 
elite*gold: 0
Join Date: Jan 2011
Posts: 28
Received Thanks: 17
aren't they using binds in v21 ? not sure how u got it to work on offi?
miniman06 is offline  
Old 04/18/2020, 23:10   #7

 
elite*gold: 28
Join Date: Feb 2010
Posts: 499
Received Thanks: 274
Quote:
Originally Posted by miniman06 View Post
aren't they using binds in v21 ? not sure how u got it to work on offi?
Official is fix, they use different type of bindsparam.
One of the smartest thing they did in 10 years actually lol.

You can also use them to your v.15 sources, you just have to check the follow bindsparam & copy them :

Code:
	BOOL	BindParameterByte( SQLSMALLINT ParamType, SQLPOINTER ParameterValuePtr );

	BOOL	BindParameterShort( SQLSMALLINT ParamType, SQLPOINTER ParameterValuePtr );
	BOOL	BindParameterUShort( SQLSMALLINT ParamType, SQLPOINTER ParameterValuePtr );

	BOOL	BindParameterInt( SQLSMALLINT ParamType, SQLPOINTER ParameterValuePtr );
	BOOL	BindParameterUInt( SQLSMALLINT ParamType, SQLPOINTER ParameterValuePtr );

	BOOL	BindParameterInt64( SQLSMALLINT ParamType, SQLPOINTER ParameterValuePtr );
	BOOL	BindParameterUInt64( SQLSMALLINT ParamType, SQLPOINTER ParameterValuePtr );

	BOOL	BindParameterFloat( SQLSMALLINT ParamType, SQLPOINTER ParameterValuePtr );

	BOOL	BindParameterChar( SQLSMALLINT ParamType, SQLUINTEGER ColumnSize, SQLPOINTER ParameterValuePtr );
	BOOL	BindParameterVarChar( SQLSMALLINT ParamType, SQLUINTEGER ColumnSize, SQLPOINTER ParameterValuePtr );
ZeroTwo02 is offline  
Old 04/19/2020, 12:50   #8
 
elite*gold: 0
Join Date: Jan 2011
Posts: 28
Received Thanks: 17
Quote:
Originally Posted by ZeroTwo02 View Post
Official is fix, they use different type of bindsparam.
One of the smartest thing they did in 10 years actually lol.

You can also use them to your v.15 sources, you just have to check the follow bindsparam & copy them :

Code:
	BOOL	BindParameterByte( SQLSMALLINT ParamType, SQLPOINTER ParameterValuePtr );

	BOOL	BindParameterShort( SQLSMALLINT ParamType, SQLPOINTER ParameterValuePtr );
	BOOL	BindParameterUShort( SQLSMALLINT ParamType, SQLPOINTER ParameterValuePtr );

	BOOL	BindParameterInt( SQLSMALLINT ParamType, SQLPOINTER ParameterValuePtr );
	BOOL	BindParameterUInt( SQLSMALLINT ParamType, SQLPOINTER ParameterValuePtr );

	BOOL	BindParameterInt64( SQLSMALLINT ParamType, SQLPOINTER ParameterValuePtr );
	BOOL	BindParameterUInt64( SQLSMALLINT ParamType, SQLPOINTER ParameterValuePtr );

	BOOL	BindParameterFloat( SQLSMALLINT ParamType, SQLPOINTER ParameterValuePtr );

	BOOL	BindParameterChar( SQLSMALLINT ParamType, SQLUINTEGER ColumnSize, SQLPOINTER ParameterValuePtr );
	BOOL	BindParameterVarChar( SQLSMALLINT ParamType, SQLUINTEGER ColumnSize, SQLPOINTER ParameterValuePtr );
Ah no nvm I derped yday, cookie was talking about how the login servers just passes to the DB the parameters are passed correctly just they aren't verified
miniman06 is offline  
Old 06/25/2020, 09:54   #9
 
elite*gold: 0
Join Date: Jun 2020
Posts: 1
Received Thanks: 0
how to use sql injection in flyff private server? teach me how or send tutorial please thanks
jhaycee2123 is offline  
Old 06/25/2020, 15:52   #10



 
Flogolo's Avatar
 
elite*gold: 830
Join Date: Nov 2011
Posts: 4,211
Received Thanks: 655
Quote:
Originally Posted by jhaycee2123 View Post
how to use sql injection in flyff private server? teach me how or send tutorial please thanks
no requests allowed
Flogolo is offline  
Old 06/25/2020, 22:25   #11
ベトナム警察



 
Lumi's Avatar
 
elite*gold: 5
The Black Market: 508/0/0
Join Date: Jan 2012
Posts: 15,972
Received Thanks: 3,393
It seems it doesn't work for offi anymore.
Lumi is offline  
Thanks
1 User
Closed Thread


Similar Threads Similar Threads
SQL Injecting FlyFF MMO
04/18/2020 - Flyff Hacks, Bots, Cheats, Exploits & Macros - 0 Replies
/delete me pliz wrong section



All times are GMT +2. The time now is 11:35.


Powered by vBulletin®
Copyright ©2000 - 2023, Jelsoft Enterprises Ltd.
SEO by vBSEO ©2011, Crawlability, Inc.
This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.

Support | Contact Us | FAQ | Advertising | Privacy Policy | Terms of Service | Abuse
Copyright ©2023 elitepvpers All Rights Reserved.