Skip to content
KitploitKITPLOIT
工具博客
提交
工具博客
提交

黑客、渗透测试和网络安全工具,武装您的安全武器库!

Kitploit 是一个黑客、网络安全和渗透测试工具的目录。发现最新的项目更新,查找漏洞、分析系统、自动化测试并加强你的安全。

··订阅源·联系·隐私·© 2026 Kitploit

工具目录

分类

查看所有分类
Loading categories
gpoParser — gpoParser 是一款用于提取和分析 Active Directory 环境中通过组策略对象(GPO)应用的配置的工具。 | Kitploit
工具/GitHubGitHub/synacktiv/gpoparser
权限提升侦察漏洞分析横向移动配置审计信息收集后渗透利用渗透测试错误配置红队
GitHubsynacktiv/gpoparser

gpoParser

369353个月前Kitploit 审核通过

最受欢迎

查看全部 →

发现我们社区最常用的工具。

探索所有工具

浏览我们的工具集合

查看所有工具 →
分享

gpoParser 是一款用于提取和分析 Active Directory 环境中通过组策略对象(GPO)应用的配置的工具。

查看仓库

gpoParser

gpoParser 是一款用于提取和分析 Active Directory 环境中通过组策略对象 (GPO) 应用的配置的工具。 由于枚举这些设置可能既繁琐又耗时,该工具能让你更清晰地理解已应用的策略,并帮助识别可能导致横向移动或权限提升的危险配置。 它曾在 leHack 2025 和 DEFCON 33 上进行展示。

安装

注意:gssapi 包需要依赖:libkrb5-dev,可通过 sudo apt install libkrb5-dev 安装(或使用你相关的包管理器)

root@kitploit:~
pipx install git+https://github.com/synacktiv/gpoParser

功能

root@kitploit:~
$ gpoParser -h
usage: gpoParser [-h] {local,remote,display,query,enrich} ...

GPO Analysis Tool

positional arguments:
  {local,remote,display,query,enrich}
                        Choose mode
    local               Parse GPOs locally
    remote              Parse GPOs via remote LDAP/SYSVOL
    display             Display parsed GPO contents
    query               Query GPO parser results in order to display affected computers
    enrich              Enrich BloodHound with new edges

options:
  -h, --help            show this help message and exit

在线或离线模式的 GPO 获取

在线模式:连接 LDAP 目录以收集 GPO 相关信息及其属性 (flags、gPLink、gPOptions 等)。它还会连接 SYSVOL 共享以收集 GPO 配置文件。

root@kitploit:~
$ gpoParser remote -h
usage: gpoParser remote [-h] [-s SERVER] [-d DOMAIN] [-u USER] [-p PASSWORD] [-H HASH] [-k] [-o OUTPUT]

options:
  -h, --help            show this help message and exit
  -s, --server SERVER   LDAP server IP or FQDN (ex: ldap://192.168.57.5 or ldaps://dc.corp.local)
  -d, --domain DOMAIN   Domain name tied to the user
  -u, --user USER       Username
  -p, --password PASSWORD
                        Password
  -H, --hash HASH       NTLM authentication, format is [LM:]NT
  -k, --kerberos        Use Kerberos authentication
  -o, --output OUTPUT   Output filename and location (default ./cache_gpoParser_<timestamp>.json)

$ gpoParser remote -u bob -p password -d corp -s 192.168.57.5
Retrieving \CORP.LOCAL\Policies\{008B0634-C0B9-443A-A06A-E2BAD875E27F}\Machine/Microsoft/Windows NT/SecEdit/GptTmpl.inf
Retrieving \CORP.LOCAL\Policies\{008B0634-C0B9-443A-A06A-E2BAD875E27F}\Machine/Preferences/Groups/Groups.xml
Retrieving \CORP.LOCAL\Policies\{008B0634-C0B9-443A-A06A-E2BAD875E27F}\Machine/Preferences/Registry/Registry.xml
[...]
Information saved to cache, now use display / query features

离线模式:需要 LDAP 目录的(部分)副本以及来自 SYSVOL 共享的 Policies 文件夹内容。目前,LDAP 目录收集依赖:

  • ldeep
  • ADExplorerSnapshot Objects 输出格式 (NDJSON)
root@kitploit:~
$ gpoParser local -h
usage: gpoParser local [-h] [-f {ldeep,adexplorer}] [-o OUTPUT] sysvol_folder ldap_folder

positional arguments:
  sysvol_folder         SYSVOL folder containing the policies
  ldap_folder           Folder with LDAP dump in ldeep format

options:
  -h, --help            show this help message and exit
  -f {ldeep,adexplorer}, --format {ldeep,adexplorer}
                        JSON files input format (default ldeep)
  -o OUTPUT, --output OUTPUT
                        Output filename and location (default ./cache_gpoParser_<timestamp>.json)

$ mkdir sysvol && cd sysvol &&  echo -e 'prompt\nrecurse\nmget *' | smbclient -W CORP -U bob%password //192.168.57.5/SYSVOL

$ mkdir ldap && ldeep ldap -u bob -p password -d corp.local -s 192.168.57.5 all ldap/corp

$ gpoParser local sysvol/ ldap/
Information saved to cache, now use display / query features

显示

此模式显示 GPO 应用的所有配置更改,但仅限于受支持的格式和已解析的数据。你可以按 GPO 名称或 GUID 过滤结果。

root@kitploit:~
$ gpoParser display -h
usage: gpoParser display [-h] [-g GPO] [-c CACHE]

options:
  -h, --help            show this help message and exit
  -g GPO, --gpo GPO     Filter by GPO name or GUID
  -c CACHE, --cache CACHE
                        Cache file location (default: ./cache_gpoParser_<timestamp>.json)

$ gpoParser display
Cache file found, using it
{6F3821B3-89B2-496D-82A5-58092D3EA588}: AddAdmin
Computer configuration
   Groups
      The following principals are added to BUILTIN\Administrators
         CORP\admin
{ADC96BD4-86D3-4516-BCF2-F7BDD5A76366}: AddRDP
Computer configuration
   Groups
      The following principals are added to BUILTIN\Remote Desktop Users
         CORP\bob
[...]

$ gpoParser display -g work
Cache file found, using it
{474D47E2-2B77-4E37-9744-A3CF6AB04449}: Workstation admins
Computer configuration
   Groups
      The following principals are added to BUILTIN\Administrators
         CORP\Admin - All Workstations

查询

此视图显示 GPO 与计算机之间的关系。例如,你可以查看某个 GPO 应用于哪些计算机,或者一台或多台计算机应用了哪些更改。

root@kitploit:~
$ gpoParser query -h
usage: gpoParser query [-h] [-g GPO] [-C COMPUTER] [-c CACHE]

options:
  -h, --help            show this help message and exit
  -g GPO, --gpo GPO     Filter by GPO name or GUID
  -C COMPUTER, --computer COMPUTER
                        Computer name or distinguishedName to filter on
  -c CACHE, --cache CACHE
                        Cache file location (default: ./cache_gpoParser_<timestamp>.json)

$ gpoParser query
Cache file found, using it
{6F3821B3-89B2-496D-82A5-58092D3EA588}: AddAdmin
This GPO affects the following computers:
CN=SRV55,OU=PROD,OU=Servers,DC=CORP,DC=LOCAL
CN=SRV54,OU=PROD,OU=Servers,DC=CORP,DC=LOCAL
CN=SRV53,OU=PROD,OU=Servers,DC=CORP,DC=LOCAL
CN=SRV52,OU=PROD,OU=Servers,DC=CORP,DC=LOCAL

{6AC1786C-016F-11D2-945F-00C04FB984F9}: Default Domain Controllers Policy
This GPO affects the following computers:
CN=DC01,OU=Domain Controllers,DC=CORP,DC=LOCAL

{31B2F340-016D-11D2-945F-00C04FB984F9}: Default Domain Policy
This GPO affects the following computers:
CN=SRV51,OU=SUBSUB,OU=SUB,DC=CORP,DC=LOCAL
CN=SRV49,OU=SUB,DC=CORP,DC=LOCAL
CN=SRV50,OU=SUB,DC=CORP,DC=LOCAL
CN=SRV55,OU=PROD,OU=Servers,DC=CORP,DC=LOCAL
[...]


$ gpoParser query -C wks
Cache file found, using it
CN=WKS01,OU=ADMIN,OU=WORKSTATIONS,DC=CORP,DC=LOCAL
{31B2F340-016D-11D2-945F-00C04FB984F9}: Default Domain Policy
Computer configuration
   Registry
      The following registry key changes have been made
      Action: Create
      Path: MACHINE\System\CurrentControlSet\Control\Lsa\NoLMHash
      Value: 4,1
      The following registry key changes have been made
      Action: Update
      Hive: HKEY_LOCAL_MACHINE
      Path: SYSTEM\CurrentControlSet\Services\Dnscache\Parameters
      Name: EnableMDNS
      Value: 00000000

BloodHound 增强

解析 GPO 信息以创建额外的边,例如 AdminTo、CanRDP 和 CanPSRemote,从而识别 BloodHound 原生可能无法检测到的横向移动机会。通过直接连接 Neo4j 数据库来添加边。

root@kitploit:~
$ gpoParser enrich -h
usage: gpoParser enrich [-h] [-u USER] [-p PASSWORD] [-s SERVER] [-c CACHE]

options:
  -h, --help            show this help message and exit
  -u USER, --user USER  Username for neo4j authentication (default: neo4j)
  -p PASSWORD, --password PASSWORD
                        Password for neo4j authentication (default: bloodhoundcommunityedition)
  -s SERVER, --server SERVER
                        Neo4j server URI (default: bolt://localhost:7687)
  -c CACHE, --cache CACHE
                        Cache file location (default: ./cache_gpoParser_<timestamp>.json)

局限性

离线数据导入会带来某些限制:诸如继承状态、用户/计算机配置状态、安全筛选、WMI 筛选和项目级目标定位等参数可能并不总是能被现有工具 (BloodHound、PowerView、GPOHound) 收集或解释。 gpoParser 将在后续开发中逐步考虑所有这些参数。 随着工具的演进,将引入更多的数据收集器。

下载工具