FProbe - 快速HTTP探测
GO111MODULE=on go get -u github.com/theblackturtle/fprobe
Status Code、Content Type、Location。Usage of fprobe:
-c int
Concurrency (default 50)
-cidr
Generate IP addresses from CIDR
-i string
Input file (default is stdin) (default "-")
-l Use ports in the same line (google.com,2087,2086)
-p value
add additional probe (proto:port)
-prefer-https
only try plain HTTP if HTTPS fails
-s skip the default probes (http:80 and https:443)
-t int
Timeout (seconds) (default 9)
-v Turn on verbose
标准输入
❯ cat domains.txt | fprobe
文件输入
❯ fprobe -i domains.txt
❯ cat domains.txt | fprobe -c 200
如果你想为每个域名使用特殊端口,可以使用-l标志。你可以解析Nmap/Masscan的输出并重新格式化以使用此功能。
输入 (domains.txt)
google.com,2087,2086,8880,2082,443,80,2052,2096,2083,8080,8443,2095,2053
yahoo.com,2087,2086,8880,2082,443,80,2052,2096,2083,8080,8443,2095,2053
sport.yahoo.com,2086,443,2096,2053,8080,2082,80,2083,8443,2052,2087,2095,8880
命令
❯ cat domains.txt | fprobe -l
❯ cat domains.txt | fprobe -t 10
❯ cat domains.txt | fprobe -p http:8080 -p https:8443
❯ echo 'https://google.com/path1?param=1' | fprobe
https://google.com/path1?param=1
❯ echo '192.168.1.1/24' | fprobe -cidr
❯ cat domains.txt | fprobe -p medium/large/xlarge
如果你不想探测80端口的HTTP或443端口的HTTPS,可以使用-s标志。
❯ cat domains.txt | fprobe -s
详细输出将以JSON格式呈现,包含一些额外的头部,如Status Code、Content Type、Location。
❯ cat domains.txt | fprobe -v
{"site":"http://google.com","status_code":301,"server":"gws","content_type":"text/html; charset=UTF-8","location":"http://www.google.com/"}
{"site":"https://google.com","status_code":301,"server":"gws","content_type":"text/html; charset=UTF-8","location":"https://www.google.com/"}
本工具的理念和部分代码来源于@tomnomnom编写的httprobe。