summaryrefslogtreecommitdiffstats
path: root/crypto/openssl/ssl/s23_lib.c
diff options
context:
space:
mode:
Diffstat (limited to 'crypto/openssl/ssl/s23_lib.c')
-rw-r--r--crypto/openssl/ssl/s23_lib.c40
1 files changed, 16 insertions, 24 deletions
diff --git a/crypto/openssl/ssl/s23_lib.c b/crypto/openssl/ssl/s23_lib.c
index ad2d8da..bc77e84 100644
--- a/crypto/openssl/ssl/s23_lib.c
+++ b/crypto/openssl/ssl/s23_lib.c
@@ -54,6 +54,8 @@
* derivative of this code cannot be changed. i.e. this code cannot simply be
* copied and put under another distribution licence
* [including the GNU Public Licence.]
+ *
+ * $FreeBSD$
*/
#include <stdio.h>
@@ -63,7 +65,6 @@
static int ssl23_num_ciphers(void );
static SSL_CIPHER *ssl23_get_cipher(unsigned int u);
static int ssl23_read(SSL *s, void *buf, int len);
-static int ssl23_peek(SSL *s, void *buf, int len);
static int ssl23_write(SSL *s, const void *buf, int len);
static long ssl23_default_timeout(void );
static int ssl23_put_cipher_by_char(const SSL_CIPHER *c, unsigned char *p);
@@ -78,7 +79,7 @@ static SSL_METHOD SSLv23_data= {
ssl_undefined_function,
ssl_undefined_function,
ssl23_read,
- ssl23_peek,
+ (int (*)(struct ssl_st *, char *, int))ssl_undefined_function,
ssl23_write,
ssl_undefined_function,
ssl_undefined_function,
@@ -170,6 +171,13 @@ static int ssl23_read(SSL *s, void *buf, int len)
{
int n;
+#if 0
+ if (s->shutdown & SSL_RECEIVED_SHUTDOWN)
+ {
+ s->rwstate=SSL_NOTHING;
+ return(0);
+ }
+#endif
clear_sys_error();
if (SSL_in_init(s) && (!s->in_handshake))
{
@@ -189,33 +197,17 @@ static int ssl23_read(SSL *s, void *buf, int len)
}
}
-static int ssl23_peek(SSL *s, void *buf, int len)
+static int ssl23_write(SSL *s, const void *buf, int len)
{
int n;
- clear_sys_error();
- if (SSL_in_init(s) && (!s->in_handshake))
+#if 0
+ if (s->shutdown & SSL_SENT_SHUTDOWN)
{
- n=s->handshake_func(s);
- if (n < 0) return(n);
- if (n == 0)
- {
- SSLerr(SSL_F_SSL23_PEEK,SSL_R_SSL_HANDSHAKE_FAILURE);
- return(-1);
- }
- return(SSL_peek(s,buf,len));
+ s->rwstate=SSL_NOTHING;
+ return(0);
}
- else
- {
- ssl_undefined_function(s);
- return(-1);
- }
- }
-
-static int ssl23_write(SSL *s, const void *buf, int len)
- {
- int n;
-
+#endif
clear_sys_error();
if (SSL_in_init(s) && (!s->in_handshake))
{
OpenPOWER on IntegriCloud