Title: [293215] trunk/Source/WebKit
Revision
293215
Author
z...@falconsigh.net
Date
2022-04-22 04:08:58 -0700 (Fri, 22 Apr 2022)

Log Message

[GLib] Make WebKitSettings XSS auditor functions no-op
https://bugs.webkit.org/show_bug.cgi?id=239651

Reviewed by Adrian Perez de Castro.

With the XSS auditor feature being deprecated and removed, and the
preference entries removed in r293199, the GLib API for this feature
has to be adjusted as well. In both getter and setter, a warning is
printed out when invoked.

* UIProcess/API/glib/WebKitSettings.cpp:
(webkit_settings_get_enable_xss_auditor):
(webkit_settings_set_enable_xss_auditor):

Modified Paths

Diff

Modified: trunk/Source/WebKit/ChangeLog (293214 => 293215)


--- trunk/Source/WebKit/ChangeLog	2022-04-22 07:25:00 UTC (rev 293214)
+++ trunk/Source/WebKit/ChangeLog	2022-04-22 11:08:58 UTC (rev 293215)
@@ -1,3 +1,19 @@
+2022-04-22  Zan Dobersek  <zdober...@igalia.com>
+
+        [GLib] Make WebKitSettings XSS auditor functions no-op
+        https://bugs.webkit.org/show_bug.cgi?id=239651
+
+        Reviewed by Adrian Perez de Castro.
+
+        With the XSS auditor feature being deprecated and removed, and the
+        preference entries removed in r293199, the GLib API for this feature
+        has to be adjusted as well. In both getter and setter, a warning is
+        printed out when invoked.
+
+        * UIProcess/API/glib/WebKitSettings.cpp:
+        (webkit_settings_get_enable_xss_auditor):
+        (webkit_settings_set_enable_xss_auditor):
+
 2022-04-21  John Cunningham  <johncunning...@apple.com>
 
         Use GCGLSpanTuple to pass buffer parameters to multidraw calls.

Modified: trunk/Source/WebKit/UIProcess/API/glib/WebKitSettings.cpp (293214 => 293215)


--- trunk/Source/WebKit/UIProcess/API/glib/WebKitSettings.cpp	2022-04-22 07:25:00 UTC (rev 293214)
+++ trunk/Source/WebKit/UIProcess/API/glib/WebKitSettings.cpp	2022-04-22 11:08:58 UTC (rev 293215)
@@ -1821,7 +1821,9 @@
 {
     g_return_val_if_fail(WEBKIT_IS_SETTINGS(settings), FALSE);
 
-    return settings->priv->preferences->xssAuditorEnabled();
+    g_warning("webkit_settings_get_enable_xss_auditor is deprecated and always returns FALSE. XSS auditor is no longer supported.");
+
+    return FALSE;
 }
 
 /**
@@ -1835,13 +1837,8 @@
 {
     g_return_if_fail(WEBKIT_IS_SETTINGS(settings));
 
-    WebKitSettingsPrivate* priv = settings->priv;
-    bool currentValue = priv->preferences->xssAuditorEnabled();
-    if (currentValue == enabled)
-        return;
-
-    priv->preferences->setXSSAuditorEnabled(enabled);
-    g_object_notify_by_pspec(G_OBJECT(settings), sObjProperties[PROP_ENABLE_XSS_AUDITOR]);
+    if (enabled)
+        g_warning("webkit_settings_set_enable_xss_auditor is deprecated and does nothing. XSS auditor is no longer supported.");
 }
 
 /**
_______________________________________________
webkit-changes mailing list
webkit-changes@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to