A
A
Andrey2016-11-23 07:20:31
Nginx
Andrey, 2016-11-23 07:20:31

How to disable https for specific URLs?

It is necessary to disable https for url of the following types:
/mailview?.....
/msd?....
/separator?....
To make them work over http. Now there is no general gluing, it works over http and https, you need to enable https for the entire site except for 3 urls:
listen xxx.xxx.xxx.xx:443 ssl http2;
If without Strict-Transport-Security, do this:

if ($scheme = http) {
rewrite ^ https://$http_host$request_uri? permanent;
}

Is it possible somehow to slip these 3 URLs here so that this rule does not work?
I googled for an hour on the Internet, there is nothing like it anywhere, neither on stackoverflows, etc., etc.

Answer the question

In order to leave comments, you need to log in

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question