X-Git-Url: https://git.openssl.org/?p=openssl.git;a=blobdiff_plain;f=ssl%2Fssl2.h;h=b04a794f13ad78a5f2b60060897ccf225c44a4ee;hp=3dc94e520bb057963d9d3b21b7825a4430995e4f;hb=566bdf2bda44f2414ffc20f0540d703f3280749c;hpb=78414a6a897db42c9bcf06aa21c705811ab33921 diff --git a/ssl/ssl2.h b/ssl/ssl2.h index 3dc94e520b..b04a794f13 100644 --- a/ssl/ssl2.h +++ b/ssl/ssl2.h @@ -67,8 +67,8 @@ extern "C" { #define SSL2_VERSION 0x0002 #define SSL2_VERSION_MAJOR 0x00 #define SSL2_VERSION_MINOR 0x02 -#define SSL2_CLIENT_VERSION 0x0002 -#define SSL2_SERVER_VERSION 0x0002 +/* #define SSL2_CLIENT_VERSION 0x0002 */ +/* #define SSL2_SERVER_VERSION 0x0002 */ /* Protocol Message Codes */ #define SSL2_MT_ERROR 0 @@ -133,8 +133,12 @@ extern "C" { /* Upper/Lower Bounds */ #define SSL2_MAX_MASTER_KEY_LENGTH_IN_BITS 256 -#define SSL2_MAX_RECORD_LENGTH_2_BYTE_HEADER (unsigned int)32767 -#define SSL2_MAX_RECORD_LENGTH_3_BYTE_HEADER 16383 /**/ +#ifdef OPENSSL_SYS_MPE +#define SSL2_MAX_RECORD_LENGTH_2_BYTE_HEADER 29998u +#else +#define SSL2_MAX_RECORD_LENGTH_2_BYTE_HEADER 32767u /* 2^15-1 */ +#endif +#define SSL2_MAX_RECORD_LENGTH_3_BYTE_HEADER 16383 /* 2^14-1 */ #define SSL2_CHALLENGE_LENGTH 16 /*#define SSL2_CHALLENGE_LENGTH 32 */ @@ -151,7 +155,7 @@ extern "C" { #define CERT char #endif -typedef struct ssl2_ctx_st +typedef struct ssl2_state_st { int three_byte_header; int clear_text; /* clear text */ @@ -162,7 +166,7 @@ typedef struct ssl2_ctx_st * args were passwd */ unsigned int wnum; /* number of bytes sent so far */ int wpend_tot; - char *wpend_buf; + const unsigned char *wpend_buf; int wpend_off; /* offset to data to write */ int wpend_len; /* number of bytes passwd to write */ @@ -214,7 +218,7 @@ typedef struct ssl2_ctx_st unsigned int clen; unsigned int rlen; } tmp; - } SSL2_CTX; + } SSL2_STATE; /* SSLv2 */ /* client */