第二章
whois 域名
whois wujialiang.com
#查詢域名信息省略法律聲明
whois -H lx138.com
#指定查詢端口
whois -p 80 lx138.com
kali偵察DNS的幾個工具
命令 | 說明 |
---|---|
dnsrnum,dnsmap,dnsrecon | 這些事綜合的DNS掃描器-DNS記錄詳細(xì)目錄(A附井、MX羡忘、TXT卷雕、SOA票从、通配符等)子區(qū)域暴力攻擊、谷歌查找反向查找區(qū)域轉(zhuǎn)換以及區(qū)域移動峰鄙,dnsrecon通常是第一選擇-他是非常可靠的結(jié)果也很容易理解魁蒜,數(shù)據(jù)可以直接輸入滲透測試Metasploit框架 |
dnstracer | 決定了從哪里得到一個給定的域名系統(tǒng)給DNS信息,并隨著DNS服務(wù)器锥咸,回到擁有數(shù)據(jù)的服務(wù)器 |
dnswalk | DNS調(diào)試器搏予,為規(guī)定的檢查其內(nèi)部的穩(wěn)定性和準(zhǔn)確性 |
fierce | 針對規(guī)定的域名弧轧,試著通過區(qū)域轉(zhuǎn)換和蠻力攻擊得到DNS信息精绎,定位為連續(xù)的IP空間和主機名 |
man dnsrecon
簡要介紹一些命令以及參數(shù)
名字(name) dnsrecon 枚舉和掃描工具
簡介(SYNOPSIS)dnsrecon(選項)
選項(參數(shù))
參數(shù) | 解釋 |
---|---|
-h,--help | 幫助捺典,顯示幫助信息并且退出 |
-d,--domain | 枚舉目標(biāo)域名 |
-r,--range | IP范圍用于格式中的反向查找暴力(第一個和最后一個)或在(范圍/位掩碼)中。 |
-n,--name_server | 使用域名服務(wù)擎浴,如果為空目標(biāo)的SOA會被使用 |
-D,--dictionary | 用于暴力破解的子域和主機名的字典文件 |
-f | 篩選出在保存記錄時解析為通配符定義的IP地址的強力域查找記錄毒涧。 |
-t,--type | 指定要執(zhí)行的枚舉類型 |
std:要枚舉常規(guī)記錄類型仿吞,請枚舉捡偏。SOA银伟、NS、A彤避、AAAA琉预、MX和SRV(如果AXRF位于NS服務(wù)器故障。 | |
rvl:反向查找給定的CIDR IP范圍 | |
brt :使用所給的字典暴力破解域名和主機 |
dnsrecon -t std -d baidu.com
NS名稱服務(wù)器
MX郵件交換主機
SPF發(fā)送者策略框架
參數(shù) | 解釋 |
---|---|
dnsdict6 | 使用基于具備字典文件或者他自己的因特網(wǎng)列表的蠻力搜索來列舉耳機域名贮缅,從而獲得已經(jīng)存在的IPV4和IPV6地址 |
dnsrevenum6 | 給定一個IPV6地址谴供,執(zhí)行反DNS枚舉 |
kali2.0以后沒有了dnsdict6齿坷,需要自己安裝,下載地址
把下載安裝包拖動到桌面崎场,ls然后解壓
tar -xzvf thc-ipv6-3.0.tar.gz
cd thc-ipv6-3.0
apt-get install libpcap-dev libssl-dev
make
cp dnsdict6 /usr/bin/
列舉百度的一些二級域名
dnsdict6 baidu.com
traceroute
traceroute跟蹤從其上的IP網(wǎng)絡(luò)獲取的路由包到一個給定的主機谭跨。它利用IP協(xié)議的生存時間(TTL)字段李滴,并嘗試引發(fā)ICMP時間\超出每個字段的響應(yīng)沿著到主機的路徑的網(wǎng)關(guān)。# windows下運行
tracrt 61.135.169.121
kali提供的路由掃描工具
參數(shù) | 解釋 |
---|---|
hping3 | u這是一個TCP/IP數(shù)據(jù)包的匯編器和分析器。它支持TCP芹助、UDP状土、ICMP以及raw-IP |
intrace | 通過利用現(xiàn)有的TCP連接,包括同本地系統(tǒng)或者網(wǎng)絡(luò)以及主機啟動該程序使用戶能計算IP hop數(shù)蒙谓。這對繞過外部過濾器(如防火墻)是很有用的彼乌。intrace用來代替無可信保障的Otrace程序。 |
trace6 | 這是一個使用ICMP6的traceroute程序 |
谷歌不允許ping請求慰照。
ping www.google.com.hk
#windows下出現(xiàn)請求超時,谷歌阻塞了給予ICMP的ping命令
hping3 -S www.google.com.hk -p 80 -c 3
#使用SYN表示集 -s的tcp像谷歌發(fā)送一個類ping命令
# 把數(shù)據(jù)包直接發(fā)送到80端口
# 為發(fā)送的目標(biāo)的三個數(shù)據(jù)包設(shè)置計數(shù)器
theharvester
參數(shù) | 解釋 |
---|---|
-d | 用來確定搜索的域毒租,一般的域或者目標(biāo)網(wǎng)站 |
-b | 用來確定提取信息的來源,來源必須是下面一種:Bing,BingAPI,Google,Google-Profiles,Jigsaw,LinkedIn,People123,PGP,或者以上全部 |
-l | 該選項使theharverster搜集來自特定數(shù)目的返回搜索結(jié)果的數(shù)據(jù) |
-f | 用來保存最會后的結(jié)果惕医,HTML或者XML |
-d: Domain to search or company name
-b: data source: baidu, bing, bingapi, censys, crtsh, dogpile,
google, google-certificates, googleCSE, googleplus, google-profiles,
hunter, linkedin, netcraft, pgp, threatcrowd,
twitter, vhost, virustotal, yahoo, all
-g: use Google dorking instead of normal Google search
-s: start in result number X (default: 0)
-v: verify host name via DNS resolution and search for virtual hosts
-f: save the results into an HTML and XML file (both)
-n: perform a DNS reverse query on all ranges discovered
-c: perform a DNS brute force for the domain name
-t: perform a DNS TLD expansion discovery
-e: use this DNS server
-p: port scan the detected hosts and check for Takeovers (80,443,22,21,8080)
-l: limit the number of results to work with(Bing goes from 50 to 50 results,
Google 100 to 100, and PGP doesn't use this option)
-h: use SHODAN database to query discovered hosts
Examples:
theharvester -d microsoft.com -l 500 -b google -f myresults.html
theharvester -d microsoft.com -b pgp, virustotal
theharvester -d microsoft -l 200 -b linkedin
theharvester -d microsoft.com -l 200 -g -b google
theharvester -d apple.com -b googleCSE -l 500 -s 300
theharvester -d cornell.edu -l 100 -b bing -h
theharvester -d lut.cn -l 10 -b baidu
在Kali系統(tǒng)中螟够,Metagoofil工具通過執(zhí)行谷歌搜索來確定并下載目標(biāo)網(wǎng)站的文件(包 括:.doc峡钓、.docx、.pdf寞宫、.ppts、.xls和.xlsx)并提取用戶名辈赋、軟件版本膏燕、存儲路徑名煌寇,以及 服務(wù)器或丁作站名。
用法
Usage:
metagoofil
options
-d: domain to search
-t: filetype to download (pdf,doc,xls,ppt,odp,ods,docx,xlsx,pptx)
-l: limit of results to search (default 200)
-h: work with documents in directory (use "yes" for local analysis) -n: limit of files to download -o: working directory -f: output file Examples:
metagoofil.py -d microsoft.com -t doc,pdf -l 200 -n 50 -o microsoftfiles -f results.html
metagoofil.py -h yes -o microsoftfiles -f results.html (local dir analysis)
kali2.0已經(jīng)沒有了對metagoofil,可以看一下