]> www.infradead.org Git - users/jedix/linux-maple.git/commit
crypto: krb5 - Use SG miter instead of doing it by hand
authorHerbert Xu <herbert@gondor.apana.org.au>
Thu, 13 Mar 2025 05:14:56 +0000 (13:14 +0800)
committerHerbert Xu <herbert@gondor.apana.org.au>
Fri, 21 Mar 2025 09:33:38 +0000 (17:33 +0800)
commitda6f9bf40ac267b5c720694a817beea84fa40f77
tree185b181ea12f1d346bca017b18270a4c11cf946c
parentfc8d5bba61ad8087af9a56337a7a297af6b46129
crypto: krb5 - Use SG miter instead of doing it by hand

The function crypto_shash_update_sg iterates through an SG by
hand.  It fails to handle corner cases such as SG entries longer
than a page.  Fix this by using the SG iterator.

Fixes: 348f5669d1f6 ("crypto/krb5: Implement the Kerberos5 rfc3961 get_mic and verify_mic")
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
crypto/krb5/rfc3961_simplified.c