1062 Commits

Author SHA1 Message Date
John Schanck
4b1a9e23ee
Make OQS_USE_CPU_EXTENSIONS imply OQS_PORTABLE_BUILD=OFF; alternative to #939 (#942) 2021-03-14 15:32:52 -04:00
Thom Wiggers
e116748c50
these two example files got moved at some time (#938) 2021-03-12 12:06:22 +01:00
John Schanck
707750e034
Fix OQS_PORTABLE_BUILD logic for Frodo (#927)
* Fix OQS_PORTABLE_BUILD logic for Frodo

* Refine 'OQS_PORTABLE_BUILD' by general architecture, e.g. x86_64

* Use CMake to define ARCH_X86_64 and ARCH_ARM_ANY used in common.{c,h}

* Avoid triggering portable build on ARM

* Set OQS_USE_CPU_EXTENSIONS even on MSVC

* Compile AES-NI code in portable x86_64 builds
2021-03-11 21:31:26 -05:00
John Schanck
b5fd8aedfc
Resolve some McEliece AVX build issues (#932)
* Fix minimal build support for McEliece avx

* mceliece avx consts.S: use .hidden to avoid putting consts in GOT

* mceliece avx int32_sort.c: avoid gcc extension __m256i_u

* cmake: Use target_compile_option when setting -Wno-language-extension-token for mceliece avx
2021-03-11 21:28:07 -05:00
Douglas Stebila
0ab1d1d95b Switch to 0.5.1-dev [skip ci] 2021-03-10 13:33:25 -05:00
Douglas Stebila
af1b14e7b6 liboqs 0.5.0 release 0.5.0 2021-03-10 13:30:25 -05:00
Douglas Stebila
1e4af5dfd1 Add to RELEASE notes [skip ci] 2021-03-10 10:21:16 -05:00
John Schanck
0e4885b569
test_constant_time: Suppression files for AVX McEliece [skip ci] (#931) 2021-03-03 12:32:22 -05:00
Douglas Stebila
5b2ed97f08
liboqs 0.5.0 release candidate 1 (#926)
* liboqs 0.5.0 release candidate 1

* picnic: compile keccak with NO_MISALIGNED_ACCESSES (#924)

* liboqs 0.5.0 release candidate 1

Co-authored-by: John Schanck <jschanck@uwaterloo.ca>
2021-02-27 22:42:11 -05:00
John Schanck
4c754a5922
picnic: compile keccak with NO_MISALIGNED_ACCESSES (#924) 2021-02-27 17:13:28 -05:00
John Schanck
fa9c2671ec
Use valgrind to check for secret-dependent branching on 'audit' branches (#904)
* Constant time checks using Valgrind and suppression files

* Suppression file for Kyber (ref+avx), HQC, SIKE, NTRUPrime, McEliece, SIDH, Falcon (ref+avx), SPHINCS, Dilithium r2+r3, picnic

* mark all BIKE implementations as vartime

* Set OQS_DEBUG_BUILD in oqsconfig.h if CMAKE_BUILD_TYPE=Debug

* Add OQS_ENABLE_TEST_CONSTANT_TIME to oqsconfig.h

* Check build options before running

* test_{kem,sig}: avoid direct call to OQS_randombytes_system

* Remove picnic3 issue based on review #889

* fix Kyber namespacing

* Missing BIKE error type, skip BIKE

* Resolve SIDH/SIKE bingcd issue as per #888

* Mark Falcon hash_to_point_vartime issue as resolved

* Disable CI tests
2021-02-25 06:51:01 +01:00
Basil Hess
9cf6171007
Dilithium 3.1 update, partially autogenerating docs (#923)
* Updates to Dilithium 3.1 (randomized)

* Update dilithium.md, point to pqcrystals-repo

* Partially autogenerating algorithm docs
2021-02-24 06:39:08 +01:00
Michael Baentsch
6040f559ec
Update Falcon & McEliece (adding AVX) (#920)
* fixing copy_from_upstream issues (>2 optimized implementations)

* adding mceliece-avx & falcon

* alg doc added
2021-02-23 16:45:56 +01:00
Thom Wiggers
d9e025852e
Support OpenSSL on Windows (#915)
* Allow OpenSSL on Windows

See https://github.com/open-quantum-safe/liboqs-rust/issues/17
2021-02-23 06:12:06 +01:00
Christian Paquin
7ef3f41e09
Updated SIKE to v3.4 (#914)
* Upgraded to sike v3.4

* Commented out check to avoid "always false" warning/error.

* Fixes for OQS inclusion.
2021-02-18 11:23:02 -05:00
John Schanck
952c628051
Fix undefined behaviour in keccak4x (#919)
* keccak4x: Fix undefined load from improperly aligned static constant

* keccak4x: Backport some minor changes

* astyle
2021-02-17 20:38:19 -05:00
Douglas Stebila
78a190ffa2
Add CODEOWNERS [skip ci] (#913)
* First attempt at a CODEOWNERS file [skip ci]

* Update CODEOWNERS [skip ci]
2021-02-16 13:57:44 -05:00
John Schanck
f4c1ef9ba5
Add OQS_MINIMAL_BUILD option and redefine CI workflow (#903)
* Add OQS_MINIMAL_BUILD option that builds only the default KEM/SIG

* CI: add buildcheck job, which uses minimal build

* Add buildcheck and testapproval to CI workflow

* CI: Only run address-sanitizer on audit branches

* CI: Disable centos-8 and debian-buster
2021-02-13 16:53:06 +01:00
Douglas Stebila
a9059ae0c5 Update README and CONTRIBUTORS [skip ci] 2021-02-12 13:51:31 -05:00
Michael Baentsch
95c9c5bdf8
Changing python platform test (#902)
Fixes #901
2021-02-12 10:25:32 +01:00
John Schanck
e9348d5500
Switch back to subprocess.run (#908)
* helpers.py: switch back to subprocess.run (revert 346305fc)

* test_free: replace find|grep|xargs with python solution
2021-02-12 06:46:59 +01:00
Douglas Stebila
1dcf3ebdc5 Change wording on algorithm changes in pull request template [skip ci] 2021-02-11 21:17:48 -05:00
Douglas Stebila
d87c997491 Update list of Dilithium algorithms in README 2021-02-11 10:57:54 -05:00
Basil Hess
405654c6ec
Kyber768 ref dependencies (#899) (#905) 2021-02-10 14:07:57 +01:00
John Schanck
1ead54fc9a
Remove round 2 Dilithium KATs (#898) 2021-02-09 07:10:27 +01:00
Michael Baentsch
1256e3ba99
Mb randloop (#897)
* fixes #895

* upgrade ubuntu 20 CI

* using status/poll pattern to retry
2021-02-08 10:11:58 -05:00
Basil Hess
bd4d09da75
Sync upstream with copy_from_upstram / pqcrystals pull (#891)
* Point Kyber and Dilithium to pqcrystals-repo.

* Pulls Kyber and Dilithium from PQCrystals using copy_from_upstream

* Dilithium Round 3
* Kyber round 3
* Updates Dilithium Round 3 KAT

* Updates kyber.md and dilithium.md (manual changes after running copy_from_upstream)
2021-02-04 15:46:45 +01:00
Basil Hess
fc35e09a14
Update copy_from_pqclean / copy_from_upstream (#883)
* Update copy_from_pqclean / copy_from_upstream (#880)

* Renames copy_from_pqclean to copy_from_upstream.

* Adds 'upstreams' field to copy_from_upstream.yml, allowing to specify upstream repositories, branches and commits.

* Modifies "copy" command in copy_from_upstream: sources are pulled from specified git-repositories. Implementation folders in $LIBOQS_DIR/src will be prefixed with the upstream-name.

* Adds "verify" command in copy_from_upstream: Implementations in $LIBOQS_DIR/src are compared with expected upstream versions.

* Prepares for copying pqclean, pqcrystals-kyber and pqcrystals-dilithium from upstream.

* Updates copy_from_upstream to process common dependencies from an upstream.

* Adds reminder text to manually update algorithm docs .md files after copying
2021-02-03 18:43:02 +01:00
Michael Baentsch
d183ccda66
remove docker auth for now (#885) 2021-01-29 15:08:54 +01:00
Douglas Stebila
a152118915 Update list of Rainbow algorithms in README 2021-01-25 20:50:46 -05:00
Douglas Stebila
fb5484cda6
FrodoKEM portable build with CPU feature detection (#878)
* Make `OQS_SHA3_shake128_4x` always available

* Simplify FrodoKEM SHA3

* Fix prettyprint

* Make SHAKE128 x4 always available and use CPU feature detection

Move contents of sha3x4.c into sha3x4_avx2.c

* CPU feature detection for FrodoKEM sa+e operation

Separate out the 4 versions (C, AVX2) x (AES, SHAKE) and then select 
appropriate one

* Missing braces for single-line for statement

* Reorganize FrodoKEM AVX2 code into separate compilation units

* Move as+e so compiler can apply AVX2 optimizations

There isn't an explicit separate AVX2 implementation since Patrick 
observed that the compiler can optimize this code well enough without 
hand-written usage of intrinsics.  This commit reorganizes the code so 
that the compiler can separately compile a version with -mavx2 options 
provided.
2021-01-18 10:13:11 -05:00
Christian Paquin
9fb0bdd6f3
Picnic Dec 2020 update. (#872)
* Updated picnic from commit 1797ab (v3.0.3) to fcddc7.

* Added commit ca45b2, disabling OQS's non-optimized sha3 impl.

* Integrated commits up to v3.0.4 tag.
2021-01-13 13:03:43 -05:00
Douglas Stebila
85597bbc6c
Rainbow Round 3 (#867) 2021-01-04 09:25:35 -05:00
Michael Baentsch
b08d581acb
add portability tests (#871)
* added portability tests only on Ubuntu, documentation added

* using Westmere as test CPU type; disable avx2 for common code other than sha3x4 on portable builds

* removed extraneous PORTABLE_BUILD guards
2020-12-17 16:10:27 +01:00
Christian Paquin
1fb8a3d382
Integrates frodokem Dec 2020 update (#869)
* Integrated frodokem Dec 2020 fix.

* Updated frodokem commit URL in doc
2020-12-11 17:06:12 -05:00
Douglas Stebila
689f789d51 Update FrodoKEM algorithm datasheet
[skip ci]
2020-12-09 20:17:48 -05:00
Goutam Tamvada
dd739fc8f2
OQS_BUILD_PORTABLE -> OQS_PORTABLE_BUILD and other refactoring. (#864)
* OQS_BUILD_PORTABLE -> OQS_PORTABLE_BUILD and associated changes.

* subprocess.run() -> subprocess.Popen() + subprocess.communicate().

* Changed temporary storage location used for memory benchmarking.
2020-12-09 15:03:57 -05:00
Christian Paquin
c91957ca7b
Integrated SIKE Dec 2020 update. (#863) 2020-12-08 17:46:26 -05:00
Douglas Stebila
3a361a17eb Documentation fix
Missed in #858

[skip ci]
2020-12-08 12:46:14 -05:00
Douglas Stebila
65b3fb6e71
Sync with PQClean (Kyber Round 3) (#858)
* Delete Kyber Round 2

* Sync with PQClean

Major changes; Kyber Round 3
Minor changes: HQC and NTRU

PQClean commit 168e3625988defacdf10812642e4d412fb295dc0
2020-12-03 09:56:03 -05:00
Michael Baentsch
3ca64c35ae
enable Valgrind memory use testing (#854) 2020-12-02 21:45:30 +01:00
Douglas Stebila
1ad950ac00
Sync with PQClean (#851)
* Remove HQC round 2

* Sync with PQClean

3c8be3cb1f8ca0953f2df44ea665f118efb468d6

* Add HQC from PQClean
2020-11-24 10:04:49 -05:00
xvzcf
0c17d3dfe7 Switched default branch from master to main. 2020-11-06 10:56:31 -05:00
Goutam Tamvada
49559aecfa
Triggering more downstream CircleCI jobs and removed GNUInstallDirs from CMake. (#850) 2020-11-05 10:53:59 -05:00
Douglas Stebila
46693cf93a
Add NTRU-Prime from PQClean (#848) 2020-11-03 13:36:24 -05:00
Goutam Tamvada
003a855695
Exported liboqs target in CMake and some CI refactoring. (#840) 2020-11-02 10:53:13 -05:00
Douglas Stebila
2665eaa933
Documentation updates (#847)
[skip ci]
2020-10-29 19:47:00 -04:00
Douglas Stebila
1a923c79e0
Sync with PQClean (#846)
* Change BMI1 and add PCLMUL

* Copy from PQClean

Commit b4078aae55f9efbc7b3ab7b3c702be376f7a7987, excluding HQC

* Update algorithm datasheets

* Prettyprint

* Update version to 0.5.0-dev
2020-10-29 19:46:39 -04:00
Michael Baentsch
993c1d757b
selectively exclude NOT_READY algorithms from copy_from_pyclean (#841) 2020-10-28 12:53:40 -04:00
Christian Paquin
7c0aa19e8c
Upgraded picnic to v3.0.3. (#838)
* Upgraded picnic to v3.0.2.

* Fix explicit_bzero function.

* Fixed redefinition of AddByte on little endian platforms (picnic's and oqs's namespacing)

* Update picnic to v3.0.3

* Fixing some picnic functions namespacing

* Added namespacing for picnic function on little endian system.

* More picnic namespacing fixes

* More picnic namespacing fixes, round 2

* Added more namespacing prefix

* More picnic namespacing

* Explicit namespacing for KeccakP1600times4_StaticInitialize function
2020-10-22 10:31:51 -04:00