diff options
author | Christoph Stoettner <christoph.stoettner@stoeps.de> | 2020-09-29 12:15:04 +0200 |
---|---|---|
committer | Christoph Stoettner <christoph.stoettner@stoeps.de> | 2020-09-29 12:15:04 +0200 |
commit | 676571dab927b0fb9b3746c36f0d7540e8dba2b5 (patch) | |
tree | ac3b2adda982687b51e62789a62e61bab28abddd /.htaccess | |
parent | 6cdca9562c7685e9a0eb77b51584d0cc458c44e0 (diff) | |
download | Shaarli-676571dab927b0fb9b3746c36f0d7540e8dba2b5.tar.gz Shaarli-676571dab927b0fb9b3746c36f0d7540e8dba2b5.tar.zst Shaarli-676571dab927b0fb9b3746c36f0d7540e8dba2b5.zip |
Workaround for hoster (ionos)
The hoster writes the environment variable with bearer token to
REDIRECT_HTTP_AUTHORIZATION and needs to provide RewriteBase / to
.htaccess
Diffstat (limited to '.htaccess')
-rw-r--r-- | .htaccess | 4 |
1 files changed, 4 insertions, 0 deletions
@@ -10,8 +10,12 @@ RewriteRule ^(.git|doxygen|vendor) - [F] | |||
10 | # fixes JWT token not correctly forwarded on some Apache/FastCGI setups | 10 | # fixes JWT token not correctly forwarded on some Apache/FastCGI setups |
11 | RewriteCond %{HTTP:Authorization} ^(.*) | 11 | RewriteCond %{HTTP:Authorization} ^(.*) |
12 | RewriteRule .* - [e=HTTP_AUTHORIZATION:%1] | 12 | RewriteRule .* - [e=HTTP_AUTHORIZATION:%1] |
13 | # Alternative (if the 2 lines above don't work) | ||
14 | # SetEnvIf Authorization .+ HTTP_AUTHORIZATION=$0 | ||
13 | 15 | ||
14 | # REST API | 16 | # REST API |
17 | # Ionos Hosting needs RewriteBase / | ||
18 | # RewriteBase / | ||
15 | RewriteCond %{REQUEST_FILENAME} !-f | 19 | RewriteCond %{REQUEST_FILENAME} !-f |
16 | RewriteCond %{REQUEST_FILENAME} !-d | 20 | RewriteCond %{REQUEST_FILENAME} !-d |
17 | RewriteRule ^ index.php [QSA,L] | 21 | RewriteRule ^ index.php [QSA,L] |