java - How to obtain "X-Forwarded-Proto" header in REST application? -
I have a REST application running on Tomcat. I am sending http requests to https using the server.xml Now, on the server side, I request that the requests be redirected to the X-Forwarded-Proto header. My code looks like this: However, it does not work. It seems that the request object only gives access to free free HTM headers. Can someone please recommend me the best way to get the header value? thank you in advanced. You need a tom to pay attention. redirectPort parameter.
@Context UriInfo uriInfo; @contact request request; Protected Response Check Security (security content sc) {string forwarded protocol} ((containeraver request)) .getHeaderValue ("X-Forward-Proto"); }
Comments
Post a Comment