From 401210d259be88918ea880aa32fde9e81fbe8bb2 Mon Sep 17 00:00:00 2001 From: Clement Wong Date: Sun, 10 May 2020 11:06:56 +0200 Subject: Proxy server could cache http response when it is not private Signed-off-by: Clement Wong --- lib/public/AppFramework/Http/Response.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'lib') diff --git a/lib/public/AppFramework/Http/Response.php b/lib/public/AppFramework/Http/Response.php index a48580c789d..27a2fd3a008 100644 --- a/lib/public/AppFramework/Http/Response.php +++ b/lib/public/AppFramework/Http/Response.php @@ -107,10 +107,10 @@ class Response { */ public function cacheFor(int $cacheSeconds) { if ($cacheSeconds > 0) { - $this->addHeader('Cache-Control', 'max-age=' . $cacheSeconds . ', must-revalidate'); + $this->addHeader('Cache-Control', 'private, max-age=' . $cacheSeconds . ', must-revalidate'); // Old scool prama caching - $this->addHeader('Pragma', 'public'); + $this->addHeader('Pragma', 'private'); // Set expires header $expires = new \DateTime(); -- cgit v1.2.3