diff --git a/conf/nginx.conf b/conf/nginx.conf index 8ae597e..92f6ae2 100644 --- a/conf/nginx.conf +++ b/conf/nginx.conf @@ -3,9 +3,9 @@ location PATHTOCHANGE { if ($scheme = http) { rewrite ^ https://$server_name$request_uri? permanent; } - + index index.php; - + location ~ ^(.+\.php)(.*)$ { fastcgi_split_path_info ^(.+\.php)(.*)$; fastcgi_pass unix:/var/run/php5-fpm.sock; @@ -13,10 +13,15 @@ location PATHTOCHANGE { fastcgi_param PATH_INFO $fastcgi_path_info; fastcgi_param SCRIPT_FILENAME $request_filename; } - #rewrite ~ ^/.well-known/caldav PATHTOCHANGE/cal.php redirect; - #rewrite ~ ^/.well-known/carddav PATHTOCHANGE/card.php redirect; } +location /.well-known/carddav { + rewrite ^(.*)$ PATHTOCHANGE/card.php redirect; + } + location /.well-known/caldav { + rewrite ^(.*)$ PATHTOCHANGE/cal.php redirect; + } + location ~ ^PATHTOCHANGE/(\.ht|Core|Specific) { deny all; } diff --git a/scripts/install b/scripts/install index b5eee0c..af79cfc 100644 --- a/scripts/install +++ b/scripts/install @@ -60,3 +60,6 @@ sudo chmod 600 /etc/nginx/conf.d/$domain.d/baikal.conf sudo service nginx reload sudo yunohost app setting baikal skipped_uris -v "/" sudo yunohost app ssowatconf + +# Remove ENABLE_INSTALL for more Security +sudo rm $final_path/Specific/ENABLE_INSTALL