diff options
author | Ben Laurie <ben@openssl.org> | 2005-04-26 18:02:40 +0200 |
---|---|---|
committer | Ben Laurie <ben@openssl.org> | 2005-04-26 18:02:40 +0200 |
commit | 36d16f8ee0845d932e250286e8e236580470e35b (patch) | |
tree | 3693300e55b12ff86ad08e9c5255ff7b87f88252 /ssl/s3_enc.c | |
parent | make depend. (diff) | |
download | openssl-36d16f8ee0845d932e250286e8e236580470e35b.tar.xz openssl-36d16f8ee0845d932e250286e8e236580470e35b.zip |
Add DTLS support.
Diffstat (limited to 'ssl/s3_enc.c')
-rw-r--r-- | ssl/s3_enc.c | 12 |
1 files changed, 9 insertions, 3 deletions
diff --git a/ssl/s3_enc.c b/ssl/s3_enc.c index 5d133eef14..6d92050bb1 100644 --- a/ssl/s3_enc.c +++ b/ssl/s3_enc.c @@ -569,7 +569,7 @@ int ssl3_mac(SSL *ssl, unsigned char *md, int send) const EVP_MD *hash; unsigned char *p,rec_char; unsigned int md_size; - int npad,i; + int npad; if (send) { @@ -612,13 +612,19 @@ int ssl3_mac(SSL *ssl, unsigned char *md, int send) EVP_MD_CTX_cleanup(&md_ctx); + ssl3_record_sequence_update(seq); + return(md_size); + } + +void ssl3_record_sequence_update(unsigned char *seq) + { + int i; + for (i=7; i>=0; i--) { ++seq[i]; if (seq[i] != 0) break; } - - return(md_size); } int ssl3_generate_master_secret(SSL *s, unsigned char *out, unsigned char *p, |