Commit Graph
1900 Commits
Author SHA1 Message Date
Frank Denis 3993b1a682 aegis mac: flip parameters to match their representation order 2020-09-27 23:38:02 +02:00
Frank Denis 3c83aeb4fa Shorten 2020-09-27 22:42:57 +02:00
Frank Denis 0454ae61c8 aegis: use more self-explanatory names for keys and nonces 2020-09-27 22:40:57 +02:00
Frank Denis dfcc95cb64 Merge branch 'master' of github.com:jedisct1/libsodium into master
* 'master' of github.com:jedisct1/libsodium:
  Add hash_to_ristretto255
  Move 2^511 -> 2^255-19 reduction to its own function
  Constify
2020-09-20 15:13:03 +02:00
Frank Denis 33b935921c Add hash_to_ristretto255
Identifier should be ristretto255_XMD:SHA-512_R255MAP_RO_
2020-08-23 18:28:58 +02:00
Frank Denis ee962b33ae Move 2^511 -> 2^255-19 reduction to its own function 2020-08-23 18:28:17 +02:00
Frank Denis 3b8891540b Constify 2020-08-23 18:27:36 +02:00
Frank Denis 3d27ee0898 Nits 2020-08-21 07:07:17 +02:00
Frank Denis ae330742cb Indent 2020-08-16 13:59:23 +02:00
Frank Denis ee6f457225 argon2 - copy raw hash after possible encoding, not before
(irrelevant in libsodium)
2020-08-16 11:35:08 +02:00
Frank Denis bc3b6a4694 Validate argon2 lanes before memory cost 2020-08-16 11:31:20 +02:00
Frank Denis e919f86257 Comments 2020-08-15 13:51:04 +02:00
Frank Denis b2d94a6da1 Cleaner ladder 2020-08-15 13:50:49 +02:00
Frank Denis 679f448d38 Indent 2020-08-14 08:37:39 +02:00
Frank Denis c02379fe8e Shorten 2020-08-05 16:34:30 +02:00
Frank Denis 1f5f71b015 Simplify 128<->64 bit casts 2020-08-02 19:59:22 +02:00
Frank Denis 290197ba3e Add comments on wrong alignment 2020-07-01 23:32:43 +02:00
P.I.E. Security Team 4744636721 Language Improvements (#972)
* Language Improvements

https://github.com/paragonie/sodium_compat/pull/121

* Update ed25519_ref10.c
2020-06-18 19:40:04 +02:00
Frank Denis 6497abb4bc Faster Jacobi symbol computation
From 261sq/11m down to 253sq/11m.

Also rename confusing was_square.
2020-06-15 09:25:22 +02:00
Frank Denis 6499766fb6 Merge branch 'master' of github.com:jedisct1/libsodium
* 'master' of github.com:jedisct1/libsodium:
  Don't even include signal.h on WASI
  Use unsigned long long for opslimit
2020-06-04 16:00:29 +02:00
Frank Denis 4e9e110031 No need to save %rdi 2020-06-04 16:00:16 +02:00
Frank Denis a8fa837aac Don't even include signal.h on WASI
Since version 11, wasi-sysroot doesn't ignore it but spits out
an error instead.
2020-06-04 10:54:53 +02:00
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