From 309068850641cb251dd26e1a52ec9137347695a4 Mon Sep 17 00:00:00 2001 From: Davide Beatrici Date: Sun, 12 Jul 2020 03:16:02 +0200 Subject: [PATCH] Cedar/Proto.c: support secure sockets This is required for SSTP, because the connection is established through TLS/SSL. --- src/Cedar/Proto.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/Cedar/Proto.c b/src/Cedar/Proto.c index 0810ccc9..596e14a4 100644 --- a/src/Cedar/Proto.c +++ b/src/Cedar/Proto.c @@ -383,7 +383,7 @@ bool ProtoHandleConnection(PROTO *proto, SOCK *sock, const char *protocol) while (true) { - const UINT ret = Recv(sock, buf, PROTO_TCP_BUFFER_SIZE, false); + const UINT ret = Recv(sock, buf, PROTO_TCP_BUFFER_SIZE, sock->SecureMode); if (ret == SOCK_LATER) { @@ -411,7 +411,7 @@ bool ProtoHandleConnection(PROTO *proto, SOCK *sock, const char *protocol) // Send data to the TCP socket while (FifoSize(send_fifo) >= 1) { - const UINT ret = Send(sock, FifoPtr(send_fifo), FifoSize(send_fifo), false); + const UINT ret = Send(sock, FifoPtr(send_fifo), FifoSize(send_fifo), sock->SecureMode); if (ret == SOCK_LATER) {