[gnome-notes] editor: Enable WebKit sandboxing



commit c3dea7fb1a9b4600329022da2b3bd94a4638db38
Author: Diego Escalante Urrelo <diegoe gnome org>
Date:   Wed Jul 1 20:54:19 2020 -0500

    editor: Enable WebKit sandboxing
    
    See: https://gitlab.gnome.org/GNOME/Initiatives/-/issues/19

 meson.build                             | 2 +-
 src/libbiji/editor/biji-webkit-editor.c | 1 +
 2 files changed, 2 insertions(+), 1 deletion(-)
---
diff --git a/meson.build b/meson.build
index 7e24e3a..d31f260 100644
--- a/meson.build
+++ b/meson.build
@@ -119,7 +119,7 @@ bijiben_deps = [
   dependency('libhandy-0.0', version: '>= 0.0.10'),
   dependency('libxml-2.0'),
   dependency('uuid'),
-  dependency('webkit2gtk-4.0', version: '>= 2.10'),
+  dependency('webkit2gtk-4.0', version: '>= 2.26'),
   cc.find_library('m')
 ]
 
diff --git a/src/libbiji/editor/biji-webkit-editor.c b/src/libbiji/editor/biji-webkit-editor.c
index f16b1fa..1ffb495 100644
--- a/src/libbiji/editor/biji-webkit-editor.c
+++ b/src/libbiji/editor/biji-webkit-editor.c
@@ -93,6 +93,7 @@ biji_webkit_editor_get_web_context (void)
     webkit_web_context_set_cache_model (web_context, WEBKIT_CACHE_MODEL_DOCUMENT_VIEWER);
     webkit_web_context_set_process_model (web_context, WEBKIT_PROCESS_MODEL_SHARED_SECONDARY_PROCESS);
     webkit_web_context_set_spell_checking_enabled (web_context, TRUE);
+    webkit_web_context_set_sandbox_enabled (web_context, TRUE);
   }
 
   return web_context;


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]