Skip to content

Commit 101c1bb

Browse files
error27davem330
authored andcommitted
rxrpc: fix rxkad_verify_response()
The error handling for if skb_copy_bits() fails was accidentally deleted so the rxkad_decrypt_ticket() function is not called. Fixes: 5d7edbc ("rxrpc: Get rid of the Rx ring") Signed-off-by: Dan Carpenter <[email protected]> Acked-by: David Howells <[email protected]> Signed-off-by: David S. Miller <[email protected]>
1 parent ec8cd13 commit 101c1bb

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

net/rxrpc/rxkad.c

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1165,8 +1165,10 @@ static int rxkad_verify_response(struct rxrpc_connection *conn,
11651165

11661166
eproto = tracepoint_string("rxkad_tkt_short");
11671167
abort_code = RXKADPACKETSHORT;
1168-
if (skb_copy_bits(skb, sizeof(struct rxrpc_wire_header) + sizeof(*response),
1169-
ticket, ticket_len) < 0)
1168+
ret = skb_copy_bits(skb, sizeof(struct rxrpc_wire_header) + sizeof(*response),
1169+
ticket, ticket_len);
1170+
if (ret < 0)
1171+
goto temporary_error_free_ticket;
11701172

11711173
ret = rxkad_decrypt_ticket(conn, server_key, skb, ticket, ticket_len,
11721174
&session_key, &expiry, _abort_code);

0 commit comments

Comments
 (0)