diff options
author | Herbert Xu <herbert@gondor.apana.org.au> | 2014-09-05 15:52:28 +0800 |
---|---|---|
committer | Herbert Xu <herbert@gondor.apana.org.au> | 2014-09-05 15:52:28 +0800 |
commit | fb38ab4cd05e11184fd2c3ef916fa106ecc505fc (patch) | |
tree | c73708cf16a0468a0cc90f0dc6601680c3acaa8e /crypto | |
parent | 7d1311b93e58ed55f3a31cc8f94c4b8fe988a2b9 (diff) | |
download | op-kernel-dev-fb38ab4cd05e11184fd2c3ef916fa106ecc505fc.zip op-kernel-dev-fb38ab4cd05e11184fd2c3ef916fa106ecc505fc.tar.gz |
crypto: drbg - backport "fix maximum value checks on 32 bit systems"
This is a backport of commit b9347aff91ce4789619168539f08202d8d6a1177.
This backport is needed as without it the code will crash on 32-bit
systems.
The maximum values for additional input string or generated blocks is
larger than 1<<32. To ensure a sensible value on 32 bit systems, return
SIZE_MAX on 32 bit systems. This value is lower than the maximum
allowed values defined in SP800-90A. The standard allow lower maximum
values, but not larger values.
SIZE_MAX - 1 is used for drbg_max_addtl to allow
drbg_healthcheck_sanity to check the enforcement of the variable
without wrapping.
Reported-by: Stephen Rothwell <sfr@canb.auug.org.au>
Reported-by: kbuild test robot <fengguang.wu@intel.com>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
Diffstat (limited to 'crypto')
0 files changed, 0 insertions, 0 deletions