ubports / ubuntu-touch

Ubuntu Touch's issue inbox is now migrated to GitLab.
https://gitlab.com/ubports/ubuntu-touch
1.29k stars 109 forks source link

Device occasionally re-asks for password for WPA2-PSK Wi-Fi network #1018

Open UniversalSuperBox opened 5 years ago

UniversalSuperBox commented 5 years ago

Device: Nexus 5 (hammerhead) Channel: RC Build: 2018-W01 (actually 2019, but who's counting?)

I've connected my Nexus 5 to my home Wi-Fi network which is hosted by a Actiontec T3200M. The connection seems generally stable and traffic flows normally.

Sometimes my device will wake up with the password prompt for my Wi-Fi network on screen. Other times (though this seems less common), the prompt will appear while I'm using the device. In either case, entering the password and tapping "Connect" will not cause the device to connect. The only way to get the device to connect is to cancel this prompt then tap on the network's name in the network indicator.

The following log occurs when this happens. I've replaced my network's BSSID with all a's: https://paste.ubuntu.com/p/dJm5g2bgJ9/

Guessing below

The fact that this issue seems to occur right after a roaming attempt leads me to believe that the AP is dropping the phone rather than the other way around. I don't have logs to prove this (either from the AP or Android), but I think I have a similar issue with the Android phones in my house. They will sometimes drop the network, even with great signal, and wait 10 seconds to reconnect.

The difference between us and other platforms is that our behavior when this happens is to assume that the entered password is incorrect, when we should instead try to connect to the SSID again with the same credentials.

But that's just guessing. Finding a way to reliably reproduce this problem (or enough reports with logs when it occurs) is the first step.

hummlbach commented 5 years ago

And if you ignore the request to enter the password an just click on the network in the it connects just fine without entering the password again right? Having that too on the pro5 but rarely.

dobey commented 5 years ago

WiFi is a fickle beast, and because of the way it works, NetworkManager doesn't always know what the connection error is which caused a disconnection, and therefore takes the assumption it was authentication, and thus asks for the password again. It would need to be changed in NetworkManager itself, to get different behavior. It's behaved this way ever since it had support for wireless.

Stefano0101 commented 5 years ago

This was happening on Pro 5 in past as well,(pre-OTA-5) now on latest OTA-7 I did not once experienced this behaviour. Exactly same behavior.

Arc676 commented 5 years ago

Can confirm that this happened on devel 2019-01-11. I didn't try connecting via the prompt though, I just hit cancel. As reported, I can reconnect without re-entering the password simply by tapping the network in System Settings.

Flohack74 commented 5 years ago

This is not device specific, happens on OPO also (but seems to depend on the counterpart AP). I hope we get more stability with the network manager upgrade in the works.

ant0nwax commented 4 years ago

I realized this happens on Note 4 Samsung Snapdragon and Exynos, too the MAC address changes after each reboot and then somehow the password needs to be reentered, we also found a workaround for this, i will edit post later

UniversalSuperBox commented 4 years ago

@ant0nwax, that sounds like a different issue to this one. This issue relates to the prompt appearing while the device is idle, even sleeping. Your issue sounds like it occurs on reboot.

Rargente commented 4 years ago

I seem to be able to replicate this bug consistently. I'm currently running 3 Wifi APs all with the same ssid. Normally as I move through the house the AP connections are handed over seamlessly. With UT as the phone moves into the next AP zone it will pop up the password dialog. The hand-over part seems to be initiating correctly (the phone is stll connected to the weaker AP when the pop up occurs) but just not completing.

This is definitely a reconnection issue as I have no problem automatically connecting to Wifi when I get home or to work, also the phone makes no attempt to connect to my 2.4 network instead.

I am on RC 2020-W13 on hammerhead.