域環境下的信息搜集(詳細)
VSole2022-07-07 16:07:25
01
單域環境
單域環境

查看域環境用戶
查看時間/dns服務器(一般為域控)
net time /domain /net view /domain

shell net group "Domain Controllers" /domain
02
查看域控制器
查看域控制器

可以得到域控制器IP地址
域控還可能開放88 Kerberos 協議,01389 ldap,
DNS 53 如果存在EXECHANGE 郵件服務器那么也開放了25還有我們熟悉的139,445.
03
查看身處在哪個域
查看身處在哪個域
net config workstaon

shell nltest /dclist:de.org 同樣可以得到域控地址net group "domain admins" /domain 查看域管有哪些

04
信息收集
信息收集:
確定存在內網后可以使用
for /L %I in (1,1,254) DO @ping -w 1 -n 1 192.168.1.%I | findstr "TTL=“
該命令批量ping 出存活的IP ,如果沒有存在策略限制一般Ping出存貨的IP都可以進行端口掃描等操作。
同等可以使用 nbtscan /fscan等內網掃描工具替代。
查看net use 有沒有IPC連過來的機器
cmdkey /list 用戶憑據

可以再
net view \\xx
查看有沒有開啟共享目錄。
之后可以查看一下用戶進程查看有沒有其他用戶進程可以注入/竊取。

echo %logonserver% 查看當前登錄域 quser 可以查詢 當前在線的user

插播tips(3389 system權限 tscon 加id可以直接切換用戶無需知道密碼)。
查找 文件 dir /s /b xxxx.exe
插播tips2:
如果不知道web目錄可以拿一個web的js來定位web位置
cmd /c "for /f "delims=" %i in ('dir /s /b c:bsa.js') do (echo %i> %i.path.txt)&(ipconfig > %i.ipconfig.txt)"
會在 js下生成一個txt 里邊有web的目錄地址域控常見命令:
dsquery server - 查找目錄中的 AD DC/LDS 實例dsquery user - 查找目錄中的用戶dsquery computer 查
主機發現系列:

查看內網其他IP 3389 的登錄記錄
arp -a

如何使用域用戶查看當前用戶機器?用戶登錄主機?
ADfind.exe,Psloggedon.exe,PvefindADuser.exe,powerview.
ADfind使用方法

查看DC機器

查看域內在活動的機器
AdFind.exe -sc computers_active name dnshostname

查看詳細域內機器

shell AdFind.exe -b dc=tide,dc=org -f "objectcategory=computer"
查看能登陸的389以及機器

shell AdFind.exe -h 192.168.100.10 -sc u:tideone userWorkstations
使用PVEFindaduser查看當前用戶胡登錄的主機

shell PVEFindaduser -current -nopingPVEFindADuser -current -target 192.168.91.133 查看指定IP的登錄記錄 PVEFindADuser -last 查看上次
VSole
網絡安全專家