Uh oh!
There was an error while loading. Please reload this page.
Fix authentication in Safari. - #199
Conversation
tibbe
commented
Mar 19, 2014
Thanks for the patch. Could you check the Travis CI test failure above please? |
hesselink
commented
Mar 19, 2014
Yes, I'll see if I can fix that, thanks for pointing it out. |
hesselink
commented
Mar 20, 2014
I think I see what the problem is. Now that we set |
tibbe
commented
Mar 20, 2014
@dcoutts, do we support both auth types or only digest auth? On Thu, Mar 20, 2014 at 2:07 PM, Erik Hesselink notifications@github.comwrote:
|
dcoutts
commented
Apr 7, 2014
We only offer digest auth (however if clients pre-emptively send basic auth then we do accept it). So a properly functioning client that gets prompted for authentication will only be offered digest and should only respond with digest auth. |
dcoutts
commented
Apr 7, 2014
Perhaps we can make the code do this conditionally for safari. Using no qop should be ok according to the standard (iirc), it's the older digest standard, but the newer one the introduces qop (I think) still says it's ok to leave it out and behave the same as the older standard. |
dcoutts
commented
Apr 7, 2014
Actually, if the HTTP package just ignores the qop then we should be ok. The server can use
|
dcoutts
commented
Apr 7, 2014
Oh, right, but that's what the TODO was about, that the HTTP package has a totally broken qop=auth impl. It sends qop=auth but does not include the required cnonce etc. We could make the server more forgiving, by treating Filed as haskell/HTTP#54 |
We now offer 'qop="auth"', because without it, authentication in Safari fails immediately. With the field set to auth, authentication seems to work in the latest Firefox, Safari, Chrome and Internet Explorer. However, the HTTP package as used in cabal-install has a bug where it send 'qop="auth"' without an 'nc' or 'cnonce' field. So we are lenient: when these fields are not present, we fall back to no qop. Fixeshaskell#132. [1] haskell/HTTP#54
hesselink
commented
Apr 8, 2014
I've amended the fix to fall back to QopNone when the 'nc' or 'cnonce' fields are missing. This fixes the test case (at least locally; let's wait for Travis). |
dcoutts
commented
Apr 9, 2014
Thanks! |
mchakravarty
commented
Apr 10, 2014
Thanks for fixing this! 👍 |
@dcoutts: I'm not sure what the TODO meant, perhaps you remember?
An empty qop field makes authentication in Safari fail immediately. With the field set to auth, authentication seems to work in the latest Firefox, Safari, Chrome and Internet Explorer. This is with HTTP 4000.2.10.
Fixes#132, which we're getting asked about a lot on admin@hackage.haskell.org.