[PATCH net] rxrpc: Fix unhandled errors in rxgk_verify_packet_integrity()
Simon Horman
horms at kernel.org
Fri Sep 12 12:05:17 PDT 2025
On Thu, Sep 11, 2025 at 11:58:16PM +0100, David Howells wrote:
>
> rxgk_verify_packet_integrity() may get more errors than just -EPROTO from
> rxgk_verify_mic_skb(). Pretty much anything other than -ENOMEM constitutes
> an unrecoverable error. In the case of -ENOMEM, we can just drop the
> packet and wait for a retransmission.
>
> Similar happens with rxgk_decrypt_skb() and its callers.
>
> Fix rxgk_decrypt_skb() or rxgk_verify_mic_skb() to return a greater variety
> of abort codes and fix their callers to abort the connection on any error
> apart from -ENOMEM.
>
> Also preclear the variables used to hold the abort code returned from
> rxgk_decrypt_skb() or rxgk_verify_mic_skb() to eliminate uninitialised
> variable warnings.
>
> Fixes: 9d1d2b59341f ("rxrpc: rxgk: Implement the yfs-rxgk security class (GSSAPI)")
> Reported-by: Dan Carpenter <dan.carpenter at linaro.org>
> Closes: https://lists.infradead.org/pipermail/linux-afs/2025-April/009739.html
> Closes: https://lists.infradead.org/pipermail/linux-afs/2025-April/009740.html
> Signed-off-by: David Howells <dhowells at redhat.com>
Reviewed-by: Simon Horman <horms at kernel.org>
More information about the linux-afs
mailing list