文章来源:Khan安全攻防实验室
此脚本尝试通过查看 URL 中的 Google Analytics ID 来获取相关域/子域。首先在网页中搜索Google Analytics的ID,然后使用ID请求builtwith和hackertarget
-> "www\.googletagmanager\.com/ns\.html\?id=[A-Z0-9\-]+"
-> GTM-[A-Z0-9]+
-> "UA-\d+-\d+"
> git clone https://github.com/Josue87/AnalyticsRelationships.git
> cd AnalyticsRelationships/Python
> sudo pip3 install -r requirements.txt
> python3 analyticsrelationships.py -u https://www.example.com
或者将输出重定向到文件(横幅或信息消息被发送到错误输出):
python3 analyticsrelationships.py -u https://www.example.com > /tmp/example.txt
输出重定向到文件 /tmp/example.txt:
没有重定向:
Go安装
> git clone https://github.com/Josue87/AnalyticsRelationships.git
> cd AnalyticsRelationships/GO
> go build -ldflags "-s -w"
> ./analyticsrelationships --url https://www.example.com
或者将输出重定向到文件(横幅或信息消息被发送到错误输出):
> ./analyticsrelationships --url https://www.example.com > /tmp/example.txt
没有重定向: