diff options
author | Lukas Reschke <lukas@statuscode.ch> | 2013-02-14 19:23:29 +0100 |
---|---|---|
committer | Lukas Reschke <lukas@statuscode.ch> | 2013-02-14 19:23:29 +0100 |
commit | be194c5b5bef563ea38e85f784e6e9a3e8f181e1 (patch) | |
tree | 779794fb4d3dfdadb08e6ecaa298f6f230157476 /lib/base.php | |
parent | f4c9d4c06797a5c9e2f30d20a8e13686e98dd7f9 (diff) | |
download | nextcloud-server-be194c5b5bef563ea38e85f784e6e9a3e8f181e1.tar.gz nextcloud-server-be194c5b5bef563ea38e85f784e6e9a3e8f181e1.zip |
Invalidate existing HSTS headers
Diffstat (limited to 'lib/base.php')
-rw-r--r-- | lib/base.php | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/lib/base.php b/lib/base.php index fd9a1d41121..ff95a87e438 100644 --- a/lib/base.php +++ b/lib/base.php @@ -231,6 +231,11 @@ class OC { header("Location: $url"); exit(); } + } else { + // Invalidate HSTS headers + if (OC_Request::serverProtocol() === 'https') { + header('Strict-Transport-Security: max-age=0'); + } } } |