Changeset 44904 in webkit
- Timestamp:
- Jun 20, 2009 2:57:16 PM (15 years ago)
- Location:
- trunk
- Files:
-
- 6 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/WebKit/gtk/ChangeLog
r44903 r44904 1 2009-06-20 Jan Michael Alonzo <jmalonzo@webkit.org> 2 3 Reviewed by Gustavo Noronha and Xan Lopez. 4 5 [Gtk] Implement DRT XSS auditor support 6 https://bugs.webkit.org/show_bug.cgi?id=26571 7 8 Add a setting "enable-xss-auditor" to enable this feature. 9 10 * webkit/webkitwebsettings.cpp: 11 (webkit_web_settings_class_init): 12 (webkit_web_settings_set_property): 13 (webkit_web_settings_get_property): 14 (webkit_web_settings_copy): 15 * webkit/webkitwebview.cpp: 16 (webkit_web_view_update_settings): 17 (webkit_web_view_settings_notify): 18 1 19 2009-06-20 Jan Michael Alonzo <jmalonzo@webkit.org> 2 20 -
trunk/WebKit/gtk/webkit/webkitwebsettings.cpp
r44106 r44904 81 81 gboolean enable_html5_database; 82 82 gboolean enable_html5_local_storage; 83 gboolean enable_xss_auditor; 83 84 }; 84 85 … … 114 115 PROP_ENABLE_CARET_BROWSING, 115 116 PROP_ENABLE_HTML5_DATABASE, 116 PROP_ENABLE_HTML5_LOCAL_STORAGE 117 PROP_ENABLE_HTML5_LOCAL_STORAGE, 118 PROP_ENABLE_XSS_AUDITOR 117 119 }; 118 120 … … 454 456 _("Whether to enable HTML5 Local Storage support"), 455 457 TRUE, 458 flags)); 459 /** 460 * WebKitWebSettings:enable-xss-auditor 461 * 462 * Whether to enable the XSS Auditor. This feature filters some kinds of 463 * reflective XSS attacks on vulnerable web sites. 464 * 465 * This is currently an experimental feature. 466 * 467 * Since 1.1.11 468 */ 469 g_object_class_install_property(gobject_class, 470 PROP_ENABLE_XSS_AUDITOR, 471 g_param_spec_boolean("enable-xss-auditor", 472 _("Enable XSS Auditor"), 473 _("Whether to enable teh XSS auditor"), 474 FALSE, 456 475 flags)); 457 476 … … 618 637 priv->spell_checking_languages_list = spellLanguages; 619 638 break; 639 case PROP_ENABLE_XSS_AUDITOR: 640 priv->enable_xss_auditor = g_value_get_boolean(value); 641 break; 620 642 default: 621 643 G_OBJECT_WARN_INVALID_PROPERTY_ID(object, prop_id, pspec); … … 710 732 case PROP_SPELL_CHECKING_LANGUAGES: 711 733 g_value_set_string(value, priv->spell_checking_languages); 734 break; 735 case PROP_ENABLE_XSS_AUDITOR: 736 g_value_set_boolean(value, priv->enable_xss_auditor); 712 737 break; 713 738 default: … … 769 794 "enable-html5-database", priv->enable_html5_database, 770 795 "enable-html5-local-storage", priv->enable_html5_local_storage, 796 "enable-xss-auditor", priv->enable_xss_auditor, 771 797 NULL)); 772 798 -
trunk/WebKit/gtk/webkit/webkitwebview.cpp
r44819 r44904 2050 2050 gboolean autoLoadImages, autoShrinkImages, printBackgrounds, 2051 2051 enableScripts, enablePlugins, enableDeveloperExtras, resizableTextAreas, 2052 enablePrivateBrowsing, enableCaretBrowsing, enableHTML5Database, enableHTML5LocalStorage; 2052 enablePrivateBrowsing, enableCaretBrowsing, enableHTML5Database, enableHTML5LocalStorage, 2053 enableXSSAuditor; 2053 2054 2054 2055 g_object_get(webSettings, … … 2072 2073 "enable-html5-database", &enableHTML5Database, 2073 2074 "enable-html5-local-storage", &enableHTML5LocalStorage, 2075 "enable-xss-auditor", &enableXSSAuditor, 2074 2076 NULL); 2075 2077 … … 2093 2095 settings->setDatabasesEnabled(enableHTML5Database); 2094 2096 settings->setLocalStorageEnabled(enableHTML5LocalStorage); 2097 settings->setXSSAuditorEnabled(enableXSSAuditor); 2095 2098 2096 2099 g_free(defaultEncoding); … … 2169 2172 else if (name == g_intern_string("enable-html5-local-storage")) 2170 2173 settings->setLocalStorageEnabled(g_value_get_boolean(&value)); 2174 else if (name == g_intern_string("enable-xss-auditor")) 2175 settings->setXSSAuditorEnabled(g_value_get_boolean(&value)); 2171 2176 else if (!g_object_class_find_property(G_OBJECT_GET_CLASS(webSettings), name)) 2172 2177 g_warning("Unexpected setting '%s'", name); -
trunk/WebKitTools/ChangeLog
r44888 r44904 1 2009-06-20 Jan Michael Alonzo <jmalonzo@webkit.org> 2 3 Reviewed by Gustavo Noronha and Xan Lopez. 4 5 [Gtk] Implement DRT XSS auditor support 6 https://bugs.webkit.org/show_bug.cgi?id=26571 7 8 * DumpRenderTree/gtk/DumpRenderTree.cpp: 9 (resetWebViewToConsistentStateBeforeTesting): 10 * DumpRenderTree/gtk/LayoutTestControllerGtk.cpp: 11 (LayoutTestController::setXSSAuditorEnabled): 12 1 13 2009-06-19 Darin Adler <darin@apple.com> 2 14 -
trunk/WebKitTools/DumpRenderTree/gtk/DumpRenderTree.cpp
r44647 r44904 235 235 "enable-html5-database", TRUE, 236 236 "enable-html5-local-storage", TRUE, 237 "enable-xss-auditor", TRUE, 237 238 NULL); 238 239 -
trunk/WebKitTools/DumpRenderTree/gtk/LayoutTestControllerGtk.cpp
r44846 r44904 246 246 void LayoutTestController::setXSSAuditorEnabled(bool flag) 247 247 { 248 // FIXME: implement 248 WebKitWebView* view = webkit_web_frame_get_web_view(mainFrame); 249 ASSERT(view); 250 251 WebKitWebSettings* settings = webkit_web_view_get_settings(view); 252 g_object_set(G_OBJECT(settings), "enable-xss-auditor", flag, NULL); 249 253 } 250 254
Note: See TracChangeset
for help on using the changeset viewer.