Frank Denis
f2da4cd8cb
core_ed25519_is_valid_point: check Y==Z in addition to X==0
2025-12-29 23:22:15 +01:00
Frank Denis
55f06e6738
Refer to the correct header
2025-12-29 23:12:15 +01:00
Frank Denis
79b9b08273
Fix typos
2025-12-29 16:09:03 +01:00
Frank Denis
d121c829ee
Format
2025-12-29 23:05:15 +01:00
Frank Denis
2a6640640f
That useless function will be removed
2025-12-29 15:44:16 +01:00
Frank Denis
3c55699b71
nsec isn't used
2025-12-08 16:05:11 +01:00
Frank Denis
7baa22c819
Downgrade ax_valgrind_check.m4
2025-12-08 04:51:33 +01:00
Frank Denis
3eabeb547f
Relax ((nonnull)) attributes where applicable
...
Reported by @stef -- Thanks!
Fixes #1477
2025-09-12 17:57:47 +02:00
Frank Denis
605f02d601
Add an optblocker in ge25519_from_hash
2025-08-27 22:57:36 +02:00
Frank Denis
37c5ecb937
Include <threads.h> if it exists
2025-07-30 13:27:37 +02:00
Frank Denis
51f3bee2bc
Remove duplicate include
2025-07-30 13:16:13 +02:00
Frank Denis
3dea5725a9
Regen
2025-07-30 12:34:41 +02:00
Frank Denis
604d0e17bd
Update autoconf
2025-07-30 12:28:39 +02:00
Frank Denis
b4cd238892
Improve AES256-GCM performance on ARM
2025-05-21 23:04:56 +02:00
Frank Denis
ff507ae4c4
Reorder arguments to vaeseq_u8 to improve AArch64 performance
...
The register arguments to the AESE instruction are commutative, however
the first input register is constrained in that it also names the output
register. The constraint on register allocation causes recent LLVM
versions to emit a lot of MOV instructions, significantly impacting
performance.
Swapping the register operands allows the compiler to emit significantly
fewer MOV instructions. This change improves performance on Arm
infrastructure micro-architectures by 14-36% depending on the
micro-architecture
Found and reported by George Steed from ARM. Thanks!
2025-05-21 14:51:27 +02:00
Frank Denis
9fff3a842a
Nits
2025-04-30 01:41:10 +02:00
Frank Denis
32de824a8d
MSC_VER -> _MSC_VER
2025-04-22 11:33:14 +02:00
Frank Denis
9e125388a1
Use uint64_t sizes in aegis*_mac()
...
No-op in libsodium for now, but useful if we introduce a streaming
API later.
2024-12-04 17:38:55 +01:00
Frank Denis
8855e8c300
Add assembly versions of equal() and negative()
2024-10-23 22:37:37 +02:00
Frank Denis
42f4e42b06
Use an optblocker in crypto_verify_n()
2024-10-23 22:34:15 +02:00
Frank Denis
c1fc74e690
Sync softaes with libaegis
2024-10-23 22:11:51 +02:00
Frank Denis
96d115cf29
Decrement and shift in separate steps
2024-10-23 19:52:14 +02:00
Frank Denis
409b3a70ad
More optblocker usage
2024-10-23 19:10:13 +02:00
Frank Denis
a9cbc57844
Add another optblocker
2024-10-23 19:09:24 +02:00
Frank Denis
3c6da4b8c2
randombytes_internal_random.c: move clang target attribute down
...
Specifically, move it after the system includes.
This appears to address an issue with clang 18 when cross-compiling
to windows.
Fixes #1413
2024-09-26 21:55:38 +02:00
mschwarzl and Frank Denis
b7b1c08272
Support for Cloudflare Workers for javascript_stir ( #1401 )
...
* Support for Cloudflare Workers for javascript_stir
* Ramove debugging comment
---------
Co-authored-by: Frank Denis <124872+jedisct1@users.noreply.github.com >
2024-08-13 21:40:54 +02:00
Frank Denis
0217d07326
Start introducing optblockers to prevent unwanted conditional jumps
2024-08-03 18:14:26 +02:00
Frank Denis
f2303ba3f0
Update autoconf
2024-08-01 13:57:57 +02:00
Frank Denis
dcc6471e26
Indent
2024-08-01 13:57:32 +02:00
SeungHwan Hur
28ac48d112
help MSVC optimize ROL/ROR functions ( #1392 )
2024-08-01 13:57:26 +02:00
Frank Denis
87f46367c4
AEGIS: improve performance of AD absorption on x86_64
...
No apparent regression on other platforms.
Adapted from libaegis.
2024-05-25 00:43:57 +02:00
Frank Denis
54b04533cc
Explicitly enabling evex512 is now required with LLVM 18
2024-05-09 22:21:10 +02:00
Frank Denis
bf972efda0
Use clang pragmas to enable features rather than depend on compiler settings
2024-04-27 23:18:59 +02:00
Andrzej Fiedukowicz
b3333f07fa
Move includes in crypto_onetimeauth_poly1305.h outside of extern C ( #1345 )
...
Includes being outside of `extern "C"` are de-facto standard in all other include files of libsodium.
At the same time, having inside the `extern "C"` is causing problem with C++ vs. C toolchain being confused about which libraries should be linked. This was especially painful while working on `swift-sodium` integration with windows.
2024-01-17 15:06:29 +01:00
Frank Denis
5068a8f257
When using MSVC on aarch64, __ARM_ARCH is not defined
...
Reported by RADDI.net -- Thanks!
2024-01-07 16:12:41 +01:00
Frank Denis
60c0c40b55
Add forgotten crypto_kdf_hkdf_sha512_statebytes()
2023-11-29 22:03:05 +01:00
Frank Denis
f1184e45d9
Include argon2id in crypto_pwhash_primitive()
...
Fixes #1331
2023-11-10 12:36:32 +01:00
Frank Denis
420356c58a
Add a comment where coordinates are expected to be normalized
2023-11-08 07:38:04 +01:00
Frank Denis
d1a0b7e7cb
_M_AMD64 is the same as _M_X64
2023-11-02 06:40:41 +01:00
Frank Denis
bb6e6a4b52
aarch64: set compiler attributes *after* including <arm_neon.h>
...
Fixes #1321
2023-10-20 13:57:44 +02:00
Frank Denis
fb4533b0a9
Port the GCC target changes for aarch64 to aegis
...
Fixes #1313
2023-09-13 15:46:16 +02:00
Frank Denis
b795a93fa8
Promote HKDF to minimal builds
2023-09-13 09:00:06 +02:00
Frank Denis
443617d750
Remove expected length from the pwhash_str_verify()/needs_rehash()
2023-09-13 09:00:06 +02:00
Frank Denis
854947a4ce
Add AEGIS AEADs
2023-09-13 09:00:06 +02:00
Frank Denis
b8a6fecdb6
Add support for HKDF
2023-09-13 09:00:06 +02:00
Frank Denis
61674c6c87
Use ANDROID_CPU_ARM64_FEATURE_AES for AES detection on Android/aarch64
2023-09-13 08:59:50 +02:00
Frank Denis
a589d64b42
Handle SIGPROT, CHERI's in-address space security exception
2023-09-12 21:04:06 +02:00
Frank Denis
b6bcb3dc22
Forgotten attribute pop
2023-09-12 16:03:13 +02:00
Frank Denis
e2935b6943
aarch64: try harder when checking for the crypto extensions
2023-09-12 15:59:05 +02:00
Frank Denis
652c081535
Don't hardcode type sizes
2023-09-12 12:52:08 +02:00