diff options
author | Dominik Picheta <dominikpicheta@googlemail.com> | 2015-09-24 01:16:57 +0100 |
---|---|---|
committer | Dominik Picheta <dominikpicheta@googlemail.com> | 2015-09-24 01:16:57 +0100 |
commit | d92f2526092d9ca088f83168c9bf4459ed0b9e35 (patch) | |
tree | baafeae93139f429368fecc335e5c8cdd1e9e691 /lib/pure | |
parent | 10a4bb6f4e52256f66dcffce472e808354ddad88 (diff) | |
parent | 8edbef346a0d24e91110084e663674f2c65d72b7 (diff) | |
download | Nim-d92f2526092d9ca088f83168c9bf4459ed0b9e35.tar.gz |
Merge pull request #3364 from tmm1/osx-ssl-compile
Avoid referencing undefined SSLv2_method on MacOSX
Diffstat (limited to 'lib/pure')
-rw-r--r-- | lib/pure/net.nim | 5 | ||||
-rw-r--r-- | lib/pure/sockets.nim | 5 |
2 files changed, 2 insertions, 8 deletions
diff --git a/lib/pure/net.nim b/lib/pure/net.nim index 0ce5b4d25..00a6c0c92 100644 --- a/lib/pure/net.nim +++ b/lib/pure/net.nim @@ -223,10 +223,7 @@ when defined(ssl): of protSSLv23: newCTX = SSL_CTX_new(SSLv23_method()) # SSlv2,3 and TLS1 support. of protSSLv2: - when not defined(linux): - newCTX = SSL_CTX_new(SSLv2_method()) - else: - raiseSslError() + raiseSslError("SSLv2 is no longer secure and has been deprecated, use protSSLv3") of protSSLv3: newCTX = SSL_CTX_new(SSLv3_method()) of protTLSv1: diff --git a/lib/pure/sockets.nim b/lib/pure/sockets.nim index 29f0bf87d..8fa69256b 100644 --- a/lib/pure/sockets.nim +++ b/lib/pure/sockets.nim @@ -314,10 +314,7 @@ when defined(ssl): of protSSLv23: newCTX = SSL_CTX_new(SSLv23_method()) # SSlv2,3 and TLS1 support. of protSSLv2: - when not defined(linux) and not defined(OpenBSD): - newCTX = SSL_CTX_new(SSLv2_method()) - else: - raiseSslError() + raiseSslError("SSLv2 is no longer secure and has been deprecated, use protSSLv3") of protSSLv3: newCTX = SSL_CTX_new(SSLv3_method()) of protTLSv1: |