Welcome! Log In Create A New Profile

Advanced

Редирект на https. Глюки или я глючу?

May 02, 2011 03:16PM
Хотел организовать редирект всех запросов с http://mydomain.ru:9111 на https://mydomain.ru:9111 , в FireFox'e все супер.. редиректы работают, но в IE (8-ой версии) существуют какие-то глюки, например, при пост запросе ссылка перекидывается на http://mydomain.ru:9111 и после 1-2 нажатий обновить страницу (f5) преобразуется в нормальный вид - https://mydomain:9111 ... может дело в конфиге:
-----------------------------------------------------------------------------------------
server {
listen 9111;
keepalive_timeout 70;
#->
keepalive_requests 150;
#<-
server_name bitrix;

ssl on;
ssl_certificate /etc/nginx/ssl/cert.pem;
ssl_certificate_key /etc/nginx/ssl/cert.key;
ssl_session_cache shared:SSL:10m;
ssl_session_timeout 10m;
error_page 497 https://mydomain.ru:9111$uri;
server_name_in_redirect off;
access_log /var/log/nginx/access.log main;
index index.php;
error_page 500 502 503 504 /500.html;
error_page 404 = /404.php;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header Host $host:9111;
client_max_body_size 1024M;
client_body_buffer_size 4M;
proxy_set_header HTTPS YES;
root /home/bitrix/www;

location / { expires 3d;
if ($request_method = OPTIONS ) {
proxy_pass http://127.0.0.1:8888;
}
if ($request_method = PROPFIND ) {
proxy_pass http://127.0.0.1:8888;
}
if ($request_method = PROPPATCH ) {
proxy_pass http://127.0.0.1:8888;
}
if ($request_method = MKCOL ) {
proxy_pass http://127.0.0.1:8888;
}
if ($request_method = COPY ) {
proxy_pass http://127.0.0.1:8888;
}
if ($request_method = MOVE ) {
proxy_pass http://127.0.0.1:8888;
}
if ($request_method = LOCK ) {
proxy_pass http://127.0.0.1:8888;
}
if ($request_method = UNLOCK ) {
proxy_pass http://127.0.0.1:8888;
}
if ($request_method = PUT ) {
proxy_pass http://127.0.0.1:8888;
}
}

location ~ ^(/extranet/docs|/docs|/workgroups|/company/profile|/bitrix/tools|/company/personal/user).*/$ {
proxy_pass http://127.0.0.1:8888;
}

location ~ ^(/extranet/docs|/docs|/workgroups|/company/profile|/bitrix/tools|/company/personal/user) {
if (-d $request_filename) {
rewrite ^(.*)(/*)$ $1/ last;
}
proxy_pass http://127.0.0.1:8888;
}

location ~ ^(/bitrix/html_pages)
{
root /home/bitrix/www;
index index@.html;
if (!-f $request_filename)
{
rewrite ^/bitrix/html_pages(.*)@(.*)\.html$ $1.php?$2 break;
rewrite ^/bitrix/html_pages(.*)\.html$ $1\.php break;
proxy_pass http://127.0.0.1:8888;
}
}

location ~ \.php$ {
root /home/bitrix/www;
if ($request_method = POST ) {
break;
proxy_pass http://127.0.0.1:8888;
}
if ($http_cookie !~ "PHPSESSID=" ) {
rewrite ^(.*)\.php$ /bitrix/html_pages$1@$args.html? last;
}
proxy_pass http://127.0.0.1:8888;
}

location ~ /$ {
root /home/bitrix/www;
if ($request_method = POST ) {
break;
proxy_pass http://127.0.0.1:8888;
}
if ($http_cookie !~ "PHPSESSID=" ) {
rewrite ^(.*)/$ /bitrix/html_pages$1/index@$args.html? last;
}
proxy_pass http://127.0.0.1:8888;
}

location ~ (/|\.php|\.asmx)$ {
proxy_pass http://127.0.0.1:8888;
}
location ~ /\.ht {
deny all;
}
location ~ /favicon.ico {
proxy_pass http://127.0.0.1:8888;
}

location ~ ^(/bitrixsetup\.php)$ {
proxy_pass http://127.0.0.1:8888;
proxy_buffering off;
}

}
}
-----------------------------------------------------------------------------------------
Subject Author Posted

Редирект на https. Глюки или я глючу?

sergeyt May 02, 2011 03:16PM



Sorry, only registered users may post in this forum.

Click here to login

Online Users

Guests: 312
Record Number of Users: 8 on April 13, 2023
Record Number of Guests: 421 on December 02, 2018
Powered by nginx      Powered by FreeBSD      PHP Powered      Powered by MariaDB      ipv6 ready