MAC address to IP conversion
While there are many tutoria开发者_StackOverflow社区ls on IP to MAC address conversion not much is available for the reverse process. I've checked out RARP(which is just the protocol). Is there a method for MAC to IP conversion. Thanks!
On Linux you can get this type of information using arp
command:
$ sudo arp -n
Address HWtype HWaddress Flags Mask Iface
192.168.1.5 ether 01:00:00:11:44:11 C eth0
192.168.1.6 ether 02:00:00:44:33:22 C eth0
I've exact solution of your question let me explain everything which you need like how to convert MAC address to IP address or MAC to IPv4 IPv6 IP address? What is MAC Address? A mac address is 48 bits, an IPv6 address is 128 bits.
Here is the MAC to IP address conversion process step by step:
take the mac address: for example 52:74:f2:b1:a8:7f.
throw ff:fe in the middle: 52:74:f2:ff:fe:b1:a8:7f.
reformat to IPv6 notation 5274:f2ff:feb1:a87f.
convert the first octet from hexadecimal to binary: 52 -> 01010010.
invert the bit at index 6 (counting from 0): 01010010 -> 01010000.
convert octet back to hexadecimal: 01010000 -> 50.
replace first octet with newly calculated one: 5074:f2ff:feb1:a87f.
prepend the link-local prefix: fe80::5074:f2ff:feb1:a87f.
How MAC address converter tool works? You can also use perfect MAC address converter can convert any MAC address into IPv4 internet protocol address ranges and IPV6 internet protocol address ranges . It takes MAC Address as input string and generates a query against given MAC address and conversion option like convert into IPv6 to IPv4 or both then performs the above steps. Query generates an output response according to selected options.As well as tool produces an invalid input message response if provided MAC address is invalid or not convert able.
精彩评论