diy:change-mac
Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
diy:change-mac [2024/06/06 04:09] – [How To Change Your MAC Address] Humphrey Boa-Gart | diy:change-mac [2024/08/06 05:48] (current) – external edit 127.0.0.1 | ||
---|---|---|---|
Line 5: | Line 5: | ||
On networks (such as your home network, or the wifi network at Starbucks) the MAC address is typically used by the network to identify and track individual machines. This means that your machine can be tracked not only every time it logs in to the same network, but it can be tracked across other networks as well. You can hinder this by changing your MAC address, or configuring it to use a **random MAC**. | On networks (such as your home network, or the wifi network at Starbucks) the MAC address is typically used by the network to identify and track individual machines. This means that your machine can be tracked not only every time it logs in to the same network, but it can be tracked across other networks as well. You can hinder this by changing your MAC address, or configuring it to use a **random MAC**. | ||
- | There are more than just privacy benefits to changing your MAC address. Some networks which provide only a limited amount of free access for guests, can have the timer reset if you disconnect, clear your browser cookies/ | + | There are more than just privacy benefits to changing your MAC address. Some networks which provide only a limited amount of free access for guests, can have the timer reset if you disconnect, clear your browser cookies/ |
MAC addresses are typically burned into the firmware of the network controller from the factory. In the past, this sometimes made them very hard to change, but this is less of a problem with modern operating systems. | MAC addresses are typically burned into the firmware of the network controller from the factory. In the past, this sometimes made them very hard to change, but this is less of a problem with modern operating systems. | ||
Scroll down for instructions for your particular system. | Scroll down for instructions for your particular system. | ||
+ | |||
+ | ===== Linux/ | ||
+ | |||
+ | ==== Manually, with ifconfig ==== | ||
+ | |||
+ | **ifconfig** (short for " | ||
+ | |||
+ | Run '' | ||
+ | |||
+ | $ ifconfig | ||
+ | |||
+ | There is a high chance it will be something like **wlan0**, but it can be anything. If you want, make note of the current MAC address under the '' | ||
+ | |||
+ | $ ifconfig wlan0 | grep ether | ||
+ | |||
+ | And it will output the current address, like '' | ||
+ | |||
+ | Set the value to any MAC address you want, like so: | ||
+ | |||
+ | $ sudo ifconfig wlan0 ether 00: | ||
+ | |||
+ | Use grep again to verify the change went through: | ||
+ | |||
+ | $ ifconfig wlan0 | grep ether | ||
+ | | ||
+ | And it should output '' | ||
+ | |||
+ | Note that this method **is not** persistent. Reboot to reset. | ||
+ | |||
+ | ==== Manual MAC Generation ==== | ||
+ | |||
+ | If you need help coming up with a random MAC, you can generate a string to use with this command: | ||
+ | |||
+ | $ openssl rand -hex 6 | sed ' | ||
===== Linux Instructions ===== | ===== Linux Instructions ===== | ||
Line 17: | Line 51: | ||
Most of you using Linux will likely have **NetworkManager** installed already. To set-and-forget your machine to automatically generate & provide a **random MAC address** every time you connect to a network, save the following file to ''/ | Most of you using Linux will likely have **NetworkManager** installed already. To set-and-forget your machine to automatically generate & provide a **random MAC address** every time you connect to a network, save the following file to ''/ | ||
- | <file conf random-mac.conf> | + | <file conf / |
- | ############################################################## | + | ######################################################### |
- | ## RANDOM MAC DROP-IN CONFIGURATION FILE FOR NETWORKMANAGER ## | + | ## DROP-IN CONFIGURATION FILE FOR NETWORKMANAGER: ## |
- | ## PROVIDED BY THE ANONYMOUS MILITARY INSTITUTE | + | ## AUTOMATIC MAC RANDOMIZATION |
- | ## HTTPS:// | + | ## REQUISITIONED FROM THE ANONYMOUS MILITARY INSTITUTE ## |
- | ############################################################## | + | ## HTTPS:// |
+ | ######################################################### | ||
[device-mac-randomization] | [device-mac-randomization] | ||
Line 38: | Line 73: | ||
$ sudo service NetworkManager restart | $ sudo service NetworkManager restart | ||
+ | |||
+ | ==== Automatically, | ||
+ | |||
+ | If you are using **iwd** and its built-in network configuration **without** NetworkManager, | ||
+ | |||
+ | [General] | ||
+ | AddressRandomization=once | ||
+ | AddressRandomizationRange=full | ||
==== Manually, with GNU MAC Changer ==== | ==== Manually, with GNU MAC Changer ==== | ||
- | Before NetworkManager had flawless MAC randomization built in, the preferred | + | Before NetworkManager had flawless MAC randomization built in, an extremely popular |
===== Windows Instructions ===== | ===== Windows Instructions ===== | ||
- | {{wst> | + | ==== Manually, with PowerShell ==== |
- | ===== Mac Instructions ===== | + | - Open the **Command Prompt** or [[tools: |
- | + | - Use the '' | |
- | {{wst> | + | - Identify the network adapter for which you want to change the MAC address. |
+ | - To change the MAC address, use this command: '' | ||
+ | - Replace ''< | ||
+ | - Press **Enter** to execute the command. | ||
+ | - Restart your computer for the changes to take effect. | ||
===== Android Instructions ===== | ===== Android Instructions ===== | ||
- | {{wst> | + | [{{ : |
+ | |||
+ | Changing your MAC address on Android is an ordeal which traditionally has involved rooting your phone. This isn't so much a problem anymore, as starting with Android 10, MAC address randomization is enabled by default. (You can double-check this if you hit the gear icon for your current wifi network, and look at the **Privacy** setting.) | ||
+ | |||
+ | However, these randomized MAC addresses are // | ||
+ | |||
+ | To set-and-forget this option: | ||
+ | |||
+ | - In **Settings**, | ||
+ | - If **Developer options** is not available, then you must enable developer access first. | ||
+ | - Under **Settings**, | ||
+ | - Find the setting **" | ||
+ | |||
+ | //More info: [[https:// | ||
{{tag> | {{tag> |
diy/change-mac.1717646979.txt.gz · Last modified: (external edit)
Find this page online at: https://bestpoint.institute/diy/change-mac
Find this page online at: https://bestpoint.institute/diy/change-mac