1280 Commits

Author SHA1 Message Date
Mark Albert
d577d0b4e9
add valgrind option (#1327) 2022-12-07 07:26:46 +01:00
Goutam Tamvada
f5d96cab5c
Removed SABER. (#1326) 2022-12-01 14:04:08 -05:00
Goutam Tamvada
c50d38e5a8
Removed NTRU-Prime. (#1325) 2022-11-29 07:31:53 +01:00
Goutam Tamvada
fac5a818ed
Removed the Picnic signature scheme. (#1323) 2022-11-28 15:29:10 -05:00
Goutam Tamvada
203c9c269b
Removed the rainbow signature scheme (#1321). 2022-11-28 11:34:59 -05:00
Basil Hess
2e2ddb4e04
Update Kyber and Dilithium from upstream (#1316) 2022-11-23 15:15:27 -05:00
Michael Baentsch
e9cd9a5c55
automatically activate USE_RASPBERRY_PI define (#1313)
* automatically activate USE_RASPERRY_PI define

* prefix RASPBERRY_PI define with OQS_
2022-11-18 08:12:19 +01:00
Jason Goertzen
c520cdb871
Fixing OQS ARM inconsistencies (#1307)
* Renamed sha2 C_OR_NI to C_OR_ARM since we only select between C and ARM

* Updated AES C_OR_NI_OR_ARM's formatting and logic

* Renamed sha2_ni.c to sha2_armv8.c and updated CMakeLists.txt to fix build issues with arm optimized AES linking

* Fixed a feature detection logic issue

* Found an issue when compiling a distributed version

* Only apply -march=armv8-a+crypto to arm builds

* updated some naming
2022-11-15 16:47:36 -05:00
John Schanck
f88e6237c5
Integer overflow leading to incorrect computation of sha3 (#1312)
Suppose a user of the incremental SHA3 API absorbs 10 bytes, and then
absorbs 2^64 - 10 bytes. At the beginning of the second
`keccak_inc_absorb` call, the 25th element of the Keccak state is equal
to 10, and there is a uint64_t overflow in
```
if (s[25] && mlen + s[25] >= r)
```
which causes the branch to be skipped. Later code assumes that mlen >= r
implies that s[25] = 0, and calls
```
(*Keccak_AddBytes_ptr)(s, m, 0, r);
```
with third argument 0 instead of s[25]. This call modifies the wrong
elements of the Keccak state, which leads to an incorrect result.

I went looking for bugs of this form because of CVE-2022-37454, but this
one is not a security concern. It is also largely theoretical since it
involves processing close to 2^64 bytes.
2022-10-26 09:05:05 +02:00
Michael Baentsch
222374e067
addressing sig length questions (#1306)
* addressing sig length questions

Co-authored-by: Douglas Stebila <dstebila@users.noreply.github.com>
2022-09-15 06:49:03 +02:00
Michael Baentsch
46deaac9a9
update version string indicating dev status (#1305) 2022-09-14 17:17:09 +02:00
Sebastian Ramacher
8ac8b1c5ab
Fallback code for aligned_alloc and use of explicit_bzero (#1300)
* Check if aligned_alloc or memalign variants are available and use them

* Use explicit_bzero if available

* Check for memset_s
2022-09-08 07:10:28 +02:00
Michael Baentsch
489aa7eb59
ARM32 gcc12 build workaround (#1297)
* add ARM32 gcc compile option workaround

* add no-ipa-modref only in gcc11 and higher
2022-09-07 19:21:27 +02:00
Sebastian Ramacher
930f78d066
Fix typo in Picnic's NEON detection (#1298)
This change addresses the Picnic part of #1296.
2022-09-07 19:03:29 +02:00
Sebastian Ramacher
9ee96d803e
Ensure build without an executable stack (fixes #1285) (#1294)
* Ensure build without an executable stack (fixes #1285)

Until it is clear why the shared library on mips64el and hppa is built
with the executable bit set for the stack, build with both
`-Wa,--noexecstack` (for the assembler) and `-Wl,-z,--noexecstack` (for
the linker).

* Check if compiler/linker support flags for noexecstack before using them

* Add a warning if unable to check for support
2022-08-31 06:41:28 +02:00
thb@sb
c5b8cfe478
Solve '-Wstrict-prototypes' for clang >= 15.0 (#1293)
* Solve '-Wstrict-prototypes'

Manual changes are applied to the following algorithms only:

 * Bike
 * Frodo
 * Picnic

* Add prototype for implementation of `OQS_SIG_alg_count`

* Add prototype for implementation of `OQS_KEM_alg_count`

* Run `copy_from_upstream.py`

Now, the constructors have a full prototype. It compiles with clang 16.0
2022-08-30 11:20:05 +02:00
thb@sb
ff09345f5f
Add missing requirements to the requirements.txt (#1295)
The script `scripts/update_docs_from_yaml.py` is using the python package
`tabulate`. It is missing from the `requirements.txt` file.

This PR adds it the the `requirements.txt` file.
2022-08-26 07:07:28 +02:00
Douglas Stebila
ea44f391fd 0.7.2 0.7.2 2022-08-21 15:54:09 -04:00
Douglas Stebila
da6e54103a 0.7.2-rc2 0.7.2-rc2 2022-08-10 13:26:37 -04:00
Sebastian Ramacher
542b2d0b6b
Cover SHA3/SHAKE-implementation specific code paths in Picnic suppression files (#1286) 2022-08-10 10:06:31 -04:00
Michael Baentsch
d3c10161e3
add warning about HQC [skip ci] (#1284) 2022-08-09 11:26:41 -04:00
Douglas Stebila
b8c9c9f299
Update release notes (#1281) 2022-08-09 11:26:05 -04:00
Sebastian Ramacher
0511af68d7
Update to Picnic 3.0.17 (#1280)
* Update to Picnic 3.0.17

* Added valgrind constant time execptions for picnic

Co-authored-by: Christian Paquin <cpaquin@microsoft.com>
2022-08-08 17:02:00 +02:00
Douglas Stebila
42f36c2a1b
Add option to all pytests to skip particular algorithms (#1282)
* Add SKIP_ALGS option to all pytests to skip particular algorithms
2022-08-07 06:36:45 +02:00
Michael Baentsch
84fde26ed2
Fixup dilithium-avx2 valgrind test file (#1283) 2022-08-06 17:43:24 -04:00
Douglas Stebila
3cf9849cc4 0.7.2-rc1 0.7.2-rc1 2022-08-03 17:07:33 -04:00
Michael Baentsch
91bfca9bdd
Add library version retrieval function (#1273) 2022-08-03 13:32:11 -04:00
Vlad Gheorghiu
33738d9354
Update CODEOWNERS (#1274)
typo
2022-08-03 13:29:26 -04:00
Michael Baentsch
fe08f69c6e
Fix FreeBSD runtime ARM CPU feature detection (#1267) 2022-08-03 10:20:41 -04:00
Douglas Stebila
1e47e14556
Remove SIDH and SIKE (#1272)
Due to https://eprint.iacr.org/2022/975.

Fixes #1268.
2022-08-03 10:19:28 -04:00
Sebastian Ramacher
af76ca3b1f
Update to Picnic 3.0.16 (fixes #1253) (#1271)
This update fixes alignment issues when built with MSVC.
2022-08-02 09:43:21 -04:00
Michael Baentsch
4abd522492
update PR template to include oqs-provider (OSSL dependency) [skip ci] (#1269) 2022-08-01 19:58:53 -04:00
Christian Paquin
fb0edb7f85
Updated to SIKE v3.5.1 (#1231)
* Updated to SIKE v3.5.1

* Prettyprint

* Newline at the end of the file (to avoid error from -Wnewline-eof)

* Wrap logical not check in parenthesis, to avoid error from -Wlogical-not-parentheses

* Added empty functions to avoid unused errors on macOS

* Adding extra empty line at the end of assembly files to avoid newline-eof errors

* Fixing missing newlines at the end of the .S files

* Initialized some sike values

* Initialized a sike value

* Small edits

* Initialized some more SIKE variables

* sike cmake update

* include for windows

Co-authored-by: Basil Hess <bhe@zurich.ibm.com>
2022-07-30 08:40:05 -04:00
Douglas Stebila
478ccba970
Remove Rainbow level 1 (#1263)
Fixes #1260
2022-07-27 15:12:16 -04:00
Vitalio
2c687b1220
pqclean_hqc: Fix build on GCC-12 (#1254)
Make index variable `i` immediate by unrolling the loop.

Link: https://github.com/open-quantum-safe/liboqs/issues/1244
Signed-off-by: Vitaly Chikunov <vt@altlinux.org>
2022-07-25 16:22:02 -04:00
HY Chang(splasky)
664c6f331d
Fix memory leak detected by valgrind (#1250) 2022-07-17 15:35:35 -04:00
Basil Hess
e88cc366b5
Sync Kyber with upstream, enable Scan-Build with Kyber (#1252) 2022-07-11 11:53:20 +02:00
yin19941005
8ec55171b0
docs: Add valgrind as test dependencies in README.md (#1251)
* docs: add valgrind as dependencies in readme

Co-authored-by: Michael Leung <michael.leung@bloombase.com>
2022-07-08 08:50:41 +02:00
Michael Baentsch
1a1e91845c
disable msys2 testing (#1243) 2022-07-01 09:53:27 -04:00
Michael Baentsch
a8dad8d305
adding memory leak testing (#1234)
* adding memory leak testing for x86_64 on ubuntu

* document test exclusion of Classic-McEliece-8192128
2022-07-01 09:09:03 +02:00
Michael Baentsch
fbb34be899
adding scan-build test (#1240)
* adding scan-build test

* upgrade to clang-14

* excluding Kyber from scan-build test
2022-06-30 08:49:06 -04:00
Basil Hess
d402280283
Updated Dilithium sign.c patch with AES context release (2) (#1242) 2022-06-30 06:48:55 +02:00
Sebastian Ramacher
0efa4b97e0
Bump Picnic to 3.0.15 (#1241)
* Bump Picnic to 3.0.15
2022-06-29 09:01:59 +02:00
Michael Baentsch
7d7fd33879
improve Windows crosscompile handling (#1236) 2022-06-29 07:40:32 +02:00
Sebastian Ramacher
c0db3d9ce3
Update Picnic to 3.0.14 (fixes #1212) (#1237)
This commit also corrects incorrect information in picnic.yml
2022-06-28 09:58:15 -04:00
Basil Hess
a9629e0a48
Updated Dilithium sign.c patch with AES context release (#1238) 2022-06-28 09:57:57 -04:00
Basil Hess
719a84ecdd
Integrates pqcrystals with common-aes / extends common code AES CTR-API (#1221)
* Integrates pqcrystals (ref and avx2) with liboqs common AES code (for Kyber-90s and Dilithium-AES).
* Extends libOQS AES-CTR with Incremental API: OQS_AES256_CTR_inc_init, OQS_AES256_CTR_inc_iv, OQS_AES256_CTR_inc_ivu64, OQS_AES256_CTR_inc_stream_iv, OQS_AES256_CTR_inc_stream_blks.
* Adds some AES-CTR shim API.
* Faster AESNI CTR code (improved iv handling, 4x interleaved blocks for higher throughput).
* OpenSSL AES supporting CTR API.
* Updated pqcrystals patches (API, context releases).
* Removes redundant AES implementations from Kyber and Dilithium.
* Copy-from-upstream with updated patches.
* Uses internal AES on x86_64 (dist & AES) because of increased performance with the internal AESNI code.
* Adds AES-CTR benchmarks to speed_common
* Update CONFIGURE.md
2022-06-23 14:44:36 +02:00
Michael Baentsch
608ea188e3
Link documentation and code (#1229)
* move Wiki documentation to source code

* adding CONFIGURE.md to doxyconfig

Co-authored-by: Douglas Stebila <dstebila@users.noreply.github.com>
2022-06-22 09:59:30 -04:00
Michael Baentsch
d9c2cd2136
doxygen update (#1228)
* upgrade script to support doxygen 1.9.3

* update CI script for doc generation

* add license identifiers
2022-06-21 10:53:16 -04:00
Jason Goertzen
e37ad5b5d8
Added typecasts to ds benchmark to make clang happy (#1225) 2022-06-14 06:31:29 +02:00