36 lines
1.7 KiB
Diff
36 lines
1.7 KiB
Diff
|
diff --git a/src/constants.c.orig b/src/constants.c
|
||
|
index 72ae217..b12d0ad 100644
|
||
|
--- a/src/constants.c.orig
|
||
|
+++ b/src/constants.c
|
||
|
@@ -445,7 +445,7 @@ int PyXmlSec_ConstantsModule_Init(PyObject* package) {
|
||
|
#endif
|
||
|
#if XMLSEC_VERSION_HEX > 0x10212
|
||
|
// from version 1.2.19
|
||
|
- PYXMLSEC_ADD_KEYDATA_CONSTANT(KeyDataEcdsa, "ECDSA")
|
||
|
+ PYXMLSEC_ADD_KEYDATA_CONSTANT(KeyDataEc, "ECDSA")
|
||
|
#endif
|
||
|
PYXMLSEC_ADD_KEYDATA_CONSTANT(KeyDataHmac, "HMAC")
|
||
|
PYXMLSEC_ADD_KEYDATA_CONSTANT(KeyDataRsa, "RSA")
|
||
|
diff --git a/src/keys.c.orig b/src/keys.c
|
||
|
index 1440331..8b84c34 100644
|
||
|
--- a/src/keys.c.orig
|
||
|
+++ b/src/keys.c
|
||
|
@@ -163,7 +163,7 @@ static PyObject* PyXmlSec_KeyFromFile(PyObject* self, PyObject* args, PyObject*
|
||
|
if (is_content) {
|
||
|
key->handle = xmlSecCryptoAppKeyLoadMemory((const xmlSecByte*)data, (xmlSecSize)data_size, format, password, NULL, NULL);
|
||
|
} else {
|
||
|
- key->handle = xmlSecCryptoAppKeyLoad(data, format, password, NULL, NULL);
|
||
|
+ key->handle = xmlSecCryptoAppKeyLoadEx(data, xmlSecKeyDataTypePrivate, format, password, NULL, NULL);
|
||
|
}
|
||
|
Py_END_ALLOW_THREADS;
|
||
|
|
||
|
@@ -206,7 +206,7 @@ static PyObject* PyXmlSec_KeyFromEngine(PyObject* self, PyObject* args, PyObject
|
||
|
if ((key = PyXmlSec_NewKey1((PyTypeObject*)self)) == NULL) goto ON_FAIL;
|
||
|
|
||
|
Py_BEGIN_ALLOW_THREADS;
|
||
|
- key->handle = xmlSecCryptoAppKeyLoad(engine_and_key_id, xmlSecKeyDataFormatEngine, NULL, xmlSecCryptoAppGetDefaultPwdCallback(),
|
||
|
+ key->handle = xmlSecCryptoAppKeyLoadEx(engine_and_key_id, xmlSecKeyDataTypePrivate, xmlSecKeyDataFormatEngine, NULL, xmlSecCryptoAppGetDefaultPwdCallback(),
|
||
|
(void*)engine_and_key_id);
|
||
|
Py_END_ALLOW_THREADS;
|
||
|
|