2个版本
0.1.1 | 2023年11月5日 |
---|---|
0.1.0 | 2021年2月4日 |
#1929 in 网络编程
35KB
794 行
ntlm-info
检索NTLM挑战中指定的主机信息。
这可以作为一种发现内部网络中计算机名称的方式,作为反向DNS查询的替代方案,也可以从暴露于互联网的主机中发现内部域的名称。
目前可以使用以下应用程序协议来获取NTLM挑战
- HTTP
- SMB
SMB使用
快速示例,要检索本地网络中主机的名称,可以这样做
$ ntlm-info smb 192.168.100.0/24 -w 20
Target: 192.168.100.7
NbComputer: WS02-7
NbDomain: CONTOSO
DnsComputer: ws02-7.contoso.local
DnsDomain: contoso.local
Version: 6.1.7601
OS: Windows 7 | Windows Server 2008 R2
Target: 192.168.100.10
NbComputer: WS01-10
NbDomain: CONTOSO
DnsComputer: ws01-10.contoso.local
DnsDomain: contoso.local
Version: 10.0.19041
OS: Windows 10 | Windows Server 2019 | Windows Server 2016
作为smb命令的输入,您可以指定...
- 主机名
- IP地址
- 网络CIDR
此外,您还可以在文件、参数或stdin中指定这些。
cat hosts.txt | ntlm-info smb
ntlm-info smb 192.168.100.10 192.168.100.7
ntlm-info smb 192.168.100.0/24
HTTP使用
快速示例,要检索http端点的信息
$ ntlm-info http http://contoso.com/
Target: 192.168.100.10
NbComputer: WS01-10
NbDomain: CONTOSO
DnsComputer: ws01-10.contoso.local
DnsDomain: contoso.local
Version: 10.0.19041
OS: Windows 10 | Windows Server 2019 | Windows Server 2016
作为http命令的输入,您可以指定一个或多个URL。
此外,您还可以在文件、参数或stdin中指定这些。
cat urls.txt | ntlm-info http
ntlm-info http http://contoso.com/ http://company.com/owa
安装
从crates中
cargo install ntlm-info
从仓库中
cargo install --git https://github.com/Zer1t0/ntlm-info.git
在Windows中静态构建(PowerShell)
git clone https://github.com/Zer1t0/ntlm-info.git
cd ntlm-info/
$env:RUSTFLAGS='-C target-feature=+crt-static'
cargo build --release
致谢
这个工具受到 ntlm_challenger 的启发
依赖项
~15–31MB
~441K SLoC