WebView是否支持HSTS

WebView是否支持HSTS

本文介绍了[UWP] WebView是否支持HSTS?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

Web应用程序可以启用HTTP严格传输安全性(HSTS),实质上在标头中指定将来与该服务器的所有通信都必须通过https,并且客户端永远不应允许通过http进行通信。  Edge和IE都支持
HSTS。

A Web application can enable HTTP Strict Transport Security (HSTS), essentially specifying in the header that all future communication to that server must be over https, and the client should never allow communication over http.  Both Edge and IE support HSTS.

如果我在我的UWP应用程序中嵌入WebView,并将其指向启用HSTS的Web应用程序,WebView是否会尊重/强制执行此操作设置,并防止通过http进行未来的通信? 如果默认情况下没有启用,是否有某种方法可以强制执行此操作?

If I embed a WebView in my UWP app, and point it to a Web app that enables HSTS, will the WebView honor/enforce this setting, and prevent future communication via http?  If it's not enabled by default, is there some way to force this behavior?

推荐答案

目前,WebView不支持HSTS,它旨在允许Winrt应用程序开发人员在应用程序中嵌入Web的某些部分,因此有很多限制,我们不能指望WebView能够工作作为普通浏览器。您
可以将此功能请求提交给UserVoice网站:

Currently, the WebView does not support the HSTS and it is intended to allow a Winrt app developer to embed some part of the web inside the application, so there is many restriction, we can not expect the WebView to work as a normal browser. you can submit this feature request to the UserVoice website:

https://wpdev.uservoice.com/forums/110705-universal-windows-platform

祝你好运,

Breeze


这篇关于[UWP] WebView是否支持HSTS?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

07-29 21:21