When processing an incoming ABORT, SHUTDOWN_COMPLETE or ERROR (NAT related)

chunk, take always the T-bit into account, when checking the verification
tag.

MFC after: 3 days
This commit is contained in:
Michael Tuexen 2013-07-04 19:47:46 +00:00
parent 2fc5db16ed
commit 5db47b3def
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=252718

View File

@ -4568,8 +4568,10 @@ __attribute__((noinline))
if ((ch->chunk_type == SCTP_ABORT_ASSOCIATION) ||
(ch->chunk_type == SCTP_SHUTDOWN_COMPLETE) ||
(ch->chunk_type == SCTP_PACKET_DROPPED)) {
if ((vtag_in == asoc->my_vtag) ||
((ch->chunk_flags & SCTP_HAD_NO_TCB) &&
/* Take the T-bit always into account. */
if ((((ch->chunk_flags & SCTP_HAD_NO_TCB) == 0) &&
(vtag_in == asoc->my_vtag)) ||
(((ch->chunk_flags & SCTP_HAD_NO_TCB) == SCTP_HAD_NO_TCB) &&
(vtag_in == asoc->peer_vtag))) {
/* this is valid */
} else {