Android M with WPA-Enterprise ssl problem - Nexus 5 Q&A, Help & Troubleshooting

I just upgrade my nexus to marshmallow and have a trouble to connecting my device to my collage wifi. It tell me that there are authentication problem on wifi setting. I try to catch some log from logcat and get this message:
wwpa_supplicant: OpenSSL: openssl_handshake - SSL_connect error:100c1069:SSL routines:ssl3_get_server_key_exchange:BAD_DH_P_LENGTHpa_supplicant: OpenSSL: openssl_handshake - SSL_connect error:100c1069:SSL routines:ssl3_get_server_key_exchange:BAD_DH_P_LENGTH
Who have the same problem withe, any solution to fix these?
Thank you.

I have same problem here, My university uses eduroam, which is wpa enterprise. and I can not connect to wifi after 6.0 upgrade. There must be some problem with wpa_supplicant had same problem with my Linux laptop and fixed the problem after downgrading the wpa_supplicant
Code:
[ 10-14 09:39:43.666 17159:17159 I/wpa_supplicant ]
wlan0: Trying to associate with 20:bb:c0:f8:e4:75 (SSID='eduroam' freq=2412 MHz)
[ 10-14 09:39:43.834 17159:17159 I/wpa_supplicant ]
wlan0: Associated with 20:bb:c0:f8:e4:75
[ 10-14 09:39:43.834 17159:17159 I/wpa_supplicant ]
wlan0: CTRL-EVENT-EAP-STARTED EAP authentication started
[ 10-14 09:39:43.841 17159:17159 I/wpa_supplicant ]
wlan0: CTRL-EVENT-EAP-PROPOSED-METHOD vendor=0 method=25
[ 10-14 09:39:43.842 17159:17159 I/wpa_supplicant ]
wlan0: CTRL-EVENT-EAP-METHOD EAP vendor 0 method 25 (PEAP) selected
[ 10-14 09:39:43.872 17159:17159 I/wpa_supplicant ]
wlan0: CTRL-EVENT-EAP-PEER-CERT depth=2 subject='/C=SE/O=AddTrust AB/OU=AddTrust External TTP Network/CN=AddTrust External CA Root' hash=687fa451382278fff0c8b11f8d43d576671c6eb2bceab413fb83d965d06d2ff2
[ 10-14 09:39:43.873 17159:17159 I/wpa_supplicant ]
wlan0: CTRL-EVENT-EAP-PEER-CERT depth=2 subject='/C=SE/O=AddTrust AB/OU=AddTrust External TTP Network/CN=AddTrust External CA Root' hash=687fa451382278fff0c8b11f8d43d576671c6eb2bceab413fb83d965d06d2ff2
[ 10-14 09:39:43.885 17159:17159 I/wpa_supplicant ]
wlan0: CTRL-EVENT-EAP-PEER-CERT depth=1 subject='/C=US/O=Internet2/OU=InCommon/CN=InCommon Server CA' hash=623727ec472644a6bb70d240565c24223fdb0f2f5ac698027e3012489c70e817
[ 10-14 09:39:43.890 17159:17159 I/wpa_supplicant ]
wlan0: CTRL-EVENT-EAP-PEER-CERT depth=0 subject='/C=US/postalCode=70803/ST=Louisiana/L=Baton Rouge/street=110 Thomas Boyd/O=Louisiana State University/OU=LSU A & M/CN=acs-wlan.lsu.edu' hash=3b1214222f27c029417be13e02a6a422f958d470e88300f81716bc04663ae790
[ 10-14 09:39:43.892 17159:17159 I/wpa_supplicant ]
wlan0: CTRL-EVENT-EAP-PEER-ALT depth=0 DNS:acs-wlan.lsu.edu
[ 10-14 09:39:43.930 17159:17159 I/wpa_supplicant ]
EAP-MSCHAPV2: Authentication succeeded
[ 10-14 09:39:43.940 17159:17159 I/wpa_supplicant ]
EAP-TLV: TLV Result - Success - EAP-TLV/Phase2 Completed
[ 10-14 09:39:43.950 17159:17159 I/wpa_supplicant ]
wlan0: CTRL-EVENT-EAP-SUCCESS EAP authentication completed successfully
[ 10-14 09:40:53.840 17159:17159 I/wpa_supplicant ]
wlan0: Authentication with 20:bb:c0:f8:e4:75 timed out.

Your enterprise needs to update their radius servers and openssl software to fix this issue. A work around, if you are rooted, you can go to \data\misc\wifi\ and edit wpa_supplicant.conf. You need to add this line to your eduroam or wpa-eap network:
phase1="tls_disable_tlsv1_2=1"
Someone has already opened a ticket with Google: https://code.google.com/p/android/issues/detail?id=188867
Here's what my wpa_supplicant.conf looks like and I can connect to eduroam now:
disable_scan_offload=1
update_config=1
device_name=hammerhead
manufacturer=LGE
model_name=Nexus 5
model_number=Nexus 5
serial_number=066450ff0060c4a1
device_type=10-0050F204-5
config_methods=physical_display virtual_push_button
p2p_disabled=1
external_sim=1
wowlan_triggers=any
network={
ssid="eduroam"
key_mgmt=WPA-EAP IEEE8021X
eap=PEAP
identity="[email protected]"
password="mypassword"
phase1="tls_disable_tlsv1_2=1"
priority=14
proactive_key_caching=1
}

it works!!
after countless hours of researching, adding the line onto the wpa_supplicamt.conf works. thanks bro!!
slackhouse said:
Your enterprise needs to update their radius servers and openssl software to fix this issue. A work around, if you are rooted, you can go to \data\misc\wifi\ and edit wpa_supplicant.conf. You need to add this line to your eduroam or wpa-eap network:
phase1="tls_disable_tlsv1_2=1"
Someone has already opened a ticket with Google: https://code.google.com/p/android/issues/detail?id=188867
Here's what my wpa_supplicant.conf looks like and I can connect to eduroam now:
disable_scan_offload=1
update_config=1
device_name=hammerhead
manufacturer=LGE
model_name=Nexus 5
model_number=Nexus 5
serial_number=066450ff0060c4a1
device_type=10-0050F204-5
config_methods=physical_display virtual_push_button
p2p_disabled=1
external_sim=1
wowlan_triggers=any
network={
ssid="eduroam"
key_mgmt=WPA-EAP IEEE8021X
eap=PEAP
identity="[email protected]"
password="mypassword"
phase1="tls_disable_tlsv1_2=1"
priority=14
proactive_key_caching=1
}
Click to expand...
Click to collapse

slackhouse said:
Your enterprise needs to update their radius servers and openssl software to fix this issue. A work around, if you are rooted, you can go to \data\misc\wifi\ and edit wpa_supplicant.conf. You need to add this line to your eduroam or wpa-eap network:
phase1="tls_disable_tlsv1_2=1"
Click to expand...
Click to collapse
Just to confirm that this is working for me too - thanks very much! :good:

al3co said:
Just to confirm that this is working for me too - thanks very much! :good:
Click to expand...
Click to collapse
That didnt seem to work for me. Are you guys doing anything else like clicking the Dev options to use legacy lollipop DHCP? or disabling the google connectivity services? or just simply rebooting?

Nope, nothing else - I just added the line to wpa_supplicant.
I've not rooted my phone, so did it a slightly different way via adb, but I made sure that the permissions (chmod) and group/owner (chown) were both set to the original settings. Have you checked to see if changing that fixes it for you?

how did you do it without rooting your phone
al3co said:
Nope, nothing else - I just added the line to wpa_supplicant.
I've not rooted my phone, so did it a slightly different way via adb, but I made sure that the permissions (chmod) and group/owner (chown) were both set to the original settings. Have you checked to see if changing that fixes it for you?
Click to expand...
Click to collapse

slackhouse said:
Your enterprise needs to update their radius servers and openssl software to fix this issue. A work around, if you are rooted, you can go to \data\misc\wifi\ and edit wpa_supplicant.conf. You need to add this line to your eduroam or wpa-eap network:
phase1="tls_disable_tlsv1_2=1"
}
Click to expand...
Click to collapse
something strange is happening when i try this. once i edited the wpa_supplicant.conf file and tried to connect to my work network a 'wpa_supplicant.conf.tmp' file is created which effectively deletes the added line.
the only difference i can see is that the network requires mschapv2 so my (edited) wpa_supplicant.conf. files reads:
network={
ssid="D Wireless"
key_mgmt=WPA-EAP IEEE8021X
eap=PEAP
identity="####"
password="#####"
phase1="tls_disable_tlsv1_2=1"
phase2="auth=MSCHAPV2"
priority=3
proactive_key_caching=1
disabled=5
Any ideas?

Here's the steps I took, though I am rooted:
1. Disabled WiFi.
2. Edited the wpa_supplicant.conf file via using ES File Explorer.
3. Verified permissions on .conf file were correct using Terminal Emulator.
4. Rebooted phone.
5. Enabled WiFi and connected.
If I enabled WiFi with incorrect permissions or prior to rebooting, the conf file reverted to its original state.

slackhouse said:
Here's the steps I took, though I am rooted:
1. Disabled WiFi.
2. Edited the wpa_supplicant.conf file via using ES File Explorer.
3. Verified permissions on .conf file were correct using Terminal Emulator.
4. Rebooted phone.
5. Enabled WiFi and connected.
If I enabled WiFi with incorrect permissions or prior to rebooting, the conf file reverted to its original state.
Click to expand...
Click to collapse
thanks for such a swift reply.
Any chance you could post the command to use in the terminal to set the permissions (i suspect this is the issue).
at the moment the wpa_supplicant.conf file is showing permissions of:
-rw-rw---- wifi wifi 566
is this correct?
Despite using linux for the last 10 years i'm useless at getting this right!
many thanks

westy123 said:
thanks for such a swift reply.
Any chance you could post the command to use in the terminal to set the permissions (i suspect this is the issue).
at the moment the wpa_supplicant.conf file is showing permissions of:
-rw-rw---- wifi wifi 566
is this correct?
Despite using linux for the last 10 years i'm useless at getting this right!
many thanks
Click to expand...
Click to collapse
i just used "ls -la" to see the permissions. and if the rw, rw, isn't right, you'd use a chmod and if the owner or group wasn't right you'd use a chown. My organization has updated our radius servers, so I don't have to do this anymore. Here's what mine looks like without making any changes to it:"
-rw-r--r-- root root
To change owner:group, you'd do this: "chown root:root wpa_supplicant.conf"
To change permissions, you'd use: "chmod wpa_supplicant.conf 644"
Just make sure you have WiFi disabled, and once you save the file, reboot prior to enabling WiFi.

Wow, that's great, I'll try it first thing tomorrow (as son as I get back to work)
Thanks very much
update: unfortunately i still can't get it to work, despite setting permissions etc. either the file become corrupted and wifi doesn't work, or a new .tmp file is created.
Anyway, the IT people got back to me today, and assured me that they'd be updating the university servers etc. in the very near future, so it shouldn't be an issue for much longer.
But thanks for the help anyway, it's been a useful learning experience.

slackhouse said:
Your enterprise needs to update their radius servers and openssl software to fix this issue. A work around, if you are rooted, you can go to \data\misc\wifi\ and edit wpa_supplicant.conf. You need to add this line to your eduroam or wpa-eap network:
phase1="tls_disable_tlsv1_2=1"
Someone has already opened a ticket with Google: https://code.google.com/p/android/issues/detail?id=188867
Here's what my wpa_supplicant.conf looks like and I can connect to eduroam now:
disable_scan_offload=1
update_config=1
device_name=hammerhead
manufacturer=LGE
model_name=Nexus 5
model_number=Nexus 5
serial_number=066450ff0060c4a1
device_type=10-0050F204-5
config_methods=physical_display virtual_push_button
p2p_disabled=1
external_sim=1
wowlan_triggers=any
network={
ssid="eduroam"
key_mgmt=WPA-EAP IEEE8021X
eap=PEAP
identity="[email protected]"
password="mypassword"
phase1="tls_disable_tlsv1_2=1"
priority=14
proactive_key_caching=1
}
Click to expand...
Click to collapse
Didn't work for me. This issue is making me crazy

slackhouse said:
Here's the steps I took, though I am rooted:
1. Disabled WiFi.
2. Edited the wpa_supplicant.conf file via using ES File Explorer.
3. Verified permissions on .conf file were correct using Terminal Emulator.
4. Rebooted phone.
5. Enabled WiFi and connected.
If I enabled WiFi with incorrect permissions or prior to rebooting, the conf file reverted to its original state.
Click to expand...
Click to collapse
Doesn't work for me. Once rebooted It tries to connect automatically without success and then appears a pop up that wants me to enter the password again

For those still with problems, I found the solution on another website. Apparently the line you must add to the config file is a little bigger, here it is:
phase1="tls_disable_tlsv1_1=1 tls_disable_tlsv1_2=1"
It finally worked for me.

MaKTaiL said:
For those still with problems, I found the solution on another website. Apparently the line you must add to the config file is a little bigger, here it is:
phase1="tls_disable_tlsv1_1=1 tls_disable_tlsv1_2=1"
It finally worked for me.
Click to expand...
Click to collapse
Same issue for me, it made me crazy! finally i solved it... thanks thanks thanks!

doesn't work for me :crying:
Moto G2 xt1068 with cm13.. any work around?

Summary: what worked for me
I have a Motorola Moto E (condor) that I've just updated to LineageOS 14.1 (Nougat). Here's what I had to do, partly for my own reference and hopefully this will help others with the same problem. I couldn't connect to eduroam at my workplace due to a faulty RADIUS server that doesn't handshake correctly with TLS 1.2.
First, install ADB & Fastboot. Make sure USB debugging is enabled on your device, and allow root as ADB (Developer Options > Android debugging, and Root access: ADB only).
With your device plugged in to your PC, open an ADB command prompt on your PC (Start > Minimal ADB and Fastboot). Type:
Code:
adb root
adb pull /data/misc/wifi/wpa_supplicant.conf
This will put the wpa_supplicant.conf file on your computer (on my PC, it's located in "%localappdata%\VirtualStore\Program Files (x86)\Minimal ADB and Fastboot\wpa_supplicant.conf"). Edit it with your favourite text editor (NOT Notepad, as it won't recognise the Linux newline format. I prefer metapad). Find the configuration section for your WiFi network. Mine looks like this:
Code:
network={
ssid="eduroam"
bssid=<deleted>
key_mgmt=WPA-EAP IEEE8021X
eap=PEAP
identity="[email protected]"
password=<deleted>
[B] phase1="tls_disable_tlsv1_2=1"
[/B] ca_cert="keystore://CACERT_stfc"
phase2="auth=MSCHAPV2"
priority=51
proactive_key_caching=1
id_str="%7B%22creatorUid%22%3A%221000%22%2C%22configKey%22%3A%22%5C%22eduroam%5C%22WPA_EAP%22%7D"
}
To disable TLS v2.1 and get the connection working, you'll need to insert the highlighted line. Save the file in the same location.
Now turn off wifi on your device, go back to your ADB shell and type:
Code:
adb push wpa_supplicant.conf /data/misc/wpa_supplicant_new.conf
adb shell
This will open a debug prompt for your device. You're now altering files on your device as root, so be careful! Type
Code:
cd /data/misc/wifi
ls -la
You should see a directory listing, including wpa_supplicant.conf and wpa_supplicant_new.conf:
Code:
-rw-rw---- 1 wifi wifi 5412 2017-03-07 08:30 wpa_supplicant.conf
-rw-rw-rw- 1 root root 5432 2017-03-07 08:18 wpa_supplicant_new.conf
You need to overwrite the old version with the new. First make a copy of the old file:
Code:
cp wpa_supplicant.conf wpa_supplicant_old.conf
Now we need to ensure the new file has the same permissions as the old. Type:
Code:
chmod 660 wpa_supplicant_new.conf
chown wifi wpa_supplicant_new.conf
chgrp wifi wpa_supplicant_new.conf
Now to overwrite the old version:
Code:
rm wpa_supplicant.conf
mv wpa_supplicant_new.conf wpa_supplicant.conf
Type ls -la again to check the permissions are correct. You should see something like:
Code:
-rw-rw---- 1 wifi wifi 5412 2017-03-07 08:30 wpa_supplicant.conf
Finally, exit from the ADB prompt (just type exit), reboot your device, enable wifi, and try to connect again.
I hope that helps!

MaKTaiL said:
For those still with problems, I found the solution on another website. Apparently the line you must add to the config file is a little bigger, here it is:
phase1="tls_disable_tlsv1_1=1 tls_disable_tlsv1_2=1"
It finally worked for me.
Click to expand...
Click to collapse
Am on Lineage 15.1 and want to add it, but under Oreo Android is using WifiConfigStore.xml to store the config. How must the line look like in my case?

Related

[Q]Spoofing MAC on Galaxy Ace [Details&attempts listed]

Hey all,
I'm trying to spoof my MAC address on the Galaxy Ace, though nothing seems to be working. [Details and attempts listed below]
Phone Details:
Samsung Galaxy Ace GT-S5830
OS: Stock Gingerbread 2.3.5
Rooted
Installed Software:
Superuser
ES File Explorer (with show hidden (. prefix) files turned on & up to root enabled, root R/W)
Busybox (Free)
Android Terminal Emulator
(all with Superuser permissions)
What I've tried:
First I cleared the phone's IP DCHP lease in the router.
In Terminal on the phone whist not connected to a network, but wifi turned on I:
su
ifconfig wlan0 down
ifconfig wlan0 hw ether 112233445566
ifconfig wlan0 up
iplink show wlan0
Click to expand...
Click to collapse
also tried
su
ifconfig wlan0 down
iplink set wlan0 address 11:22:33:44:55:66
-->At which point I get (even with busybox prefixed)
iplink: SIOCSIFHWADDR: Operation not supported
Click to expand...
Click to collapse
The first code I quoted gave me no errors and appeared to execute successfully, but iplink show wlan0, the router (once the phone had connected), and several other tools (to see if ANY could see the change) also displayed the phone's default MAC.
(I also tired: ifconfig wlan0 hw link 112233445566, offsetting the existing MAC by only 1, and prefixing commands with busybox - busybox ifconfig wlan0 hw ether 112233445566 -resulted in ifconfig: SIOCSIFHWADDR: Operation not supported)
Looking for /data/misc/wifi/nvram.txt. Can see /data/misc/wifi/nvram.info containing my MAC. Have edited this and tried joining network again, but no MAC change is showing. Have read it's a rather bad idea to restart the phone before changing the MAC in files back, [Why?] so am yet to do a restart to test the file change...
Various apk tools (preceded by clearing DHCP lease for phone's IP & proceeded by checking router & iplink show wlan0) including:
Wireless MAC Changer - Osama Abukmail
Mac Address Ghost - diewland
MAC Spoofer for HD2 - Ian Kim (as the description stated although for a HD2, there was a change it may work for other types [later found out mine doesn't use/have /system/etc/calibration])
(all with super permissions)
Does anyone know of, or have any other ideas that may work?
Is this possible with only Custom ROM's?
Much thanks in advance,
Blue
MAC address spoofing is a type of discussion that XDA does not allow. For that reason, thread closed.

[GUIDE][CWM] WLAN Calibration and MAC address fix [CM]

This is for CyanogenMod and its derivates. Stock ROMs should be fine.
If you are inrested in editing your MAC address, there's a guide linked below. I don't know if stock ROMs will automcatically correct the MAC. In this case I think you have to edit /efs/imei/.nvmac.info (read more something about /efs before playing with it!)
Click to expand...
Click to collapse
The easiest way to do the calibration is:
Turn wifi ON and run
Code:
tiwlan_plts -n
This is the script called from a oneshot init service in my init.latona.rc if someone is interested. It will calibrate and correct the MAC automatically, even after a data wipe:
Code:
#!/system/bin/sh
if [ ! -f /data/misc/wifi/nvs_map.bin ]; then
insmod /system/lib/modules/tiwlan_drv.ko
/system/bin/tiwlan_loader -i /system/etc/wifi/tiwlan.ini -f /system/etc/wifi/firmware.bin
/system/bin/tiwlan_plts -n
rmmod tiwlan_drv
fi
____________________________________
Older method
Click to expand...
Click to collapse
UPDATE: I found an easy way to get the real MAC.
Download the apk attached or run the following commands:
Code:
su
mount -o remount,rw /system
ln -s /system/lib/modules/tiwlan_drv.ko /system/etc/wifi/tiwlan_drv.ko
#Make sure wifi is off
./mfgloader -l #Take the binary from a stock ROM
./mfgloader -u
rm /system/etc/wifi/tiwlan_drv.ko
mount -o remount,ro /system
After that your MAC address shoud begin with D0:C1:B1 and not 08:00:28.
To see your current MAC: System Settings > About phone > Status (turn wifi on)
Click to expand...
Click to collapse
____________________________________
This is the first post with some more informations about the calibration
Click to expand...
Click to collapse
While I was reading some logs, I noticed these lines
Code:
TIWLAN: 1089.979242: Starting to process NVS...
TIWLAN: 1089.983698: No Nvs, Setting default MAC address
TIWLAN: 1089.989007: pHwInit->uEEPROMCurLen: 1c
TIWLAN: 1089.993462: ERROR: If you are not calibating the device, you will soon get errors !!!
...
TIWLAN: 1094.726827: Station ID : 08-00-28-12-03-58
...
You can see that the device is not calibrated and that the default MAC address is assigned.
Each device should have a unique MAC address, two devices with the same MAC address in the same network will give problems.
________
UPDATE
I made two flashable files:
wlan_calibration.zip will only do the calibration
wlan_calibration_rand.zip will do the calibration and will randomize the last three octets of the address
Click to expand...
Click to collapse
If you still want to do it on your own, here the guide:
_______________
WLAN Calibration
Here the steps you need to follow (taken from: WLAN Calibration):
1) Turn wifi off
2) From ADB/terminal emulator run the following commands [1]:
Code:
$ su
# cd /data/misc/wifi
# insmod /system/lib/modules/tiwlan_drv.ko
# start wlan_loader
# ifconfig tiwlan0 up
# tiwlan_cu -b
/ w p 1 l 2 f 2
/ t b v 21
/ t b t 1 0 0 0 0 0 0 0
/ q
# rmmod tiwlan_drv
This will create this file: /data/misc/wifi/nvs_map.bin. If it's not there, you did something wrong.
After that you should not get the error while turning wifi ON.
________
MAC address fix
Even after the calibration, you'll still have the default MAC address (Station ID : 08-00-28-12-03-58). But no problem, you can 'easly' change it: Editing the MAC Address.
You need to get the newly created /data/misc/wifi/nvs_map.bin and edit it with an hex editor as described in the guide linked above.
I still don't know if the calibration will improve anything, but it surely won't hurt:
For optimal Wi-Fi performance it is mandatory to calibrate the Wi-Fi hardware
Click to expand...
Click to collapse
NOTE: nvs_map.bin is in /data, so if you do a factory reset you have to do this again.
___
[1]
ADB: System settings > Developers options (ON) > Root access > Apps and ADB
Wow...good solution buddy. I think u shouldpost this in development thread. People dont look much in general thread.
this should be added to the cm9/10 instalation .zip file
I did flash the zip file, ran the other commands thru terminal and see the file /data/misc/wifi/nvs_map.bin.
I don't understand the next step to be done.
I cannot open the bin file using hexeditor, I gave it root access.
And, in case i open it what mac address should i use? Is some address hard coded to each phone?
Hetalk said:
I did flash the zip file, ran the other commands thru terminal and see the file /data/misc/wifi/nvs_map.bin.
I don't understand the next step to be done.
I cannot open the bin file using hexeditor, I gave it root access.
And, in case i open it what mac address should i use? Is some address hard coded to each phone?
Click to expand...
Click to collapse
I don't know how MAC are assigned, I simply randomized the last part of the address (I kept the first part: 80:00:28).
Anyway I just uploaded a new zip file to make things even simpler. It will automatically randomize the last four three groups. If you want to use it, you need to delete /data/misc/wifi/nvs_map.bin first. EDIT: I changed the script, now you can do the calibration without removing the file.
Anyway I don't know what's wrong with your editor, I did it from my computer.
I tried using hex editor from play store.
I'll try the new zip tomorrow..
As I wrote in the OP, today I found the way to get the original MAC.
I don't know what is needed to make the commands work while in recovery (services needed etc...), so I made a dummy app (I simply adapted the code of an app I made few days ago to do a similar thing).
No fancy icon (it's the default one), no checks, ugly etc... It simply does the job (my Java knowledge is almost zero)
EDIT:
I almost forgot to say that the real MAC is in /efs/imei/.nvmac.info. It was the first place where I looked, but it's an hidden file an I didn't see at first.
bam....
Dear @loSconosciuto
I following this guide to solve the problem that actually I have in my phone with CM 11. In the Status menu, "non available" appears in my device WIFI mac. I following the guide step by step and I couldn't change it.
Could you help me?
carniman78 said:
Dear @loSconosciuto
I following this guide to solve the problem that actually I have in my phone with CM 11. In the Status menu, "non available" appears in my device WIFI mac. I following the guide step by step and I couldn't change it.
Could you help me?
Click to expand...
Click to collapse
This guide is for the kernel 2.6.35 which uses a completely different driver, it's quite an old thread. The calibration is done in a different way and I don't think that's the problem.
I'm not using CM11, so it's quite hard for me to know exactly what's wrong.
loSconosciuto said:
This guide is for the kernel 2.6.35 which uses a completely different driver, it's quite an old thread. The calibration is done in a different way and I don't think that's the problem.
I'm not using CM11, so it's quite hard for me to know exactly what's wrong.
Click to expand...
Click to collapse
Ok, sir. Thank you for your help.
Hi there
trying to fix Samsung s4 active i9295 wifi problem. at least got the MAC address showing (was 02:lots of zeroes) still unable to start wifi. is there anything else I should search for? tiwlan_drv.ko was not there so I downloaded it sepparately. do I need some more modules to be added? using stock 4 file engineering FW Android 5.0.1

100% WiFi Monitor Mode using Samsung Galaxy S2 (GT-I9100) Step by Step

Hi xda-mates. In this post I'm gonna show you, How to get wifi monitor mode on your device without external wifi adapter. If you don't know what is "wifi mode" goto wikipedia. The package consist from drivers, some wifi tools and aircrack.
Monitor Mode getting steps:
1. You have to root your device.
2. Flash CM 9.1.0.
3. Check out, your using originally cwm kernel included in the firmware you flashed.
4. Download my package(the password is my nickname).
5. Extract it to your sd.
6. Open up the terminal.
7. Type
Code:
su
cd pathToYourSd
sh install.sh
it will simply install all stuff to your system.
8. Type 'wmon on' in the terminal to activate monitor mode (type 'wmon off' to activate managed mode).
That's all. You have installed all that you needed, activated monitor mode and now you can use aircrack.
Troubleshooting:
Problem:
Code:
cannot find wireless tools, exiting!
Solution:
a) You must execute wifi tools (aircrack also) from root directory!
Code:
cd /
b) Check out of iwconfig, iwmulticall, iwpriv existance in /data/local/bin/.
Problem:
Code:
insmod: can't insert 'dhd.ko': invalid module format
error: SIOCGIFFLAGS (No such device)
Solution:
a) Make sure you are in supported rom and kernel.
b) Check out the file existance in /data/wmon/ (3 file).
Credits:
Aspartame21
Omri Ildis
Ruby Feinstein
Yuval Ofir
MemoryController
Could this possibly work on the Sprint Galaxy S2?
Sent from my SPH-D710 using xda premium
Mattix724 said:
Could this possibly work on the Sprint Galaxy S2?
Sent from my SPH-D710 using xda premium
Click to expand...
Click to collapse
May be but I don't know exactly. Try to istall it. I'll help you.
GREAT!
Thanks man! i was waiting for someone to go into this much detail, but does the wmon siyah mean that i can dualboot CM 9 and w/e rom ( in my case alliance) and get this to work? my problem with this before is that nothing would happen after my wifi is disabled and module is "loaded", also what do you mean run aircrack from the root dir? like root of the sd?
P.S. Testing now on the Galaxy S2 LTE version ( Rogers)
tutchthesky7 said:
Thanks man! i was waiting for someone to go into this much detail, but does the wmon siyah mean that i can dualboot CM 9 and w/e rom ( in my case alliance) and get this to work? my problem with this before is that nothing would happen after my wifi is disabled and module is "loaded", also what do you mean run aircrack from the root dir? like root of the sd?
P.S. Testing now on the Galaxy S2 LTE version ( Rogers)
Click to expand...
Click to collapse
I get suck after airmon-ng wlan0
says cannot find wireless tools, exiting!
Some help please and thanks?
tutchthesky7 said:
I get suck after airmon-ng wlan0
says cannot find wireless tools, exiting!
Some help please and thanks?
Click to expand...
Click to collapse
Use iwconfig wlan0 instead of airmon-ng wlan0. And make sure that you are in the root directory.
Code:
su
cd /
wmon on
iwconfig wlan0
iwconfig wlan0
aspartame21 said:
Use iwconfig wlan0 instead of airmon-ng wlan0. And make sure that you are in the root directory.
Code:
su
cd /
wmon on
iwconfig wlan0
Click to expand...
Click to collapse
OK thank you!, i'll give that a shot and post back!
Nada
aspartame21 said:
Use iwconfig wlan0 instead of airmon-ng wlan0. And make sure that you are in the root directory.
Code:
su
cd /
wmon on
iwconfig wlan0
Click to expand...
Click to collapse
# wmon on
Original module loaded. disabling wifi
LOADING MODULE
insmod: cant insrt dhd.ko : file exists error : SI0CIFFLAGS (no such device)
then i tried iwconfig wlan0
wlan0 No such device
so i checked iwconfig to see whats up
and my Wlan0 isn't there.. hmmm
Edit: I typed in wmon on and it responded with LOADING MODULE, then i did iwconfig wlan0 and it showed it in manage mode, what next?
tutchthesky7 said:
# wmon on
Original module loaded. disabling wifi
LOADING MODULE
insmod: cant insrt dhd.ko : file exists error : SI0CIFFLAGS (no such device)
then i tried iwconfig wlan0
wlan0 No such device
so i checked iwconfig to see whats up
and my Wlan0 isn't there.. hmmm
Edit: I typed in wmon on and it responded with LOADING MODULE, then i did iwconfig wlan0 and it showed it in manage mode, what next?
Click to expand...
Click to collapse
Don't pay attention to "managed mode" lettering, you are in monitor mode. To test monitor mode working type 'airodump-ng wlan0' and you will see that everything works perfect.
errrm.. not QUIIITEE, it says cannot find wireless tools, exiting. then it deletes all the files i extracted
IT IS WORK! one little question
THIS WORK, first, and ofc, THX man
I had a sgs2(official), rooted in gingerbread, and then i flashed ICS with CM 9.1, then i folllow yours steps, y putted my sgs2 in mode monitor and i checked.
Just one question, i searched in google, and ask in IRC, but i don't find the answer:
¿Do can i use the same steps to get WPA as Ubuntu or Backtrack? else... ¿do you know some link where a tutorial get wpa via sgs2?
I want complete the last step, thx for your time, and sry for my english
Clitoris Errante said:
THIS WORK, first, and ofc, THX man
I had a sgs2(official), rooted in gingerbread, and then i flashed ICS with CM 9.1, then i folllow yours steps, y putted my sgs2 in mode monitor and i checked.
Just one question, i searched in google, and ask in IRC, but i don't find the answer:
¿Do can i use the same steps to get WPA as Ubuntu or Backtrack? else... ¿do you know some link where a tutorial get wpa via sgs2?
I want complete the last step, thx for your time, and sry for my english
Click to expand...
Click to collapse
You can use all stuff like in ubuntu/bt.
Mode inyecction?
Thx for answer me, i did decide install another time backtrack in my sgs2(i removed ), but i want crack wpa without brute force or diccionaries, because it is imposible.
¿Is there some way to crack a wpa without brute force or diccionaries? ¿Do i could implement rainbow tables in sgs2, or is there some way to hashing with aircrack?
Thx for your time,
Clitoris Errante said:
Thx for answer me, i did decide install another time backtrack in my sgs2(i removed ), but i want crack wpa without brute force or diccionaries, because it is imposible.
¿Is there some way to crack a wpa without brute force or diccionaries? ¿Do i could implement rainbow tables in sgs2, or is there some way to hashing with aircrack?
Thx for your time,
Click to expand...
Click to collapse
Aircrack-ng is included to the package you installed. Just type aircrack-ng after switching wifi monitor mode
from a day to other, i can't use this
i didn't use somedays, and now i can't use, it is appears as delete, or simplely, not work. I did install applications in my sgs2.
But now i can't run it. I tried reinstall, but always put in the output:
"wmon on" not found
"wmod on" not found
"wmod monitor" not found
i did that in /, and i executed the install.sh in sdcard as you said in your post.
In internet i not found nothing, and i know programming bash a little, i tried solved gave wmon bit executable but is useless, i follow all steps rights as you said. The only one thing interesant when i execute install that is the output:
Installing Driver...
OK
Installing Utils...
OK
Creating Symlink...
link failed FIle exists
link failed File exists
//I think here is the fail of my steps, i think that make reference to /data/wmon, but i am not sure, i checked that files, but i can't solved
OK
Fixing Permissions...
OK
Temporary FIles Cleaning...
OK
Installation COmpleted! To start WiFi monitor mode just type : "wmod monitor"
I am sry if i am heavy, thx for your time.
This is pretty cool, I managed to make some progress, however got error at authorization stage at line:
aireplay-ng -1 0 -a MAC wlan0
Waiting for beacon frame (BSSID: .......) on channel -1
Couldn't determine current channel for wlan0, you should either force the operation with --ignore-negative-one or apply kernel patch
same error with injection
I'm pretty new to linux stuff, is there any way to bypass this?
Another thing is that I can't use wi-fi after using monitor mode, even if i shut it down (wmon off) until phone restart, is that alright?
Thanks in advance, and keep doing the great job!
Clitoris Errante said:
i didn't use somedays, and now i can't use, it is appears as delete, or simplely, not work. I did install applications in my sgs2.
But now i can't run it. I tried reinstall, but always put in the output:
"wmon on" not found
"wmod on" not found
"wmod monitor" not found
i did that in /, and i executed the install.sh in sdcard as you said in your post.
In internet i not found nothing, and i know programming bash a little, i tried solved gave wmon bit executable but is useless, i follow all steps rights as you said. The only one thing interesant when i execute install that is the output:
Installing Driver...
OK
Installing Utils...
OK
Creating Symlink...
link failed FIle exists
link failed File exists
//I think here is the fail of my steps, i think that make reference to /data/wmon, but i am not sure, i checked that files, but i can't solved
OK
Fixing Permissions...
OK
Temporary FIles Cleaning...
OK
Installation COmpleted! To start WiFi monitor mode just type : "wmod monitor"
I am sry if i am heavy, thx for your time.
Click to expand...
Click to collapse
I've to correct my scripts, but don't wait for it. Just type "export PATH=/data/local/bin:$PATH". You can also add this to your terminal emulator as launch commands or create a script in autostart folder:
Code:
su
cd /system/etc/init.d/
touch 17env
echo "#!/system/bin/sh\nexport PATH=/data/local/bin:$PATH\nexit 0" > 21env
makslll said:
This is pretty cool, I managed to make some progress, however got error at authorization stage at line:
aireplay-ng -1 0 -a MAC wlan0
Waiting for beacon frame (BSSID: .......) on channel -1
Couldn't determine current channel for wlan0, you should either force the operation with --ignore-negative-one or apply kernel patch
same error with injection
I'm pretty new to linux stuff, is there any way to bypass this?
Another thing is that I can't use wi-fi after using monitor mode, even if i shut it down (wmon off) until phone restart, is that alright?
Thanks in advance, and keep doing the great job!
Click to expand...
Click to collapse
I use "aireplay-ng -2 -b VICTIM -h FAKEDMAC wlan0"
aspartame21 said:
I've to correct my scripts, but don't wait for it. Just type "export PATH=/data/local/bin:$PATH". You can also add this to your terminal emulator as launch commands or create a script in autostart folder:
Code:
su
cd /system/etc/init.d/
touch 17env
echo "#!/system/bin/sh\nexport PATH=/data/local/bin:$PATH\nexit 0" > 21env
Click to expand...
Click to collapse
Where is this Terminal autostart folder? Also, I tried executing the first command and it gave me nothing but a "> " line. What should I do?
Hi guy,
first of all, thanks for your great job.
I've seen as you have uploaded a wmon_siyah4.5.1 version... does it work with that siyah version?
I have that kernel (and that version), and I get the error:
Code:
insmod: can't insert 'dhd.ko': invalid module format
error: SIOCGIFFLAGS (No such device)
just after run 'wmon on'.
Can you help me, please?
thanks

How to fix wireless stuck on turn on .

Hi all,
Recently my nexus 5 wireless stopped working. It blocks on turning on.
I know it's a common problem on the forums, and people are returning the phones to the warranty and they are replaced, but i cannot do that. (link)
Also i don't know if really it's a hardware problem, since sometimes it works, i think it's something related with the software.
I investigate further the problem.
So what i tried:
- different factory images
- changed also .macaddr from here. http://forum.xda-developers.com/showpost.php?p=52441901&postcount=47. Still my mac address is not visible in About phone - Status. And of course i have the permissions set OK, owner, and other things. (i have the nexus7 tablet so similar to that).
- my wpa_supplicant.conf from /data/misc/wifi looks like this http://prntscr.com/7jhz6v[/url[B]] ... in /etc/wifi [url]http://prntscr.com/7ji6rz. Here i have also a wpa_supplicant.conf and a p2p_supplicant.conf. So what i can see from the logcat, wireless config is set from here. So what's the purpose of that one from /persist ? To store network lists?
On my nexus 7 2013 i have also in this folder driver binary, WCNSS_qcom_wlan_nv_deb.bin. Tried to find one for Nexus 5, but just found one for mako. I added also this but with no success.
So, any other ideas, suggestions ? Thanks for listening and reading.
Try looking up TOT files and flash them as described in this tutorial http://www.usoftsmartphone.com/t192632.html. I saw a trace of these TOT files here on XDA. Be very careful of the storage (16 or 32 GB) and of the version (US/International).
When did your issues start exactly?
I am having the same issue, also my bluetooth. Mine appeared 2 OTAs ago.
I'm unable to turn on WiFi either. It's just stuck on "WiFi turning on." I rooted my Nexus 5 and tried following the directions in post 107 in this thread:
http://forum.xda-developers.com/google-nexus-5/help/wifi-stuck-t2721643/post60011636#post60011636
When I use a root explorer, the folder is empty. If I use a terminal, it says permission denied to do anything with the file. Any ideas on how to delete the .macaddr file? Root Checker Basic says that I am indeed rooted.
Instead of an external site, this one is the same here right?
http://forum.xda-developers.com/goo...orial-how-to-flash-factory-images-lg-t2713833
I also found the megadrive links no longer worked. Mirrors provided on the XDA one.
tmihai20 said:
Try looking up TOT files and flash them as described in this tutorial http://www.usoftsmartphone.com/t192632.html. I saw a trace of these TOT files here on XDA. Be very careful of the storage (16 or 32 GB) and of the version (US/International).
Click to expand...
Click to collapse
Flashing .tot files is useless
Prodeje79 - Yes, that link it's ok. You can try that, but will be useless. Bluetooth seems to be ok for me. Check at phone status if you have a Bluetooth address. If not then responsible for that is .baddr file from /persist/bluetooth folder. You can find examples of the file, if not, i can provide mine. IMPORTANT. Also be careful at permissions and owner for bluetooth folder and .badddr file.
I successfully flashed a .tot image but it's useless. /persist folder it's skipped anyway. Also please make sure that in order to be possible to enter download mode you need to be on a 4.4 rom. I don't know why for lollipop they removed this. /persist folder it's the problem, cannot delete and recreate, rename.
I apreciate the response. Thanks for point that out. I indeed did the bluetooth .baddr piece as well and noted the differences. I am getting read/write errors as well. I was able to COPY them out to read them. The secret was to put phone in airplane mode. Oddly enough, Even after replacing the folders/files (as I could not EDIT but delete worked), paying special attention to their corresponding permissions and owners etc etc, my wifi worked for a few moments and showed my ORIGINAL mac address. This means it must be written somewhere else?????
if you don't mind, please see my personal thread http://forum.xda-developers.com/google-nexus-5/help/wifi-bluetooth-sim-card-issues-ota-t3140987
Are you saying I should get back to stock 4.4 (KRT16M) from
from https://developers.google.com/android/nexus/images#hammerhead
?
I have an 820 from USA, 16GB.
THen try TOT?
I am not clear to use BIN_LGD820AT-00-V10a-NXS-XX-OCT-01-2013-KFS78N-USER-16G or BIN_LGD820AT-00-V10a-NXS-XX-OCT-09-2013-KQS81M-USER-16G
Also, am I supposed to add a +0 or +1 or something to file name? at this point I see a few different versions of TOT flashing and I'd love to confirm instructions exactly!!!
yoncy said:
Prodeje79 - Yes, that link it's ok. You can try that, but will be useless. Bluetooth seems to be ok for me. Check at phone status if you have a Bluetooth address. If not then responsible for that is .baddr file from /persist/bluetooth folder. You can find examples of the file, if not, i can provide mine. IMPORTANT. Also be careful at permissions and owner for bluetooth folder and .badddr file.
I successfully flashed a .tot image but it's useless. /persist folder it's skipped anyway. Also please make sure that in order to be possible to enter download mode you need to be on a 4.4 rom. I don't know why for lollipop they removed this. /persist folder it's the problem, cannot delete and recreate, rename.
Click to expand...
Click to collapse
Another question, the MAC address that showed for a few minutes, did not match what was in my stock macaddr file nor the one I created. Where else could this be listed????
Yes, i think i reverted to 4.4 stock image (KRT16M). Just with that i succeeded to enter download mode with Volume Up + plug in USB cable. After that drivers will be installed, you need to change the port to COM41.
Prodeje79 said:
Are you saying I should get back to stock 4.4 (KRT16M) from
from https://developers.google.com/androi...ges#hammerhead
?
Click to expand...
Click to collapse
So you have 820 version i had 821. I haven't renamed anything, i think i just downloaded the latest version, so in this case 09-OCT. Remembered that saw in the thread something with renaming but i didn't get too much attention to that, wasn't my case. Will take a look again.
Again as i told you flashing a .tot image will not help, persist folder will be skipped.
Prodeje79 said:
I have an 820 from USA, 16GB.
THen try TOT?
I am not clear to use BIN_LGD820AT-00-V10a-NXS-XX-OCT-01-2013-KFS78N-USER-16G or BIN_LGD820AT-00-V10a-NXS-XX-OCT-09-2013-KQS81M-USER-16G
Also, am I supposed to add a +0 or +1 or something to file name? at this point I see a few different versions of TOT flashing and I'd love to confirm instructions exactly!!!
Click to expand...
Click to collapse
Mine as well, until in a moment when i played with permissions. After that, no wifi at all.
I found a MAC address in the /etc/wifi/bcmhd.cal file. Open it with a text editor and you will see it there. I changed also that with no results.
Prodeje79 said:
Another question, the MAC address that showed for a few minutes, did not match what was in my stock macaddr file nor the one I created. Where else could this be listed????
Click to expand...
Click to collapse
So as a resume:
- /persist/wifi ..... where the mac address is stores
- /data/misc/wifi - wpa_supplicant, entropy, p2p_supplicant - these files can be deleted, copied from another device. In wpa_supplicant we have serial number (i changed to my actual one with no difference)
- /etc/wifi with bcmdhd.cal file and some general wpa_supplicant_overlay etc.
Compared to my flo if i run in the phone terminal or adb shell --- ip link show ----- i don't have wlan0 and p2p0. These should be there, in this list they are all the interfaces used by Android linux system. If i add that binary file WCNSS_qcom_wlan_nv.bin (from a mako i have found it) to /data/misc/wifi after a reboot i will have those. But again with no difference.
Plus i don't understand why phone tries to set the wlan0 interface down and not up
------'3 interface setcfg wlan0 0.0.0.0 0 down"----ok 0.0.0.0 no mac address found but why down and not up.
That's it for now, thank you too, let's hope in the end will succeed to fix this problem (if really it's a software problem).
Compared to my flo:
flo: /persist/wifi - owner root/root (775)
hammerhead: event if you try to change to root/root in init.hammerhead.rc owner is changed to system/wifi in the script (you can comment that). Compared the two scripts and everything should be ok.
Can someone tell me where are located network interfaces on Android ? (nothing like on linux ex: /etc/network/interfaces). Trying to add those wlan0 and p2p0 manually,
{
"lightbox_close": "Close",
"lightbox_next": "Next",
"lightbox_previous": "Previous",
"lightbox_error": "The requested content cannot be loaded. Please try again later.",
"lightbox_start_slideshow": "Start slideshow",
"lightbox_stop_slideshow": "Stop slideshow",
"lightbox_full_screen": "Full screen",
"lightbox_thumbnails": "Thumbnails",
"lightbox_download": "Download",
"lightbox_share": "Share",
"lightbox_zoom": "Zoom",
"lightbox_new_window": "New window",
"lightbox_toggle_sidebar": "Toggle sidebar"
}
but i think they are dinamically set or something?
https://www.dropbox.com/s/30s8nqo74cweuqt/2015-06-28 10.30.30.png?dl=0
@bitdomo
Could you give us a hand?
yoncy said:
Compared to my flo:
flo: /persist/wifi - owner root/root (775)
hammerhead: event if you try to change to root/root in init.hammerhead.rc owner is changed to system/wifi in the script (you can comment that). Compared the two scripts and everything should be ok.
Can someone tell me where are located network interfaces on Android ? (nothing like on linux ex: /etc/network/interfaces). Trying to add those wlan0 and p2p0 manually,
but i think they are dinamically set or something?
https://www.dropbox.com/s/30s8nqo74cweuqt/2015-06-28 10.30.30.png?dl=0
Click to expand...
Click to collapse
Did you see these posts?
http://forum.xda-developers.com/showpost.php?p=56035498&postcount=42
http://code.google.com/p/android/issues/detail?id=78702#c78
This is from Xperia, and I am not sure what this would do: http://forum.xda-developers.com/xperia-sp/general/guide-fix-connectivity-android-5-0-t2951677
yoncy said:
Compared to my flo:
flo: /persist/wifi - owner root/root (775)
hammerhead: event if you try to change to root/root in init.hammerhead.rc owner is changed to system/wifi in the script (you can comment that). Compared the two scripts and everything should be ok.
Can someone tell me where are located network interfaces on Android ? (nothing like on linux ex: /etc/network/interfaces). Trying to add those wlan0 and p2p0 manually,
but i think they are dinamically set or something?
https://www.dropbox.com/s/30s8nqo74cweuqt/2015-06-28 10.30.30.png?dl=0
Click to expand...
Click to collapse
I flashed a ton of stock roms yesterday. I also switched to recovery-clockwork-touch-6.0.4.5-hammerhead
In regards to PA, I did pa_hammerhead-4.45-20140729
I then tried twrp-2.8.7.0-hammerheadcaf and proceeded to flash cm-12.1-20150629-NIGHTLY-hammerheadcaf
My wifi and bluetooth now turn on, scan, and connect in CM! Unfortunately, the wifi frequently disconnects and my cell data no longer works! VOice and text work OK though.
For fun I went back to stock 4.4. wifi and BT no longer turn on. My cell data still doesnt work. Voice and text work OK. Says ATT but has exclamation point........
I then flashed back to 5.1.1 stock. Cell data works fine in 5.1.1. Not sure why my cell data doesn't work in 4.4???????????
@Prodeje79 Hi again, thanks for the links. But tried both, with pmf removed and ap_scan on 0. Even tried other wpa_supplicant variants (nexus 7 , nexus4, even linux ones). setenforce 0 disable selinux (set to permissive).
Right now i was concentrated on this error. As i can see
--------------
avc: denied { read } for name="wpa_supplicant.conf" dev="mmcblk0p28" ino=318356 scontext=u:r:wpa:s0 tcontext=ubject_r:app_data_file:s0 tclass=file permissive=1
----------- it's related with selinux . For a moment Wifi started working, HW addr for wlan0 was detected ( i had wlan0 and p2p in "ip link show" terminal command ). Will investigate more related with that.
I/wpa_supplicant( 3427): type=1400 audit(0.0:13): avc: denied { read } for name="wpa_supplicant.conf" dev="mmcblk0p28" ino=318356 scontext=u:r:wpa:s0 tcontext=ubject_r:app_data_file:s0 tclass=file permissive=1
I/wpa_supplicant( 3427): type=1400 audit(0.0:14): avc: denied { open } for name="wpa_supplicant.conf" dev="mmcblk0p28" ino=318356 scontext=u:r:wpa:s0 tcontext=ubject_r:app_data_file:s0 tclass=file permissive=1
I/wpa_supplicant( 3427): type=1400 audit(0.0:15): avc: denied { getattr } for path="/data/misc/wifi/wpa_supplicant.conf" dev="mmcblk0p28" ino=318356 scontext=u:r:wpa:s0 tcontext=ubject_r:app_data_file:s0 tclass=file permissive=1
D/SoftapController( 190): Softap fwReload - Ok
W/CommandListener( 190): Failed to retrieve HW addr for wlan0 (No such device)
D/CommandListener( 190): Setting iface cfg
E/WifiStateMachine( 770): Unable to change interface settings: java.lang.IllegalStateException: command '29 interface setcfg wlan0 0.0.0.0 0 down' failed with '400 29 Failed to set address (No such device)'
E/WifiMonitor( 770): killSupplicant p2ptrue init.svc.wpa_supplicant=unknown init.svc.p2p_supplicant=unknown
E/WifiMonitor( 770): startMonitor called with unknown iface=wlan0
Click to expand...
Click to collapse
Solution for this problem.
http://forum.xda-developers.com/showpost.php?p=62176769&postcount=164
Click to expand...
Click to collapse
Also having the same issue, here's a few parts of my log.
Code:
W/CommandListener( 194): Failed to retrieve HW addr for wlan0 (No such device)
D/CommandListener( 194): Setting iface cfg
E/WifiStateMachine( 888): Unable to change interface settings: java.lang.IllegalStateException: command '4 interface setcfg wlan0 0.0.0.0 0 down' failed with '400 4 Failed to set address (No such device)'
E/WifiMonitor( 888): killSupplicant p2ptrue init.svc.wpa_supplicant=unknown init.svc.p2p_supplicant=unknown
D/WifiMonitor( 888): startMonitoring(wlan0) with mConnected = false
E/WifiHW ( 888): Unable to open connection to supplicant on "@android:wpa_wlan0": No such file or directory
Code:
I/wpa_supplicant( 1429): rfkill: Cannot open RFKILL control device
E/wpa_supplicant( 1429): Could not read interface wlan0 flags: No such device
E/wpa_supplicant( 1429): Could not read interface wlan0 flags: No such device
E/wpa_supplicant( 1429): wlan0: Failed to initialize driver interface
Any other ideas? I've tried different kernels, wiping /system and installing new ROM, deleting and creating .macaddr, setting permissions of /persist/wifi, deleting /data/misc/wifi/wpa_supplicant.conf.
I managed to get it working for a little while by booting into safe mode and starting wifi there, then rebooting, but it only worked once.
Lollipop eventually overheats your phone and fries WiFi.
Put phone in fridge and then try. It works while cool
Prodeje79 said:
Lollipop eventually overheats your phone and fries WiFi.
Put phone in fridge and then try. It works while cool
Click to expand...
Click to collapse
I don't think Lollipop has anything to do with the issue, as I have been running my Nexus 5 on CM12.1 for a little over 5 months and nothing has ever happened. I purchased my girlfriend her first Nexus, it came with PACman KK on it, but wifi didn't work. I will try the fridge, thank you for the advice.
Kytosion said:
I don't think Lollipop has anything to do with the issue, as I have been running my Nexus 5 on CM12.1 for a little over 5 months and nothing has ever happened. I purchased my girlfriend her first Nexus, it came with PACman KK on it, but wifi didn't work. I will try the fridge, thank you for the advice.
Click to expand...
Click to collapse
OK I guess it could just be coincidence with the age of my phone and release of lolliop. Just literally right after my first reboot on the new OTA my sim card slot, wifi, and bluetooth started having intermittant issues....
PUtting in fridge and boom my wifi and BT work for a few mins...... same results as others.
also the battery draining has helped some, but just temporary....
yoncy said:
Solution for this problem.
Click to expand...
Click to collapse
What's the latest on your end? @yoncy
That other thread has some success flashing 6.0.
I already sent my phone to lg and authorized repair.....
Just call me bad luck Brian

How to change wifi mac address?

Hi guys,
I'd like to be able to change the mac address of my device to be able to use airport Wifi while on transit.
Here is what I do using tasker
1) Turn off wifi
2) Launch the shell script below
Code:
array=( 1 2 3 4 5 6 7 8 9 0 A B C D E F )
newmac=${array[$RANDOM%16]}${array[$RANDOM%16]}${array[$RANDOM%16]}${array[$RANDOM%16]}${array[$RANDOM%16]}${array[$RANDOM%16]}
chattr -i /persist/wlan_mac.bin
sed -i "1 s/=.*/=64A2F9$newmac/" /persist/wlan_mac.bin
chattr +i /persist/wlan_mac.bin
3) Turn on wifi
But it doesn't work
/persist/wlan_mac.bin is successfully modified by the script but real mac address isn't.
Need your help!
chattr binary is not present on Oxygen Os...
So file gets overwritten while setting airplane mode on and off
It works!
Installed busybox magisk module (which includes chattr binary) and replaced chattr by busybox chattr!
Also modified script by adding command line toggle for airplane mode.
Code:
#!/system/bin/sh
array=( 1 2 3 4 5 6 7 8 9 0 A B C D E F )
newmac=${array[$RANDOM%16]}${array[$RANDOM%16]}${array[$RANDOM%16]}${array[$RANDOM%16]}${array[$RANDOM%16]}${array[$RANDOM%16]}
busybox chattr -i /persist/wlan_mac.bin
sed -i "1 s/=.*/=64A2F9$newmac/" /persist/wlan_mac.bin
busybox chattr +i /persist/wlan_mac.bin
settings put global airplane_mode_on 1; am broadcast -a android.intent.action.AIRPLANE_MODE --ez state true
settings put global airplane_mode_on 0; am broadcast -a android.intent.action.AIRPLANE_MODE --ez state false
i can't thank you enough! i was looking for a way to hard change my mac and none of the rooted apps were working for me. just stumbled upon this thread and it's working good.
Can you guys guide me on How to run That script .. I've already installed BusyBox ..
Thank you so much
Dimitrimem said:
Can you guys guide me on How to run That script .. I've already installed BusyBox ..
Thank you so much
Click to expand...
Click to collapse
Save this into text file, upload to internal memory, name and extension is relevant (mac.sh for example, load to internal memory.
In terminal emulator:
Open directory with file:
cd /sdcard
Add rights to execute:
chmod +x mac.sh
Run:
su sh mac.sh
OnePlus 6 @ Tapatalk
I have BusyBox installed .. how do I replace chattr with the BusyBox one or that's done by default .. I
I managed to save the script and run it from terminal emulator .. however the Mac Address don't changes
Hey there,
Looks like this method doesn't work anymore with pie.
Modifying /persist/wlan_mac.bin has no effect but managed to change mac temporarily (until next reboot) by using the commands below:
Code:
svc wifi disable
ip link set wlan0 addr 01:02:03:04:05:06
svc wifi enable
Modifying hostname method has also changed. It doesn't survive reboot either
Before PIE:
Code:
resetprop -v ro.product.name "newHostname"
#Toggle airplane mode
settings put global airplane_mode_on 1; am broadcast -a android.intent.action.AIRPLANE_MODE --ez state true
settings put global airplane_mode_on 0; am broadcast -a android.intent.action.AIRPLANE_MODE --ez state false
After PIE: net.hostname gets its value from system settings after toggling airplane mode on/off
Code:
settings put system oem_oneplus_devicename newHostname
#Toggle airplane mode
settings put global airplane_mode_on 1; am broadcast -a android.intent.action.AIRPLANE_MODE --ez state true
settings put global airplane_mode_on 0; am broadcast -a android.intent.action.AIRPLANE_MODE --ez state false
[/CODE]
Have you guys succeeded in modifying these permanently?
Karboush the first code actaully worked for me so thnak you .. i wish there was a script for this that actually can randomly change the macaddress .. would be great
thank you <3
Karboush said:
Hey there,
Looks like this method doesn't work anymore with pie.
Modifying /persist/wlan_mac.bin has no effect but managed to change mac temporarily (until next reboot) by using the commands below:
Code:
svc wifi disable
ip link set wlan0 addr 01:02:03:04:05:06
svc wifi enable
Modifying hostname method has also changed. It doesn't survive reboot either
Before PIE:
Code:
resetprop -v ro.product.name "newHostname"
#Toggle airplane mode
settings put global airplane_mode_on 1; am broadcast -a android.intent.action.AIRPLANE_MODE --ez state true
settings put global airplane_mode_on 0; am broadcast -a android.intent.action.AIRPLANE_MODE --ez state false
After PIE: net.hostname gets its value from system settings after toggling airplane mode on/off
Code:
settings put system oem_oneplus_devicename newHostname
#Toggle airplane mode
settings put global airplane_mode_on 1; am broadcast -a android.intent.action.AIRPLANE_MODE --ez state true
settings put global airplane_mode_on 0; am broadcast -a android.intent.action.AIRPLANE_MODE --ez state false
[/CODE]
Have you guys succeeded in modifying these permanently?
Click to expand...
Click to collapse
Time to revive a dead thread. The new method using
Code:
svc wifi disable
ip link set wlan0 addr 01:02:03:04:05:06
svc wifi disable
Doesn't seem to work anymore. After I set the new Mac address I get an error saying
"RTNETLINK answers: Device or resources busy"
Does anyone know a fix for this or if I'm doing anything wrong? Thanks.
From what I understand, Pie uses a random mac address for each specific wifi connection and no longer reveals your true id.
Android Pie by default doesn't change your Mac address when connecting to wifis. The option can only be turned on by editing the system config.xml file, which idk how to do. h ttps://source.android.com/devices/tech/connect/wifi-mac-randomization
Anyone know how to edit it and turn on the option?
Well, after a bit of experimenting I found out a solution to this, bit some issues.
When you want to change your mac address put the phone into airplane mode. The. Put the code
Code:
ip link set wlan0 addr XX:XX:XX:XX:XX:XX
There are some specifications though. Any letters put into it, hexidecimal or not, will make it invalid. And any zeros at the beginning of a pair will also make it invalid, so 01:02:03:04:05:06 would be invalid but 10:20:30:40:50:60 would be valid. The parsing must have changed. Anyone got any solutions to get letters in?
I'm using macchanger and my phone is rooted with magisk .. that easy .. all I had to do is change from iproute to airroute for the " method" works like a charm ?
Dimitrimem said:
I'm using macchanger and my phone is rooted with magisk .. that easy .. all I had to do is change from iproute to airroute for the " method" works like a charm ?
Click to expand...
Click to collapse
Did you have to do anything in particular to make this work? I am on 9.0.4 rooted with Magisk, using this app with mode set to airtable and it does not seem to work. The app is confirmed granted root access per Magisk.
The only thing I'm doing is set airplane mode and wifi enabled .. when I run the app the phone comes out of airplane mode .. not sure I see the "airtable" feature on this app ... Anyways wish you luck
Dimitrimem said:
The only thing I'm doing is set airplane mode and wifi enabled .. when I run the app the phone comes out of airplane mode .. not sure I see the "airtable" feature on this app ... Anyways wish you luck
Click to expand...
Click to collapse
I am using the latest BETA if that makes a difference
after updating to pie I can't change my Mac address anymore. tried it a few ways via terminal and tried at least 3 different apps.
it seems that as soon as I do ifconfig wlan up, or disable airplane mode, it gets reverted back.
if I do ifconfig wlan0 he ether 00:11:22:33:44:55 while the interface is up, it fails to authenticate me to the network
I may have to revert to Oreo
EDIT:
so after reverting to oreo, i still was unable to change the mac using the app that worked before. I found the values for the mac adderss in the file in /persist/wlan_mac.bin.
now, i tried changing these values but they kept getting re-written when i flipped Airplane mode off. so added the immutable flag to it after editing it. now the change is persistent accross boot
so after editing the file, do
chattr +i /persist/wlan_mac.bin
Click to expand...
Click to collapse
and whatever values you have for the interfaces should stick after you boot
i wonder if this would've worked if i tried it in android 9.... too lazy to factory reset again to try it out
keep in mind i was working with a oneplus 3t.

Categories

Resources