Bug 216822 - [GTK][WPE] Move TLS errors API from WebKitContext to WebKitWebsiteDataManager
Summary: [GTK][WPE] Move TLS errors API from WebKitContext to WebKitWebsiteDataManager
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: WebKitGTK (show other bugs)
Version: WebKit Nightly Build
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Nobody
URL:
Keywords: Gtk
Depends on:
Blocks: 216041
  Show dependency treegraph
 
Reported: 2020-09-22 06:23 PDT by Carlos Garcia Campos
Modified: 2020-09-24 02:02 PDT (History)
6 users (show)

See Also:


Attachments
Patch (56.18 KB, patch)
2020-09-22 06:59 PDT, Carlos Garcia Campos
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Carlos Garcia Campos 2020-09-22 06:23:52 PDT
Make it per session instead of global to the network process.
Comment 1 Carlos Garcia Campos 2020-09-22 06:59:19 PDT
Created attachment 409358 [details]
Patch
Comment 2 EWS Watchlist 2020-09-22 07:00:04 PDT
Thanks for the patch. If this patch contains new public API please make sure it follows the guidelines for new WebKit2 GTK+ API. See https://trac.webkit.org/wiki/WebKitGTK/AddingNewWebKit2API
Comment 3 Alex Christensen 2020-09-23 14:45:50 PDT
Comment on attachment 409358 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=409358&action=review

> Source/WebCore/platform/network/soup/SoupNetworkSession.h:82
> +    bool m_ignoreTLSErrors { false };

You may want to have this be consistent with its default value on WebsiteDataStore.
You may also want to have the default be false, but it was true on WebProcessPool so this is maintaining the status quo.
Comment 4 EWS 2020-09-23 15:14:20 PDT
Committed r267502: <https://trac.webkit.org/changeset/267502>

All reviewed patches have been landed. Closing bug and clearing flags on attachment 409358 [details].
Comment 5 Lauro Moura 2020-09-23 20:36:53 PDT
GTK and WPE layout test bots are exiting early after this change:

https://build.webkit.org/results/GTK%20Linux%2064-bit%20Release%20(Tests)/r267504%20(16003)/results.html

Maybe something missing in WTR?
Comment 6 Lauro Moura 2020-09-23 20:58:33 PDT
Using http/tests/ssl/verify-ssl-enabled.php (a failure) and enabling logging, the only network request/response that appears is:

set 24 00:52:47 lauro-desktop WebKitNetworkProcess[1575042]: < HTTP/1.1 1 Cancelled
set 24 00:52:47 lauro-desktop WebKitNetworkProcess[1575042]: < Soup-Debug-Timestamp: 1600919567
set 24 00:52:47 lauro-desktop WebKitNetworkProcess[1575042]: < Soup-Debug: SoupMessage 0 (0x563077e470d0)
set 24 00:52:47 lauro-desktop WebKitNetworkProcess[1575042]: 

(Instead of the regular GET request)
Comment 7 Carlos Garcia Campos 2020-09-24 01:01:53 PDT
Comment on attachment 409358 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=409358&action=review

>> Source/WebCore/platform/network/soup/SoupNetworkSession.h:82
>> +    bool m_ignoreTLSErrors { false };
> 
> You may want to have this be consistent with its default value on WebsiteDataStore.
> You may also want to have the default be false, but it was true on WebProcessPool so this is maintaining the status quo.

The default is false for the GLib API, but true internally so that TLS errors are ignored by default in WTR. But it seems I broke it, see bug #216911