1
mirror of https://github.com/jedisct1/libsodium.git synced 2024-12-24 12:36:01 -07:00
Commit Graph

1878 Commits

Author SHA1 Message Date
Frank Denis
0cb4db084f Use unsigned long long for opslimit
Fixes #966
2020-06-03 17:36:07 +02:00
Frank Denis
3c49e89c19 Add memory clobber
Fixes #965
2020-05-30 23:21:17 +02:00
Frank Denis
d854d39b51 Shorten 2020-05-26 14:03:49 +02:00
Frank Denis
f9ef57db0b Faster sc25519 inversion, with one less squaring 2020-05-26 13:15:19 +02:00
Frank Denis
b0369e7391 Update prototypes 2020-05-26 00:15:42 +02:00
Frank Denis
214076fc09 Replace the multiplication by the group order with an addition chain.
Rename ge25519_{add,sub,madd,msub} for clarity.
2020-05-25 23:54:43 +02:00
Frank Denis
1127c43278 Add extra box_seal() tests 2020-05-21 18:38:55 +02:00
Frank Denis
23bba4a2b2 crypto_box_seal(): copy the key after encryption to support in-place encryption
Fixes #961
2020-05-21 18:22:37 +02:00
Frank Denis
da3fc4dd91 Add explicit casts and make things a bit more consistent 2020-05-19 17:40:18 +02:00
Frank Denis
c3ca08913c Add AEGIS-128L for no good reasons 2020-05-19 15:36:22 +02:00
Frank Denis
8706f2e8d7 Indent 2020-05-19 15:00:51 +02:00
Frank Denis
4cc7d9027c Constify 2020-05-18 20:46:09 +02:00
Frank Denis
a85afdc5ba Remove unused code 2020-05-14 18:45:56 +02:00
Frank Denis
62c6dbcf36 Comment 2020-05-14 12:21:09 +02:00
Frank Denis
056a1aeef5 Avoid & and && mix without brackets 2020-05-13 23:08:19 +02:00
Frank Denis
c2efce113d Add crypto_core_{ed25519,ristretto255}_scalar_is_canonical() 2020-05-13 22:59:08 +02:00
Frank Denis
d39dd88301 Remove unreferenced variables, fix Windows build 2020-05-13 22:38:59 +02:00
Frank Denis
cc2bcbc217 aes256gcm: handle 8 blocks at a time instead of 4
Keep using 4 blocks at time for AD, as AD is usually short.

Decrypt-and-verify instead of verify-then-decrypt.
2020-05-13 17:36:01 +02:00
Frank Denis
c4b08fb208 Merge branch 'master' of github.com:jedisct1/libsodium
* 'master' of github.com:jedisct1/libsodium: (55 commits)
  H2C: change sign computation for Ell2 to match BHKL13
  Deprecate non-easy secretbox
  Remove memory shielding
  Deprecate low-level non-easy crypto boxes as well
  Deprecate the non-easy crypto_box API
  Nits
  Remove unneeded casts
  Indent
  Use inline asm if supported
  Nits
  Inline
  space
  Simplify scalarmult{2,5} tests
  Add a scalarmult test to show that the high bit is ignored
  Fix wasi-sdk path
  One more test vector cannot hurt
  ristretto255_is_canonical(): sync with wasm-crypto
  Rename a few things
  Merge mont->ed conversion
  Revert "Add the BlaBla2000 stream cipher - will eventually become the default"
  ...
2020-05-13 14:10:14 +02:00
Frank Denis
06e219e165 Format 2020-05-13 14:10:04 +02:00
Frank Denis
f23c932d74 H2C: change sign computation for Ell2 to match BHKL13
https://github.com/cfrg/draft-irtf-cfrg-hash-to-curve/pull/250
2020-05-12 16:33:13 +02:00
Frank Denis
3f1586623c Deprecate non-easy secretbox 2020-05-10 22:29:25 +02:00
Frank Denis
67a9e79655 Remove memory shielding
That was a great idea to protect against information leak through
speculative loads.

Realistically, nobody is going to use this.
2020-05-10 21:05:24 +02:00
Frank Denis
bf2238bbc4 Deprecate low-level non-easy crypto boxes as well 2020-05-10 20:32:42 +02:00
Frank Denis
5bb0cdc616 Merge branch 'master' of github.com:jedisct1/libsodium
* 'master' of github.com:jedisct1/libsodium:
  Nits
  Remove unneeded casts
  Indent
2020-05-10 20:28:39 +02:00
Frank Denis
507409d59e Deprecate the non-easy crypto_box API
It is really too complicated to use.
2020-05-10 20:27:50 +02:00
Frank Denis
ce19bc7a69 Remove unneeded casts
Fixes #954
2020-05-05 01:25:42 +02:00
Frank Denis
c68b071e52 Indent 2020-05-05 01:09:22 +02:00
Frank Denis
4967aa8f23 Use inline asm if supported 2020-05-04 18:23:09 +02:00
Frank Denis
88c568a035 Nits 2020-05-02 17:54:02 +02:00
Frank Denis
809a9f9d7e Inline 2020-05-02 17:42:25 +02:00
Frank Denis
300f12c6a3 space 2020-05-02 17:13:41 +02:00
Frank Denis
8b6f5ef505 ristretto255_is_canonical(): sync with wasm-crypto
Reject string with the top bit set.
2020-04-25 12:15:30 +02:00
Frank Denis
e768eae76d Rename a few things 2020-04-23 11:10:19 +02:00
Frank Denis
599cb10246 Merge mont->ed conversion 2020-04-21 16:13:05 +02:00
Frank Denis
29f098d237 Revert "Add the BlaBla2000 stream cipher - will eventually become the default"
This reverts commit a31fe2a966.
2020-04-21 13:35:29 +02:00
Frank Denis
72ec06c189 Comment 2020-04-21 13:35:29 +02:00
Frank Denis
f582db039f Handle identity; fix comment 2020-04-21 13:35:26 +02:00
Frank Denis
6f1c987d2e Add an assertion 2020-04-18 23:37:12 +02:00
Frank Denis
d01c49df02 H2C: convert DST encoding to suffix free
https://github.com/cfrg/draft-irtf-cfrg-hash-to-curve/pull/241
2020-04-10 09:48:26 +02:00
Frank Denis
a31fe2a966 Add the BlaBla2000 stream cipher - will eventually become the default
2000 rounds variant of the BlaBla20 cipher
for Very Post Quantum (VPQ) security.
2020-03-31 21:42:54 +02:00
Frank Denis
7d0aea6d5e Remove unused code 2020-03-31 17:37:06 +02:00
Frank Denis
d9844396e3 Fix and add HKDF tests 2020-03-31 17:14:04 +02:00
Frank Denis
5f39c3ce09 Don't force include the suite ID in tags 2020-03-31 14:33:40 +02:00
Frank Denis
89eb497efa Handle oversized contexts 2020-03-31 14:16:16 +02:00
Frank Denis
728b26c2c1 Remove edwards25519sha512batch
Tagged as deprecated for years, never imported by `<sodium.h>`, and
intentionally never documented.

`edwards25519sha512batch` was just around for ABI compatibility
with NaCl, but no projects seem to be using it.
2020-03-31 12:11:32 +02:00
Frank Denis
ac48996492 Remove crypto_core_ed25519_from_hash()
Undocumented, was deprecated for a while in stable versions,
obsoleted by `_from_string()` and `from_string_ro()`.
2020-03-31 12:04:47 +02:00
Frank Denis
2d5b9547d1 yield in spinlock on aarch64 2020-03-30 22:00:35 +02:00
Frank Denis
bf3bc8c386 Add nonnull attributes for new functions 2020-03-30 17:44:17 +02:00
Frank Denis
5fdd12fa97 Add crypto_core_ed25519_from_string() and crypto_core_ed25519_from_string_ro() 2020-03-30 17:19:36 +02:00