Skip to content

Commit

Permalink
Run copy_from_upstream
Browse files Browse the repository at this point in the history
  • Loading branch information
SWilson4 committed Sep 12, 2023
1 parent 68912bc commit a236605
Show file tree
Hide file tree
Showing 776 changed files with 29,308 additions and 1,224 deletions.
2 changes: 1 addition & 1 deletion docs/algorithms/kem/classic_mceliece.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
- **Authors' website**: https://classic.mceliece.org
- **Specification version**: SUPERCOP-20221025.
- **Primary Source**<a name="primary-source"></a>:
- **Source**: https://github.com/PQClean/PQClean/commit/ef80f51badac27b78f8e0ef26f23cbd71ca0f283
- **Source**: https://github.com/PQClean/PQClean/commit/8e220a87308154d48fdfac40abbb191ac7fce06a
- **Implementation license (SPDX-Identifier)**: Public domain
- **Ancestors of primary source**:
- SUPERCOP-20221025 "clean" and "avx2" implementations
Expand Down
2 changes: 1 addition & 1 deletion docs/algorithms/kem/classic_mceliece.yml
Original file line number Diff line number Diff line change
Expand Up @@ -375,4 +375,4 @@ parameter-sets:
auxiliary-submitters: []
primary-upstream:
spdx-license-identifier: Public domain
source: https://github.com/PQClean/PQClean/commit/ef80f51badac27b78f8e0ef26f23cbd71ca0f283
source: https://github.com/PQClean/PQClean/commit/8e220a87308154d48fdfac40abbb191ac7fce06a
2 changes: 1 addition & 1 deletion docs/algorithms/kem/hqc.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
- **Authors' website**: https://pqc-hqc.org/
- **Specification version**: NIST Round 3 submission.
- **Primary Source**<a name="primary-source"></a>:
- **Source**: https://github.com/PQClean/PQClean/commit/ef80f51badac27b78f8e0ef26f23cbd71ca0f283
- **Source**: https://github.com/PQClean/PQClean/commit/8e220a87308154d48fdfac40abbb191ac7fce06a
- **Implementation license (SPDX-Identifier)**: Public domain
- **Ancestors of primary source**:
- https://github.com/jschanck/package-pqclean/tree/29f79e72/hqc, which takes it from:
Expand Down
2 changes: 1 addition & 1 deletion docs/algorithms/kem/hqc.yml
Original file line number Diff line number Diff line change
Expand Up @@ -125,4 +125,4 @@ parameter-sets:
upstream: primary-upstream
primary-upstream:
spdx-license-identifier: Public domain
source: https://github.com/PQClean/PQClean/commit/ef80f51badac27b78f8e0ef26f23cbd71ca0f283
source: https://github.com/PQClean/PQClean/commit/8e220a87308154d48fdfac40abbb191ac7fce06a
2 changes: 1 addition & 1 deletion docs/algorithms/kem/kyber.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
- **Implementation license (SPDX-Identifier)**: CC0-1.0 or Apache-2.0
- **Optimized Implementation sources**: https://github.com/pq-crystals/kyber/commit/518de2414a85052bb91349bcbcc347f391292d5b with copy_from_upstream patches
- **pqclean-aarch64**:<a name="pqclean-aarch64"></a>
- **Source**: https://github.com/PQClean/PQClean/commit/ef80f51badac27b78f8e0ef26f23cbd71ca0f283 with copy_from_upstream patches
- **Source**: https://github.com/PQClean/PQClean/commit/8e220a87308154d48fdfac40abbb191ac7fce06a with copy_from_upstream patches
- **Implementation license (SPDX-Identifier)**: CC0-1.0 and (CC0-1.0 or Apache-2.0) and (CC0-1.0 or MIT) and MIT


Expand Down
2 changes: 1 addition & 1 deletion docs/algorithms/kem/kyber.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ primary-upstream:
spdx-license-identifier: CC0-1.0 or Apache-2.0
optimized-upstreams:
pqclean-aarch64:
source: https://github.com/PQClean/PQClean/commit/ef80f51badac27b78f8e0ef26f23cbd71ca0f283
source: https://github.com/PQClean/PQClean/commit/8e220a87308154d48fdfac40abbb191ac7fce06a
with copy_from_upstream patches
spdx-license-identifier: CC0-1.0 and (CC0-1.0 or Apache-2.0) and (CC0-1.0 or MIT)
and MIT
Expand Down
2 changes: 1 addition & 1 deletion docs/algorithms/sig/dilithium.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
- **Implementation license (SPDX-Identifier)**: CC0-1.0 or Apache-2.0
- **Optimized Implementation sources**: https://github.com/pq-crystals/dilithium/commit/3e9b9f1412f6c7435dbeb4e10692ea58f181ee51 with copy_from_upstream patches
- **pqclean-aarch64**:<a name="pqclean-aarch64"></a>
- **Source**: https://github.com/PQClean/PQClean/commit/ef80f51badac27b78f8e0ef26f23cbd71ca0f283 with copy_from_upstream patches
- **Source**: https://github.com/PQClean/PQClean/commit/8e220a87308154d48fdfac40abbb191ac7fce06a with copy_from_upstream patches
- **Implementation license (SPDX-Identifier)**: CC0-1.0 and (CC0-1.0 or Apache-2.0) and (CC0-1.0 or MIT) and MIT


Expand Down
2 changes: 1 addition & 1 deletion docs/algorithms/sig/dilithium.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ primary-upstream:
spdx-license-identifier: CC0-1.0 or Apache-2.0
optimized-upstreams:
pqclean-aarch64:
source: https://github.com/PQClean/PQClean/commit/ef80f51badac27b78f8e0ef26f23cbd71ca0f283
source: https://github.com/PQClean/PQClean/commit/8e220a87308154d48fdfac40abbb191ac7fce06a
with copy_from_upstream patches
spdx-license-identifier: CC0-1.0 and (CC0-1.0 or Apache-2.0) and (CC0-1.0 or MIT)
and MIT
Expand Down
2 changes: 1 addition & 1 deletion docs/algorithms/sig/falcon.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
- **Authors' website**: https://falcon-sign.info
- **Specification version**: 20211101.
- **Primary Source**<a name="primary-source"></a>:
- **Source**: https://github.com/PQClean/PQClean/commit/ef80f51badac27b78f8e0ef26f23cbd71ca0f283
- **Source**: https://github.com/PQClean/PQClean/commit/8e220a87308154d48fdfac40abbb191ac7fce06a
- **Implementation license (SPDX-Identifier)**: MIT


Expand Down
2 changes: 1 addition & 1 deletion docs/algorithms/sig/falcon.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ website: https://falcon-sign.info
nist-round: 3
spec-version: 20211101
primary-upstream:
source: https://github.com/PQClean/PQClean/commit/ef80f51badac27b78f8e0ef26f23cbd71ca0f283
source: https://github.com/PQClean/PQClean/commit/8e220a87308154d48fdfac40abbb191ac7fce06a
spdx-license-identifier: MIT
upstream-ancestors:
- https://www.falcon-sign.info
Expand Down
2 changes: 1 addition & 1 deletion docs/algorithms/sig/sphincs.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
- **Authors' website**: https://sphincs.org/
- **Specification version**: NIST Round 3 submission, v3.1 (June 10, 2022).
- **Primary Source**<a name="primary-source"></a>:
- **Source**: https://github.com/PQClean/PQClean/commit/ef80f51badac27b78f8e0ef26f23cbd71ca0f283 with copy_from_upstream patches
- **Source**: https://github.com/PQClean/PQClean/commit/8e220a87308154d48fdfac40abbb191ac7fce06a with copy_from_upstream patches
- **Implementation license (SPDX-Identifier)**: CC0-1.0


Expand Down
2 changes: 1 addition & 1 deletion docs/algorithms/sig/sphincs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ nist-round: 3
spec-version: NIST Round 3 submission, v3.1 (June 10, 2022)
spdx-license-identifier: CC0-1.0
primary-upstream:
source: https://github.com/PQClean/PQClean/commit/ef80f51badac27b78f8e0ef26f23cbd71ca0f283
source: https://github.com/PQClean/PQClean/commit/8e220a87308154d48fdfac40abbb191ac7fce06a
with copy_from_upstream patches
spdx-license-identifier: CC0-1.0
upstream-ancestors:
Expand Down
1 change: 0 additions & 1 deletion src/kem/classic_mceliece/pqclean_mceliece348864_avx2/api.h
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@
#define PQCLEAN_MCELIECE348864_AVX2_CRYPTO_CIPHERTEXTBYTES 96
#define PQCLEAN_MCELIECE348864_AVX2_CRYPTO_BYTES 32


int PQCLEAN_MCELIECE348864_AVX2_crypto_kem_enc(
uint8_t *c,
uint8_t *key,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -286,4 +286,3 @@ void benes(uint64_t *r, uint64_t cond[][32], int rev) {

transpose_64x64(bs);
}

2 changes: 0 additions & 2 deletions src/kem/classic_mceliece/pqclean_mceliece348864_avx2/benes.h
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@
This file is for Benes network related functions
*/


#include "namespace.h"

#define benes CRYPTO_NAMESPACE(benes)
Expand All @@ -16,4 +15,3 @@ void load_bits(uint64_t out[][32], const unsigned char *bits);
void benes(uint64_t *r, uint64_t cond[][32], int rev);

#endif

1 change: 0 additions & 1 deletion src/kem/classic_mceliece/pqclean_mceliece348864_avx2/bm.c
Original file line number Diff line number Diff line change
Expand Up @@ -224,4 +224,3 @@ void bm(uint64_t out[ GFBITS ], vec128 in[ GFBITS ]) {

vec_mul_sp(out, out, &BC[0][0]);
}

2 changes: 0 additions & 2 deletions src/kem/classic_mceliece/pqclean_mceliece348864_avx2/bm.h
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@
see https://ieeexplore.ieee.org/document/87857
*/


#include "namespace.h"

#define bm CRYPTO_NAMESPACE(bm)
Expand All @@ -15,4 +14,3 @@
void bm(uint64_t out[GFBITS], vec128 in[GFBITS]);

#endif

Original file line number Diff line number Diff line change
Expand Up @@ -84,4 +84,3 @@ MASK5_0:
.quad 0x00000000FFFFFFFF, 0x00000000FFFFFFFF, 0x00000000FFFFFFFF, 0x00000000FFFFFFFF
MASK5_1:
.quad 0xFFFFFFFF00000000, 0xFFFFFFFF00000000, 0xFFFFFFFF00000000, 0xFFFFFFFF00000000

Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@
#include "crypto_declassify.h"
#include "int32_sort.h"
#include <string.h>
#include <assert.h>
typedef int16_t int16;
typedef int32_t int32;
#include "crypto_int32.h"
Expand Down Expand Up @@ -182,8 +181,7 @@ static void cbrecursion(unsigned char *out, long long pos, long long step, const
/* output: the result of apply the control bits to p */
static void layer(int16_t *p, const unsigned char *cb, int s, int n) {
int i, j;
assert(s < 255);
int stride = 1 << (uint8_t)s;
int stride = 1 << (uint8_t)(s & 0x1F);
int index = 0;
int16_t d, m;

Expand Down Expand Up @@ -247,4 +245,3 @@ void controlbitsfrompermutation(unsigned char *out, const int16 *pi, long long w
}
}
}

Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,8 @@
/* See David Nassimi, Sartaj Sahni "Parallel algorithms to set up the Benes permutationnetwork" */
/* See also https://cr.yp.to/papers/controlbits-20200923.pdf */


#include "namespace.h"


#define controlbitsfrompermutation CRYPTO_NAMESPACE(controlbitsfrompermutation)

#include <inttypes.h>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,7 @@
#define crypto_hash_32b(out, in, inlen) \
shake256(out, 32, in, inlen)


#define shake(out,outlen,in,inlen) \
shake256(out, outlen, in, inlen)


#endif
Original file line number Diff line number Diff line change
Expand Up @@ -57,4 +57,3 @@ void crypto_uint16_minmax(crypto_uint16 *crypto_uint16_a, crypto_uint16 *crypto_
*crypto_uint16_a = crypto_uint16_x ^ crypto_uint16_z;
*crypto_uint16_b = crypto_uint16_y ^ crypto_uint16_z;
}

Original file line number Diff line number Diff line change
Expand Up @@ -57,4 +57,3 @@ void crypto_uint32_minmax(crypto_uint32 *crypto_uint32_a, crypto_uint32 *crypto_
*crypto_uint32_a = crypto_uint32_x ^ crypto_uint32_z;
*crypto_uint32_b = crypto_uint32_y ^ crypto_uint32_z;
}

Original file line number Diff line number Diff line change
Expand Up @@ -57,4 +57,3 @@ void crypto_uint64_minmax(crypto_uint64 *crypto_uint64_a, crypto_uint64 *crypto_
*crypto_uint64_a = crypto_uint64_x ^ crypto_uint64_z;
*crypto_uint64_b = crypto_uint64_y ^ crypto_uint64_z;
}

Original file line number Diff line number Diff line change
Expand Up @@ -229,7 +229,5 @@ int decrypt(unsigned char *e, const unsigned char *sk, const unsigned char *s) {

check_weight = weight_check(e, error128);


return 1 - (check_synd & check_weight);
}

Original file line number Diff line number Diff line change
Expand Up @@ -4,12 +4,10 @@
This file is for Niederreiter decryption
*/


#include "namespace.h"

#define decrypt CRYPTO_NAMESPACE(decrypt)

int decrypt(unsigned char *e, const unsigned char *sk, const unsigned char *s);

#endif

Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@
This file is for Niederreiter encryption
*/


#include "util.h"
#include "crypto_declassify.h"
#include "crypto_uint16.h"
Expand Down Expand Up @@ -115,7 +114,5 @@ static void gen_e(unsigned char *e) {
void encrypt(unsigned char *s, const unsigned char *pk, unsigned char *e) {
gen_e(e);


syndrome_asm(s, pk, e);
}

Original file line number Diff line number Diff line change
Expand Up @@ -4,12 +4,10 @@
This file is for Niederreiter encryption
*/


#include "namespace.h"

#define encrypt CRYPTO_NAMESPACE(encrypt)

void encrypt(unsigned char *s, const unsigned char *pk, unsigned char *e);

#endif

1 change: 0 additions & 1 deletion src/kem/classic_mceliece/pqclean_mceliece348864_avx2/fft.c
Original file line number Diff line number Diff line change
Expand Up @@ -172,4 +172,3 @@ void fft(vec256 out[][ GFBITS ], uint64_t *in) {
radix_conversions(in);
butterflies(out, in);
}

2 changes: 0 additions & 2 deletions src/kem/classic_mceliece/pqclean_mceliece348864_avx2/fft.h
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@
sse http://www.math.clemson.edu/~sgao/papers/GM10.pdf
*/


#include "namespace.h"

#define fft CRYPTO_NAMESPACE(fft)
Expand All @@ -18,4 +17,3 @@
void fft(vec256 out[][GFBITS], uint64_t *in);

#endif

Original file line number Diff line number Diff line change
Expand Up @@ -355,4 +355,3 @@ void fft_tr(vec128 out[GFBITS], vec256 in[][ GFBITS ]) {
butterflies_tr(out, in);
radix_conversions_tr(out);
}

2 changes: 0 additions & 2 deletions src/kem/classic_mceliece/pqclean_mceliece348864_avx2/fft_tr.h
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@
This file is for transpose of the Gao-Mateer FFT
*/


#include "namespace.h"

#define fft_tr CRYPTO_NAMESPACE(fft_tr)
Expand All @@ -15,4 +14,3 @@
void fft_tr(vec128 out[GFBITS], vec256 in[][ GFBITS ]);

#endif

1 change: 0 additions & 1 deletion src/kem/classic_mceliece/pqclean_mceliece348864_avx2/gf.c
Original file line number Diff line number Diff line change
Expand Up @@ -136,4 +136,3 @@ void GF_mul(gf *out, gf *in0, gf *in1) {
out[i] = prod[i];
}
}

2 changes: 0 additions & 2 deletions src/kem/classic_mceliece/pqclean_mceliece348864_avx2/gf.h
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@
This file is for functions for field arithmetic
*/


#include "namespace.h"

#define gf_add CRYPTO_NAMESPACE(gf_add)
Expand Down Expand Up @@ -60,4 +59,3 @@ static inline uint64_t gf_mul2(gf a, gf b0, gf b1) {
}

#endif

Original file line number Diff line number Diff line change
Expand Up @@ -51,4 +51,3 @@ static void int32_sort(int32_t *x, long long n) {
}

#endif

Original file line number Diff line number Diff line change
Expand Up @@ -148,4 +148,3 @@ int crypto_kem_keypair

return 0;
}

Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@

#include "namespace.h"


#include "crypto_kem.h"

int crypto_kem_enc(
Expand All @@ -25,4 +24,3 @@ int crypto_kem_keypair
);

#endif

2 changes: 0 additions & 2 deletions src/kem/classic_mceliece/pqclean_mceliece348864_avx2/params.h
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@

#include "namespace.h"


#define GFBITS 12
#define SYS_N 3488
#define SYS_T 64
Expand All @@ -20,4 +19,3 @@
#define GFMASK ((1 << GFBITS) - 1)

#endif

Original file line number Diff line number Diff line change
Expand Up @@ -393,4 +393,3 @@ int pk_gen(unsigned char *pk, const unsigned char *irr, const uint32_t *perm, in

return 0;
}

2 changes: 0 additions & 2 deletions src/kem/classic_mceliece/pqclean_mceliece348864_avx2/pk_gen.h
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@
This file is for public-key generation
*/


#include "namespace.h"

#define pk_gen CRYPTO_NAMESPACE(pk_gen)
Expand All @@ -14,4 +13,3 @@
int pk_gen(unsigned char *pk, const unsigned char *irr, const uint32_t *perm, int16_t *pi);

#endif

Original file line number Diff line number Diff line change
Expand Up @@ -144,4 +144,3 @@ int genpoly_gen(gf *out, gf *f) {

return 0;
}

2 changes: 0 additions & 2 deletions src/kem/classic_mceliece/pqclean_mceliece348864_avx2/sk_gen.h
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@
This file is for secret-key generation
*/


#include "namespace.h"

#define genpoly_gen CRYPTO_NAMESPACE(genpoly_gen)
Expand All @@ -16,4 +15,3 @@
int genpoly_gen(gf *out, gf *f);

#endif

Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@
This file is for matrix transposition
*/


#include "namespace.h"

#define transpose_64x128_sp_asm CRYPTO_NAMESPACE(transpose_64x128_sp_asm)
Expand All @@ -28,4 +27,3 @@ static inline void transpose_64x256_sp(vec256 *in) {
}

#endif

Loading

0 comments on commit a236605

Please sign in to comment.