Web 应用管理设置
支持的版本
- 自 120 或更高版本起在 Windows 和 macOS 上
描述
此策略允许管理员为已安装的 Web 应用指定设置。 此策略将 Web 应用 ID 映射到其特定设置。 可以使用特殊 ID *设置默认配置,该 ID 适用于此策略中没有自定义配置的所有 Web 应用。
- manifest_id字段是 Web 应用的清单 ID。 有关如何确定已安装 Web 应用的清单 ID 的说明,请参阅 https://developer.chrome.com/blog/pwa-manifest-id/ 。
- run_on_os_login字段指定是否可以在 OS 登录期间运行 Web 应用。 如果此字段设置为“阻止”,则 Web 应用在 OS 登录期间不会运行,并且用户以后将无法启用此功能。 如果此字段设置为 run_windowed,则 Web 应用将在 OS 登录期间运行,用户以后将无法禁用此字段。 如果此字段设置为“允许”,则用户将能够将 Web 应用配置为在 OS 登录时运行。 默认策略配置仅允许允许和阻止的值。
- (从 Microsoft Edge 版本 120) prevent_close_after_run_on_os_login 字段指定是否可以以任何方式阻止 Web 应用关闭。 例如,按用户、任务管理器或 Web API。 仅当run_on_os_login设置为run_windowed时,才能启用此行为。 如果应用已在运行,则此设置仅在重启应用后生效。 如果未定义此字段,用户可以关闭应用。 (Microsoft Edge.) 目前不支持此功能
- (自版本 118) force_unregister_os_integration 字段指定是否将删除 Web 应用的所有 OS 集成,即快捷方式、文件处理程序、协议处理程序等。 如果应用已在运行,则此属性将在应用重启后生效。 应谨慎使用,因为它可以覆盖在启动 Web 应用程序系统期间自动设置的任何 OS 集成。 目前仅适用于 Windows、Mac 和 Linux 平台。
支持的功能
- 可以强制:是
- 可以推荐:否
- 动态策略刷新:是
- 按配置文件:是
- 适用于使用Microsoft帐户登录的配置文件:否
数据类型
- Dictionary
Windows 信息和设置
组策略 (ADMX) 信息
- GP 唯一名称:WebAppSettings
- GP 名称:Web 应用管理设置
- GP 路径 (强制) :管理模板/Microsoft Edge
- GP 路径(推荐):不适用
- GP ADMX 文件名:MSEdge.admx
示例值
[{"manifest_id": "https://foo.example/index.html", "run_on_os_login": "allowed"}, {"manifest_id": "https://bar.example/index.html", "run_on_os_login": "allowed"}, {"manifest_id": "https://foobar.example/index.html", "prevent_close_after_run_on_os_login": true, "run_on_os_login": "run_windowed"}, {"manifest_id": "*", "run_on_os_login": "blocked"}, {"force_unregister_os_integration": true, "manifest_id": "https://foo.example/index.html"}]
注册表设置
- 路径(强制):SOFTWARE\Policies\Microsoft\Edge
- 路径(推荐):不适用
- 值名称:WebAppSettings
- 值类型:REG_SZ
示例注册表值
[{"manifest_id": "https://foo.example/index.html", "run_on_os_login": "allowed"}, {"manifest_id": "https://bar.example/index.html", "run_on_os_login": "allowed"}, {"manifest_id": "https://foobar.example/index.html", "prevent_close_after_run_on_os_login": true, "run_on_os_login": "run_windowed"}, {"manifest_id": "*", "run_on_os_login": "blocked"}, {"force_unregister_os_integration": true, "manifest_id": "https://foo.example/index.html"}]
扩展的示例注册表值
[
{
"manifest_id": "https://foo.example/index.html",
"run_on_os_login": "allowed"
},
{
"manifest_id": "https://bar.example/index.html",
"run_on_os_login": "allowed"
},
{
"manifest_id": "https://foobar.example/index.html",
"prevent_close_after_run_on_os_login": true,
"run_on_os_login": "run_windowed"
},
{
"manifest_id": "*",
"run_on_os_login": "blocked"
},
{
"force_unregister_os_integration": true,
"manifest_id": "https://foo.example/index.html"
}
]
Mac 信息和设置
- 首选项项名称:WebAppSettings
- 示例值:
<key>WebAppSettings</key>
<array>
<dict>
<key>manifest_id</key>
<string>https://foo.example/index.html</string>
<key>run_on_os_login</key>
<string>allowed</string>
</dict>
<dict>
<key>manifest_id</key>
<string>https://bar.example/index.html</string>
<key>run_on_os_login</key>
<string>allowed</string>
</dict>
<dict>
<key>manifest_id</key>
<string>https://foobar.example/index.html</string>
<key>prevent_close_after_run_on_os_login</key>
<true/>
<key>run_on_os_login</key>
<string>run_windowed</string>
</dict>
<dict>
<key>manifest_id</key>
<string>*</string>
<key>run_on_os_login</key>
<string>blocked</string>
</dict>
<dict>
<key>force_unregister_os_integration</key>
<true/>
<key>manifest_id</key>
<string>https://foo.example/index.html</string>
</dict>
</array>