Chrome 和 Vivaldi 的 id 不同?
id is different for Chrome and Vivaldi?
在 Vivaldi 浏览器上安装我的扩展后,我发现 id(来源)与 Chrome 不同。这是预期的行为吗?
我的manifest.json
:
{
"manifest_version": 2,
"default_locale": "en",
"short_name": "Intelligent Speaker",
"name": "Text to speech that brings productivity",
"description": "__MSG_appDesc__",
"homepage_url": "https://intelligent-speaker.com",
"content_security_policy": "default-src 'self'; img-src *; media-src https://intelligent-speaker.com https://intelligentspeaker.s3.amazonaws.com blob:; connect-src https://intelligentspeaker.auth.us-east-1.amazoncognito.com https://intelligent-speaker.com/voice-preview/ https://mjqj47yt17.execute-api.us-east-1.amazonaws.com https://api.intelligent-speaker.com https://intelligentspeaker.s3.amazonaws.com; style-src https://fonts.googleapis.com; font-src https://fonts.gstatic.com/;",
"permissions": [
"storage",
"activeTab",
"contextMenus"
],
"offline_enabled": true,
"version": "2018.10.12.1214",
"browser_action": {
"default_icon": {
"128": "images/logo/logo128.png"
},
"default_popup": "popup.html"
},
"icons": {
"128": "images/logo/logo128.png"
},
"background": {
"page": "eventPage.html",
"persistent": false
},
"author": "Intelligent Speaker",
"incognito": "not_allowed",
"container": "GOOGLE_DRIVE",
"minimum_chrome_version": "60"
}
您的插件加载为具有临时 ID 的插件。这意味着浏览器可以决定插件 ID,因为您没有指定一个。这就是为什么您最终会得到不同的临时插件 ID(为了安全起见,它应该是随机的。)
在 Firefox 中,您可以像这样指定插件 ID:
"applications": {
"gecko": {
"id": "addonid@domain.org"
}
}
但是,内部 ID 仍可用于来源 headers 和文件 URL。不用担心,这是为了安全。
在 Vivaldi 浏览器上安装我的扩展后,我发现 id(来源)与 Chrome 不同。这是预期的行为吗?
我的manifest.json
:
{
"manifest_version": 2,
"default_locale": "en",
"short_name": "Intelligent Speaker",
"name": "Text to speech that brings productivity",
"description": "__MSG_appDesc__",
"homepage_url": "https://intelligent-speaker.com",
"content_security_policy": "default-src 'self'; img-src *; media-src https://intelligent-speaker.com https://intelligentspeaker.s3.amazonaws.com blob:; connect-src https://intelligentspeaker.auth.us-east-1.amazoncognito.com https://intelligent-speaker.com/voice-preview/ https://mjqj47yt17.execute-api.us-east-1.amazonaws.com https://api.intelligent-speaker.com https://intelligentspeaker.s3.amazonaws.com; style-src https://fonts.googleapis.com; font-src https://fonts.gstatic.com/;",
"permissions": [
"storage",
"activeTab",
"contextMenus"
],
"offline_enabled": true,
"version": "2018.10.12.1214",
"browser_action": {
"default_icon": {
"128": "images/logo/logo128.png"
},
"default_popup": "popup.html"
},
"icons": {
"128": "images/logo/logo128.png"
},
"background": {
"page": "eventPage.html",
"persistent": false
},
"author": "Intelligent Speaker",
"incognito": "not_allowed",
"container": "GOOGLE_DRIVE",
"minimum_chrome_version": "60"
}
您的插件加载为具有临时 ID 的插件。这意味着浏览器可以决定插件 ID,因为您没有指定一个。这就是为什么您最终会得到不同的临时插件 ID(为了安全起见,它应该是随机的。)
在 Firefox 中,您可以像这样指定插件 ID:
"applications": {
"gecko": {
"id": "addonid@domain.org"
}
}
但是,内部 ID 仍可用于来源 headers 和文件 URL。不用担心,这是为了安全。