Issue #11746: Fix SSLContext.load_cert_chain() to accept elliptic curve private keys.
This commit is contained in:
parent
361467e522
commit
9c25486093
|
@ -49,6 +49,9 @@ Core and Builtins
|
||||||
Library
|
Library
|
||||||
-------
|
-------
|
||||||
|
|
||||||
|
- Issue #11746: Fix SSLContext.load_cert_chain() to accept elliptic curve
|
||||||
|
private keys.
|
||||||
|
|
||||||
- sys.getfilesystemencoding() raises a RuntimeError if initfsencoding() was not
|
- sys.getfilesystemencoding() raises a RuntimeError if initfsencoding() was not
|
||||||
called yet: detect bootstrap (startup) issues earlier.
|
called yet: detect bootstrap (startup) issues earlier.
|
||||||
|
|
||||||
|
|
|
@ -1623,7 +1623,7 @@ load_cert_chain(PySSLContext *self, PyObject *args, PyObject *kwds)
|
||||||
goto error;
|
goto error;
|
||||||
}
|
}
|
||||||
PySSL_BEGIN_ALLOW_THREADS
|
PySSL_BEGIN_ALLOW_THREADS
|
||||||
r = SSL_CTX_use_RSAPrivateKey_file(self->ctx,
|
r = SSL_CTX_use_PrivateKey_file(self->ctx,
|
||||||
PyBytes_AS_STRING(keyfile ? keyfile_bytes : certfile_bytes),
|
PyBytes_AS_STRING(keyfile ? keyfile_bytes : certfile_bytes),
|
||||||
SSL_FILETYPE_PEM);
|
SSL_FILETYPE_PEM);
|
||||||
PySSL_END_ALLOW_THREADS
|
PySSL_END_ALLOW_THREADS
|
||||||
|
|
Loading…
Reference in New Issue