2013-03-20 61 views
0

我最近在Google App Engine Java App上安装了GoDaddy证书。 一切正常,HTTPS链接在直接访问时正在工作。Google App Engine - 不会将HTTP流量重定向到HTTPS

当我试图配置所有需要在Web.xml中保护的链接时,我遇到了重定向问题。出于某种原因,GAE承认链接应该是安全的,但它无法将它们重定向到HTTPS(因为它应该)。

我用下面的定义在web.xml中:

<security-constraint> 
    <display-name>SecurityConstraint</display-name> 
     <web-resource-collection>    
     <url-pattern>/Login.html</url-pattern> 
     <url-pattern>/Register.html</url-pattern> 
     <url-pattern>/Billing.html</url-pattern> 
     <url-pattern>/PurchaseCredit.html</url-pattern> 
     <url-pattern>/PastPurchases.html</url-pattern>            
     </web-resource-collection> 
     <user-data-constraint> 
     <transport-guarantee>CONFIDENTIAL</transport-guarantee> 
     </user-data-constraint> 
    </security-constraint> 

例子:当我试图达到

 http://MyDomain/Login.html 

我得到:HTTP错误403(禁止):服务器拒绝履行请求。

相反的:

 https://MyDomain/Login.html 

回答

4

看来,当我关掉谷歌的的PageSpeed问题得到解决。

我刚才读,谷歌发布有关的PageSpeed和HTTPS

https://developers.google.com/speed/docs/pss/faq

看来,整合这两个,你必须给他们发邮件进行进一步说明特别通知。

无论哪种方式,我很高兴我发现了这一点,并希望它能为您节省很多时间。