Config option for SSL protocols (resolves #720)

ZNC currently disables SSLv2 and SSLv3 by default. To keep the ZNC
defaults (recommended, may change in the future versions) and for
example disable TLSv1 in addition, specify in the global config
section:

    SSLProtocols = -TLSv1

Available (case-insentive) values are:

    All, SSLv2, SSLv3, TLSv1, TLSv1.1, TLSv1.2

A non-prefixed "absolute" value overrides the ZNC defaults:

    SSLProtocols = TLSV1 +TLSv1.1 +TLSv1.2
This commit is contained in:
J-P Nurmi
2014-11-06 20:39:00 +01:00
parent 54e8b62b87
commit b759c68847
3 changed files with 50 additions and 2 deletions
+3
View File
@@ -128,6 +128,7 @@ public:
unsigned int GetConnectDelay() const { return m_uiConnectDelay; }
bool GetProtectWebSessions() const { return m_bProtectWebSessions; }
CString GetSSLCiphers() const { return m_sSSLCiphers; }
Csock::EDisableProtocol GetDisabledSSLProtocols() const { return static_cast<Csock::EDisableProtocol>(m_uDisabledSSLProtocols); }
// !Getters
// Static allocator
@@ -211,6 +212,7 @@ protected:
CString m_sPidFile;
CString m_sSSLCertFile;
CString m_sSSLCiphers;
CString m_sSSLProtocols;
VCString m_vsBindHosts;
VCString m_vsTrustedProxies;
VCString m_vsMotd;
@@ -218,6 +220,7 @@ protected:
unsigned int m_uiConnectDelay;
unsigned int m_uiAnonIPLimit;
unsigned int m_uiMaxBufferSize;
unsigned int m_uDisabledSSLProtocols;
CModules* m_pModules;
unsigned long long m_uBytesRead;
unsigned long long m_uBytesWritten;