Last Comment Bug 671422 - First sync should prompt for Master Password
: First sync should prompt for Master Password
Status: VERIFIED FIXED
[verfied in services]
: regression, verified-aurora
Product: Cloud Services
Classification: Client Software
Component: Firefox Sync: Backend (show other bugs)
: unspecified
: All All
: -- normal (vote)
: mozilla8
Assigned To: Philipp von Weitershausen [:philikon]
:
:
Mentors:
Depends on:
Blocks: 671435 664792
  Show dependency treegraph
 
Reported: 2011-07-13 14:41 PDT by Philipp von Weitershausen [:philikon]
Modified: 2011-08-03 10:18 PDT (History)
1 user (show)
See Also:
Crash Signature:
(edit)
QA Whiteboard:
Iteration: ---
Points: ---
fixed


Attachments
v1 (3.87 KB, patch)
2011-07-13 15:24 PDT, Philipp von Weitershausen [:philikon]
rnewman: review+
asa: approval‑mozilla‑aurora+
Details | Diff | Splinter Review

Description Philipp von Weitershausen [:philikon] 2011-07-13 14:41:06 PDT
This is a regression from bug 664792 where we made autoconnect in charge of the first sync. We should make it prompt for the MP.
Comment 1 Philipp von Weitershausen [:philikon] 2011-07-13 15:24:25 PDT
Created attachment 545760 [details] [diff] [review]
v1

Simply remove the bail out in Service._autoconnect if the master password is locked. This restored the previous behaviour:

* we prompt for the MP on autoconnect
* if the user cancels, we continue to schedule syncs at MASTER_PASSWORD_LOCKED_RETRY_INTERVAL (which is 15 minutes), rather than the singleDeviceInterval (which is 1 day)
Comment 2 Richard Newman [:rnewman] 2011-07-13 15:55:18 PDT
Comment on attachment 545760 [details] [diff] [review]
v1

Review of attachment 545760 [details] [diff] [review]:
-----------------------------------------------------------------

I will file a followup to write an automated test that subsequent timed sync attempts do not attempt to access MP-protected credentials.
Comment 3 Philipp von Weitershausen [:philikon] 2011-07-13 15:57:45 PDT
http://hg.mozilla.org/services/services-central/rev/98ffad2ab85e
Comment 4 Tracy Walker [:tracy] 2011-07-14 07:21:37 PDT
This is asking for the MP when you click the Connect button in setup.  Is that correct?

If you give the MP at that time, then proceed through setup, everything works fine.
Comment 5 Philipp von Weitershausen [:philikon] 2011-07-14 07:45:10 PDT
(In reply to comment #4)
> This is asking for the MP when you click the Connect button in setup.  Is
> that correct?

Yes, this is correct.

More crucially, though, once you have Sync set up and restart, about 10 seconds later you should get an MP prompt for the initial sync. If you enter your MP then, it will sync. If you deny it, it will not bother you anymore, but it will check every 15 minutes whether your MP is unlocked now (you may have unlocked it by some other means).
Comment 6 Tracy Walker [:tracy] 2011-07-14 08:12:11 PDT
ok, yes, 10 seconds after restart we get the MP prompt.  Cancelling it sets next sync to 15 minutes later.  Instant sync triggers don't attempt to sync during the 15 minute MP interval. I assume that's expected, otherwise we get MP prompted relentlessly, right.

However, at the expected time, MP does not prompt again and instant sync triggers don't fire a prompt either.
Comment 7 Philipp von Weitershausen [:philikon] 2011-07-14 08:17:25 PDT
(In reply to comment #6)
> ok, yes, 10 seconds after restart we get the MP prompt.  Cancelling it sets
> next sync to 15 minutes later.  Instant sync triggers don't attempt to sync
> during the 15 minute MP interval. I assume that's expected, otherwise we get
> MP prompted relentlessly, right.

Exactly.

> However, at the expected time, MP does not prompt again and instant sync
> triggers don't fire a prompt either.

That is precisely the intended behaviour.
Comment 8 Philipp von Weitershausen [:philikon] 2011-07-14 11:02:55 PDT
https://hg.mozilla.org/mozilla-central/rev/98ffad2ab85e
Comment 9 Philipp von Weitershausen [:philikon] 2011-07-14 11:05:38 PDT
Comment on attachment 545760 [details] [diff] [review]
v1

Request approval for Aurora since this is a regression caused by bug 664792 which is in Aurora. The risk is minimal and the fix has already been verified by Services QA.
Comment 10 Philipp von Weitershausen [:philikon] 2011-07-14 14:36:02 PDT
http://hg.mozilla.org/releases/mozilla-aurora/rev/1efb6881323c

Note You need to log in before you can comment on or make changes to this bug.