在HTTPS请求中,Request.IsSecureConnection返回false [英] In HTTPS request , Request.IsSecureConnection return false

查看:720
本文介绍了在HTTPS请求中,Request.IsSecureConnection返回false的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一个使用https(SSL)的asp.net应用程序。这在我的本地计算机和Amazon AWS(生产环境)中运行良好。

I have an asp.net application working in https (SSL). This is working well in my local computer and Amazon AWS(production environment).

但是当我在办公室托管这个应用程序(用于测试)时,会发生一些奇怪的事情。

But when I host this application in office (for testing) some strange things happens.


  1. 我可以在浏览器中看到 https 和锁定标志。

Fiddler还显示输出已加密并显示端口443。

Fiddler also showing that the output is encrypted and shows port 443.

但是 HttpContext。 Current.Request.IsSecureConnection 返回 false

HttpContext.Current。 Request.Url.Scheme 返回 http

In我们正在使用Juniper SSG防火墙和TMG 2010(Forefront Threat Management Gateway 2010)的办公室。因此服务器通过Juniper和TMG 2010接收请求。提前感谢。

In the office we are using Juniper SSG firewall and TMG 2010 (Forefront Threat Management Gateway 2010). So server receive request through Juniper and TMG 2010. Thanks in advance.

推荐答案

为了降低成本,我怀疑在TMG网关上安装了SSL证书,并且该网关只是将请求重写为将标准HTTP传递给实际的Web服务器时的标准HTTP。因此,当请求到达IIS和您的Web应用程序时,它是标准的纯HTTP请求。

To reduce costs I suspect that the SSL certificate is installed on the TMG Gateway and that this gateway is simply rewriting the request to standard HTTP when passing it to the actual web server. So by the time the request hits IIS and your web application it is a standard plain HTTP request.

这篇关于在HTTPS请求中,Request.IsSecureConnection返回false的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆