[Webkit-unassigned] [Bug 99352] [GTK] [WebKit2] Add an 'authenticate' signal to WebKitWebView
bugzilla-daemon at webkit.org
bugzilla-daemon at webkit.org
Wed Aug 7 00:49:23 PDT 2013
https://bugs.webkit.org/show_bug.cgi?id=99352
--- Comment #51 from Martin Robinson <mrobinson at webkit.org> 2013-08-07 00:49:01 PST ---
(From update of attachment 207922)
View in context: https://bugs.webkit.org/attachment.cgi?id=207922&action=review
Couple little things...
> Source/WebKit2/UIProcess/API/gtk/WebKitAuthenticationRequest.cpp:202
> + request->priv->realm = request->priv->authenticationChallenge->protectionSpace()->realm().utf8();
> + return request->priv->realm.data();
The realm doesn't change, so I think it makes sense to do this:
if (request->priv->realm.isNull())
request->priv->realm = request->priv->authenticationChallenge->protectionSpace()->realm().utf8();
This will prevent an application that caches the realm from crashing if something else calls the method again.
> Source/WebKit2/UIProcess/API/gtk/WebKitAuthenticationRequest.cpp:254
> +guint webkit_authentication_request_get_previous_failure_count(WebKitAuthenticationRequest* request)
> +{
> + g_return_val_if_fail(WEBKIT_IS_AUTHENTICATION_REQUEST(request), 0);
> +
> + return request->priv->authenticationChallenge->previousFailureCount();
> +}
We can't really expose this properly. The reason is that the authentication request we get from soup only exposes whether or not the challenge is a retry. This will always be one or zero, regardless of how many times it has failed. So I think you should either remove this method or turn it into webkit_authentication_request_is_retry.
See AuthenticationChallenge::AuthenticationChallenge in AuthenticationChallengeSoup.cpp.
> Source/WebKit2/UIProcess/API/gtk/WebKitCredential.cpp:125
> + credential->username = credential->credential.user().utf8();
Same comment here and for password about the realm above.
--
Configure bugmail: https://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.
More information about the webkit-unassigned
mailing list