Mac上如何对付ARP攻击 2
似乎国内很多大学的校园网ARP攻击都很泛滥,苹果论坛上不断有人询问Mac系统出现IP被占用提示的解决办法. Windows上对付ARP攻击有很多反制软件比如360安全卫士, 但是Mac/Linux上就没有现成的软件可以用, 这应该和国外局域网管理一般比较完善, ARP攻击比较罕见有关. 当然我们有很多强大的终端工具比如arpoison可以对付arp攻击, 但问题是这些工具的安装和使用对一般用户来说太过复杂.
今天在网上发现了一个相对简单的工具, 原文见这个帖子7楼.
from sandfox:
在Google上搜索到了一个开源的代码,是为OpenBSD上写的,不过我在Mac上编译过了,只要修改一个参数就可以运行了。
OpenAAPD的原文件地址是:http://www.openbeer.it/codes/projects/aapd.c
附件里面带了修改过的代码和运行程序。
运行方式:
1、在终端中进入aapd程序所在目录;
2、输入 sudo ./aapd -i en0
一般都应该是使用en0(普通网口), 如果使用无线网口,可能需要使用en1,详细情况可以使用“Network Utility”察看。
sandfox同学编译过的aapd+源程序点此下载, 在我的ibook g3 + 10.4.11 上运行通过.
附: 对系统比较熟悉的同学可以参考我在macx.cn这个帖子2楼的回复, 按下面的方法试试看arpoison
Linux上这里有一篇教程: Linux上 arpoison的使用
Mac上在安装前需要先安装darwinports和libnet, 先装好darwinports, 然后终端里执行
sudo port install libnet
接下来按照上面Linux版里提到的执行
gcc arpoison.c /usr/lib/libnet.a -o arposionsudo cp arpoison /usr/sbin
就可以直接在Mac上的终端中用arpoison 这个软件了. 使用方法是执行
sudo arpoison -i eth0 -d 网关IP -s 本机IP -t ff:ff:ff:ff:ff:ff -r 本机MAC









sudo port install libnet
—> Configuring expat
Error: Target org.macports.configure returned: configure failure: shell command ” cd “/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_ports_textproc_expat/work/expat-2.0.1″ && ./configure –prefix=/opt/local –mandir=/opt/local/share/man ” returned error 77
Command output: checking build system type… i386-apple-darwin9.6.0
checking host system type… i386-apple-darwin9.6.0
checking for gcc… /usr/bin/gcc-4.0
checking for C compiler default output file name… configure: error: C compiler cannot create executables
See `config.log’ for more details.
Error: The following dependencies failed to build: libtool automake autoconf help2man gettext expat libiconv gperf ncurses ncursesw p5-locale-gettext perl5 perl5.8 m4 netinet-headers
Error: Status 1 encountered during processing.
这怎么办呀
我的也是这样的情况,不知道怎么解决,达人如果能明示一下,那真是太感谢了!