From bbcd77c95bcbc866e4482d29735ac8373f2494ec Mon Sep 17 00:00:00 2001 From: sim Date: Mon, 30 Dec 2024 13:28:14 +0000 Subject: [PATCH 1/2] Add webpush headers, fake encryption for now --- lib/PushTransports/WebPushTransport.php | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/lib/PushTransports/WebPushTransport.php b/lib/PushTransports/WebPushTransport.php index 644447f..0eb8989 100644 --- a/lib/PushTransports/WebPushTransport.php +++ b/lib/PushTransports/WebPushTransport.php @@ -93,6 +93,10 @@ public function notify(string $userId, string $collectionName, int $subscription 'http' => [ 'method' => 'POST', 'content' => $content, + 'header' => [ + 'TTL: 86400', + 'Content-Encoding: aes128gcm', + ], ], ]; From 402e868cad714e70c41722c59637ef0d2f0b67f9 Mon Sep 17 00:00:00 2001 From: sim Date: Thu, 2 Jan 2025 18:06:12 +0000 Subject: [PATCH 2/2] Hint about unencrypted push notifications --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index d2adef9..18e0108 100644 --- a/README.md +++ b/README.md @@ -15,7 +15,7 @@ Watch the video (YouTube): It is the server part of our efforts to draft a WebDAV-Push standard and provide a working implementation (server + client) in order to demonstrate it. > [!WARNING] -> This extension is in an early stage of development. It is for demonstration and testing purposes only. Don't use it on production systems! +> This extension is in an early stage of development. It is for demonstration and testing purposes only. It also marks unencrypted data as encrypted. Don't use it on production systems! For instance, push subscriptions currently don't expire and won't be removed when they have become invalid. So the table will grow bigger and bigger and everything will become slow over time. You can however install/enable the extension to test it and disable or remove it again at any time. When the extension is disabled, it doesn't influence your system.