How to avoid mac-adress spoofing auto reset on connecting

The name of the pictureThe name of the pictureThe name of the pictureClash Royale CLAN TAG#URR8PPP











up vote
0
down vote

favorite












Everytime I spoof my mac-adress on Ubuntu using different approaches including macchanger it auto resets as soon as I actually try to reconnect to the network.



This is what my problem looks like:

TERMINAL ENTRY before reconnection



root@M-Linux:~# macchanger -s wlp2s0
Current MAC: XY (changed, obviously) (Hon Hai Precision Ind. Co.,Ltd.)
Permanent MAC: XY (Hon Hai Precision Ind. Co.,Ltd.)
root@M-Linux:~# ifconfig wlp2s0 down
root@M-Linux:~# macchanger -rb wlp2s0
Current MAC: XY (Hon Hai Precision Ind. Co.,Ltd.)
Permanent MAC: XY (Hon Hai Precision Ind. Co.,Ltd.)
New MAC: AB (unknown)
root@M-Linux:~# ifconfig wlp2s0 up
root@M-Linux:~# macchanger -s wlp2s0
Current MAC: AB (unknown)
Permanent MAC: XY (Hon Hai Precision Ind. Co.,Ltd.)


Then I reconnect to the WIFI and then this happens



root@M-Linux:~# macchanger -s wlp2s0
Current MAC: XY (Hon Hai Precision Ind. Co.,Ltd.)
Permanent MAC: XY (Hon Hai Precision Ind. Co.,Ltd.)


So the mac is back to normal.



I tried this on kubuntu 16.04.3 and another debian-based distro.



I tried it on my home and a public network. I tried it on two different machines: HP and Acer Notebooks.



Exact same results every time and NO information about the issue on the web.



What should I do?










share|improve this question















migrated from stackoverflow.com Aug 13 '17 at 13:21


This question came from our site for professional and enthusiast programmers.














  • This Q is not about programming as defined for StackOverflow. It may be more appropriate on the S.E. related sites apple.stackexchange.com (AskDifferent) OR SuperUser.com . Use the flag link at the bottom of your Q and ask the moderator to move it there. Please don't post the same Q on 2 different sites. Please read stackoverflow.com/help/how-to-ask stackoverflow.com/help/dont-ask and stackoverflow.com/help/mcve before posting more Qs here. Good luck.
    – shellter
    Aug 11 '17 at 2:22














up vote
0
down vote

favorite












Everytime I spoof my mac-adress on Ubuntu using different approaches including macchanger it auto resets as soon as I actually try to reconnect to the network.



This is what my problem looks like:

TERMINAL ENTRY before reconnection



root@M-Linux:~# macchanger -s wlp2s0
Current MAC: XY (changed, obviously) (Hon Hai Precision Ind. Co.,Ltd.)
Permanent MAC: XY (Hon Hai Precision Ind. Co.,Ltd.)
root@M-Linux:~# ifconfig wlp2s0 down
root@M-Linux:~# macchanger -rb wlp2s0
Current MAC: XY (Hon Hai Precision Ind. Co.,Ltd.)
Permanent MAC: XY (Hon Hai Precision Ind. Co.,Ltd.)
New MAC: AB (unknown)
root@M-Linux:~# ifconfig wlp2s0 up
root@M-Linux:~# macchanger -s wlp2s0
Current MAC: AB (unknown)
Permanent MAC: XY (Hon Hai Precision Ind. Co.,Ltd.)


Then I reconnect to the WIFI and then this happens



root@M-Linux:~# macchanger -s wlp2s0
Current MAC: XY (Hon Hai Precision Ind. Co.,Ltd.)
Permanent MAC: XY (Hon Hai Precision Ind. Co.,Ltd.)


So the mac is back to normal.



I tried this on kubuntu 16.04.3 and another debian-based distro.



I tried it on my home and a public network. I tried it on two different machines: HP and Acer Notebooks.



Exact same results every time and NO information about the issue on the web.



What should I do?










share|improve this question















migrated from stackoverflow.com Aug 13 '17 at 13:21


This question came from our site for professional and enthusiast programmers.














  • This Q is not about programming as defined for StackOverflow. It may be more appropriate on the S.E. related sites apple.stackexchange.com (AskDifferent) OR SuperUser.com . Use the flag link at the bottom of your Q and ask the moderator to move it there. Please don't post the same Q on 2 different sites. Please read stackoverflow.com/help/how-to-ask stackoverflow.com/help/dont-ask and stackoverflow.com/help/mcve before posting more Qs here. Good luck.
    – shellter
    Aug 11 '17 at 2:22












up vote
0
down vote

favorite









up vote
0
down vote

favorite











Everytime I spoof my mac-adress on Ubuntu using different approaches including macchanger it auto resets as soon as I actually try to reconnect to the network.



This is what my problem looks like:

TERMINAL ENTRY before reconnection



root@M-Linux:~# macchanger -s wlp2s0
Current MAC: XY (changed, obviously) (Hon Hai Precision Ind. Co.,Ltd.)
Permanent MAC: XY (Hon Hai Precision Ind. Co.,Ltd.)
root@M-Linux:~# ifconfig wlp2s0 down
root@M-Linux:~# macchanger -rb wlp2s0
Current MAC: XY (Hon Hai Precision Ind. Co.,Ltd.)
Permanent MAC: XY (Hon Hai Precision Ind. Co.,Ltd.)
New MAC: AB (unknown)
root@M-Linux:~# ifconfig wlp2s0 up
root@M-Linux:~# macchanger -s wlp2s0
Current MAC: AB (unknown)
Permanent MAC: XY (Hon Hai Precision Ind. Co.,Ltd.)


Then I reconnect to the WIFI and then this happens



root@M-Linux:~# macchanger -s wlp2s0
Current MAC: XY (Hon Hai Precision Ind. Co.,Ltd.)
Permanent MAC: XY (Hon Hai Precision Ind. Co.,Ltd.)


So the mac is back to normal.



I tried this on kubuntu 16.04.3 and another debian-based distro.



I tried it on my home and a public network. I tried it on two different machines: HP and Acer Notebooks.



Exact same results every time and NO information about the issue on the web.



What should I do?










share|improve this question















Everytime I spoof my mac-adress on Ubuntu using different approaches including macchanger it auto resets as soon as I actually try to reconnect to the network.



This is what my problem looks like:

TERMINAL ENTRY before reconnection



root@M-Linux:~# macchanger -s wlp2s0
Current MAC: XY (changed, obviously) (Hon Hai Precision Ind. Co.,Ltd.)
Permanent MAC: XY (Hon Hai Precision Ind. Co.,Ltd.)
root@M-Linux:~# ifconfig wlp2s0 down
root@M-Linux:~# macchanger -rb wlp2s0
Current MAC: XY (Hon Hai Precision Ind. Co.,Ltd.)
Permanent MAC: XY (Hon Hai Precision Ind. Co.,Ltd.)
New MAC: AB (unknown)
root@M-Linux:~# ifconfig wlp2s0 up
root@M-Linux:~# macchanger -s wlp2s0
Current MAC: AB (unknown)
Permanent MAC: XY (Hon Hai Precision Ind. Co.,Ltd.)


Then I reconnect to the WIFI and then this happens



root@M-Linux:~# macchanger -s wlp2s0
Current MAC: XY (Hon Hai Precision Ind. Co.,Ltd.)
Permanent MAC: XY (Hon Hai Precision Ind. Co.,Ltd.)


So the mac is back to normal.



I tried this on kubuntu 16.04.3 and another debian-based distro.



I tried it on my home and a public network. I tried it on two different machines: HP and Acer Notebooks.



Exact same results every time and NO information about the issue on the web.



What should I do?







linux mac-address spoofing






share|improve this question















share|improve this question













share|improve this question




share|improve this question








edited Sep 2 '17 at 12:41









xhienne

11.7k2553




11.7k2553










asked Aug 10 '17 at 21:31









NoBullsh1t

4




4




migrated from stackoverflow.com Aug 13 '17 at 13:21


This question came from our site for professional and enthusiast programmers.






migrated from stackoverflow.com Aug 13 '17 at 13:21


This question came from our site for professional and enthusiast programmers.













  • This Q is not about programming as defined for StackOverflow. It may be more appropriate on the S.E. related sites apple.stackexchange.com (AskDifferent) OR SuperUser.com . Use the flag link at the bottom of your Q and ask the moderator to move it there. Please don't post the same Q on 2 different sites. Please read stackoverflow.com/help/how-to-ask stackoverflow.com/help/dont-ask and stackoverflow.com/help/mcve before posting more Qs here. Good luck.
    – shellter
    Aug 11 '17 at 2:22
















  • This Q is not about programming as defined for StackOverflow. It may be more appropriate on the S.E. related sites apple.stackexchange.com (AskDifferent) OR SuperUser.com . Use the flag link at the bottom of your Q and ask the moderator to move it there. Please don't post the same Q on 2 different sites. Please read stackoverflow.com/help/how-to-ask stackoverflow.com/help/dont-ask and stackoverflow.com/help/mcve before posting more Qs here. Good luck.
    – shellter
    Aug 11 '17 at 2:22















This Q is not about programming as defined for StackOverflow. It may be more appropriate on the S.E. related sites apple.stackexchange.com (AskDifferent) OR SuperUser.com . Use the flag link at the bottom of your Q and ask the moderator to move it there. Please don't post the same Q on 2 different sites. Please read stackoverflow.com/help/how-to-ask stackoverflow.com/help/dont-ask and stackoverflow.com/help/mcve before posting more Qs here. Good luck.
– shellter
Aug 11 '17 at 2:22




This Q is not about programming as defined for StackOverflow. It may be more appropriate on the S.E. related sites apple.stackexchange.com (AskDifferent) OR SuperUser.com . Use the flag link at the bottom of your Q and ask the moderator to move it there. Please don't post the same Q on 2 different sites. Please read stackoverflow.com/help/how-to-ask stackoverflow.com/help/dont-ask and stackoverflow.com/help/mcve before posting more Qs here. Good luck.
– shellter
Aug 11 '17 at 2:22










2 Answers
2






active

oldest

votes

















up vote
0
down vote













When you restart the network interface, the network manager reloads the default configuration stored in /etc/network/interfaces.
On Ubuntu, this is the standard way to change MAC address temporarily:



/etc/init.d/networking stop
ifconfig wlp2s0 hw ether 02:01:02:03:04:08
/etc/init.d/networking start


If you want to add it permanently, add it to /etc/network/interfaces:



iface wlp2s0 inet static
address 10.0.0.100
netmask 255.255.255.0
gateway 10.0.0.1
hwaddress ether 02:01:02:03:04:08





share|improve this answer




















  • Thank you, but unfortunately that didn't work. The first option is being resettet when I connect to the network, just as my way was before. The second option keeps the network from being connected to completely
    – NoBullsh1t
    Aug 13 '17 at 13:15

















up vote
0
down vote













This askubuntu Q&A suggest the following commands to be execute on Ubuntu:



sudo ifconfig wlan0 down
sudo macchanger -a wlan0
sudo ifconfig wlan0 up





share|improve this answer




















  • I know, and it works. Until it's being resetted when I try to reconnect to the wifi network. So what I really need is a way to keep another program (I suppose NetworkManager) from resetting it
    – NoBullsh1t
    Aug 14 '17 at 13:52










Your Answer







StackExchange.ready(function()
var channelOptions =
tags: "".split(" "),
id: "106"
;
initTagRenderer("".split(" "), "".split(" "), channelOptions);

StackExchange.using("externalEditor", function()
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled)
StackExchange.using("snippets", function()
createEditor();
);

else
createEditor();

);

function createEditor()
StackExchange.prepareEditor(
heartbeatType: 'answer',
convertImagesToLinks: false,
noModals: false,
showLowRepImageUploadWarning: true,
reputationToPostImages: null,
bindNavPrevention: true,
postfix: "",
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
);



);













 

draft saved


draft discarded


















StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f385831%2fhow-to-avoid-mac-adress-spoofing-auto-reset-on-connecting%23new-answer', 'question_page');

);

Post as a guest






























2 Answers
2






active

oldest

votes








2 Answers
2






active

oldest

votes









active

oldest

votes






active

oldest

votes








up vote
0
down vote













When you restart the network interface, the network manager reloads the default configuration stored in /etc/network/interfaces.
On Ubuntu, this is the standard way to change MAC address temporarily:



/etc/init.d/networking stop
ifconfig wlp2s0 hw ether 02:01:02:03:04:08
/etc/init.d/networking start


If you want to add it permanently, add it to /etc/network/interfaces:



iface wlp2s0 inet static
address 10.0.0.100
netmask 255.255.255.0
gateway 10.0.0.1
hwaddress ether 02:01:02:03:04:08





share|improve this answer




















  • Thank you, but unfortunately that didn't work. The first option is being resettet when I connect to the network, just as my way was before. The second option keeps the network from being connected to completely
    – NoBullsh1t
    Aug 13 '17 at 13:15














up vote
0
down vote













When you restart the network interface, the network manager reloads the default configuration stored in /etc/network/interfaces.
On Ubuntu, this is the standard way to change MAC address temporarily:



/etc/init.d/networking stop
ifconfig wlp2s0 hw ether 02:01:02:03:04:08
/etc/init.d/networking start


If you want to add it permanently, add it to /etc/network/interfaces:



iface wlp2s0 inet static
address 10.0.0.100
netmask 255.255.255.0
gateway 10.0.0.1
hwaddress ether 02:01:02:03:04:08





share|improve this answer




















  • Thank you, but unfortunately that didn't work. The first option is being resettet when I connect to the network, just as my way was before. The second option keeps the network from being connected to completely
    – NoBullsh1t
    Aug 13 '17 at 13:15












up vote
0
down vote










up vote
0
down vote









When you restart the network interface, the network manager reloads the default configuration stored in /etc/network/interfaces.
On Ubuntu, this is the standard way to change MAC address temporarily:



/etc/init.d/networking stop
ifconfig wlp2s0 hw ether 02:01:02:03:04:08
/etc/init.d/networking start


If you want to add it permanently, add it to /etc/network/interfaces:



iface wlp2s0 inet static
address 10.0.0.100
netmask 255.255.255.0
gateway 10.0.0.1
hwaddress ether 02:01:02:03:04:08





share|improve this answer












When you restart the network interface, the network manager reloads the default configuration stored in /etc/network/interfaces.
On Ubuntu, this is the standard way to change MAC address temporarily:



/etc/init.d/networking stop
ifconfig wlp2s0 hw ether 02:01:02:03:04:08
/etc/init.d/networking start


If you want to add it permanently, add it to /etc/network/interfaces:



iface wlp2s0 inet static
address 10.0.0.100
netmask 255.255.255.0
gateway 10.0.0.1
hwaddress ether 02:01:02:03:04:08






share|improve this answer












share|improve this answer



share|improve this answer










answered Aug 10 '17 at 22:08







Wrotcod


















  • Thank you, but unfortunately that didn't work. The first option is being resettet when I connect to the network, just as my way was before. The second option keeps the network from being connected to completely
    – NoBullsh1t
    Aug 13 '17 at 13:15
















  • Thank you, but unfortunately that didn't work. The first option is being resettet when I connect to the network, just as my way was before. The second option keeps the network from being connected to completely
    – NoBullsh1t
    Aug 13 '17 at 13:15















Thank you, but unfortunately that didn't work. The first option is being resettet when I connect to the network, just as my way was before. The second option keeps the network from being connected to completely
– NoBullsh1t
Aug 13 '17 at 13:15




Thank you, but unfortunately that didn't work. The first option is being resettet when I connect to the network, just as my way was before. The second option keeps the network from being connected to completely
– NoBullsh1t
Aug 13 '17 at 13:15












up vote
0
down vote













This askubuntu Q&A suggest the following commands to be execute on Ubuntu:



sudo ifconfig wlan0 down
sudo macchanger -a wlan0
sudo ifconfig wlan0 up





share|improve this answer




















  • I know, and it works. Until it's being resetted when I try to reconnect to the wifi network. So what I really need is a way to keep another program (I suppose NetworkManager) from resetting it
    – NoBullsh1t
    Aug 14 '17 at 13:52














up vote
0
down vote













This askubuntu Q&A suggest the following commands to be execute on Ubuntu:



sudo ifconfig wlan0 down
sudo macchanger -a wlan0
sudo ifconfig wlan0 up





share|improve this answer




















  • I know, and it works. Until it's being resetted when I try to reconnect to the wifi network. So what I really need is a way to keep another program (I suppose NetworkManager) from resetting it
    – NoBullsh1t
    Aug 14 '17 at 13:52












up vote
0
down vote










up vote
0
down vote









This askubuntu Q&A suggest the following commands to be execute on Ubuntu:



sudo ifconfig wlan0 down
sudo macchanger -a wlan0
sudo ifconfig wlan0 up





share|improve this answer












This askubuntu Q&A suggest the following commands to be execute on Ubuntu:



sudo ifconfig wlan0 down
sudo macchanger -a wlan0
sudo ifconfig wlan0 up






share|improve this answer












share|improve this answer



share|improve this answer










answered Aug 13 '17 at 13:30









Yaron

3,19421027




3,19421027











  • I know, and it works. Until it's being resetted when I try to reconnect to the wifi network. So what I really need is a way to keep another program (I suppose NetworkManager) from resetting it
    – NoBullsh1t
    Aug 14 '17 at 13:52
















  • I know, and it works. Until it's being resetted when I try to reconnect to the wifi network. So what I really need is a way to keep another program (I suppose NetworkManager) from resetting it
    – NoBullsh1t
    Aug 14 '17 at 13:52















I know, and it works. Until it's being resetted when I try to reconnect to the wifi network. So what I really need is a way to keep another program (I suppose NetworkManager) from resetting it
– NoBullsh1t
Aug 14 '17 at 13:52




I know, and it works. Until it's being resetted when I try to reconnect to the wifi network. So what I really need is a way to keep another program (I suppose NetworkManager) from resetting it
– NoBullsh1t
Aug 14 '17 at 13:52

















 

draft saved


draft discarded















































 


draft saved


draft discarded














StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f385831%2fhow-to-avoid-mac-adress-spoofing-auto-reset-on-connecting%23new-answer', 'question_page');

);

Post as a guest













































































Popular posts from this blog

How to check contact read email or not when send email to Individual?

Christian Cage

How to properly install USB display driver for Fresco Logic FL2000DX on Ubuntu?