⛔🚧 本仓库已不再维护。若要提交问题、拉取请求或获取最新版本,请参阅 https://github.com/coffeegist/bofhound 🚧⛔
_____________________________ __ __ ______ __ __ __ __ _______
| _ / / __ / | ____/| | | | / __ \ | | | | | \ | | | \
| |_) | | | | | | |__ | |__| | | | | | | | | | | \| | | .--. |
| _ < | | | | | __| | __ | | | | | | | | | | . ` | | | | |
| |_) | | `--' | | | | | | | | `--' | | `--' | | |\ | | '--' |
|______/ \______/ |__| |__| |___\_\________\_\________\|__| \___\|_________\
作者: Fortalice ✪
BOFHound 是一款离线 BloodHound 数据采集与 LDAP 结果解析工具,兼容 TrustedSec 的 ldapsearch BOF、其 Python 改编版 pyldapsearch 以及 Brute Ratel 的 LDAP Sentinel。
通过解析上述工具生成的日志文件,BOFHound 使操作人员能够使用 BloodHound 广受欢迎的界面,同时完全控制所执行的 LDAP 查询及其执行速度。这为操作人员留出了根据自身判断应对潜在蜜罐账户、昂贵的 LDAP 查询阈值以及其他针对传统自动化 BloodHound 采集器设计的检测机制的空间。
BOFHound 可通过 pip3 install bofhound 安装,或克隆本仓库后运行 pip3 install .。

解析 Cobalt Strike 日志(默认路径 /opt/cobaltstrike/logs)中的 ldapsearch BOF 结果,输出到 /data/ 目录:
bofhound -o /data/
解析 pyldapsearch 日志,并包含所有属性(而非仅常用属性):
bofhound -i ~/.pyldapsearch/logs/ --all-properties
解析 BRc4 日志中的 LDAP Sentinel 数据(默认输入路径将变为 /opt/bruteratel/logs):
bofhound --brute-ratel
以下属性是正常运行所必需的:
samaccounttype
dn
objectsid
获取所有数据(也许改用 BloodHound 更合适?)
ldapsearch (objectclass=*) *,ntsecuritydescriptor
检索所有架构信息
ldapsearch (schemaIDGUID=*) name,schemaidguid -1 "" CN=Schema,CN=Configuration,DC=windomain,DC=local
仅检索 ms-Mcs-AdmPwd 的 schemaIDGUID
ldapsearch (name=ms-mcs-admpwd) name,schemaidguid 1 "" CN=Schema,CN=Configuration,DC=windomain,DC=local
BOFHound 使用 Poetry 管理依赖。从源码安装并设置开发环境:
git clone https://github.com/fortalice/bofhound
cd bofhound
poetry install
poetry run bofhound --help