|
|
|
|
Menu |
|
|
Home |
| |
|
Discussions |
| |
|
Tools |
| |
|
Affiliates |
| |
|
Content |
| |
|
Info |
| | |
|
|
|
|
|
User Info |
|
Membership:
Latest: MichaelSnaRe
New Today: 0
New Yesterday: 0
Overall: 9144
People Online:
Visitors: 55
Members: 0
Total: 55
|
|
|
|
|
|
Full disclosure |
|
|
|
|
|
|
|
|
|
IT Security and Insecurity Portal |
|
|
UNION SELECT possible? |
|
Posted: Tue May 25, 2010 11:58 am |
|
|
tommy |
Beginner |
|
|
Joined: May 25, 2010 |
Posts: 2 |
|
|
|
|
|
|
|
Hi there,
I discovered an exploitable site.
The URL looks like this: http://www.site.com/list.php?search=asdf
This query gets executed:
SELECT * FROM sometable WHERE somecolumn LIKE '%asdf%';
I tried to use a UNION SELECT (I know the column-count of "sometable"), but the PHP script splits the input by commas (probably using explode() ).
So if I enter search=a,b,c, this query is executed:
SELECT * FROM sometable WHERE somecolumn LIKE '%a%' AND somecolumn LIKE '%b%' AND somecolumn LIKE '%c%';
Can anybody please help me how to use a UNION SELECT here?
Thanks in advance,
tommy |
|
|
|
|
|
|
|
|
Posted: Tue May 25, 2010 8:01 pm |
|
|
waraxe |
Site admin |
|
|
Joined: May 11, 2004 |
Posts: 2407 |
Location: Estonia, Tartu |
|
|
|
|
|
|
Seems to be complicated case. You can:
1. try to search other sql injections in same website
2. use subselects and blind injection, so that instead of
Code: | zzz' UNION ALL SELECT 1,2,3 4,5 |
use something like:
Code: | commonword' AND(SELECT COUNT(*)FROM members)>1# |
In case of "true" search will return some result, in other case no results.
Basically you will have communication channel with database with bandwith 1 bit per http request |
|
|
|
|
www.waraxe.us Forum Index -> Sql injection
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
All times are GMT
Page 1 of 1
|
|
|
Powered by phpBB © 2001-2008 phpBB Group
|
|
|
|
|
|
|