Skip to content
This repository was archived by the owner on Jul 21, 2025. It is now read-only.

Commit acc0d14

Browse files
committed
Fix elliptic curve setup
as per matrix-org/synapse#3157
1 parent 844d3d6 commit acc0d14

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

sydent/http/httpclient.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -84,8 +84,8 @@ class FederationPolicyForHTTPS(object):
8484
def creatorForNetloc(self, hostname, port):
8585
context = SSL.Context(SSL.SSLv23_METHOD)
8686
try:
87-
_ecCurve = _OpenSSLECCurve(_defaultCurveName)
88-
_ecCurve.addECKeyToContext(context)
87+
_ecCurve = crypto.get_elliptic_curve(_defaultCurveName)
88+
context.set_tmp_ecdh(_ecCurve)
8989
except Exception:
9090
logger.exception("Failed to enable elliptic curve for TLS")
9191
context.set_options(SSL.OP_NO_SSLv2 | SSL.OP_NO_SSLv3)

0 commit comments

Comments
 (0)