file-type

ARP扫描工具 arp-scan-1.9:Linux下的IP冲突检测源码包

1星 | 下载需积分: 48 | 360KB | 更新于2025-01-28 | 116 浏览量 | 4 评论 | 26 下载量 举报 收藏
download 立即下载
在今天的数字世界中,网络管理和故障排除变得至关重要。其中,ARP(地址解析协议)扫描工具在网络管理员的工作中扮演着不可或缺的角色。ARP协议用于将网络层的IP地址解析为链路层的MAC地址。在Linux操作系统中,arp-scan是一个功能强大的网络工具,它可以帮助网络管理员检测网络中的IP地址冲突以及发现网络上的设备。 ### ARP协议和ARP扫描简介 ARP协议是网络通信的基础协议之一。它工作在数据链路层和网络层之间,主要任务是将网络中的IP地址转换为对应的物理硬件地址(MAC地址)。在正常的网络通信过程中,当一个设备需要向另一个设备发送数据时,它首先会检查ARP缓存表,查看是否已经存储了目的IP地址对应的MAC地址。如果找到了对应关系,数据就可以直接发送到对应的MAC地址上。如果没有找到,设备会发送一个ARP请求广播包,询问网络上所有设备谁拥有指定的IP地址,并等待回应,从而获取正确的MAC地址。 在某些情况下,网络上可能会出现IP地址冲突。这通常发生在两个设备被错误地配置成了相同的IP地址时。当这种情况发生时,网络通信可能会出现混乱,导致数据包丢失或错误地发送到错误的设备上。因此,及时发现和解决IP地址冲突对于保证网络的正常运行至关重要。 ### arp-scan工具的安装和使用 arp-scan是一个专门用于在Linux环境下进行ARP扫描的工具。它可以从命令行接受IP地址范围作为参数,并向这些地址发送ARP请求,从而获取响应并显示网络上的设备信息。arp-scan支持广泛的选项,可以定制扫描过程,包括扫描的速率、数据包类型、输出格式等。 给定文件信息中提供了arp-scan 1.9版本的源码包文件“arp-scan-1.9.tar.gz”。安装arp-scan的步骤如下: 1. 使用`tar`命令解压源码包。 ```bash tar -xzvf arp-scan-1.9.tar.gz ``` 2. 进入解压后的目录。 ```bash cd arp-scan-1.9 ``` 3. 运行`autoreconf --install`命令来安装工具依赖的环境。 ```bash ./autoreconf --install ``` 4. 执行`./configure`来配置安装环境。 5. 编译安装arp-scan。 ```bash make && make check && make install ``` 这个过程中,`make`命令负责编译源码,`make check`用来进行测试确保程序的正确性,最后`make install`将程序安装到系统路径中。 ### arp-scan的特点和应用场景 arp-scan具有多种特性,使其成为网络管理和故障排查的重要工具: - **灵活的扫描范围**:arp-scan允许用户指定扫描的IP地址范围,无论是单个IP、一个子网还是多个子网。 - **详细的设备信息**:扫描结果不仅包括IP地址,还包括对应的MAC地址、网络接口类型等信息。 - **自定义扫描参数**:用户可以定制扫描速度、发送的ARP请求类型等参数。 - **脚本和自动化**:arp-scan可以用于创建脚本,自动检测网络拓扑结构或监控特定IP地址的变动。 - **网络入侵检测**:arp-scan也可作为网络入侵检测系统的一部分,用来检测和报告异常的ARP活动。 arp-scan特别适合于以下应用场景: - **网络监控**:定期运行arp-scan可以检测网络中的IP地址冲突情况。 - **安全审计**:检查网络中的动态ARP表项,以发现可能的ARP欺骗或中毒设备。 - **故障排除**:在设备无法连接时,arp-scan有助于识别问题是否由网络上的设备引起。 - **网络规划和管理**:帮助网络管理员绘制准确的网络设备图谱。 ### 结论 arp-scan工具是Linux平台上一个非常有效的ARP扫描工具,它帮助网络管理员在复杂的网络环境中维护和管理设备。无论是解决IP地址冲突、网络入侵检测,还是用于更广泛的网络监控和审计,arp-scan都是一个不可或缺的工具。通过使用该工具,网络管理员可以确保网络的健康和安全,提高网络的可靠性和效率。

相关推荐

filetype

root@ImmortalWrt:~# tcpdump -i br-lan -nn 'arp' tcpdump: verbose output suppressed, use -v[v]... for full protocol decode listening on br-lan, link-type EN10MB (Ethernet), snapshot length 262144 bytes 23:19:48.700409 ARP, Request who-has 192.168.2.190 tell 192.168.2.11, length 46 23:19:48.818338 ARP, Request who-has 192.168.2.159 tell 192.168.2.159, length 46 23:19:48.857705 ARP, Request who-has 192.168.2.118 tell 192.168.2.118, length 46 23:19:48.951036 ARP, Request who-has 192.168.2.193 tell 192.168.2.193, length 46 23:19:49.741960 ARP, Request who-has 192.168.2.190 tell 192.168.2.11, length 46 23:19:50.765910 ARP, Request who-has 192.168.2.190 tell 192.168.2.11, length 46 23:19:53.645945 ARP, Request who-has 192.168.2.113 tell 192.168.2.11, length 46 23:19:53.698932 ARP, Reply 192.168.2.113 is-at 7c:c2:94:5d:1d:9f, length 46 23:19:56.644027 ARP, Request who-has 192.168.2.2 tell 192.168.2.1, length 46 23:19:56.644043 ARP, Reply 192.168.2.2 is-at 00:0c:29:88:a8:5d, length 28 23:19:56.901893 ARP, Request who-has 192.168.2.11 tell 192.168.2.1, length 46 23:19:56.902638 ARP, Reply 192.168.2.11 is-at 00:0c:29:b3:d9:93, length 46 23:19:58.822726 ARP, Request who-has 192.168.2.159 tell 192.168.2.159, length 46 23:19:58.859986 ARP, Request who-has 192.168.2.118 tell 192.168.2.118, length 46 23:19:58.953302 ARP, Request who-has 192.168.2.193 tell 192.168.2.193, length 46 23:20:00.207269 ARP, Request who-has 192.168.2.12 (ff:ff:ff:ff:ff:ff) tell 192.168.2.2, length 28 23:20:00.207683 ARP, Reply 192.168.2.12 is-at b8:97:5a:eb:2b:49, length 46 23:20:00.208557 ARP, Request who-has 192.168.2.13 (ff:ff:ff:ff:ff:ff) tell 192.168.2.2, length 28 23:20:00.208847 ARP, Reply 192.168.2.13 is-at 00:0c:29:c3:6f:66, length 46 23:20:00.210712 ARP, Request who-has 192.168.2.1 (ff:ff:ff:ff:ff:ff) tell 192.168.2.2, length 28 23:20:00.211301 ARP, Reply 192.168.2.1 is-at a4:a9:30:cd:d2:4c, length 46 23:20:00.212879 ARP, Request who-has 192.168.2.160 (ff:ff:ff:ff:ff:ff) tell 192.168.2.2, length 28 23:20:00.213905 ARP, Request who-has 192.168.2.11 (ff:ff:ff:ff:ff:ff) tell 192.168.2.2, length 28 23:20:00.214100 ARP, Reply 192.168.2.11 is-at 00:0c:29:b3:d9:93, length 46 23:20:00.252506 ARP, Reply 192.168.2.160 is-at 54:ef:44:46:85:9a, length 46 23:20:00.309073 ARP, Request who-has 192.168.2.182 (ff:ff:ff:ff:ff:ff) tell 192.168.2.2, length 28 23:20:00.310294 ARP, Request who-has 192.168.2.201 (ff:ff:ff:ff:ff:ff) tell 192.168.2.2, length 28 23:20:00.312394 ARP, Reply 192.168.2.182 is-at 54:ef:44:46:67:92, length 46 23:20:00.314036 ARP, Request who-has 192.168.2.214 (ff:ff:ff:ff:ff:ff) tell 192.168.2.2, length 28 23:20:00.332624 ARP, Request who-has 192.168.2.234 (ff:ff:ff:ff:ff:ff) tell 192.168.2.2, length 28 23:20:00.337297 ARP, Reply 192.168.2.234 is-at 54:ef:44:46:83:1a, length 46 23:20:00.362484 ARP, Reply 192.168.2.214 is-at 38:00:25:8a:8f:04, length 46 23:20:01.310351 ARP, Request who-has 192.168.2.201 (ff:ff:ff:ff:ff:ff) tell 192.168.2.2, length 28

filetype

逐行解析一下root@ImmortalWrt:~# tcpdump -i br-lan -nn 'arp' tcpdump: verbose output suppressed, use -v[v]... for full protocol decode listening on br-lan, link-type EN10MB (Ethernet), snapshot length 262144 bytes 23:39:17.345552 ARP, Request who-has 192.168.2.1 (ff:ff:ff:ff:ff:ff) tell 192.168.2.2, length 28 23:39:17.346296 ARP, Reply 192.168.2.1 is-at a4:a9:30:cd:d2:4c, length 46 23:39:17.346434 ARP, Request who-has 192.168.2.160 (ff:ff:ff:ff:ff:ff) tell 192.168.2.2, length 28 23:39:17.350042 ARP, Request who-has 192.168.2.13 (ff:ff:ff:ff:ff:ff) tell 192.168.2.2, length 28 23:39:17.350302 ARP, Reply 192.168.2.13 is-at 00:0c:29:c3:6f:66, length 46 23:39:17.353640 ARP, Request who-has 192.168.2.11 (ff:ff:ff:ff:ff:ff) tell 192.168.2.2, length 28 23:39:17.353958 ARP, Reply 192.168.2.11 is-at 00:0c:29:b3:d9:93, length 46 23:39:17.355578 ARP, Request who-has 192.168.2.12 (ff:ff:ff:ff:ff:ff) tell 192.168.2.2, length 28 23:39:17.355847 ARP, Reply 192.168.2.12 is-at b8:97:5a:eb:2b:49, length 46 23:39:17.476310 ARP, Request who-has 192.168.2.182 (ff:ff:ff:ff:ff:ff) tell 192.168.2.2, length 28 23:39:17.478113 ARP, Request who-has 192.168.2.201 (ff:ff:ff:ff:ff:ff) tell 192.168.2.2, length 28 23:39:17.483021 ARP, Request who-has 192.168.2.214 (ff:ff:ff:ff:ff:ff) tell 192.168.2.2, length 28 23:39:17.485643 ARP, Request who-has 192.168.2.234 (ff:ff:ff:ff:ff:ff) tell 192.168.2.2, length 28 23:39:17.490919 ARP, Reply 192.168.2.160 is-at 54:ef:44:46:85:9a, length 46 23:39:17.493686 ARP, Reply 192.168.2.182 is-at 54:ef:44:46:67:92, length 46 23:39:17.496285 ARP, Reply 192.168.2.214 is-at 38:00:25:8a:8f:04, length 46 23:39:18.478162 ARP, Request who-has 192.168.2.201 (ff:ff:ff:ff:ff:ff) tell 192.168.2.2, length 28 23:39:18.485684 ARP, Request who-has 192.168.2.234 (ff:ff:ff:ff:ff:ff) tell 192.168.2.2, length 28

filetype

root@ImmortalWrt:~# tcpdump -i br-lan arp tcpdump: verbose output suppressed, use -v[v]... for full protocol decode listening on br-lan, link-type EN10MB (Ethernet), snapshot length 262144 bytes 21:37:22.974416 ARP, Request who-has 192.168.2.47 tell 192.168.2.11, length 46 21:37:23.728505 ARP, Request who-has 192.168.2.16 tell 192.168.2.11, length 46 21:37:23.984477 ARP, Request who-has 192.168.2.47 tell 192.168.2.11, length 46 21:37:24.097443 ARP, Request who-has 192.168.2.204 tell 192.168.2.1, length 46 21:37:24.419089 ARP, Request who-has 192.168.2.164 tell 192.168.2.1, length 46 21:37:25.008510 ARP, Request who-has 192.168.2.47 tell 192.168.2.11, length 46 21:37:25.111376 ARP, Request who-has 192.168.2.204 tell 192.168.2.1, length 46 21:37:25.431614 ARP, Request who-has 192.168.2.164 tell 192.168.2.1, length 46 21:37:26.135719 ARP, Request who-has 192.168.2.204 tell 192.168.2.1, length 46 21:37:26.455742 ARP, Request who-has 192.168.2.164 tell 192.168.2.1, length 46 21:37:26.795248 ARP, Request who-has 192.168.2.74 tell 192.168.2.11, length 46 21:37:27.049590 ARP, Request who-has 192.168.2.179 tell 192.168.2.11, length 46 21:37:27.183999 ARP, Request who-has 192.168.2.204 tell 192.168.2.1, length 46 21:37:27.824556 ARP, Request who-has 192.168.2.74 tell 192.168.2.11, length 46 21:37:27.826488 ARP, Request who-has 192.168.2.164 tell 192.168.2.1, length 46 21:37:28.054472 ARP, Request who-has 192.168.2.30 tell 192.168.2.30, length 46 21:37:28.080542 ARP, Request who-has 192.168.2.179 tell 192.168.2.11, length 46 21:37:28.216214 ARP, Request who-has 192.168.2.204 tell 192.168.2.1, length 46 ^C 18 packets captured 18 packets received by filter 0 packets dropped by kernel root@ImmortalWrt:~#root@ImmortalWrt:~# uci show dhcp dhcp.@dnsmasq[0]=dnsmasq dhcp.@dnsmasq[0].domainneeded='1' dhcp.@dnsmasq[0].boguspriv='1' dhcp.@dnsmasq[0].filterwin2k='0' dhcp.@dnsmasq[0].localise_queries='1' dhcp.@dnsmasq[0].rebind_protection='1' dhcp.@dnsmasq[0].rebind_localhost='1' dhcp.@dnsmasq[0].local='/lan/' dhcp.@dnsmasq[0].domain='lan' dhcp.@dnsmasq[0].expandhosts='1' dhcp.@dnsmasq[0].min_cache_ttl='3600' dhcp.@dnsmasq[0].use_stale_cache='3600' dhcp.@dnsmasq[0].cachesize='8000' dhcp.@dnsmasq[0].nonegcache='1' dhcp.@dnsmasq[0].authoritative='1' dhcp.@dnsmasq[0].readethers='1' dhcp.@dnsmasq[0].leasefile='/tmp/dhcp.leases' dhcp.@dnsmasq[0].nonwildcard='1' dhcp.@dnsmasq[0].localservice='1' dhcp.@dnsmasq[0].dns_redirect='1' dhcp.@dnsmasq[0].ednspacket_max='1232' dhcp.@dnsmasq[0].filter_aaaa='0' dhcp.@dnsmasq[0].filter_a='0' dhcp.@dnsmasq[0].noresolv='0' dhcp.@dnsmasq[0].localuse='1' dhcp.@dnsmasq[0].resolvfile='/tmp/resolv.conf.d/resolv.conf.auto' dhcp.lan=dhcp dhcp.lan.interface='lan' dhcp.lan.start='100' dhcp.lan.limit='150' dhcp.lan.leasetime='12h' dhcp.lan.dhcpv4='server' dhcp.lan.ignore='1' dhcp.wan=dhcp dhcp.wan.interface='wan' dhcp.wan.ignore='1' dhcp.odhcpd=odhcpd dhcp.odhcpd.maindhcp='0' dhcp.odhcpd.leasefile='/tmp/hosts/odhcpd' dhcp.odhcpd.leasetrigger='/usr/sbin/odhcpd-update' dhcp.odhcpd.loglevel='4'

资源评论
用户头像
李诗旸
2025.08.19
这款ARP扫描工具对于Linux平台的网络问题诊断非常实用。
用户头像
洪蛋蛋
2025.06.16
确保网络安全,ARP扫描不可或缺。
用户头像
魏水华
2025.06.11
安装过程简单明了,非常适合技术用户使用。
用户头像
阿汝娜老师
2025.05.19
对于需要快速识别IP地址冲突的用户来说,它是一个高效的解决方案。☔️
kerry616
  • 粉丝: 0
上传资源 快速赚钱