Searched hist:bc97e57eb21f8db55bf0e1f182d384e75b2e3c99 (Results 1 – 1 of 1) sorted by relevance
/openbmc/linux/crypto/ |
H A D | algif_skcipher.c | diff bc97e57eb21f8db55bf0e1f182d384e75b2e3c99 Tue Nov 30 03:04:31 CST 2010 Herbert Xu <herbert@gondor.apana.org.au> crypto: algif_skcipher - Handle unaligned receive buffer
As it is if user-space passes through a receive buffer that's not aligned to to the cipher block size, we'll end up encrypting or decrypting a partial block which causes a spurious EINVAL to be returned.
This patch fixes this by moving the partial block test after the af_alg_make_sg call.
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
|