[epiphany/pgriffis/web-extension-beastify] WebExtensions: Grant permissions to extension's own host by default
- From: Patrick Griffis <pgriffis src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [epiphany/pgriffis/web-extension-beastify] WebExtensions: Grant permissions to extension's own host by default
- Date: Mon, 23 May 2022 01:49:29 +0000 (UTC)
commit 453381150a9cb9452e8ce215ea060c9c3bdbc277
Author: Patrick Griffis <pgriffis igalia com>
Date: Sun May 22 20:49:05 2022 -0500
WebExtensions: Grant permissions to extension's own host by default
src/webextension/ephy-web-extension.c | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
---
diff --git a/src/webextension/ephy-web-extension.c b/src/webextension/ephy-web-extension.c
index cf1c27c5d..4bf75086e 100644
--- a/src/webextension/ephy-web-extension.c
+++ b/src/webextension/ephy-web-extension.c
@@ -760,6 +760,8 @@ ephy_web_extension_init (EphyWebExtension *self)
self->permissions = g_ptr_array_new_full (1, g_free);
self->guid = g_uuid_string_random ();
+
+ g_ptr_array_add (self->permissions, g_strdup_printf ("ephy-webextension://%s/*", self->guid));
}
static EphyWebExtension *
@@ -1212,7 +1214,7 @@ static gboolean
is_supported_scheme (const char *scheme)
{
static const char * const supported_schemes[] = {
- "http", "https", "ws", "wss", "data", "file"
+ "http", "https", "ws", "wss", "data", "file", "ephy-webextension"
};
for (uint i = 0; i < G_N_ELEMENTS (supported_schemes); i++) {
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]