Lines Matching refs:auth
67 packet->auth = NULL;
214 /* Try to bundle an auth chunk into the packet. */
220 struct sctp_chunk *auth;
226 /* See if this is an auth chunk we are bundling or if
227 * auth is already bundled.
235 if (!chunk->auth)
238 auth = sctp_make_auth(asoc, chunk->shkey->key_id);
239 if (!auth)
242 auth->shkey = chunk->shkey;
243 sctp_auth_shkey_hold(auth->shkey);
245 retval = __sctp_packet_append_chunk(pkt, auth);
248 sctp_chunk_free(auth);
342 packet->auth = chunk;
410 struct sctp_auth_chunk *auth = NULL;
433 if (chunk == packet->auth)
466 if (chunk == packet->auth)
467 auth = (struct sctp_auth_chunk *)
482 if (!sctp_chunk_is_data(chunk) && chunk != packet->auth)
489 if (auth) {
490 sctp_auth_calculate_hmac(tp->asoc, nskb, auth,
491 packet->auth->shkey, gfp);
492 /* free auth if no more chunks, or add it back */
494 sctp_chunk_free(packet->auth);
496 list_add(&packet->auth->list,
764 /* Don't bundle in this packet if this chunk's auth key doesn't
766 * don't bundle the chunk with auth key if other chunks in this
767 * packet don't have auth key.
769 if ((packet->auth && chunk->shkey != packet->auth->shkey) ||
770 (!packet->auth && chunk->shkey &&
790 (!packet->has_data && chunk->auth)) {
805 if (packet->auth)
806 maxsize -= SCTP_PAD4(packet->auth->skb->len);