Active Directory 环境的虚假用户生成器
Youzer 的目标是创建信息丰富的 Active Directory 环境。它使用 python3 库 'faker' 生成随机账户。
pip3 install faker
你可以提供一个单词列表,或让密码自动生成。生成的选项非常适合测试像 hashcat 规则掩码之类的场景。单词列表选项则适用于希望将特定密码列表植入环境,或练习字典攻击的情况。
输出为 CSV 和 PowerShell 脚本,两者均可复制到目标。执行时,PowerShell 脚本通过 LDAP 绑定(不依赖较新的 Active Directory 模块)并创建每个用户对象。目前 OU 需要预先存在,但此工具是 'Labseed' 的子项目,后者将负责创建 Active Directory 结构。
Youzer 可以在 30 秒内创建 100,000 个用户,并在约 3 分钟内创建 1,000,000 个用户。
[-] 域名设置为 : example
[*] 正在写入输出文件 : sales_example.csv
[!] 正在以密码生成模式生成 100000 个用户
[!] 正在创建用于导入的 PowerShell 脚本 : sales_example.ps1
python3 youzer.py --generate --generate_length 20 --ou --domain example 20.35s user 0.11s system 95% cpu 21.354 total
python3 youzer.py --generate --generate_length 20 --ou "ou=sales,dc=example,dc=domain" --domain example --users 1000 --output sales_example.csv
?88 d8P d8888b ?88 d8Pd88888P d8888b 88bd88b
d88 88 d8P' ?88d88 88 d8P' d8b_,dP 88P' `
?8( d88 88b d88?8( d88 d8P' 88b d88
`?88P'?8b `?8888P'`?88P'?8bd88888P'`?888P'd88'
)88
,d8P version : 0.1
`?888P'
author : @lorentzenman
team : SpiderLabs
[-] 域名设置为 : example
[*] 正在写入输出文件 : sales_example.csv
[!] 正在以密码生成模式生成 1000 个用户
[!] 正在创建用于导入的 PowerShell 脚本 : sales_example.ps1
从生成选项创建的 CSV 文件示例输出
Name,GivenName,sn,ou,password,address,description
Dennis Shaw,Dennis,Shaw,"ou=sales,dc=example,dc=domain",VwVeloi09FaECRdNbbXD,
Sam Francis,Sam,Francis,"ou=sales,dc=example,dc=domain",qhitxgjDW4gZFuraLJbB,
Ellie Freeman,Ellie,Freeman,"ou=sales,dc=example,dc=domain",7qbLcknqlPtpkOzdLyw3,
Terence Arnold,Terence,Arnold,"ou=sales,dc=example,dc=domain",lumPMbDk1YomypRj26by,
Anne Murphy,Anne,Murphy,"ou=sales,dc=example,dc=domain",6r42EGGoEJYe9PydHRTV,
Wendy Smith,Wendy,Smith,"ou=sales,dc=example,dc=domain",tKI2zFUOU8XdK4ZTUJas,
Jay Lyons,Jay,Lyons,"ou=sales,dc=example,dc=domain",wxEIbw18tW9uFYXtMI9H,
Jonathan White,Jonathan,White,"ou=sales,dc=example,dc=domain",caoHcm2Y90lIH7zskJYr,
Adam Roberts,Adam,Roberts,"ou=sales,dc=example,dc=domain",Qu0y7mlb2haQQddxYrcN,
Georgina Jones,Georgina,Jones,"ou=sales,dc=example,dc=domain",rYBjxs4tpj9Qza7HcKYI,
Lee Newton,Lee,Newton,"ou=sales,dc=example,dc=domain",6CVlBvEutc3Ahco2UI5q,
Aaron Smith,Aaron,Smith,"ou=sales,dc=example,dc=domain",hmSSoKILfvrHuHbPTDIQ,
Max Hall,Max,Hall,"ou=sales,dc=example,dc=domain",11Ys9Zdk2M8J1JAScBkP,
Kimberley Douglas,Kimberley,Douglas,"ou=sales,dc=example,dc=domain",WQ9285gSHv2MXkwoLYlg,
Denise Fisher,Denise,Fisher,"ou=sales,dc=example,dc=domain",CT1pbfAnCoezuyrJbQX9,
python3 youzer.py --wordlist ~/tools/pw/Probable-Wordlists/Real-Passwords/Top12Thousand-probable-v2.txt --ou "ou=IT,dc=example,dc=domain" --domain example --users 1000 --output IT_example.csv
?88 d8P d8888b ?88 d8Pd88888P d8888b 88bd88b
d88 88 d8P' ?88d88 88 d8P' d8b_,dP 88P' `
?8( d88 88b d88?8( d88 d8P' 88b d88
`?88P'?8b `?8888P'`?88P'?8bd88888P'`?888P'd88'
)88
,d8P version : 0.1
`?888P'
author : @lorentzenman
team : SpiderLabs
[-] 域名设置为 : example
[*] 正在写入输出文件 : IT_example.csv
[!] 正在以单词列表模式生成 1000 个用户
[!] 正在创建用于导入的 PowerShell 脚本 : IT_example.ps1
上述单词列表选项的 CSV 文件示例输出
Name,GivenName,sn,ou,password,address,description
Rhys Parker,Rhys,Parker,"ou=IT,dc=example,dc=domain",houston,
Geoffrey Harris,Geoffrey,Harris,"ou=IT,dc=example,dc=domain",clothing,
Georgia Davis,Georgia,Davis,"ou=IT,dc=example,dc=domain",spotty,
Gemma Norris,Gemma,Norris,"ou=IT,dc=example,dc=domain",brendan1,
Daniel Marsh,Daniel,Marsh,"ou=IT,dc=example,dc=domain",pauline,
Dominic Harvey,Dominic,Harvey,"ou=IT,dc=example,dc=domain",devin,
Teresa Stokes,Teresa,Stokes,"ou=IT,dc=example,dc=domain",snapple,
Joanna Morgan,Joanna,Morgan,"ou=IT,dc=example,dc=domain",volcom,
Oliver Middleton,Oliver,Middleton,"ou=IT,dc=example,dc=domain",master,