Closed Bug 736196 Opened 13 years ago Closed 13 years ago

Wifi: Fix handling of passwords

Categories

(Core :: DOM: Device Interfaces, defect)

x86_64
Linux
defect
Not set
normal

Tracking

()

RESOLVED FIXED

People

(Reporter: mrbkap, Assigned: mrbkap)

References

Details

Attachments

(1 file)

Attached patch Patch (deleted) — Splinter Review
The version of the wifi patch that landed mishandles passwords for networks that we want to reconnect to, but don't want to update the password for. In the patch, I also update our internal representation of the network when we update it.
Attachment #606308 - Flags: review?(jones.chris.g)
Comment on attachment 606308 [details] [diff] [review]
Patch

>diff --git a/dom/wifi/nsWifiWorker.js b/dom/wifi/nsWifiWorker.js

>@@ -1438,6 +1452,7 @@ nsWifiWorker.prototype = {
>         networkReady();
>       }).bind(this));
>     } else {
>+      privnet.disabled = 0;

What is this doing?

The rest looks OK.
Attachment #606308 - Flags: review?(jones.chris.g)
(In reply to Chris Jones [:cjones] [:warhammer] from comment #1)
> >+      privnet.disabled = 0;
> 
> What is this doing?

By default, networks added by add_network are disabled and need an explicit enableNetwork call to enable them. However, here we do:

add_network
set_network_config
save_config
enable_network (and disable others)

which means that wpa_supplicant saves the network as being disabled. Because we want our networks to be enabled by default, we want to make sure to enable the network before the save_config. This ensures that the new network is remembered as being enabled.
Comment on attachment 606308 [details] [diff] [review]
Patch

I'll add a comment to that effect before checkin.
Attachment #606308 - Flags: review?(jones.chris.g)
Comment on attachment 606308 [details] [diff] [review]
Patch

r=me with comment added
Attachment #606308 - Flags: review?(jones.chris.g) → review+
https://hg.mozilla.org/mozilla-central/rev/ca1b5de7c0eb
Status: NEW → RESOLVED
Closed: 13 years ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: