Closed Bug 736111 Opened 10 years ago Closed 10 years ago

Master password appears two times


(Core :: Security: PSM, defect)

10 Branch
Not set





(Reporter: megia.oscar, Unassigned)



(1 file)

User Agent: Mozilla/5.0 (X11; Linux x86_64; rv:10.0.1) Gecko/20100101 Firefox/10.0.1
Build ID: 20120209085555

Steps to reproduce:

Firefox 10.0.2 (and previous with sync)
Setup Sync and master pasword. Then open a tab with saved password (like gmail) and setup Edit/Preferences/General "When firefox starts->show my windows and tabs from last time".

Actual results:

The next time I start firefox it will ask two times for the master password.

Expected results:

It must ask only one time for the master password. It has no sense to ask two times for the same.

And is very annoying being typing the master pasword and see open a new window with the last caracters of the password in it.
This is a patch to avoid to show maore than one time the Master password input window. There are more bugzilla bugs with similar problem:
Bug 177175 - Should not display more than one "Master Password" prompts
Bug 625051 - Two windows for master password appear 
Bug 720672 - Master password entry box appears multiple times

I think with this patch will solve this kid of bug forever.
Attachment #606265 - Flags: review?(honzab.moz)
Component: Untriaged → Security: PSM
Product: Firefox → Core
QA Contact: untriaged → psm
Attachment #606265 - Flags: review?(honzab.moz) → review?(bsmith)
Comment on attachment 606265 [details] [diff] [review]
Patch to avoid to have more than one Master password window

Review of attachment 606265 [details] [diff] [review]:

Thanks for the patch. I think it isn't correct because we cannot just return without doing anything when bRunning is true. In particular, I think there can be race conditions where you could still get one master password prompt after another: the user closes a master password prompt (set bRunning = false) just as a SSL connection enqueues a request to show the master password prompt. We should avoid that case too, if we can.

I am going to dupe this to bug 177175. Please reopen this bug if you think I am wrong in doing so. If you think your patch already handles the case above, or you rework it to do so, please attach it to bug 177175.
Attachment #606265 - Flags: review?(bsmith)
Closed: 10 years ago
Resolution: --- → DUPLICATE
Duplicate of bug: 177175
Brian, I *think* we have some AutoBool or similar name class that would reset the flag to false in dtor.  If not, I think you should create one in mfbt.  Thanks.
You need to log in before you can comment on or make changes to this bug.