How to Spoof MAC Address - Galaxy S I9000 General

Hi,
i couldn't find any info on how to spoof/change MAC address on Galaxy S.
I so some commands for Android like:
ip link set eth0 address XX:XX:XX:XX:XX:XX'
and
'ip link set eth0 broadcast XX:XX:XX:XX:XX:XX'
but it gives me error like this:
ip: either "dev" is duplicate, or "XX:XX:XX:XX:XX:XX" is garbage
there are some threads here on xda in HD2 forum, they have a krenel that allows spoofing MAC address by changing startup.txt....
http://forum.xda-developers.com/showthread.php?p=8828147
what are solutions for Galaxy S?
thanks in advance

did you find the answer?

It is possible. i have given procedure for LG Optimus One. Same can be used for u'r phone. Just have to locate nvram.txt file. and appen line "macaddr = XX:XX:XX:XX:XX:XX" Where "XX:XX:X..." is u'r new mac address.
Here's the link
http://forum.xda-developers.com/showthread.php?t=917684

nice find, thanks!

Doesn't work for me.
All I found was nvram_net.txt in /system/etc/wifi
inside there was a line:
#macaddr=00:11:22:33:44:55
so I removed the coment mark (#) and restarted the phone but MAC address didn't change.
The file should be right, because in wifi.conf there is a line:
"DRIVER_MODULE_ARG=firmware_path=/system/etc/wifi/bcm4329_sta.bin nvram_path=/system/etc/wifi/nvram_net.txt"
Any other ideas?

ifconfig/ip commands do not work on sgs
I think that the problem is related to how the wifi driver is compiled.
SGS uses bcm4329 and it has an option for custom mac address.
I saw this in odriod's forum
drivers/net/wireless/bcm4329/Makefile line 9
-DGET_CUSTOM_MAC_ENABLE
Disable above definition and make a new bcm4329.ko
Put is with "adb push" command to /system/lib/modules (replacement),
Change the permission of /system/etc/dhcpcd file with 777.
Click to expand...
Click to collapse
want to change this.
Let's hope that there is a kernel builder out there that want to change it.

try dowing the interface before changing the MAC and uping it afterwards as in:
http://forum.xda-developers.com/showthread.php?t=1901171

Related

AOKP

As there is a useless requirement for posting in development I have to come here to answer a simple question,
Yes on build 28 I have the same MAC address, that will be a big problem since the ROM should not be changing that.
lorinkundert said:
As there is a useless requirement for posting in development I have to come here to answer a simple question,
Yes on build 28 I have the same MAC address, that will be a big problem since the ROM should not be changing that.
Click to expand...
Click to collapse
Sure. Wait, what?
Lol
sent from my nokia 3210
I´ve also notice that since a few versions back, there is a static MAC address in the ROM.
This one: 00:90:4c:c5:12:38, my orginal MAC was like this: 8c:77:12...
(If you don´t know what your MAC was before flashing this ROM ? Look at your WLAN Hotspot Log...)
When someone uses 2 Devices (with this ROM) in the same WLAN, only one would be connected.
You can edit 2 text files in "/etc/wifi" and change the MAC to the one you like or have.
nvram_mfg.txt
nvram_net.txt
Yes, of course, the filesystem should be remounted:
open Terminal:
mount
su
mount -t ext4 -o remount, rw /dev/block/mmcblk0p4 /system
Then set permissions 755 on directory "wifi" and the 2 files.
Now you can edit the files.
An other and easier way to temporary solve the MAC problem is to edit the 2 files in the ROM zip archive itself,
then flash the ROM again.
I hope that in one of the next releases the orginal hardware MAC should be used again.
There is a dev thread with a download to change your mac .... recently started
Sent from my GT-P7500 using XDA
lorinkundert said:
As there is a useless requirement for posting in development I have to come here to answer a simple question,
Yes on build 28 I have the same MAC address, that will be a big problem since the ROM should not be changing that.
Click to expand...
Click to collapse
Also, solution is here: http://forum.xda-developers.com/showthread.php?p=23468681&highlight=module#post23468681
or, same thread, post 1607. I downloaded the module, copied it to the path pershoot specified (backed up the old module), fixed permissions, rebooted, and all fixed.

[GUIDE] Change WiFi MAC Address

Hello everybody,
i have found a solution to change the WiFi MAC address if "/system/etc/calibration" doesn't exist.
Requirements:
root
ES File Explorer or Root Explorer
1. Copy file "/proc/calibration" to "/system/etc/calibration"
2. Edit "/system/etc/calibration"
Code:
- Search line "macaddr=your current mac"
- Replace "your current mac" with your new mac
- Save
3. Edit "/system/etc/init.d/01_modules"
Code:
- Add this line at the bottom:
mount -o bind /system/etc/calibration /proc/calibration
- Save
4. Change permissions of "/system/etc/init.d/01_modules"
Code:
Read Write Execute
X X X
X X X
X X X
5. Reboot
Your MAC address should now be changed.
Please ask if you have a question.
Tested with:
- NexusHD2 V2.9 (tytung's kernel)
Dragon812 said:
Hello everybody,
i have found a solution to change the WiFi MAC address
Click to expand...
Click to collapse
Hello
why would you do that ? Reading a unique wifi/bluetooth macaddress in the hd2 is implemended since ~one year ?
Franck
Franck78 said:
Hello
why would you do that ? Reading a unique wifi/bluetooth macaddress in the hd2 is implemended since ~one year ?
Franck
Click to expand...
Click to collapse
But some routers have a limited number of authorized MACs.
For example, in my router you can enter only 10 MAC addresses, but we have 12 devices.

[GUIDE][Dual Boot][TheEasyway] How to setup Linux RootBind Method [Updated May 16th]

Hello everyone ! I made this guide for all who want to try to dualboot Android and Ubuntu using the RootBind method.
But first, what is RootBind ?
Actually, the RootBind method consist to have a Linux file system, living in a folder of our Android partition.
The default location for this linux file system is /data/linuxroot.
The way to switch between Android and Linux is to flash an Android kernel or the linux kernel. That's all.
It means you'll be able to have a linux installation, without erasing Android ( Still available, not touched at all ) and it means that you can easily manage your Linux installation.
You dont want it anymore ? Just delete a folder. You want to try another version, but you dont want to lose your current data ? Just do a zip of the folder, and extract a new version instead.
Advantages :
No need to repartitionate your tab.
It works with all TF101.
It doesnt touch current Android Installation.
It has same free space as your /data Android partition.
You can easily access it from within Android.
It has good performances
Kernel has everything working
And you only need to flash an Android or Linux Kernel to boot desired OS.
Everything is possible thanks to @jrohwer and @DjDill and @TravellingGuy.
Dont forget to thanks them : jrohwer Kernel Thread - jrohwer 14.04 Kubuntu IMG / DjDill images thread / TravellingGuy Image thread​Of course, every manipulation is risky, Me, jrohwer, DjDill, Travelling Guy, my dog, or even my math professor, can NOT be responsible for any damage on your tab, use this guide at your own risk​First Post : Dualboot setup
Second Post : How to change the linux location / How to have multiple linux installations
Third Post : FAQ & Tips​
DualBoot setup. Linux installation
First of all, here is all what you'll need :
The last rootbind kernel : Download Here Take the zip version.
[*]WARING : Note that if you use the last kernel ( 15 one ) YOU MUST TAKE MODULES AND EXTRACT IT IN /lib/modules/ when installation is done
The last Linux IMG of your choice, DjDill made imgs for this method with everything pre working here : DjDill images thread / TravellingGuy Image thread / jrohwer 14.04 Kubuntu IMG
Kernel for booting back Android You can find the KatKiss kernel there for exemple : KatKernel
A terminal emulator in Android or ADB Shell
If you dont want to use one of DjDill img, you'll need the bcm4329 tar from there : http://forum.xda-developers.com/showpost.php?p=43203818&postcount=569
You need to have a rooted device with a custom recovery. Check by here or by there
This method works on any TF101
Note that all command can be done with ADB shell aswell.
If you choose to install one of DjDill img :
Boot to Android as usual
Copy all download files to your tab. You can rename the kernel zip to Linux_Loader.zip and Android_Loader.zip to be clearer.
Now, I assume you have files in internal storage ( change sdcard0 by sdcard1 if it's on microSD )
We will now ensure terminal has root permissions :
Open Terminal emulator
Type su then Enter
SuperUser will ask terminal emulator root permission, allow it.
If you have an error with this command, your device may not be properly rooted.
Now we will setup installation location and extract our linux tar.gz ( Be aware it may take a while ) :
Code:
busybox mount -o remount,rw /
mkdir /data/linuxroot
chmod 755 /data/linuxroot
cd /data/linuxroot
tar -pxvzf /storage/sdcard0/yourubuntufilename.tar.gz
busybox mount -o remount,ro /
If you don't choose to install one of pre configured img :
Boot to Android as usual
Copy all download files to your tab. You can rename the kernel zip to Linux_Loader.zip and Android_Loader.zip to be clearer.
Now, I assume you have files in internal storage ( change sdcard0 by sdcard1 if it's on microSD )
We will now ensure terminal has root permissions :
Open Terminal emulator
Type su then Enter
SuperUser will ask terminal emulator root permission, allow it.
If you have an error with this command, your device may not be properly rooted.
Now we will setup installation location and extract our linux tar.gz ( Be aware it may take a while ) :
Code:
busybox mount -o remount,rw /
mkdir /data/linuxroot
chmod 755 /data/linuxroot
cd /data/linuxroot
tar -pxvzf /storage/sdcard0/yourubuntufilename.tar.gz
cd /data/linuxroot/lib/firmware
tar -pxvzf /storage/sdcard0/bcm4329.tar.gz
cp nvram.txt nvram_3429.txt
busybox mount -o remount,ro /
The setup is now complete.
In order to boot your linux installation, flash the linux kernel.
To get back to Android, flash the Android kernel.
​
How to change the linux location / How to have multiple linux installations
Here we are, so in order to have multiple linux instllations or change defaut linux installation location, you will need a Linux computer. ( Or a Virtual Machine, that's what I use, with Virtual Box for exemple.
You will need 3 tools to get it done too.
You can get it there abootimg, blobpack and blobunpack files at the end of first post ( Thanks to @shaola ).
I post the zip in attachement for mirror.
MORE INFORMATIONS ABOUT THESE TOOLS : http://forum.xda-developers.com/showpost.php?p=13713619&postcount=3
Now you have to get in the Rootbind kernel, the blob file. Blob file in Asus ROM can contain any partition of the device ( System, kernel, recovery etc ). In this kernel blob, there is only the kernel partition. Soooo, here we go for some commands.
Open your linux computer
Place all four files in same place ( better to have a folder created for this ). I'll take exemple of ~/kerneltf/ It's a exemple, so adapt in consequencies of course.
Now you have your four files in same place, blobunpack, blobpack, and abootimg-i686 so let's start with commands :
Go to the desired place :
Code:
cd ~/kerneltf
Unpack the blob containing partition imgs
Code:
./blobunpack blob
This will create partitions img. The one that interest us is the .LNX partition. ( Here blob.LNX )
Now unpack the kernel parition img
Code:
./abootimg-i686 -x blob.LNX
This will create 3 files, bootimg.cfg, zImage and initrd.img
The file we want to edit is bootimg.cfg. so open it with a text editor.
You'll see the last line is a cmdline. At the end we have the location of linux system place.
For exemple here : root=/dev/mmcblk0p7 bind=/linuxroot that means, the folder takes place in mmcblk0p7 ( /data partition of device ) and is placed in /linuxroot folder. So with Android layout it means /data/linuxroot.
You can now change the location of your folder, so you have some choices :
1-Change the folder location or name. ( This can be used to have multiple linux systems )
So you have this part : root=/dev/mmcblk0p7 bind=/linuxroot
If you want to change folder place/name change this part : bind=/linuxroot into whatever you want
For exemple root=/dev/mmcblk0p7 bind=/linuxroot2 or root=/dev/mmcblk0p7 bind=/linuxroot3 ( To have more linux systems )
Or root=/dev/mmcblk0p7 bind=/Linuxroot/Linux1
ATTENTION as said in rootbind thread : Make sure, however, not to put the Linux rootfs to the "internal storage" (/data/media) or any subdirectories thereof. This plays havoc with the Android media scanner when re-booting into Android and your tablet may slow down to a crawl.
2-Change the folder location in order to have it on an other partition like SDCard
For this choice, a 2nd partition on your SDcard is greatly recommended and should be in ext4. ( Must be the second partition, it is better for general use of SDcard )
So root=/dev/mmcblk0p7 bind=/linuxroot will become root=/dev/mmcblk1p2 ( can be p3 p4 or more if you have more than 2 partitions in your sdcard to have several systems on your SDcard ) the bind argument must be deleted as it will not be used.
3-Change the folder location in order to have it on first partition on SDCard
The problem here if you want your linuxroot folder in you SDcard with your other files, is that sdcard MUST be formatted in ext4 and so will not be recognized directly by Windows ( Using MTP in the TF will work but not Storage Mount ) cause Windows doesnt support ext4 partition. It's definitively the worse choice IMHO. The precedent process is definitively better choice. More than that it could make MediaScanner in Android going crazy too ( a .nomedia can maybe do the trick but not sure ).
More again, it hasnt been tested at all so you're the only responsible, but if you want to do it :
For exemple, to put folder on SDcard, you should change root=/dev/mmcblk0p7 bind=/linuxroot to root=/dev/mmcblk1p1 bind=/linuxroot
This means your folder is in sdcard ( The one in the tab ) at root in /linuxroot folder. ( /storage/sdcard1/linuxroot in android )
THIS HAS NOT BEEN TESTED YET, I CANT TELL YOU IF IT WORKS OR NOT.
Sooo, now you seted up your new location ( BE SURE TO DONT TOUCH ANYTHING ELSE ON THE CMDLINE, ONLY THIS PART ):
We will now repack the kernel to get it flashable.
Once again, be sure that you didnt make mistake with the file, and you only edited root=/dev/mmcblk0p7 bind=/linuxroot this part without deleting something or got a typo error.
We will now update the new bootimg :
Code:
abootimg-i686 -u blob.LNX -f bootimg.cfg
Then we will rename old blob file to create a new one with our modified kernel:
Code:
mv blob blobold
Now, we will repack our blob in order to make a new flashable zip with our kernel:
Code:
./blobpack blob LNX blob.LNX
You're done, make a copy of the old zip, rename it as you wish ( avoid spaces in the zip title ) for exemple Linux_Loader_2.zip
Then open it, and replace the blob file with your new one.
Now you're good to flash. Be sure to install a linux system in desired location before flashing it of course. See post 1 for this !
And a last one !
Envoyé de mon Nexus 4 en utilisant Tapatalk
Nice does work with TF101 G model (3G+) ?
Envoyé depuis ma TF101G-B80 with Revolution HD 4.0 (3.6g release) by Mike _1986
stephane.papin said:
Nice does work with TF101 G model (3G+) ?
Envoyé depuis ma TF101G-B80 with Revolution HD 4.0 (3.6g release) by Mike _1986
Click to expand...
Click to collapse
Yes, it works with all TF101
Si t'as besoin d'aide, hésite pas à me MP
Is a bootloader within the realm of possibility?
Thanks for the write-up.. I'm at the drinking my coffee while the untar keeps chugging stage, and it occurs to me that a bootloader would be very cool to have. Kernels flash so quickly, the recovery method isn't far off in terms of usability.. but it did motivate the question: is it possible?
So I'm just curious - is there any reason why we couldn't have the android and linux kernels both on disk to be loaded by a bootloader based on user choice?
Hello,
I have tried the "DjDill img" method.
When it finishes booting, it tells me that there are networks, and yhat I have to configure wifi.
I can't find how.
ifconfig shows lo and wlan0, and wlan0 is up but of course has no address.
if I try a iwlist scan, it tells me that wlan0 is an interface that doesn't support scanning.
In "settings manager/network connections", if I try to add a connection, it doesn't see my ssid.
Do you have any idea or point me to some doc/tuto.
Thanks in advance
nbenm
nbenm said:
Hello,
I have tried the "DjDill img" method.
When it finishes booting, it tells me that there are networks, and yhat I have to configure wifi.
I can't find how.
ifconfig shows lo and wlan0, and wlan0 is up but of course has no address.
if I try a iwlist scan, it tells me that wlan0 is an interface that doesn't support scanning.
In "settings manager/network connections", if I try to add a connection, it doesn't see my ssid.
Do you have any idea or point me to some doc/tuto.
Thanks in advance
nbenm
Click to expand...
Click to collapse
What kernel and what image did you used?
Tapatalké depuis mon Nexus 4 MIUI !
Couple questions
First, BIG thx to you and all the devs for hacking the tf-101!!
I've tried several of the images and they all worked as posted (Go figure ). I will be trying to compile a kernel for some custom work.
1 - Are the kernels compiled on the TF-101 and the tarballed?
2 - Any idea if Kali Linux 1.0.6 ARMHF Image, build will work?
I'll be using an external wifi dongle and not the internal.
Again much excitement to the tf-101 world!
Kingzak34 said:
What kernel and what image did you used?
Tapatalké depuis mon Nexus 4 MIUI !
Click to expand...
Click to collapse
I'm using kernel:Ubuntu-3.1.10-12-rootbind-oc1.0GHz.zip from your rootbind kernel link
I use image:tf101-14.04-xubuntu-armhf.tar.gz which is a DjDill image.
Before you reply me, I wanted to try "TravellingGuy Image". On its page, it was told to create wlan0 entry in the interfaces file. I did this and it works now.
But I can't understant why:
- iwlist scan doesn't work
- network manager doesn't see any of the multiple essids tahere are here
When I try to iwconfig essid "my_ssid", it says "cannot read /proc/net/wireless". Does it need some module ?
Thanks
nbenm
nbenm said:
I'm using kernel:Ubuntu-3.1.10-12-rootbind-oc1.0GHz.zip from your rootbind kernel link
I use image:tf101-14.04-xubuntu-armhf.tar.gz which is a DjDill image.
Before you reply me, I wanted to try "TravellingGuy Image". On its page, it was told to create wlan0 entry in the interfaces file. I did this and it works now.
But I can't understant why:
- iwlist scan doesn't work
- network manager doesn't see any of the multiple essids tahere are here
When I try to iwconfig essid "my_ssid", it says "cannot read /proc/net/wireless". Does it need some module ?
Thanks
nbenm
Click to expand...
Click to collapse
Ubuntu-3.1.10-12-rootbind-oc1.0GHz.zip doesnt exist ?
It's Ubuntu-3.1.10-12-rootbind-oc1.2GHz.zip
Or Ubuntu-3.1.10-10-rootbind-1.0GHz.zip
If you choose the Ubuntu-3.1.10-12-rootbind-oc1.2GHz.zip, wifi will works by default with defaut network manager without needing any cmd config or anything on pre installed DjDill img, IDK for Travelling guy img I didnt tested it, but you can try the other method if you're on Debian img and wifi doest work.
If you choose DjDill img, choose one of the lastest, This one http://forum.xda-developers.com/showpost.php?p=50335555&postcount=1
Or the 1.1 14.04 one, end of this post : http://forum.xda-developers.com/showpost.php?p=50335574&postcount=2
Or the Lxde build from same post.
But I suggest to use the first for now, it's the newer and have a lot of fixes.
Updated !
With second post and added jrohwer 14.04 IMG !
image: Kubuntu 14.04 With Tegra drivers.
kernel: Ubuntu-3.1.10-12-rootbind-oc1.2GHz.zip also tried Ubuntu-3.1.10-10-rootbind-1.0GHz.zip
It boots into KDE fine now but initially had some warnings even after running depmod -a. I had to issue the comnmand depmod -a a few times and it black screened once on boot.
I cant seem to get the wifi networking working even though it finds local networks clicking on the networks in the GUI doesn't do anything. Any help here. This is my first linux boot on the transformer but I have used Ubuntu since gutsy. I have to admit I am a little confused after reading a couple of posts here about exactly comes with these premade images. For instance the nvidia drivers are they included as modules in these images. When i read jrohwer's thread for the image he includes his apt sources list and states that the it took a little to get the nvidia drivers working?
Like I said on the other thread to setup Wi-Fi you have to setup in cmd line. Search on the net to setup with nmcli command or you install another network manager
Tapatalké depuis mon Nexus 4 MIUI !
Kingzak34 said:
Like I said on the other thread to setup Wi-Fi you have to setup in cmd line. Search on the net to setup with nmcli command or you install another network manager
Tapatalké depuis mon Nexus 4 MIUI !
Click to expand...
Click to collapse
Yes sorry I was struggling with the command for nmcli. I should have elaborated ... Tried various commands .. and this was what worked.
Code:
nmcli dev wifi
to list off the possible availables ap's then to join what you want
Code:
sudo nmcli dev wifi connect "whatever ap u want to connect to"
much easier to hunt down answers with a working intenet connection
Sorry bout that. I suppose my other question about the nvidia drivers is most likely too silly to answer ??
dasbooter said:
Yes sorry I was struggling with the command for nmcli. I should have elaborated ... Tried various commands .. and this was what worked.
Code:
nmcli dev wifi
to list off the possible availables ap's then to join what you want
Code:
sudo nmcli dev wifi connect "whatever ap u want to connect to"
much easier to hunt down answers with a working intenet connection
Sorry bout that. I suppose my other question about the nvidia drivers is most likely too silly to answer ??
Click to expand...
Click to collapse
What question ?
You dont have to do anything with the driver as in 14.04 build from jrohwer, is pre installed.
Kingzak34 said:
What question ?
You dont have to do anything with the driver as in 14.04 build from jrohwer, is pre installed.
Click to expand...
Click to collapse
Thanks i was reading jrohwer's thread for the 14.04 image and he was discussing the fact that it took alot of work to get the nvidia drivers up and running and then gives his apt sources list for download but after what u said it sounds like this is for people who want to get there own images together with working nvidia drivers. So compiling your own modules. Sorry I just wasnt sure. Anyways thanks for the trouble. I have connected to the ap but cant get a connection out to the internet. Oh well maybe I will try that lubuntu image on the first page. Thanks
dasbooter said:
Thanks i was reading jrohwer's thread for the 14.04 image and he was discussing the fact that it took alot of work to get the nvidia drivers up and running and then gives his apt sources list for download but after what u said it sounds like this is for people who want to get there own images together with working nvidia drivers. So compiling your own modules. Sorry I just wasnt sure. Anyways thanks for the trouble. I have connected to the ap but cant get a connection out to the internet. Oh well maybe I will try that lubuntu image on the first page. Thanks
Click to expand...
Click to collapse
Sounds weird, you successfully connected but dont have access to internet ?
Correct command for connecting on AP with a password is
sudo nmcli dev wifi connect <ssid> password <password>
And yes, the files that jrohwer gave, is for those who want to create a 14.04 with nvidia driver working img.
Kingzak34 said:
Sounds weird, you successfully connected but dont have access to internet ?
Correct command for connecting on AP with a password is
sudo nmcli dev wifi connect <ssid> password <password>
And yes, the files that jrohwer gave, is for those who want to create a 14.04 with nvidia driver working img.
Click to expand...
Click to collapse
Ya its at a hospital with no wpa type encryption only a login web page with name and password. I am most certainly connected ifconfig shows I have pulled a IP address etc etc. I have been reading about similiar problems in other linux type threads where there is automatic redirection to the login page. I actually use an app hellowifi to automatically enter the info in katkiss 4.4.2 so I am actually having trouble getting the address of that login page lol. I will give it a try at home where i have a wpa2 encrypted connection
dasbooter said:
Ya its at a hospital with no wpa type encryption only a login web page with name and password. I am most certainly connected ifconfig shows I have pulled a IP address etc etc. I have been reading about similiar problems in other linux type threads where there is automatic redirection to the login page. I actually use an app hellowifi to automatically enter the info in katkiss 4.4.2 so I am actually having trouble getting the address of that login page lol. I will give it a try at home where i have a wpa2 encrypted connection
Click to expand...
Click to collapse
Ho yeah I see, sometimes I cannot get login at the university hotspot, cause it doesnt want to redirect to login page.
I dont think you'll got problem with a 'normal' router.

[ROOT] How to change MAC address of the OnePlus 5T

TL;DR: (story in second post)
As always, everything you do is at your own risk. I'm not responsible for your phone running away or any nuclear wars.
1. Edit the content of /persist/wlan_mac.bin using a file manager with root access (e.g. Solid Explorer) and change the first two lines to your desired MAC. It's a good idea to keep the first 3 bytes (the OUI), or bad things may happen.
2. Using a terminal emulator (e.g. Termux), execute the following commands:
Code:
su
chattr +i /persist/wlan_mac.bin
And done! You may have to switch airplane mode on and off.
I just got my new OnePlus 5T, and of course, one of the first things I want to do is to change my MAC address. I immediately spotted the file:
Code:
/persist/wlan_mac.bin
But even if I hadn't, tools like my overseer can find it automatically for us.
So the file is in a standard directory for Qualcomm chips. Using Solid Explorer (with root access), I modified the file's content to change the first two lines to my desired MAC address. I then switched airplane mode on and off and..... it didn't work? I quickly checked the file content again - it had reverted back. Ouch.
To combat this, I ran my overseer tool, but to no avail. There was no obvious file containing our MAC, only symlinks to this one. I then figured that maybe the system caches the value somewhere, and restores it when I toggle airplane mode (spoiler: it doesn't).
Well, the next attempt is mainstream: write-protect the file (set it to immutable). Using a terminal emulator (e.g. Termux), I executed:
Code:
su
chattr +i /persist/wlan_mac.bin
Airplane mode on and off... and it works! I restarted the phone and verified our success. Now, one last question burdened me. Was the system caching the MAC address? I removed the immutable attribute after the restart (so the new MAC would have been cached) and after I switched airplane mode -- original MAC was restored! So the system is doing something else to stop us.
Anyways, the current method works flawlessly and I shall refrain from digging any further just now.
Good luck!
i did whatever you mentioned here. after i set it to immutable, wifi wasn't working, mac address was 02:00:00:00:00:00 . i couldn't even edit the file because i set it to immutable. so i had to remove the immutation by using -i command. i still wanna know how to change my mac address. please help me out
aneesh12 said:
i did whatever you mentioned here. after i set it to immutable, wifi wasn't working, mac address was 02:00:00:00:00:00 . i couldn't even edit the file because i set it to immutable. so i had to remove the immutation by using -i command. i still wanna know how to change my mac address. please help me out
Click to expand...
Click to collapse
Hey,
You have to edit the file before you set the immutable flag, otherwise you'll get access denied just like you observed. Unless you messed up the content of the file I see no reason you are getting an invalid MAC. Make sure you preserve the first 3 bytes (the OUI) when setting a new MAC.
ViRb3 said:
Hey,
You have to edit the file before you set the immutable flag, otherwise you'll get access denied just like you observed. Unless you messed up the content of the file I see no reason you are getting an invalid MAC. Make sure you preserve the first 3 bytes (the OUI) when setting a new MAC.
Click to expand...
Click to collapse
is there no way to change the whole Mac address(including the OUI)?
aneesh12 said:
is there no way to change the whole Mac address(including the OUI)?
Click to expand...
Click to collapse
Sure you can, as long as you use a valid OUI. While using a made-up OUI won't affect you in the short-term, some (public) hotspots could block you.
okay, by your method, i could change the mac address but not completely, only the last 4 digits. i searched for woan_mac.bin . this is what i found. these files might be causing for you to reverting back to the original mac address after removing the immutation.
I tried to change mac address of my OP5T completely to my laptop's(lenovo thinkpad) mac address
system is reading that address in reverse fashion.
eg. i put Aa:Ba:Ccd:Ee:Ff at the first line of wlan_mac.bin then system is showing Ff:Eed:Cc:Bb:Aa as mac after airplan mod on/off

How to fix WLAN MAC Address on LeEco Le 2 (s2)

Heyyo, so after hearing about the broken LeEco Le 2 Qualcomm Edition (aka s2, x52x series) MAC address issue? It seems like certain earlier builds of Pixel Experience 9 and maybe other pie ROMs from around July last year (at least, that's what it seems like from searching Telegram chat history for an s2 group) could be the root of the issue... That, or some random mod that messed up persist.
So here's a method for fixing your MAC address issues properly via persist (that is, as long as something doesn't break your persist/wlan_mac.bin again).
Please note! This guide is for s2, but you can use this guide for other devices, but instead of wlan_mac.bin being in hex it could be normal text or some vendors might use something completely different.
You can optionally use a hex editing app on your PC (like GHex on Linux) or an app like Hex Editor Free on the Play Store.
Download this blank wlan_mac.bin that we will be editing
https://osdn.net/projects/lineageos-for-s2/releases/73055
Now, we will select a MAC address prefix for Lemobile (the company name that LeEco used for s2). According to a MAC Address/OUI Lookup we have three choices:
B4EFFA
28FECD
C825E1
Using this MAC Generator website (or you can use one of your choice) and enter one of the three MAC address prefixes of your choice from the top.
We will need to create FOUR MAC addresses as that is what s2 stores in its wlan_mac.bin. It is recommended to keep them similar with only the last digit changed as that's what s2 wants.
For example, I'll use C825E1 as my MAC address prefix in that MAC generator. I generated... C825E1BCA0E9, but I want to start my MAC address with a 1 at the end, so I'll do this for my four MAC addresses.
C825E1BCA0E1
C825E1BCA0E2
C825E1BCA0E3
C825E1BCA0E4
Using the hex editor of your choice, Hex edit the downloaded wlan_mac.bin and from beginning to end? Enter your four new MAC addresses into the HEX fields and not the strings. Please note how I already put in a 1, 2, 3 and 4 to mark the last digit of each of the four MAC addresses. We must OVERWRITE the hex values in there, so please make sure you don't accidentally enable insert mode on whichever hex editing app you use.
Save it and make sure the new wlan_mac.bin is copied somewhere onto your s2.
Reboot to TWRP and mount persist.
Go into TWRP's file manager found under Advanced > File Manager.
Browse to /persist and select your defective wlan_mac.bin and either delete it or copy it somewhere to your user data if you want to keep a backup of it.
Copy the good wlan_mac.bin to /persist
(optional) Go to the new /persist/wlan_mac.bin and select it and chmod it to 0644
Reboot to System and check your MAC address in System > About Phone and if your changes were correct then your new MAC address will appear there.
thank you so much man , it worked.
I have confirmation from two s2 users that their WLAN MAC address is properly fixed with the newly generated addresses. :good:
ThE_MarD said:
I have confirmation from two s2 users that their WLAN MAC address is properly fixed with the newly generated addresses. :good:
Click to expand...
Click to collapse
For some reason it didn't work for me. Do I need to have root access? My MAC adress now says 02:00:00:00:00:00
Edit: After updating TWRP to version 3.3.1-0 it worked!!
@T-Jay can you please share you wlan_mac.bin? I'll take a look
ThE_MarD said:
@T-Jay can you please share you wlan_mac.bin? I'll take a look
Click to expand...
Click to collapse
I hope this works. This is the new wlan_mac.bin I created:
https://drive.google.com/file/d/1pdi3P5PNHfu2rkHEJ2xHjVJqFKA2ySFO/view?usp=sharing
I replied in a PM for your newly generated wlan_mac.bin
UPDATE: We got T-Jay's wlan MAC address fixed! I'll mark the chmod step as optional as that might have caused him issues.
Thank you Sir! This was of great help to me.
ThE_MarD said:
Heyyo, so after hearing about the broken LeEco Le 2 Qualcomm Edition (aka s2, x52x series) MAC address issue? It seems like certain earlier builds of Pixel Experience 9 and maybe other pie ROMs from around July last year (at least, that's what it seems like from searching Telegram chat history for an s2 group) could be the root of the issue... That, or some random mod that messed up persist.
So here's a method for fixing your MAC address issues properly via persist (that is, as long as something doesn't break your persist/wlan_mac.bin again).
Please note! This guide is for s2, but you can use this guide for other devices, but instead of wlan_mac.bin being in hex it could be normal text or some vendors might use something completely different.
You can optionally use a hex editing app on your PC (like GHex on Linux) or an app like Hex Editor Free on the Play Store.
Download this blank wlan_mac.bin that we will be editing
https://osdn.net/projects/lineageos-for-s2/releases/73055
Now, we will select a MAC address prefix for Lemobile (the company name that LeEco used for s2). According to a MAC Address/OUI Lookup we have three choices:
B4EFFA
28FECD
C825E1
Using this MAC Generator website (or you can use one of your choice) and enter one of the three MAC address prefixes of your choice from the top.
We will need to create FOUR MAC addresses as that is what s2 stores in its wlan_mac.bin. It is recommended to keep them similar with only the last digit changed as that's what s2 wants.
For example, I'll use C825E1 as my MAC address prefix in that MAC generator. I generated... C825E1BCA0E9, but I want to start my MAC address with a 1 at the end, so I'll do this for my four MAC addresses.
C825E1BCA0E1
C825E1BCA0E2
C825E1BCA0E3
C825E1BCA0E4
Using the hex editor of your choice, Hex edit the downloaded wlan_mac.bin and from beginning to end? Enter your four new MAC addresses into the HEX fields and not the strings. Please note how I already put in a 1, 2, 3 and 4 to mark the last digit of each of the four MAC addresses. We must OVERWRITE the hex values in there, so please make sure you don't accidentally enable insert mode on whichever hex editing app you use.
Save it and make sure the new wlan_mac.bin is copied somewhere onto your s2.
Reboot to TWRP and mount persist.
Go into TWRP's file manager found under Advanced > File Manager.
Browse to /persist and select your defective wlan_mac.bin and either delete it or copy it somewhere to your user data if you want to keep a backup of it.
Copy the good wlan_mac.bin to /persist
(optional) Go to the new /persist/wlan_mac.bin and select it and chmod it to 0644
Reboot to System and check your MAC address in System > About Phone and if your changes were correct then your new MAC address will appear there.
Click to expand...
Click to collapse
Bro i need some help related to my le 2s in a bad situation can you help?
Heyyo @Taran2312, I can try and help but tbh I don't own an s2 but I'll try my best to help

Categories

Resources