解决alitomcat中无法获得https协议的问题
事件:
客户反馈,为什么配置https请求,使用request.getScheme()、request.getServerPort(),后台获取访问协议和端口的时候还是获取的http和80。。
用户架构: CDN+SLB+EDAS应用
其中
CDN使用443端口回源
SLB配置安全证书使用HTTPS公网IP访问
EDAS使用Alitomcat,server.xml配置
< Valve className="org.apache.catalina.valves.RemoteIpValve"
remoteIpHeader="x-forwarded-for"
remoteIpProxiesHeader="x-forwarded-by"
protocolHeader="x-forwarded-proto"/&g