How to spoof your ether MAC on FreeBSD

D

Deleted member 30996

Guest
This command will allow you to change your current ether MAC on your FreeBSD boxen without bringing down and back up the network interface. In this instance shown using the designated network interface of my machina and spoofed ether MAC as an example:

# ifconfig bge0 ether DE:AD:B0:0B:DE:AD

It can be set to anything that stays within the MAC character limits of 0-9 and A-F, or a-f is acceptable as well.

Be sure to run # ifconfig -a before issuing the command and make note of your original ether MAC should you need to change it back.

This way you can see for yourself that the MAC has changed by running it again after the command is issued.

Below is an example of how it's spoofed and then set back to the original ether MAC using the steps I have described:

Code:
root@jigoku:/ # ifconfig -a
bge0: flags=8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> metric 0 mtu 1500
options=c019b<RXCSUM,TXCSUM,VLAN_MTU,VLAN_HWTAGGING,VLAN_HWCSUM,TSO4,VLAN_HWTSO,LINKSTATE>
    ether b0:0b:de:ad:b0:0b
    inet 192.168.1.7 netmask 0xffffff00 broadcast 192.168.1.255
    media: Ethernet autoselect (100baseTX <full-duplex>)
    status: active
    nd6 options=29<PERFORMNUD,IFDISABLED,AUTO_LINKLOCAL>
lo0: flags=8049<UP,LOOPBACK,RUNNING,MULTICAST> metric 0 mtu 16384
options=680003<RXCSUM,TXCSUM,LINKSTATE,RXCSUM_IPV6,TXCSUM_IPV6>
    inet6 ::1 prefixlen 128
    inet6 fe80::1%lo0 prefixlen 64 scopeid 0x2
    inet 127.0.0.1 netmask 0xff000000
    groups: lo
    nd6 options=21<PERFORMNUD,AUTO_LINKLOCAL>
pflog0: flags=141<UP,RUNNING,PROMISC> metric 0 mtu 33160
groups: pflog

root@jigoku:/ # ifconfig bge0 ether DE:AD:B0:0B:DE:AD
root@jigoku:/ # ifconfig -a
bge0: flags=8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> metric 0 mtu 1500
options=c019b<RXCSUM,TXCSUM,VLAN_MTU,VLAN_HWTAGGING,VLAN_HWCSUM,TSO4,VLAN_HWTSO,LINKSTATE>
    ether de:ad:b0:0b:de:ad
    hwaddr 1c:75:08:22:06:65
    inet 192.168.1.7 netmask 0xffffff00 broadcast 192.168.1.255
    media: Ethernet autoselect (100baseTX <full-duplex>)
    status: active
    nd6 options=29<PERFORMNUD,IFDISABLED,AUTO_LINKLOCAL>
lo0: flags=8049<UP,LOOPBACK,RUNNING,MULTICAST> metric 0 mtu 16384
options=680003<RXCSUM,TXCSUM,LINKSTATE,RXCSUM_IPV6,TXCSUM_IPV6>
    inet6 ::1 prefixlen 128
    inet6 fe80::1%lo0 prefixlen 64 scopeid 0x2
    inet 127.0.0.1 netmask 0xff000000
    groups: lo
    nd6 options=21<PERFORMNUD,AUTO_LINKLOCAL>
pflog0: flags=141<UP,RUNNING,PROMISC> metric 0 mtu 33160
groups: pflog

root@jigoku:/ # ifconfig bge0 ether b0:0b:de:ad:b0:0b
root@jigoku:/ # ifconfig -a
bge0: flags=8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> metric 0 mtu 1500
options=c019b<RXCSUM,TXCSUM,VLAN_MTU,VLAN_HWTAGGING,VLAN_HWCSUM,TSO4,VLAN_HWTSO,LINKSTATE>
    ether b0:0b:de:ad:b0:0b
    inet 192.168.1.7 netmask 0xffffff00 broadcast 192.168.1.255
    media: Ethernet autoselect (100baseTX <full-duplex>)
    status: active
    nd6 options=29<PERFORMNUD,IFDISABLED,AUTO_LINKLOCAL>
lo0: flags=8049<UP,LOOPBACK,RUNNING,MULTICAST> metric 0 mtu 16384
options=680003<RXCSUM,TXCSUM,LINKSTATE,RXCSUM_IPV6,TXCSUM_IPV6>
    inet6 ::1 prefixlen 128
    inet6 fe80::1%lo0 prefixlen 64 scopeid 0x2
    inet 127.0.0.1 netmask 0xff000000
    groups: lo
    nd6 options=21<PERFORMNUD,AUTO_LINKLOCAL>
pflog0: flags=141<UP,RUNNING,PROMISC> metric 0 mtu 33160
groups: pflog
 
Thanks. Proofreading my own material is always hardest.

The rest was copied from the terminal.
 
There is a MAC Address OUI Lookup Search tool at speedguide.net:

"About the SG MAC Address lookup tool

The MAC Address OUI search helps identify unknown devices on your local network by simply typing their MAC address (or its OUI prefix), commonly listed by your NAT/Wireless router. It can be useful in identifying network adapter manufacturers, IoT devices, wireless clients, etc.

MAC address (media access control address) is a hardware identification number that uniquely identifies each device on a network, hard-coded by the manufacturer. It is typically a string of six sets of two-digits or hex characters, separated by colons, for example: 00:40:96:AA:BB:CC . The first three octets of a MAC address are referred to as the OUI (Organizationally Unique Identifier). The OUI uniquely identifies the manufacturer, vendor, or other orgranization that makes your networked device. OUIs are assigned to vendors by the IEEE."

"No results for de:ad:b0:0b:de:ad"
 
Back
Top