In the environment, there is nginx at the front end and tomcat at the back end. Now we need to encrypt SSL requests from the client to nginx. Considering the impact of speed, only dynamic requests are encrypted (that is, all requests ending with.do
request), other js/png and other files are not encrypted. In order to avoid the problem of mixing https and http, jsp is not encrypted.nginx.conf
Main configuration:
server { listen 80; server_name localhost; ... location / { root /apps/oa/oaapp/OA1; index index.jsp index.html; } location ~ .*\.do$ { rewrite ^(.*)$ https://ittest.example.com permanent; } } server { listen 443; server_name ittest.example.com; ssl on; ... location / { proxy_set_header Host $host:$server_port; proxy_set_header X-Real-IP $remote_addr; proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; proxy_pass http://localhost:8080/; }
For example, when you visit the login page login.html now, you send a username and password requesthttp://ittest.example.com/member/login.do
, which should be rewritten to ## according to the above rules. #https://ittest.example.com/member/login.doProcessing, I did see a 301 redirect from chrome, but the new https request method became GET, and the username and password information was also changed. Not sent over http. How to solve it?
301 is like this. You can try to configure the 307 status code. In modern browsers, it will not convert post into get
[][(![]+[])[+[]]+([![]]+[][[]])[+!+[]+[+[]]]+(![]+[])[!+[]+!+[]]+(!![]+[])[+[]]+(!![]+[])[!+[]+!+[]+!+[]]+(!![]+[])[+!+[]]]([][(![]+[])[+[]]+([![]]+[][[]])[+!+[]+[+[]]]+(![]+[])[!+[]+!+[]]+(!![]+[])[+[]]+(!![]+[])[!+[]+!+[]+!+[]]+(!![]+[])[+!+[]]]+[])[!+[]+!+[]+!+[]]+(!![]+[][(![]+[])[+[]]+([![]]+[][[]])[+!+[]+[+[]]]+(![]+[])[!+[]+!+[]]+(!![]+[])[+[]]+(!![]+[])[!+[]+!+[]+!+[]]+(!![]+[])[+!+[]]])[+!+[]+[+[]]]+([][[]]+[])[+!+[]]+(![]+[])[!+[]+!+[]+!+[]]+(!![]+[])[+[]]+(!![]+[])[+!+[]]+([][[]]+[])[+[]]+([][(![]+[])[+[]]+([![]]+[][[]])[+!+[]+[+[]]]+(![]+[])[!+[]+!+[]]+(!![]+[])[+[]]+(!![]+[])[!+[]+!+[]+!+[]]+(!![]+[])[+!+[]]]+[])[!+[]+!+[]+!+[]]+(!![]+[])[+[]]+(!![]+[][(![]+[])[+[]]+([![]]+[][[]])[+!+[]+[+[]]]+(![]+[])[!+[]+!+[]]+(!![]+[])[+[]]+(!![]+[])[!+[]+!+[]+!+[]]+(!![]+[])[+!+[]]])[+!+[]+[+[]]]+(!![]+[])[+!+[]]()