aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGravatar Sadie Powell2025-10-23 11:54:05 +0100
committerGravatar Sadie Powell2025-10-23 11:54:38 +0100
commit8e6bd270ca5ab04d1cd952f2d9d3b5ca90d78fab (patch)
tree30c179e42ab97adf21e809ea4430e399761c792a
parentSet the groups on the client context as well as the server one. (diff)
Set the security level on the client context as well as the server one.
-rw-r--r--src/modules/extra/m_ssl_openssl.cpp7
1 files changed, 5 insertions, 2 deletions
diff --git a/src/modules/extra/m_ssl_openssl.cpp b/src/modules/extra/m_ssl_openssl.cpp
index 9d0591778..36dac31c4 100644
--- a/src/modules/extra/m_ssl_openssl.cpp
+++ b/src/modules/extra/m_ssl_openssl.cpp
@@ -442,9 +442,12 @@ namespace OpenSSL
SetContextOptions("server", tag, ctx);
SetContextOptions("client", tag, clientctx);
- const auto securitylevel = tag->getNum<int>("securitylevel", 0, 0, 10);
- if (securitylevel)
+ const auto securitylevel = tag->getNum<int>("securitylevel", -1, -1, 10);
+ if (securitylevel >= 0)
+ {
ctx.SetSecurityLevel(securitylevel);
+ clientctx.SetSecurityLevel(securitylevel);
+ }
/* Load our keys and certificates
* NOTE: OpenSSL's error logging API sucks, don't blame us for this clusterfuck.