Run the following code. Save as doarp. bat and add it to auto run.
Copy codeThe Code is as follows: @ echo OFF
If % ~ N0 = arp exit
If % ~ N0 = Arp exit
If % ~ N0 = ARP exit
Echo is obtaining local information .....
: IP
FOR/f "skip = 13 tokens = 15 usebackq" % I in ('ipconfig/all') do Set IP = % I & GOTO MAC
: MAC
Echo IP: % IP %
FOR/f "skip = 13 tokens = 12 usebackq" % I in ('ipconfig/all') do Set MAC = % I & GOTO custom IP
: Elastic IP
Echo MAC: % MAC %
Arp-s % IP % MAC %
Echo is obtaining gateway information .....
FOR/f "skip = 17 tokens = 13 usebackq" % I in ('ipconfig/all') do Set multicast IP = % I & GOTO encrypt Mac
: Running Mac
Echo IP: % GateIP %
FOR/f "skip = 3 tokens = 2 usebackq" % I in ('Arp-a % Taobao IP % ') do Set hosts MAC = % I & GOTO Start
: Start
Echo MAC: % running MAC %
Arp-d
Arp-s % GateIP % GateMAC %
Echo operation completed !!!
Exit
A detailed description is provided below:
This script is an anti-ARP attack. You can manually add local ip addresses, mac addresses, gateway ip addresses, and mac programs.
If % ~ N0 = arp exit
If % ~ N0 = Arp exit
If % ~ N0 = ARP exit // determine if the virus has been infected and exited
Echo is obtaining local information .....
: IP
FOR/f "skip = 13 tokens = 15 usebackq" % I in ('ipconfig/all') do Set IP = % I & GOTO MAC
: MAC
Echo IP: % IP %
FOR/f "skip = 13 tokens = 12 usebackq" % I in ('ipconfig/all') do Set MAC = % I & GOTO custom IP
: Elastic IP
Echo MAC: % MAC %
Arp-s % IP % MAC %
// Obtain the local IP address and mac address as prompted above. arp-s % IP % MAC % adds the local ip Address/mac address to the corresponding table of the local ip/mac address.
Echo is obtaining gateway information .....
FOR/f "skip = 17 tokens = 13 usebackq" % I in ('ipconfig/all') do Set multicast IP = % I & GOTO encrypt Mac
: Running Mac
Echo IP: % GateIP %
FOR/f "skip = 3 tokens = 2 usebackq" % I in ('Arp-a % Taobao IP % ') do Set hosts MAC = % I & GOTO Start
: Start
Echo MAC: % running MAC %
Arp-d
Arp-s % GateIP % GateMAC %
// Obtain the ip address/mac address of the Gateway. arp-s % GateIP % GateMAC % loads the ip address and mac address of the gateway to the corresponding table of the local machine.