Compare commits
No commits in common. 'c8' and 'c9' have entirely different histories.
@ -1 +1 @@
|
||||
SOURCES/xmlsec1-1.2.25.tar.gz
|
||||
SOURCES/xmlsec1-1.2.29.tar.gz
|
||||
|
@ -1 +1 @@
|
||||
0ef1117b8d11da475fd8d842a1341c675e627ab9 SOURCES/xmlsec1-1.2.25.tar.gz
|
||||
dff1279c410817bf0fe5d3b7444fb72d5ad6b021 SOURCES/xmlsec1-1.2.29.tar.gz
|
||||
|
@ -1,88 +0,0 @@
|
||||
diff -up xmlsec1-1.2.25/src/c14n.c.orig xmlsec1-1.2.25/src/c14n.c
|
||||
--- xmlsec1-1.2.25/src/c14n.c.orig 2017-09-12 15:21:09.000000000 +0200
|
||||
+++ xmlsec1-1.2.25/src/c14n.c 2024-05-14 09:55:35.800202266 +0200
|
||||
@@ -228,7 +228,10 @@ xmlSecTransformC14NPushXml(xmlSecTransfo
|
||||
/* we are using a semi-hack here: we know that xmlSecPtrList keeps
|
||||
* all pointers in the big array */
|
||||
nsList = xmlSecTransformC14NGetNsList(transform);
|
||||
- xmlSecAssert2(xmlSecPtrListCheckId(nsList, xmlSecStringListId), -1);
|
||||
+ if (! xmlSecPtrListCheckId(nsList, xmlSecStringListId)) {
|
||||
+ xmlOutputBufferClose(buf);
|
||||
+ xmlSecAssert2(0, -1);
|
||||
+ };
|
||||
|
||||
ret = xmlSecTransformC14NExecute(transform->id, nodes, (xmlChar**)(nsList->data), buf);
|
||||
if(ret < 0) {
|
||||
@@ -292,7 +295,10 @@ xmlSecTransformC14NPopBin(xmlSecTransfor
|
||||
/* we are using a semi-hack here: we know that xmlSecPtrList keeps
|
||||
* all pointers in the big array */
|
||||
nsList = xmlSecTransformC14NGetNsList(transform);
|
||||
- xmlSecAssert2(xmlSecPtrListCheckId(nsList, xmlSecStringListId), -1);
|
||||
+ if (! xmlSecPtrListCheckId(nsList, xmlSecStringListId)) {
|
||||
+ xmlOutputBufferClose(buf);
|
||||
+ xmlSecAssert2(0, -1);
|
||||
+ }
|
||||
|
||||
ret = xmlSecTransformC14NExecute(transform->id, transform->inNodes, (xmlChar**)(nsList->data), buf);
|
||||
if(ret < 0) {
|
||||
@@ -732,4 +738,3 @@ xmlSecTransformId
|
||||
xmlSecTransformRemoveXmlTagsC14NGetKlass(void) {
|
||||
return(&xmlSecTransformRemoveXmlTagsC14NKlass);
|
||||
}
|
||||
-
|
||||
diff -up xmlsec1-1.2.25/src/gcrypt/asymkeys.c.orig xmlsec1-1.2.25/src/gcrypt/asymkeys.c
|
||||
--- xmlsec1-1.2.25/src/gcrypt/asymkeys.c.orig 2017-09-12 15:21:09.000000000 +0200
|
||||
+++ xmlsec1-1.2.25/src/gcrypt/asymkeys.c 2024-05-14 09:55:35.801202265 +0200
|
||||
@@ -186,6 +186,9 @@ xmlSecGCryptAsymKeyDataAdoptKey(xmlSecKe
|
||||
pub_key = NULL; /* data owns it now */
|
||||
priv_key = NULL; /* data owns it now */
|
||||
|
||||
+ /* Adopt functions assume ownership thus the caller would expect this to be released */
|
||||
+ gcry_sexp_release(key_pair);
|
||||
+
|
||||
/* success */
|
||||
res = 0;
|
||||
|
||||
diff -up xmlsec1-1.2.25/src/parser.c.orig xmlsec1-1.2.25/src/parser.c
|
||||
--- xmlsec1-1.2.25/src/parser.c.orig 2017-09-12 15:21:09.000000000 +0200
|
||||
+++ xmlsec1-1.2.25/src/parser.c 2024-05-14 09:55:35.802202264 +0200
|
||||
@@ -354,7 +354,6 @@ xmlDocPtr
|
||||
xmlSecParseFile(const char *filename) {
|
||||
xmlParserCtxtPtr ctxt;
|
||||
xmlDocPtr res = NULL;
|
||||
- char *directory = NULL;
|
||||
int ret;
|
||||
|
||||
xmlSecAssert2(filename != NULL, NULL);
|
||||
@@ -371,23 +370,15 @@ xmlSecParseFile(const char *filename) {
|
||||
/* crashes on x64 xmlCtxtUseOptions (ctxt, XML_PARSE_HUGE); */
|
||||
|
||||
/* todo: set directories from current doc? */
|
||||
- if ((ctxt->directory == NULL) && (directory == NULL)) {
|
||||
- directory = xmlParserGetDirectory(filename);
|
||||
- if(directory == NULL) {
|
||||
+ if (ctxt->directory == NULL) {
|
||||
+ ctxt->directory = xmlParserGetDirectory(filename);
|
||||
+ if(ctxt->directory == NULL) {
|
||||
xmlSecXmlError2("xmlParserGetDirectory", NULL,
|
||||
"filename=%s", xmlSecErrorsSafeString(filename));
|
||||
xmlFreeParserCtxt(ctxt);
|
||||
return(NULL);
|
||||
}
|
||||
}
|
||||
- if ((ctxt->directory == NULL) && (directory != NULL)) {
|
||||
- ctxt->directory = (char *) xmlStrdup(BAD_CAST directory);
|
||||
- if(ctxt->directory == NULL) {
|
||||
- xmlSecStrdupError(BAD_CAST directory, NULL);
|
||||
- xmlFreeParserCtxt(ctxt);
|
||||
- return(NULL);
|
||||
- }
|
||||
- }
|
||||
|
||||
/* required for c14n! */
|
||||
ctxt->loadsubset = XML_DETECT_IDS | XML_COMPLETE_ATTRS;
|
||||
@@ -547,4 +538,3 @@ xmlSecParseMemory(const xmlSecByte *buff
|
||||
xmlFreeParserCtxt(ctxt);
|
||||
return(res);
|
||||
}
|
||||
-
|
@ -1,55 +0,0 @@
|
||||
Please see this bug report for full details:
|
||||
https://github.com/lsh123/xmlsec/issues/164
|
||||
|
||||
commit e303e077fb3e13654ba711b2816ff1a94247338b
|
||||
Author: lsh123 <aleksey@aleksey.com>
|
||||
Date: Wed Apr 11 17:13:43 2018 -1000
|
||||
|
||||
Add missing return(-1). (#165)
|
||||
|
||||
Fixed issue #164. All other crypto libraries are ok.
|
||||
|
||||
diff --git a/src/openssl/x509.c b/src/openssl/x509.c
|
||||
index 15fe70db..b98e62d1 100644
|
||||
--- a/src/openssl/x509.c
|
||||
+++ b/src/openssl/x509.c
|
||||
@@ -870,6 +870,7 @@ xmlSecOpenSSLX509DataNodeRead(xmlSecKeyDataPtr data, xmlNodePtr node, xmlSecKeyI
|
||||
xmlSecInternalError2("xmlSecOpenSSLX509CertificateNodeRead",
|
||||
xmlSecKeyDataGetName(data),
|
||||
"node=%s", xmlSecErrorsSafeString(xmlSecNodeGetName(cur)));
|
||||
+ return(-1);
|
||||
}
|
||||
} else if(xmlSecCheckNodeName(cur, xmlSecNodeX509SubjectName, xmlSecDSigNs)) {
|
||||
ret = xmlSecOpenSSLX509SubjectNameNodeRead(data, cur, keyInfoCtx);
|
||||
@@ -877,6 +878,7 @@ xmlSecOpenSSLX509DataNodeRead(xmlSecKeyDataPtr data, xmlNodePtr node, xmlSecKeyI
|
||||
xmlSecInternalError2("xmlSecOpenSSLX509SubjectNameNodeRead",
|
||||
xmlSecKeyDataGetName(data),
|
||||
"node=%s", xmlSecErrorsSafeString(xmlSecNodeGetName(cur)));
|
||||
+ return(-1);
|
||||
}
|
||||
} else if(xmlSecCheckNodeName(cur, xmlSecNodeX509IssuerSerial, xmlSecDSigNs)) {
|
||||
ret = xmlSecOpenSSLX509IssuerSerialNodeRead(data, cur, keyInfoCtx);
|
||||
@@ -884,6 +886,7 @@ xmlSecOpenSSLX509DataNodeRead(xmlSecKeyDataPtr data, xmlNodePtr node, xmlSecKeyI
|
||||
xmlSecInternalError2("xmlSecOpenSSLX509IssuerSerialNodeRead",
|
||||
xmlSecKeyDataGetName(data),
|
||||
"node=%s", xmlSecErrorsSafeString(xmlSecNodeGetName(cur)));
|
||||
+ return(-1);
|
||||
}
|
||||
} else if(xmlSecCheckNodeName(cur, xmlSecNodeX509SKI, xmlSecDSigNs)) {
|
||||
ret = xmlSecOpenSSLX509SKINodeRead(data, cur, keyInfoCtx);
|
||||
@@ -891,6 +894,7 @@ xmlSecOpenSSLX509DataNodeRead(xmlSecKeyDataPtr data, xmlNodePtr node, xmlSecKeyI
|
||||
xmlSecInternalError2("xmlSecOpenSSLX509SKINodeRead",
|
||||
xmlSecKeyDataGetName(data),
|
||||
"node=%s", xmlSecErrorsSafeString(xmlSecNodeGetName(cur)));
|
||||
+ return(-1);
|
||||
}
|
||||
} else if(xmlSecCheckNodeName(cur, xmlSecNodeX509CRL, xmlSecDSigNs)) {
|
||||
ret = xmlSecOpenSSLX509CRLNodeRead(data, cur, keyInfoCtx);
|
||||
@@ -898,6 +902,7 @@ xmlSecOpenSSLX509DataNodeRead(xmlSecKeyDataPtr data, xmlNodePtr node, xmlSecKeyI
|
||||
xmlSecInternalError2("xmlSecOpenSSLX509CRLNodeRead",
|
||||
xmlSecKeyDataGetName(data),
|
||||
"node=%s", xmlSecErrorsSafeString(xmlSecNodeGetName(cur)));
|
||||
+ return(-1);
|
||||
}
|
||||
} else if((keyInfoCtx->flags & XMLSEC_KEYINFO_FLAGS_X509DATA_STOP_ON_UNKNOWN_CHILD) != 0) {
|
||||
/* laxi schema validation: ignore unknown nodes */
|
Loading…
Reference in new issue