如果我从 HTTP URL 向 HTTPS URL 提交表单,表单数据会加密吗?
我即将加密我网站的登录表单,我想知道登录的用户是否需要通过 HTTPS URL 登陆登录表单,或者表单数据是否可以从 HTTP url 发布到 HTTPS url 并且仍然可以加密的?
I'm about to encrypt my website's login form and I was wondering if the user logging in needs to land on the login form at a HTTPS URL, or whether the form data can be posted to a HTTPS url from a HTTP url and still be encrypted?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
是的,登录数据已加密,但用户没有明显的方法可以知道这一点。它还让用户对 人持开放态度中间攻击,因为攻击者可以简单地更改表单发布的位置。
对于真正需要安全性的网站,强烈建议您在任何登录页面上都需要 https。
Yes, the login data is encrypted, but there is no obvious way for the user to know this. It also leaves users open to a man-in-the-middle attack because an attacker could simply change where the form posts to.
For a site that really needs security, it is highly recommend that you require https on any login page.
是的,它将被加密。提交表单的页面的 URL 并不重要,重要的是表单目标 URL。
不过,需要注意的一件事是,某些浏览器(至少 IE 6)会在从不安全页面提交安全表单时向用户发出警告。为什么这需要警告以及用户应该对此做什么,我不知道,但它可能会让人们感到困惑(如果他们费心阅读警告)。
Yes, it will be encrypted. The URL of the page from which the form is submitted doesn't matter, only the form target URL.
One thing to note, though, is that some browsers (IE 6, at least) will warn the user when submitting a secure form from an insecure page. Why that requires a warning and what the user is supposed to do about it, I have no idea, but it can confuse people (if they bother to read the warning).