Notices


Reply
Thread Tools
Posts: 11 | Thanked: 0 times | Joined on Oct 2009
#1
Hi, is it possible to change mac address of N900 via xterminal? Thank you for your posts
 
allnameswereout's Avatar
Posts: 3,397 | Thanked: 1,212 times | Joined on Jul 2008 @ Netherlands
#2
Should be possible with ifconfig. First bring down your WLAN, or make sure it isn't in use.

Then, as root:

ifconfig wlan0 hw ether 00:00:00:00:00:00
__________________
Goosfraba! All text written by allnameswereout is public domain unless stated otherwise. Thank you for sharing your output!
 
Posts: 11 | Thanked: 0 times | Joined on Oct 2009
#3
I know how to change, but i asked if is it possible, because some drivers doesn't support this function...
 
Posts: 21 | Thanked: 8 times | Joined on Dec 2009
#4
Yes it is posible.
 

The Following User Says Thank You to VII For This Useful Post:
Posts: 135 | Thanked: 151 times | Joined on Dec 2009 @ Slovakia/Bratislava
#5
there is macchanger in extras-devel, but be sure you know what you're doing, because extras-devel includes software that is untested, unstable and might brick your device, proceed with caution, you have been warned.
 
Posts: 2 | Thanked: 0 times | Joined on Aug 2010
#6
Is there a way to set it up so that the mac address gets automatically changed on start-up?
 
hawaii's Avatar
Posts: 1,030 | Thanked: 792 times | Joined on Jun 2009
#7
Put it in an upstart script.
 
Posts: 3 | Thanked: 1 time | Joined on Apr 2011
#8
I wrote a little handy script that help me a lot when needing a new mac fast on my n900 (its just bash so it works on every linux dist that names their vlan interface wlan0):

Create a file in /usr/bin/ called macchanger, make it executable:
chmod +x /usr/bin/macchanger
edit /usr/bin/macchanger and insert this text:

#!/bin/bash
echo "they block my mac"
ifconfig wlan0 down
ole=`ifconfig wlan0|grep HWaddr|awk '{print $5}'`
one=`df |md5sum |awk '{print }'|grep -o ..`
two=`free |md5sum |grep -o ..`
thr=`ps auxww |md5sum |grep -o ..`
ifconfig wlan0 hw ether 00:1FF:`echo $one`:`echo $two`:`echo $thr`
new=`ifconfig wlan0|grep HWaddr|awk '{print $5}'`
ifconfig wlan0 up
echo $ole "->" $new
echo "i fist their fish"

Reason i am using 3 strings md5sumed is to get decent randomization as this is hard to accomplish in bash

Last edited by h4xx0r; 2011-04-11 at 11:52.
 

The Following User Says Thank You to h4xx0r For This Useful Post:
hawaii's Avatar
Posts: 1,030 | Thanked: 792 times | Joined on Jun 2009
#9
You do realize that `macchanger` is in the repositories?
 

The Following User Says Thank You to hawaii For This Useful Post:
Posts: 9 | Thanked: 1 time | Joined on Nov 2010
#10
Originally Posted by h4xx0r View Post
I wrote a little handy script that help me a lot when needing a new mac fast on my n900 (its just bash so it works on every linux dist that names their vlan interface wlan0):

Create a file in /usr/bin/ called macchanger, make it executable:
chmod +x /usr/bin/macchanger
edit /usr/bin/macchanger and insert this text:

#!/bin/bash
echo "they block my mac"
ifconfig wlan0 down
ole=`ifconfig wlan0|grep HWaddr|awk '{print $5}'`
one=`df |md5sum |awk '{print }'|grep -o ..`
two=`free |md5sum |grep -o ..`
thr=`ps auxww |md5sum |grep -o ..`
ifconfig wlan0 hw ether 00:1FF:`echo $one`:`echo $two`:`echo $thr`
new=`ifconfig wlan0|grep HWaddr|awk '{print $5}'`
ifconfig wlan0 up
echo $ole "->" $new
echo "i fist their fish"

Reason i am using 3 strings md5sumed is to get decent randomization as this is hard to accomplish in bash
After installing enhanced bash package, these lines don't work anymore:
Code:
one=`df |md5sum |awk '{print }'|grep -o ..`
two=`free |md5sum |grep -o ..`
thr=`ps auxww |md5sum |grep -o ..`
It (the ifconfig) stops at $one, resulting in truncated addreas (only 4 out of 6, ie 00:1FF:xx). Tried changing to:
Code:
one=`df |md5sum |awk '{print }'|head -c 2`
two=`free |md5sum |head -c 2`
thr=`ps auxww |md5sum |head -c 2`
Now it works again

Last edited by anagarika; 2012-01-04 at 13:52.
 
Reply

Tags
mac, n900, xterminal

Thread Tools

 
Forum Jump


All times are GMT. The time now is 10:51.