Closed Bug 1075384 Opened 10 years ago Closed 10 years ago

Autofilled password should be cleared if autofilled username is changed by the user

Categories

(Toolkit :: Password Manager, defect)

32 Branch
x86_64
Windows 7
defect
Not set
normal

Tracking

()

RESOLVED DUPLICATE of bug 967315

People

(Reporter: vladislav_kurkotov, Unassigned)

Details

User Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:32.0) Gecko/20100101 Firefox/32.0
Build ID: 20140923175406

Steps to reproduce:

Need to have already saved email and password in passwords manager.
1. Create a form with inputs for email and password that uses angular for submitting data to server. 
2. Fill form with autocomplete.
3. Change email.
4. Submit form with angular.

You can check this behavior on our test site: https://testlp.licenseportal.co:444/User/Register
Just try to register with autocomplete.



Actual results:

3. Email is changed.
4. Form send without password.


Expected results:

3. Email is changed, password field should become empty.
4. Form must be send entirely.
As a result I want to see one of three solutions:
1. After autocomplete, when email is changed password must be erased from form (such behavior is in chrome).
2. Developers must have instruments to turn autocomplete off.
3. Other way of filling form with autocomplete (to support angular)
Isn't this a bug in angular, if it's not submitting what's actually in the form fields?
Flags: needinfo?(vladislav_kurkotov)
I have found the reason: filling the form with firefox password manager doesn't call on input event (http://api.jquery.com/on/)
Flags: needinfo?(vladislav_kurkotov)
And on change too.
> doesn't call on input event

Ah.  That's bug 1025483, which is fixed in Firefox 33.  Do you see the problem in a beta 33 build?

> And on change too.

Bug 1077308.
Component: HTML: Form Submission → Password Manager
Product: Core → Toolkit
And Vladislav, thank you for figuring out what's going on here!  It's very much appreciated.
(In reply to Boris Zbarsky [:bz] from comment #5)
> Ah.  That's bug 1025483, which is fixed in Firefox 33.  Do you see the
> problem in a beta 33 build?

It's OK in 33.

But how about
> 3. When Email is changed, password field should become empty.
?
Is emptying the password field something the _site_ is doing in this case, or something you think the browser is doing?
the browser (like in Chrome)
OK.  Let's focus this bug on that the, I guess.
Summary: Password from autocomplete on registration form is not sent with angular → Autofilled password should be cleared if autofilled username is changed by the user
Thank you. I think I should have done this in two separate bugs. First is for submitting with angular (resolved in 33b) and second for erasing password in form when email is changed.
Note that there are cases where you don't want to clear the password e.g. if we save the password with the wrong username (e.g. we think the username is the email instead of the username field) or the username is saved with the wrong case (although bug 499649 helped with that in Fx32).

(In reply to vladislav_kurkotov from comment #1)
> 2. Developers must have instruments to turn autocomplete off.

That's what @autocomplete=off is for. Since this is a registration form, it seems like that's what you'd want anyways.

Does @autocomplete=off not work for you?
Flags: needinfo?(vladislav_kurkotov)
> Does @autocomplete=off not work for you?
No, it doesn't.
Flags: needinfo?(vladislav_kurkotov)
Can you explain? Why not? autocomplete=off should prevent auto-filling. It will still autocomplete the username and then fill in the password but with your STR you're using a different username so the autocompletion won't happen.
Flags: needinfo?(vladislav_kurkotov)
http://screencast.com/t/70yoGFedXYz
Flags: needinfo?(vladislav_kurkotov)
Status: UNCONFIRMED → RESOLVED
Closed: 10 years ago
Resolution: --- → DUPLICATE
You need to log in before you can comment on or make changes to this bug.