From f122de3970a44a1510778d5eb3680043d0fe54fa Mon Sep 17 00:00:00 2001 From: yflory Date: Mon, 20 Jul 2026 12:02:27 +0200 Subject: [PATCH 1/5] perf(eviction): use Set to list channels and blobs faster --- lib/storage/blob.js | 4 +++- lib/storage/file.js | 3 ++- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/lib/storage/blob.js b/lib/storage/blob.js index 3fda70217..5b952bb52 100644 --- a/lib/storage/blob.js +++ b/lib/storage/blob.js @@ -658,6 +658,8 @@ var listBlobs = function (root, handler, fast, cb) { var nestedDirPath = Path.join(root, dir); Fs.readdir(nestedDirPath, w(function (err, list) { if (err) { return void handler(err); } // Is this correct? + + const s = new Set(list); list.forEach(function (item) { // ignore hidden files if (/^\./.test(item)) { return; } @@ -671,7 +673,7 @@ var listBlobs = function (root, handler, fast, cb) { if (!/^[0-9a-fA-F]{48}$/.test(item)) { blobName = item.replace(/\.metadata\.ndjson/, ''); // check if blob already exists - if (list.indexOf(blobName) !== -1) { return; } + if (s.has(blobName)) { return; } // otherwise set a flag indicating that we should // handle the metadata on its own isLonelyMetadata = true; diff --git a/lib/storage/file.js b/lib/storage/file.js index 6485536c1..9ab2daa59 100644 --- a/lib/storage/file.js +++ b/lib/storage/file.js @@ -680,6 +680,7 @@ var listChannels = function (root, handler, cb, fast) { Fs.readdir(nestedDirPath, w(function (err, list) { if (err) { return void handler(err); } // Is this correct? + const s = new Set(list); list.forEach(function (item) { // ignore hidden files if (/^\./.test(item)) { return; } @@ -698,7 +699,7 @@ var listChannels = function (root, handler, cb, fast) { // if there is a corresponding channel present in the list, // then we should stop here and handle everything when we get to the channel - if (list.indexOf(channelName) !== -1) { return; } + if (s.has(channelName)) { return; } // otherwise set a flag indicating that we should // handle the metadata on its own isLonelyMetadata = true; From 4e51c4071324ea3e9e7d05b1d6a835bb51b8b5f2 Mon Sep 17 00:00:00 2001 From: Fabrice Mouhartem Date: Tue, 21 Jul 2026 10:34:22 +0200 Subject: [PATCH 2/5] docs(security): add new security policy --- SECURITY.md | 2 ++ 1 file changed, 2 insertions(+) diff --git a/SECURITY.md b/SECURITY.md index c596e676c..da46b14dc 100644 --- a/SECURITY.md +++ b/SECURITY.md @@ -6,6 +6,8 @@ SPDX-License-Identifier: AGPL-3.0-or-later # Security Policy +CryptPad security policy is detailed on the following document: https://cryptpad.org/security/ + ## Supported Versions Considering the amount of resources necessary to backport security or bug fixes to previous, unsupported CryptPad versions, it's not something we do. From 6b7f069aa3406cca51a71aa55b61dcb79292c280 Mon Sep 17 00:00:00 2001 From: Fabrice Mouhartem Date: Tue, 21 Jul 2026 10:34:43 +0200 Subject: [PATCH 3/5] fix(security policy): add link to RSS feed for releases --- SECURITY.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/SECURITY.md b/SECURITY.md index da46b14dc..ac7512a56 100644 --- a/SECURITY.md +++ b/SECURITY.md @@ -15,7 +15,7 @@ However, we quickly release new minor versions in case of need. Please keep up with the latest release published here: https://github.com/cryptpad/cryptpad/releases -Note that every GitHub release page has an RSS compatible feed that you can subscribe on to be informed of every new release. +Note that every GitHub release page has an [RSS compatible feed](https://github.com/cryptpad/cryptpad/releases.atom) that you can subscribe on to be informed of every new release. We do also communicate about this topic on: - [Our blog](https://blog.cryptpad.org) From 302314d301ea6f2b523537bb5135f6f39284cac8 Mon Sep 17 00:00:00 2001 From: Fabrice Mouhartem Date: Tue, 21 Jul 2026 11:36:52 +0200 Subject: [PATCH 4/5] docs(typo): missing period --- SECURITY.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/SECURITY.md b/SECURITY.md index ac7512a56..0d7fe68f9 100644 --- a/SECURITY.md +++ b/SECURITY.md @@ -6,7 +6,7 @@ SPDX-License-Identifier: AGPL-3.0-or-later # Security Policy -CryptPad security policy is detailed on the following document: https://cryptpad.org/security/ +CryptPad security policy is detailed on the following document: https://cryptpad.org/security/. ## Supported Versions From f8766443550659554b751ddbb44f7c93f7d07de6 Mon Sep 17 00:00:00 2001 From: Fabrice Mouhartem Date: Fri, 31 Jul 2026 10:58:56 +0200 Subject: [PATCH 5/5] docs(security): typo --- SECURITY.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/SECURITY.md b/SECURITY.md index 0d7fe68f9..7283fe0e2 100644 --- a/SECURITY.md +++ b/SECURITY.md @@ -6,7 +6,7 @@ SPDX-License-Identifier: AGPL-3.0-or-later # Security Policy -CryptPad security policy is detailed on the following document: https://cryptpad.org/security/. +CryptPad security policy is detailed in the following document: https://cryptpad.org/security/. ## Supported Versions