Commit Graph
19 Commits
Author SHA1 Message Date
Dimitris Apostolou fe60cea959 fix: avoid duplicate crates 2025-02-24 13:48:31 +02:00
Karolin Varnerand@phildremi 5187e50bb7 fix: Accidental removed line of comment
9bae080c4d

Co-Authored-By: @phildremi
2025-02-04 18:37:38 +01:00
Karolin Varner 9bae080c4d fix: Input dependent memory access in statistical constant time execution test
Supplying different memory locations to the memcmp function
in the test is not constant time; this was an issue wit
the test and not with memcmp itself.

The issue mainly showed up in the Release build where the
correlation coefficient was in the ballpark of just below
-0.01 with enough variance to sometimes but not usually fail
the test. The precise reason for this is unknown but some
optimization applied in the release build is most likely the
culprit.

This should increase the stability of our CI which occasionally
was flaky.
2025-02-04 13:34:19 +01:00
Paul SpoorenandGitHub a279dfc0b1 docs+doctest(to): Add tests, examples and documentation to the to-crate (#546) 2024-12-18 14:30:38 +01:00
Karolin VarnerandDavid Niehues d398ad369e fix: Disable asserts that rely on timing characteristics during coverage testing 2024-12-18 14:28:35 +01:00
Amin Faez 26f77924f8 docs(constant-time): add docs, examples and safety notices 2024-12-17 11:56:33 +01:00
Karolin Varner 398da99df2 chore: Documentation and unit tests for crate rosenpass-constant-time 2024-10-13 16:58:20 +02:00
Karolin Varner a4b8fc2226 chore: Move memcmp test API doc to test memcmp test module 2024-08-03 14:05:22 +02:00
Emil Engler 8099bc4bdd constant-time: Remove redundant cast 2024-04-25 11:01:41 +02:00
Paul SpoorenandKarolin Varner b2de384fcf constant-time: add secure memcmp_le function
The compare function should do a little-endian comparision, therefore
copy the code from quinier/memsec and don't revert the loop, tada, le.

Signed-off-by: Paul Spooren <mail@aparcar.org>
2024-03-11 13:08:41 +01:00
Ilka SchulzandKarolin Varner 27ba729c14 move each primitive into its own module; add rough documentation
This commit does not change anything about the implementations.
2024-02-29 13:36:54 +01:00
Ilka SchulzandKarolin Varner 36c99c020e implement test to statistically check constant run time of memcmp (feature: constant_time_tests) 2024-02-28 17:07:40 +01:00
Karolin VarnerandKarolin Varner 9690085156 chore: Cargo fmt 2024-01-27 21:38:13 +01:00
Karolin VarnerandKarolin Varner ca972e8b70 feat: Remove libsodium 2024-01-27 21:38:13 +01:00
Karolin VarnerandKarolin Varner 2fa0a2a72a feat: Use core::hint::black_box in rosenpass_constant_time::xor 2024-01-27 21:38:13 +01:00
wucke13andwucke13 62aa9b4351 fix: second round of clippy lints
Clippy would not automatically apply these fixes, so they were applied
by hand.
2024-01-03 18:43:05 +01:00
Jemilu MohammedandKarolin Varner ba224a2200 add default member
add shared dependencies to workspace dependencies

all package level dependencies now rely on workspace
2023-11-30 18:44:28 +01:00
Karolin VarnerandKarolin Varner 09aa0e027e chore: Move hashing functions into sodium/ciphers crate
This finishes the last step of removing sodium.rs from the rosenpass crate
itself and also removes the NOTHING and NONCE0 constants.

Hashing functions now use destination parameters;
rosenpass_constant_time::xor now does too.
2023-11-29 11:36:28 +01:00
Karolin VarnerandKarolin Varner 86300ca936 chore: Use naming scheme without rosenpass- for crates 2023-11-26 10:38:24 +01:00