static int
dtls_new_record_layer(OSSL_LIB_CTX *libctx, const char *propq, int vers,
- int role, int direction, int level, unsigned int epoch,
+ int role, int direction, int level, uint16_t epoch,
unsigned char *key, size_t keylen, unsigned char *iv,
size_t ivlen, unsigned char *mackey, size_t mackeylen,
const EVP_CIPHER *ciph, size_t taglen,
static int
ktls_new_record_layer(OSSL_LIB_CTX *libctx, const char *propq, int vers,
- int role, int direction, int level, unsigned int epoch,
+ int role, int direction, int level, uint16_t epoch,
unsigned char *key, size_t keylen, unsigned char *iv,
size_t ivlen, unsigned char *mackey, size_t mackeylen,
const EVP_CIPHER *ciph, size_t taglen,
int direction;
int level;
/* DTLS only */
- unsigned int epoch;
+ uint16_t epoch;
/*
* A BIO containing any data read in the previous epoch that was destined
*data = rec->data + rec->off;
*datalen = rec->length;
if (rl->isdtls) {
- *epoch = (uint16_t)rec->epoch;
+ *epoch = rec->epoch;
memcpy(seq_num, rec->seq_num, sizeof(rec->seq_num));
}
static int
tls_new_record_layer(OSSL_LIB_CTX *libctx, const char *propq, int vers,
- int role, int direction, int level, unsigned int epoch,
+ int role, int direction, int level, uint16_t epoch,
unsigned char *key, size_t keylen, unsigned char *iv,
size_t ivlen, unsigned char *mackey, size_t mackeylen,
const EVP_CIPHER *ciph, size_t taglen,
unsigned char *comp;
/* epoch number, needed by DTLS1 */
/* r */
- unsigned long epoch;
+ uint16_t epoch;
/* sequence number, needed by DTLS1 */
/* r */
unsigned char seq_num[SEQ_NUM_SIZE];
} DTLS1_BITMAP;
typedef struct record_pqueue_st {
- unsigned short epoch;
+ uint16_t epoch;
struct pqueue_st *q;
} record_pqueue;
* undefined, and starts at zero once the initial handshake is
* completed
*/
- unsigned short r_epoch;
- unsigned short w_epoch;
+ uint16_t r_epoch;
+ uint16_t w_epoch;
/*
* Buffered application records. Only for records between CCS and
const char *propq, int vers,
int role, int direction,
int level,
- unsigned int epoch,
+ uint16_t epoch,
unsigned char *key,
size_t keylen,
unsigned char *iv,
EVP_MD_CTX *write_hash; /* used for mac generation */
COMP_CTX *compress; /* compression */
SSL_SESSION *session;
- unsigned short epoch;
+ uint16_t epoch;
};
struct hm_header_st {
typedef struct mempacket_test_ctx_st {
STACK_OF(MEMPACKET) *pkts;
- unsigned int epoch;
+ uint16_t epoch;
unsigned int currrec;
unsigned int currpkt;
unsigned int lastpkt;