aboutsummaryrefslogtreecommitdiffstats
path: root/net/sctp/associola.c
diff options
context:
space:
mode:
authorVlad Yasevich <vladislav.yasevich@hp.com>2007-10-03 20:51:34 -0400
committerDavid S. Miller <davem@sunset.davemloft.net>2007-10-10 19:51:31 -0400
commitbbd0d59809f923ea2b540cbd781b32110e249f6e (patch)
tree8a278cfa0e7bcc7b415e93baf6d1a93536efe17a /net/sctp/associola.c
parent4cd57c8078fae0a4b1bf421191e94626d0cba92a (diff)
[SCTP]: Implement the receive and verification of AUTH chunk
This patch implements the receive path needed to process authenticated chunks. Add ability to process the AUTH chunk and handle edge cases for authenticated COOKIE-ECHO as well. Signed-off-by: Vlad Yasevich <vladislav.yasevich@hp.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/sctp/associola.c')
-rw-r--r--net/sctp/associola.c10
1 files changed, 10 insertions, 0 deletions
diff --git a/net/sctp/associola.c b/net/sctp/associola.c
index 3bdd8dcb76a7..03158e3665da 100644
--- a/net/sctp/associola.c
+++ b/net/sctp/associola.c
@@ -1011,6 +1011,16 @@ static void sctp_assoc_bh_rcv(struct work_struct *work)
1011 state = asoc->state; 1011 state = asoc->state;
1012 subtype = SCTP_ST_CHUNK(chunk->chunk_hdr->type); 1012 subtype = SCTP_ST_CHUNK(chunk->chunk_hdr->type);
1013 1013
1014 /* SCTP-AUTH, Section 6.3:
1015 * The receiver has a list of chunk types which it expects
1016 * to be received only after an AUTH-chunk. This list has
1017 * been sent to the peer during the association setup. It
1018 * MUST silently discard these chunks if they are not placed
1019 * after an AUTH chunk in the packet.
1020 */
1021 if (sctp_auth_recv_cid(subtype.chunk, asoc) && !chunk->auth)
1022 continue;
1023
1014 /* Remember where the last DATA chunk came from so we 1024 /* Remember where the last DATA chunk came from so we
1015 * know where to send the SACK. 1025 * know where to send the SACK.
1016 */ 1026 */