From 13f592239781e7eec09e390edaf19e02c4b453ae Mon Sep 17 00:00:00 2001 From: Nicolas Lepage <19571875+nlepage@users.noreply.github.com> Date: Thu, 31 Jul 2025 14:08:40 +0200 Subject: [PATCH 1/3] fix: attach paste listener on message field paste listener prevents default behavior in unexpected cases such as pasting a password in the passworddecrypt field attaching the paste listener on the message field instead of the whole document should fix this problem --- js/privatebin.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/js/privatebin.js b/js/privatebin.js index e61b0924..a5bfc578 100644 --- a/js/privatebin.js +++ b/js/privatebin.js @@ -3382,7 +3382,7 @@ jQuery.PrivateBin = (function($) { * @function */ function addClipboardEventHandler() { - $(document).on('paste', function (event) { + $('#message').on('paste', function (event) { const items = (event.clipboardData || event.originalEvent.clipboardData).items; const files = [...items] .filter(item => item.kind === 'file') From 79dc03660b5b6109c057e23d063027077db90383 Mon Sep 17 00:00:00 2001 From: Nicolas Lepage <19571875+nlepage@users.noreply.github.com> Date: Thu, 31 Jul 2025 16:19:42 +0200 Subject: [PATCH 2/3] chore: updates SRI hash for privatebin.js --- lib/Configuration.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/Configuration.php b/lib/Configuration.php index 4e421273..a131f75a 100644 --- a/lib/Configuration.php +++ b/lib/Configuration.php @@ -116,7 +116,7 @@ class Configuration 'js/kjua-0.10.0.js' => 'sha512-BYj4xggowR7QD150VLSTRlzH62YPfhpIM+b/1EUEr7RQpdWAGKulxWnOvjFx1FUlba4m6ihpNYuQab51H6XlYg==', 'js/legacy.js' => 'sha512-08+subq1Lo+r+la5ENqeXiMgNJcVaaTtBIFGkrjziSpvtgCId3Jtin4/OkSdHYSoeztwwIab8uvCzPKHta6puQ==', 'js/prettify.js' => 'sha512-puO0Ogy++IoA2Pb9IjSxV1n4+kQkKXYAEUtVzfZpQepyDPyXk8hokiYDS7ybMogYlyyEIwMLpZqVhCkARQWLMg==', - 'js/privatebin.js' => 'sha512-ytZMcsBxoon+uFaTyES2QBm0oN445Fu1iE4txInHaME1wpo3NUu02gxOvjrZhCimM59wTLgSMhm60BxE/DIm3w==', + 'js/privatebin.js' => 'sha512-5ngU5T+BRPoN2XEZLA2Fk5vYqOM/16muI5iSxp/7WVDitpAF/wvoU3XnqFG/O62UkntQzmvHqlLmXuCifzBtmw==', 'js/purify-3.2.6.js' => 'sha512-zqwL4OoBLFx89QPewkz4Lz5CSA2ktU+f31fuECkF0iK3Id5qd3Zpq5dMby8KwHjIEpsUgOqwF58cnmcaNem0EA==', 'js/showdown-2.1.0.js' => 'sha512-WYXZgkTR0u/Y9SVIA4nTTOih0kXMEd8RRV6MLFdL6YU8ymhR528NLlYQt1nlJQbYz4EW+ZsS0fx1awhiQJme1Q==', 'js/zlib-1.3.1-1.js' => 'sha512-5bU9IIP4PgBrOKLZvGWJD4kgfQrkTz8Z3Iqeu058mbQzW3mCumOU6M3UVbVZU9rrVoVwaW4cZK8U8h5xjF88eQ==', From 8e3f59a49c7e4f6b3de9b369fefbdfc1beaa6a01 Mon Sep 17 00:00:00 2001 From: Nicolas Lepage <19571875+nlepage@users.noreply.github.com> Date: Thu, 31 Jul 2025 16:31:37 +0200 Subject: [PATCH 3/3] chroe: adds bugfix in CHANGELOG.md --- CHANGELOG.md | 1 + 1 file changed, 1 insertion(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 3bfaf1d8..7bb3b93c 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,6 +2,7 @@ ## 2.0.1 (not yet released) * CHANGED: CSP recommendation around bootstrap5 template resolved in Firefox 131 (#1613) +* FIXED: Allow pasting a password for decrypting a paste (#1620) ## 2.0.0 (2025-07-28) * ADDED: Error logging in database and filesystem backend (#1554)