Skip to content

139,593 - RPC

#ActiveDirectory #rpc #pentestinterno

bash
rpcclient -U '' IP -N

enumdomusers
bash
rpcclient -U 'USER%PASS' IP
bash
rpcclient -U 'USER%HASH' IP --pw-nt-hash
bash
rpcclient -U '' IP -c "enumdomusers" -N | tr '[]' ' '| awk '{print $2}' > validUsers.txt
bash
rpcclient -U 'USER%PASS' IP -c "enumdomusers" | tr '[]' ' '| awk '{print $2}' > validUsers.txt

Por kerberos:

bash
nxc smb DC.DOMAIN -u 'USER' -p 'PASSWORD' -k --users
bash
nxc smb DC.voleur.htb -u 'ryan.naylor' -p 'HollowOct31Nyt' -k --users | awk '{print $5}' | grep -vE '\-|\[' > validUsers.txt

Lista de usuarios con descripción

querydispinfo
BASH
setuserinfo2 USER 23 'PASS'
bash
impacket-lookupsid anonymous@domain.htb -target-ip IP -no-pass
bash
impacket-lookupsid anonymous@domain.htb -target-ip IP -no-pass | grep SidTypeUser | tr '\\' ' ' | awk '{print $3}'

Notas personales de seguridad ofensiva.