用于 Active Directory 证书服务枚举与滥用的工具
此仓库包含 ly4k/Certipy 的一个分支,合并了许多开放的 pull request,使其彼此兼容,并进行了(一定程度的)测试。
由于这是一个_正在进行的工作_,某些功能可能无法按预期工作,也可能会出现损坏。
pipx(推荐)如果你更喜欢自动管理的虚拟环境的便利性,请使用 pipx:
pipx install git+https://github.com/zimedev/certipy-merged.git@main
如果你需要 LDAP 通道绑定(Channel Binding)支持,你需要将打过补丁的 ldap3 库注入到 Python 虚拟环境中:
pipx inject --force certipy-ad git+https://github.com/ly4k/ldap3
pip 配合虚拟环境如果你想手动管理安装,请使用 Python 的 pip 配合 venv,将其安装到你选择的目录中,例如 /opt:
cd /opt
git clone https://github.com/zimedev/certipy-merged
cd certipy-merged
python3 -m venv .venv
source .venv/bin/activate
python3 -m pip install .
如果你使用 Arch Linux,可以添加 dadevel/archpkgs 仓库,该仓库默认使用 certipy-merged,并开箱即用地包含 LDAP 通道绑定支持。
要添加 archpkgs 仓库,请参考官方的 设置说明。
接下来,你可以安装 archpkgs/certipy:
sudo pacman -Sy archpkgs/certipy
/opt/archpkgs/bin/certipy
Certipy v4.8.2 - by Oliver Lyak (ly4k)
usage: certipy [-v] [-h] {account,auth,ca,cert,find,forge,ptt,relay,req,shadow,template} ...
Active Directory Certificate Services enumeration and abuse
positional arguments:
{account,auth,ca,cert,find,forge,ptt,relay,req,shadow,template}
Action
account Manage user and machine accounts
auth Authenticate using certificates
ca Manage CA and certificates
cert Manage certificates and private keys
find Enumerate AD CS
forge Create Golden Certificates
ptt Inject TGT for SSPI authentication
relay NTLM Relay to AD CS HTTP Endpoints
req Request certificates
shadow Abuse Shadow Credentials for account takeover
template Manage certificate templates
options:
-v, --version Show Certipy's version number and exit
-h, --help Show this help message and exit
这些功能是新增的,已直接合并到 certipy-merged 中。
原始仓库中没有对应的 PR,因为代码库已经分叉得太过严重。