Revision 3 as of 2007-07-11 18:52:30

Clear message

Skill: Intermediate Complexity: Minimal estTimeToComplete: 0.5 Hours

Randomized Network MAC Address

You leak information about yourself everytime you associate to a network. Your computers network hardware contains an encoded, unique and serialized hexadecimal address. The MAC address is used by routers and switches on networks to direct traffic to and from your laptop.

Randomizing the MAC address your network hardware reports affords some level of anonymity and privacy.

CAUTION!: While randomization of the MAC address may afford some degree of anonymity and privacy your network traffic activity may identify you. Additionally, if you fully randomize your MAC address you may report such a bizzare hardware vendor id as to be quite conspicuous.

Commands in this quide assume you have sudo'ed root. i.e., sudo -i after each terminal login.

Install NetworkManager

You likely have it installed already and can skip this step. To check ls /etc/NetworkManager which should return at least dispatcher.d. If you don't have it installed already, load it.

apt-get install network-manager

Install MACCHANGER

The package macchanger is in the Networking (universe). Install it.

apt-get install macchanger

Create the Randomizer Trigger

Utilizing Network-Managers methods to trigger events when a network interface changes state, place the macchanger script into /etc/network/if-pre-up.d.

vi /etc/network/if-pre-up.d/macchanger

# Radomize the mac address for the given interface
/usr/bin/macchanger -e $IFACE

Interface State Change

Now everytime any managed interface is activated, as it passes through the pre-up phase, the network MAC address will be randomized under the VENDOR id.

Fully Random

If you desire a completely random MAC address change the -e in the macchanger script to -r. There are additional switches you may consider. man macchanger.

Anonymity, Privacy, Detection

CAUTION!: While randomization of the MAC address may afford some degree of anonymity and privacy your network traffic activity may identify you. Additionally, if you fully randomize your MAC address you may report such a bizzare hardware vendor id as to be quite conspicuous.

Creative Commons License

Author: James B. Crocker

EMail: ubuntu@james.crocker.name

[http://i.creativecommons.org/l/by-sa/3.0/88x31.png]

This work is licensed under a [http://creativecommons.org/licenses/by-sa/3.0/ Creative Commons Attribution-Share Alike 3.0 License].


CategoryDocumentation CategorySecurity