Skip to content

Commit

Permalink
try to fix issue #122 about missing tls 1.2 support
Browse files Browse the repository at this point in the history
use SSLv23 (leading to call of SSLv23_client_method at openssl) instead of TLS (leading to call of TLSv1_client_method at openssl)
  • Loading branch information
chcg committed Mar 3, 2017
1 parent f54d2e5 commit 108ae83
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions UTCP/src/ftp_c.cpp
Expand Up @@ -184,7 +184,7 @@ int CUT_FTPClient::FTPConnect(LPCSTR hostname,LPCSTR userName,LPCSTR password,LP
m_cachedResponse = false;

if (m_sMode != FTP) {
if (m_sMode == FTPS) { //in case of implicit SSL, negatiate security version with v23
if (m_sMode == FTPS) { //in case of implicit SSL, negotiate security version with v23
SetSecurityMode(CUT_FTPClient::SSLv23);
m_wsData.SetSecurityMode(CUT_FTPClient::SSLv23);
} else {
Expand Down Expand Up @@ -3297,8 +3297,9 @@ int CUT_FTPClient::SocketOnConnected(SOCKET s, const char *lpszName){
}
else
{
SetSecurityMode(CUT_WSClient::TLS);
m_wsData.SetSecurityMode(CUT_WSClient::TLS);
//SSLv23 is the default starting with TLS 1.2 -> SSLV3
SetSecurityMode(CUT_WSClient::SSLv23);
m_wsData.SetSecurityMode(CUT_WSClient::SSLv23);
rt = ConnectSSL();
}

Expand Down

0 comments on commit 108ae83

Please sign in to comment.