diff options
author | awr1 <41453959+awr1@users.noreply.github.com> | 2018-09-04 16:33:52 -0500 |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-09-04 16:33:52 -0500 |
commit | eb668003bf35671d7358e5f54e05820c0f4aef3d (patch) | |
tree | e5c5d6315f8ba4a5dd647bf67a4d0afb609916e7 /examples/ssl/pskclient.nim | |
parent | 89ad1cc9b18db8320e5b170ee45888cf79d52001 (diff) | |
parent | 4aba2981dd47672744191bd17b39bb149f494637 (diff) | |
download | Nim-eb668003bf35671d7358e5f54e05820c0f4aef3d.tar.gz |
Merge branch 'devel' into experimentalize-reorder
Diffstat (limited to 'examples/ssl/pskclient.nim')
-rw-r--r-- | examples/ssl/pskclient.nim | 16 |
1 files changed, 0 insertions, 16 deletions
diff --git a/examples/ssl/pskclient.nim b/examples/ssl/pskclient.nim deleted file mode 100644 index c83f27fbc..000000000 --- a/examples/ssl/pskclient.nim +++ /dev/null @@ -1,16 +0,0 @@ -# Create connection encrypted using preshared key (TLS-PSK). -import net - -static: assert defined(ssl) - -let sock = newSocket() -sock.connect("localhost", Port(8800)) - -proc clientFunc(identityHint: string): tuple[identity: string, psk: string] = - echo "identity hint ", identityHint.repr - return ("foo", "psk-of-foo") - -let context = newContext(cipherList="PSK-AES256-CBC-SHA") -context.clientGetPskFunc = clientFunc -context.wrapConnectedSocket(sock, handshakeAsClient) -context.destroyContext() |