Welcome! Log In Create A New Profile

Advanced

ssl trouble

Posted by flo 
flo
ssl trouble
October 08, 2010 03:24PM
hello, i run latest nginx

[code]

nginx -V
nginx version: nginx/0.8.52
built by gcc 4.4.5 (Debian 4.4.5-2)
TLS SNI support enabled
configure arguments: --conf-path=/etc/nginx/nginx.conf --error-log-path=/var/log/nginx/error.log --http-client-body-temp-path=/var/lib/nginx/body --http-fastcgi-temp-path=/var/lib/nginx/fastcgi --http-log-path=/var/log/nginx/access.log --http-proxy-temp-path=/var/lib/nginx/proxy --lock-path=/var/lock/nginx.lock --pid-path=/var/run/nginx.pid --with-http_dav_module --with-http_flv_module --with-http_geoip_module --with-http_gzip_static_module --with-http_realip_module --with-http_stub_status_module --with-http_ssl_module --with-http_sub_module --with-ipv6 --with-mail --with-mail_ssl_module --with-sha1=/usr/lib
[/code]

I have setup a ssl certificat for a virtualhost, it work, but i have some trouble with "dokuwiki"

here is my configuration for my dokuwiki:

[code]
server {
listen 80;
server_name example.org;
root /home/user/www/example.org;
location / {
if ($host ~* ^(example\.org|www\.example\.org)$ ) {
rewrite ^/(.*)$ https://example.org/$1 permanent;
}
return 444;
}
}

server {
listen 443;
server_name example.org;
root /home/user/www/example.org;
index css index.php index.html index.htm;
if ($host ~* ^(www\.example\.org)$ ) {
rewrite ^/(.*)$ https://example.org/$1 permanent;
}
...
[/code]

First i don't want http (and www), i rewrite with a 301 redirect, but dokuwiki for logging or writing ,when i submit he switch:

https://example.org/... to http://example.org:443/...

the problem is nginx don't like this, and paste an error 400.
If you can help me ? :)
Re: ssl trouble
November 12, 2010 03:04PM
Maybe try turning port_in_redirect off?
Sorry, only registered users may post in this forum.

Click here to login

Online Users

Guests: 81
Record Number of Users: 6 on February 13, 2018
Record Number of Guests: 421 on December 02, 2018
Powered by nginx      Powered by FreeBSD      PHP Powered      Powered by MariaDB      ipv6 ready