Closed Bug 614642 Opened 13 years ago Closed 13 years ago

HTTP Auth Prompt failure

Categories

(Firefox for Android Graveyard :: General, defect)

x86_64
Linux
defect
Not set
normal

Tracking

(fennec2.0b3+)

VERIFIED FIXED
Tracking Status
fennec 2.0b3+ ---

People

(Reporter: mfinkle, Assigned: dougt)

Details

Attachments

(1 file)

"Method not implemented" when calling [nsIAuthPrompt2::asyncPromptAuth]

Some kind of regression
tracking-fennec: --- → 2.0b3+
(In reply to comment #0)
> "Method not implemented" when calling [nsIAuthPrompt2::asyncPromptAuth]

This is not the problem. This is expected:

http://mxr.mozilla.org/mozilla-central/source/netwerk/protocol/http/nsHttpChannelAuthProvider.cpp#955

This code calls aysncPromptAuth and it fails, so the sync fallback is used. The
fallback works, a dialog is displayed and the credentials are filled in.

However, we keep calling nsHttpChannelAuthProvider::PromptForIdentity - I don't
know why yet.
Auth prompts appear to work fine for me on Linux - or is this indeed just limited to OS X (as stated)?
I see it on desktop Linux. Not sure what Stuart is using.
OS: Mac OS X → Linux
Hardware: x86 → x86_64
I see the assertion without a doubt on android or linux, however the prompt still works for me.  I tried both with a sync'ed profile and a clean profile.
(In reply to comment #4)
> I see the assertion without a doubt on android or linux, however the prompt
> still works for me.  I tried both with a sync'ed profile and a clean profile.

Yeah, the assertion is expected and is not the problem.
yeah, either way, it seems to work fine for me.
Using a nightly on Android (nexus one), I am able to log into Mozilla HTTP basic auth sites. I am still unable to log into the sites using a desktop Linux build.
This works for me on builds:

Mozilla/5.0 (Maemo; Linux armv71; rv:2.0b8pre) Gecko/20101201 Namoroka/4.0b8pre Fennec/4.0b3pre

and

Mozilla/5.0 (Android; Linux armv71; rv:2.0b8pre) Gecko/20101201 Namoroka/4.0b8pre Fennec/4.0b3pre

and

Mozilla/5.0 (X11; Linux i686; rv:2.0b8pre) Gecko/20101202 Firefox/4.0b8pre Fennec/4.0b3pre
okay.

so, if you have a username+password saved in your profile, we will try to use this pair and never asked again. It doesn't matter if you have the correct username/password pair or a bad one.... we just use it.

The reason is that if we have a saved username and passwords for a realm, we return it from our prompting code here:

http://mxr.mozilla.org/mobile-browser/source/components/PromptService.js#595

This is quite different than what Firefox does.  Firefox desktop always displays a dialog.  IFF you agree to the prompt, do we log you in.

I think we should follow the same pattern -- at least for beta3.  If we want to discuss alternative methods to log into a site, we can have that discussion somewhere else.

To fix this bug for beta 3, we just need to remove that |return true| statement mention above.
Attached patch patch v.1Splinter Review
Assignee: nobody → doug.turner
Attachment #494789 - Flags: review?(mark.finkle)
ignore comment at the end of the patch... blah
Comment on attachment 494789 [details] [diff] [review]
patch v.1


>   asyncPromptAuth: function asyncPromptAuth(aChannel, aCallback, aContext, aLevel, aAuthInfo) {
>     // bug 514196
>+    // This will for the prompt to be sync (even if there is an assertion)
>     throw Cr.NS_ERROR_NOT_IMPLEMENTED;
>   }

Make the comment english or remove it
Attachment #494789 - Flags: review?(mark.finkle) → review+
http://hg.mozilla.org/mobile-browser/rev/1bf399f3abd1
Status: NEW → RESOLVED
Closed: 13 years ago
Resolution: --- → FIXED
Nice, verified FIXED On builds:

Mozilla/5.0 (Maemo; Linux armv71; rv:2.0b8pre) Gecko/20101203 Namoroka/4.0b8pre Fennec/4.0b3pre

and

Mozilla/5.0 (Android; Linux armv71; rv:2.0b8pre) Gecko/20101203 Namoroka/4.0b8pre Fennec/4.0b3pre
Status: RESOLVED → VERIFIED
You need to log in before you can comment on or make changes to this bug.