1
0
mirror of https://github.com/ARMmbed/mbedtls.git synced 2025-10-21 14:51:23 +08:00
Commit Graph

4 Commits

Author SHA1 Message Date
Gilles Peskine
6cb9f35d8c Switch legacy cipher to constant-time invalid padding reporting
In internal `get_padding` functions, report whether the padding was invalid
through a separate output parameter, rather than the return code. Take
advantage of this to have `mbedtls_cipher_finish_padded()` be the easy path
that just passes the `invalid_padding` through. Make
`mbedtls_cipher_finish()` a wrapper around `mbedtls_cipher_finish_padded()`
that converts the invalid-padding output into an error code.

Signed-off-by: Gilles Peskine <Gilles.Peskine@arm.com>
2025-08-08 15:14:47 +02:00
David Horstmann
ab7bb5734d Appease check-names with prefix
Adding an mbedtls_prefix is preferred to having '//no-check-names'
littered about.

Signed-off-by: David Horstmann <david.horstmann@arm.com>
2025-03-05 18:09:05 +00:00
David Horstmann
32d8c90528 Disable check-names for static padding function
Check names is intended for public APIs. It doesn't matter if we call a
static function a non-namespaced name, so add an exception in the
invasive testing header file.

Signed-off-by: David Horstmann <david.horstmann@arm.com>
2025-01-22 11:36:16 +00:00
David Horstmann
d37e0c4639 Add constant-flow testing for PKCS7 padding
Signed-off-by: David Horstmann <david.horstmann@arm.com>
2025-01-22 11:36:15 +00:00