Linux下修改网卡MAC地址最直接的方式是修改 /etc/network/interfaces 文件配置,如:
auto eth0
iface eth0 inet dhcp
hwaddress eth0 11:AA:22:BB:33:DD
保存后重启网络服务即可。
下面是使用macchanger克隆MAC地址的方法。
Debian/Ubuntu下安装命令:
xxx@yyy:~$ sudo apt-get install macchanger
先看帮助文档:
xxx@yyy:~$ macchanger --help
GNU MAC Changer
Usage: macchanger [options] device
-h, --help Print this help
-V, --version Print version and exit
-s, --show Print the MAC address and exit
-e, --ending Don't change the vendor bytes
-a, --another Set random vendor MAC of the same kind
-A Set random vendor MAC of any kind
-p, --permanent Reset to original, permanent hardware MAC
-r, --random Set fully random MAC
-l,