Open Bug 538719 Opened 15 years ago Updated 2 years ago

Canceling HTTP auth prompt does not cancel other pending requests for the same host

Categories

(Core :: Networking: HTTP, defect, P5)

x86
macOS
defect

Tracking

()

People

(Reporter: Dolske, Unassigned)

References

Details

(Whiteboard: [necko-would-take])

Bug 475053 added support for asyncPromptAuth; now if session restore opens two tabs requiring authentication for the same host+realm, only 1 prompt is shown and you only need to enter credentials once. I noticed that if you *cancel* the prompt, you'll then get the prompt again (for the second tab). This isn't desirable. In fact, what seems to be happening is that the multiple requests for authentication are not actually making it to the code added in 475053 (which explicitly has code for handling this situation, the |consumers| array created in asyncPromptAuth() holds each request for the same host+realm). So, when Cancel is clicked, we only have one nsIAuthPromptCallback to notify of the cancellation. Even when entering valid credentials, there's only one nsIAuthPromptCallback that gets notified of success. STR: 1) New profile, set to restore tabs on startup, set signon.debug pref to true 2) Open 2 tabs to a site requesting authentication (eg http://dolske.net/mozilla/tests/httpauth/realmX) 3) Restart browser 4) Click cancel on first authprompt 5) Click cancel on second authpromt Note debug logging between steps 3 and 5. The auth prompter knows nothing about the second request until after step 4.
-> me
Assignee: nobody → honzab.moz
Status: NEW → ASSIGNED
Blocks: 411085
Assignee: honzab.moz → nobody
Status: ASSIGNED → NEW
Whiteboard: [necko-would-take]
Priority: -- → P5
Severity: normal → S3
You need to log in before you can comment on or make changes to this bug.