本系列共18篇,涵盖OSCP认证考试所需全部技能点,本章为“技能5-AD域信息枚举”,技术交流可加微信群,资源免费共享可加QQ群:一、基础命令行工具
1. Windows内置命令
# 域基本信息net view /domainnet group "domain computers" /domainnet user /domainnet group "domain admins" /domain# 信任关系nltest /domain_trustsnltest /dclist:domain_name# 会话和共享net sessionnet sharenet use \target_ipshare# 时间同步net time \dc_hostname# 组策略gpresult /rgpupdate /force
2. PowerShell基础枚举
# 域基本信息Get-ADDomainGet-ADForestGet-ADDomainController# 用户枚举Get-ADUser -Filter * -Properties *Get-ADUser -Identity administrator -Properties *Get-ADUser -Filter "Description -like '*admin*'" -Properties Description# 计算机枚举Get-ADComputer -Filter * -Properties *Get-ADComputer -Filter "OperatingSystem -like '*Server*'" -Properties OperatingSystem# 组枚举Get-ADGroup -Filter * -Properties *Get-ADGroupMember "Domain Admins" -Recursive# 组织单位Get-ADOrganizationalUnit -Filter * -Properties *
二、PowerView - 高级枚举工具
1. 基础信息收集
# 导入PowerView. .PowerView.ps1Import-Module PowerView# 域信息Get-NetDomainGet-NetForestGet-DomainSIDGet-NetDomainController# 用户枚举Get-NetUser | Select-Object samaccountname,description,lastlogonGet-NetUser -SPN | Select-Object samaccountname,serviceprincipalnameGet-NetUser -UACFilter NOT_ACCOUNTDISABLE | Select-Object samaccountname# 计算机枚举Get-NetComputer | Select-Object name,operatingsystemGet-NetComputer -OperatingSystem "*Server*"Get-NetComputer -Ping# 组信息Get-NetGroup | Select-Object name,descriptionGet-NetGroupMember "Domain Admins"Get-NetLocalGroup -ComputerName target_host
2. 高级查询技巧
# 会话和登录信息Get-NetSession -ComputerName target_hostGet-NetLoggedon -ComputerName target_hostInvoke-UserHunter -StealthFind-DomainUserLocation -CheckAccess# 共享枚举Get-NetShare -ComputerName target_hostGet-NetFileServer# 权限和ACLGet-ObjectAcl -SamAccountName "Domain Admins" -ResolveGUIDsGet-PathAcl -Path "\dcsysvol"# GPO枚举Get-NetGPO | Select-Object displayname, gpopathGet-NetGPOGroup | Select-Object gpodisplayname, groupname# OU和站点Get-NetOU | Select-Object name, gplinkGet-NetSite | Select-Object name, description
三、BloodHound系列工具
还没有评论,来说两句吧...