f5a8d01d38
The problem in the new code was that previously xmlSecNssInit() didn't require an already initialized NSS, but 1.3.3 did. Backport upstream fix that restores the old behavior that NSS init is not needed, which allows no longer reverting the xmlSecNssUpdateAvailableCryptoTransforms() call that upstream added recently. Change-Id: Ie33ccbff0149e3c406d5574e889d90da4fdbbfb5 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/162292 Reviewed-by: Miklos Vajna <vmiklos@collabora.com> Tested-by: Jenkins
33 lines
999 B
Groff
33 lines
999 B
Groff
From 356fdcfaf6e126835ac3bd7f410a3fa4d4a6877b Mon Sep 17 00:00:00 2001
|
|
From: lsh123 <aleksey@aleksey.com>
|
|
Date: Sat, 13 Jan 2024 18:07:49 -0500
|
|
Subject: [PATCH] (xmlsec-nss) Ensure NSS algorithms are initialized (#754)
|
|
|
|
---
|
|
src/nss/crypto.c | 8 ++++++++
|
|
1 file changed, 8 insertions(+)
|
|
|
|
diff --git a/src/nss/crypto.c b/src/nss/crypto.c
|
|
index 6455ec72..7ba0c77a 100644
|
|
--- a/src/nss/crypto.c
|
|
+++ b/src/nss/crypto.c
|
|
@@ -361,8 +361,16 @@ xmlSecCryptoGetFunctions_nss(void) {
|
|
|
|
static void
|
|
xmlSecNssUpdateAvailableCryptoTransforms(xmlSecCryptoDLFunctionsPtr functions) {
|
|
+ SECStatus rv;
|
|
xmlSecAssert(functions != NULL);
|
|
|
|
+ /* in theory NSS should be already initialized but just in case */
|
|
+ rv = SECOID_Init();
|
|
+ if (rv != SECSuccess) {
|
|
+ xmlSecNssError("SECOID_Init", NULL);
|
|
+ return;
|
|
+ }
|
|
+
|
|
/******************************* AES ********************************/
|
|
/* cbc */
|
|
if (xmlSecNssCryptoCheckAlgorithm(SEC_OID_AES_128_CBC) == 0) {
|
|
--
|
|
2.35.3
|
|
|