diff options
| author | jsing <> | 2014-10-22 15:29:31 +0000 | 
|---|---|---|
| committer | jsing <> | 2014-10-22 15:29:31 +0000 | 
| commit | 45f1b926dda92890b8db01ae7fd609215dadc365 (patch) | |
| tree | da946aaf9f31b1dc29c2b8cb33c8e544f761c500 | |
| parent | b1f3b316c6b24b0d08fe8ea1964bb106cd07a732 (diff) | |
| download | openbsd-45f1b926dda92890b8db01ae7fd609215dadc365.tar.gz openbsd-45f1b926dda92890b8db01ae7fd609215dadc365.tar.bz2 openbsd-45f1b926dda92890b8db01ae7fd609215dadc365.zip | |
Avoid a NULL pointer dereference that can be triggered by
SSL3_RT_HANDSHAKE replays.
Reported by Markus Stenberg <markus.stenberg at iki.fi> - thanks!
ok deraadt@
Diffstat (limited to '')
| -rw-r--r-- | src/lib/libssl/d1_pkt.c | 4 | ||||
| -rw-r--r-- | src/lib/libssl/src/ssl/d1_pkt.c | 4 | 
2 files changed, 4 insertions, 4 deletions
| diff --git a/src/lib/libssl/d1_pkt.c b/src/lib/libssl/d1_pkt.c index 6f3ee26217..7aa5aac752 100644 --- a/src/lib/libssl/d1_pkt.c +++ b/src/lib/libssl/d1_pkt.c | |||
| @@ -1,4 +1,4 @@ | |||
| 1 | /* $OpenBSD: d1_pkt.c,v 1.35 2014/10/18 16:13:16 jsing Exp $ */ | 1 | /* $OpenBSD: d1_pkt.c,v 1.36 2014/10/22 15:29:31 jsing Exp $ */ | 
| 2 | /* | 2 | /* | 
| 3 | * DTLS implementation written by Nagendra Modadugu | 3 | * DTLS implementation written by Nagendra Modadugu | 
| 4 | * (nagendra@cs.stanford.edu) for the OpenSSL project 2005. | 4 | * (nagendra@cs.stanford.edu) for the OpenSSL project 2005. | 
| @@ -586,7 +586,7 @@ again: | |||
| 586 | * would be dropped unnecessarily. | 586 | * would be dropped unnecessarily. | 
| 587 | */ | 587 | */ | 
| 588 | if (!(s->d1->listen && rr->type == SSL3_RT_HANDSHAKE && | 588 | if (!(s->d1->listen && rr->type == SSL3_RT_HANDSHAKE && | 
| 589 | *p == SSL3_MT_CLIENT_HELLO) && | 589 | p != NULL && *p == SSL3_MT_CLIENT_HELLO) && | 
| 590 | !dtls1_record_replay_check(s, bitmap)) { | 590 | !dtls1_record_replay_check(s, bitmap)) { | 
| 591 | rr->length = 0; | 591 | rr->length = 0; | 
| 592 | s->packet_length=0; /* dump this record */ | 592 | s->packet_length=0; /* dump this record */ | 
| diff --git a/src/lib/libssl/src/ssl/d1_pkt.c b/src/lib/libssl/src/ssl/d1_pkt.c index 6f3ee26217..7aa5aac752 100644 --- a/src/lib/libssl/src/ssl/d1_pkt.c +++ b/src/lib/libssl/src/ssl/d1_pkt.c | |||
| @@ -1,4 +1,4 @@ | |||
| 1 | /* $OpenBSD: d1_pkt.c,v 1.35 2014/10/18 16:13:16 jsing Exp $ */ | 1 | /* $OpenBSD: d1_pkt.c,v 1.36 2014/10/22 15:29:31 jsing Exp $ */ | 
| 2 | /* | 2 | /* | 
| 3 | * DTLS implementation written by Nagendra Modadugu | 3 | * DTLS implementation written by Nagendra Modadugu | 
| 4 | * (nagendra@cs.stanford.edu) for the OpenSSL project 2005. | 4 | * (nagendra@cs.stanford.edu) for the OpenSSL project 2005. | 
| @@ -586,7 +586,7 @@ again: | |||
| 586 | * would be dropped unnecessarily. | 586 | * would be dropped unnecessarily. | 
| 587 | */ | 587 | */ | 
| 588 | if (!(s->d1->listen && rr->type == SSL3_RT_HANDSHAKE && | 588 | if (!(s->d1->listen && rr->type == SSL3_RT_HANDSHAKE && | 
| 589 | *p == SSL3_MT_CLIENT_HELLO) && | 589 | p != NULL && *p == SSL3_MT_CLIENT_HELLO) && | 
| 590 | !dtls1_record_replay_check(s, bitmap)) { | 590 | !dtls1_record_replay_check(s, bitmap)) { | 
| 591 | rr->length = 0; | 591 | rr->length = 0; | 
| 592 | s->packet_length=0; /* dump this record */ | 592 | s->packet_length=0; /* dump this record */ | 
