请求已被阻止;内容必须通过HTTPS提供 [英] request has been blocked; the content must be served over HTTPS
本文介绍了请求已被阻止;内容必须通过HTTPS提供的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我正在使用Spring Security和Spring MVC在后端,而Angular在前端进行应用程序.
我的问题是我可以正确登录,但是注销的问题是我在本地主机上正确实现的: http://localhost:8080
可以正常工作.当我将其更改为 https://
时,出现此错误:
混合内容:位于"的页面已通过HTTPS加载,但请求了不安全的XMLHttpRequest端点".该请求已被阻止;内容必须通过HTTPS提供.
我想知道如何纠正它?以及如何知道浏览器中的https阻止了哪个网址,例如chrome?
解决方案
此帖子为您的问题提供了解决方案: 解决方案
This post which gives a solution to your problem: http://www.learningthegoodstuff.com/2015/08/mixed-http-error-with-spring-security.html
All the details are explained there, basically all you have to do is add this two lines to my application.properties file:
server.tomcat.remote_ip_header=x-forwarded-for
server.tomcat.protocol_header=x-forwarded-proto
这篇关于请求已被阻止;内容必须通过HTTPS提供的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文