Compare commits
10 Commits
cdb80105c7
...
c28a9c257e
Author | SHA256 | Date | |
---|---|---|---|
c28a9c257e | |||
4ea424f806 | |||
f5b015f854 | |||
2fafa433af | |||
07df1b4de3 | |||
d149b9025a | |||
9be4e2bcfd | |||
012153cb84 | |||
e4523bbc2b | |||
8a3e1b3345 |
16
libpqcrypto-generic-compiler.patch
Normal file
16
libpqcrypto-generic-compiler.patch
Normal file
@@ -0,0 +1,16 @@
|
||||
Index: libpqcrypto-20180314/compilers/c
|
||||
===================================================================
|
||||
--- libpqcrypto-20180314.orig/compilers/c
|
||||
+++ libpqcrypto-20180314/compilers/c
|
||||
@@ -1,2 +1,2 @@
|
||||
-gcc -fPIC -Wall -march=native -mtune=native -O3 -fomit-frame-pointer -fwrapv
|
||||
-clang -fPIC -Wall -march=native -mtune=native -O3 -fomit-frame-pointer -fwrapv
|
||||
+gcc -fPIC -Wall -O3 -fomit-frame-pointer -fwrapv
|
||||
+clang -fPIC -Wall -O3 -fomit-frame-pointer -fwrapv
|
||||
Index: libpqcrypto-20180314/compilers/cpp
|
||||
===================================================================
|
||||
--- libpqcrypto-20180314.orig/compilers/cpp
|
||||
+++ libpqcrypto-20180314/compilers/cpp
|
||||
@@ -1 +1 @@
|
||||
-g++ -march=native -mtune=native -O3 -fomit-frame-pointer -fwrapv
|
||||
+g++ -O3 -fomit-frame-pointer -fwrapv
|
@@ -629,3 +629,111 @@ Index: libpqcrypto-20180314/crypto_kem/ntruhrss701/avx2/square_3_701_patience.S
|
||||
pop %r15
|
||||
ret
|
||||
+.section .note.GNU-stack,"",%progbits
|
||||
Index: libpqcrypto-20180314/crypto_kem/mceliece8192128/avx/syndrome_asm.S
|
||||
===================================================================
|
||||
--- libpqcrypto-20180314.orig/crypto_kem/mceliece8192128/avx/syndrome_asm.S
|
||||
+++ libpqcrypto-20180314/crypto_kem/mceliece8192128/avx/syndrome_asm.S
|
||||
@@ -1459,3 +1459,4 @@ movdqu %xmm0,192(%rdi)
|
||||
# qhasm: return
|
||||
add %r11,%rsp
|
||||
ret
|
||||
+.section .note.GNU-stack,"",%progbits
|
||||
Index: libpqcrypto-20180314/crypto_kem/mceliece8192128/avx/transpose_64x128_sp_asm.S
|
||||
===================================================================
|
||||
--- libpqcrypto-20180314.orig/crypto_kem/mceliece8192128/avx/transpose_64x128_sp_asm.S
|
||||
+++ libpqcrypto-20180314/crypto_kem/mceliece8192128/avx/transpose_64x128_sp_asm.S
|
||||
@@ -8145,3 +8145,4 @@ movdqa %xmm1,1008(%rdi)
|
||||
# qhasm: return
|
||||
add %r11,%rsp
|
||||
ret
|
||||
+.section .note.GNU-stack,"",%progbits
|
||||
Index: libpqcrypto-20180314/crypto_kem/mceliece8192128/avx/vec256_ama_asm.S
|
||||
===================================================================
|
||||
--- libpqcrypto-20180314.orig/crypto_kem/mceliece8192128/avx/vec256_ama_asm.S
|
||||
+++ libpqcrypto-20180314/crypto_kem/mceliece8192128/avx/vec256_ama_asm.S
|
||||
@@ -2322,3 +2322,4 @@ vmovupd %ymm0,0(%rsi)
|
||||
# qhasm: return
|
||||
add %r11,%rsp
|
||||
ret
|
||||
+.section .note.GNU-stack,"",%progbits
|
||||
Index: libpqcrypto-20180314/crypto_kem/mceliece8192128/avx/vec256_maa_asm.S
|
||||
===================================================================
|
||||
--- libpqcrypto-20180314.orig/crypto_kem/mceliece8192128/avx/vec256_maa_asm.S
|
||||
+++ libpqcrypto-20180314/crypto_kem/mceliece8192128/avx/vec256_maa_asm.S
|
||||
@@ -2322,3 +2322,4 @@ vmovupd %ymm0,0(%rsi)
|
||||
# qhasm: return
|
||||
add %r11,%rsp
|
||||
ret
|
||||
+.section .note.GNU-stack,"",%progbits
|
||||
Index: libpqcrypto-20180314/crypto_kem/mceliece8192128/avx/vec256_mul_asm.S
|
||||
===================================================================
|
||||
--- libpqcrypto-20180314.orig/crypto_kem/mceliece8192128/avx/vec256_mul_asm.S
|
||||
+++ libpqcrypto-20180314/crypto_kem/mceliece8192128/avx/vec256_mul_asm.S
|
||||
@@ -2127,3 +2127,4 @@ vmovupd %ymm3,0(%rdi)
|
||||
# qhasm: return
|
||||
add %r11,%rsp
|
||||
ret
|
||||
+.section .note.GNU-stack,"",%progbits
|
||||
Index: libpqcrypto-20180314/crypto_scalarmult/x25519notpq/athlon/todouble.S
|
||||
===================================================================
|
||||
--- libpqcrypto-20180314.orig/crypto_scalarmult/x25519notpq/athlon/todouble.S
|
||||
+++ libpqcrypto-20180314/crypto_scalarmult/x25519notpq/athlon/todouble.S
|
||||
@@ -142,3 +142,4 @@ faddp %st(0),%st(1)
|
||||
fstpl 72(%ecx)
|
||||
add %eax,%esp
|
||||
ret
|
||||
+.section .note.GNU-stack,"",%progbits
|
||||
Index: libpqcrypto-20180314/crypto_scalarmult/x25519notpq/athlon/const.S
|
||||
===================================================================
|
||||
--- libpqcrypto-20180314.orig/crypto_scalarmult/x25519notpq/athlon/const.S
|
||||
+++ libpqcrypto-20180314/crypto_scalarmult/x25519notpq/athlon/const.S
|
||||
@@ -149,3 +149,4 @@ out9offset:
|
||||
rounding:
|
||||
.byte 0x7f
|
||||
.byte 0x13
|
||||
+.section .note.GNU-stack,"",%progbits
|
||||
Index: libpqcrypto-20180314/crypto_scalarmult/x25519notpq/athlon/fromdouble.S
|
||||
===================================================================
|
||||
--- libpqcrypto-20180314.orig/crypto_scalarmult/x25519notpq/athlon/fromdouble.S
|
||||
+++ libpqcrypto-20180314/crypto_scalarmult/x25519notpq/athlon/fromdouble.S
|
||||
@@ -193,3 +193,4 @@ movl %edx,28(%ecx)
|
||||
movl 0(%esp),%ebp
|
||||
add %eax,%esp
|
||||
ret
|
||||
+.section .note.GNU-stack,"",%progbits
|
||||
Index: libpqcrypto-20180314/crypto_scalarmult/x25519notpq/athlon/init.S
|
||||
===================================================================
|
||||
--- libpqcrypto-20180314.orig/crypto_scalarmult/x25519notpq/athlon/init.S
|
||||
+++ libpqcrypto-20180314/crypto_scalarmult/x25519notpq/athlon/init.S
|
||||
@@ -11,3 +11,4 @@ sub %eax,%esp
|
||||
fldcw rounding
|
||||
add %eax,%esp
|
||||
ret
|
||||
+.section .note.GNU-stack,"",%progbits
|
||||
Index: libpqcrypto-20180314/crypto_scalarmult/x25519notpq/athlon/mainloop.S
|
||||
===================================================================
|
||||
--- libpqcrypto-20180314.orig/crypto_scalarmult/x25519notpq/athlon/mainloop.S
|
||||
+++ libpqcrypto-20180314/crypto_scalarmult/x25519notpq/athlon/mainloop.S
|
||||
@@ -3988,3 +3988,4 @@ movl 172(%ecx),%edi
|
||||
movl 176(%ecx),%ebp
|
||||
add %eax,%esp
|
||||
ret
|
||||
+.section .note.GNU-stack,"",%progbits
|
||||
Index: libpqcrypto-20180314/crypto_scalarmult/x25519notpq/athlon/mult.S
|
||||
===================================================================
|
||||
--- libpqcrypto-20180314.orig/crypto_scalarmult/x25519notpq/athlon/mult.S
|
||||
+++ libpqcrypto-20180314/crypto_scalarmult/x25519notpq/athlon/mult.S
|
||||
@@ -408,3 +408,4 @@ fstpl 72(%ecx)
|
||||
movl 0(%esp),%ebp
|
||||
add %eax,%esp
|
||||
ret
|
||||
+.section .note.GNU-stack,"",%progbits
|
||||
Index: libpqcrypto-20180314/crypto_scalarmult/x25519notpq/athlon/square.S
|
||||
===================================================================
|
||||
--- libpqcrypto-20180314.orig/crypto_scalarmult/x25519notpq/athlon/square.S
|
||||
+++ libpqcrypto-20180314/crypto_scalarmult/x25519notpq/athlon/square.S
|
||||
@@ -296,3 +296,4 @@ fstpl 64(%ecx)
|
||||
fstpl 72(%ecx)
|
||||
add %eax,%esp
|
||||
ret
|
||||
+.section .note.GNU-stack,"",%progbits
|
||||
|
@@ -1,5 +1,17 @@
|
||||
-------------------------------------------------------------------
|
||||
Wed Feb 8 09:57:07 UTC 2023 - Jan Engelhardt <jengelh@inai.de>
|
||||
|
||||
- Trim history lesson and author lists from the package
|
||||
software description.
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Mon Dec 5 13:45:32 UTC 2022 - Marcus Meissner <meissner@suse.com>
|
||||
|
||||
- imported the libpbcrypto library, version 20180314
|
||||
- libpqcrypto-shortertimeouts.patch: avoid 1 hour timeouts, go down to 10 minutes
|
||||
- libpqcrypto-shortertimeouts.patch: avoid 1 hour timeouts, go
|
||||
down to 10 minutes
|
||||
- libpqcrypto-gnu-stack.patch: tag assembly with GNU.stack notes
|
||||
- libpqcrypto-generic-compiler.patch: avoid -mtune=native
|
||||
-march=native, as we want generic binaries
|
||||
- NOTE: Not all is built, the build does not really fail if
|
||||
something fails, it will just not included it
|
||||
|
@@ -27,23 +27,25 @@ Url: https://libpqcrypto.org/
|
||||
Source: https://libpqcrypto.org/libpqcrypto-%version.tar.gz
|
||||
Patch0: libpqcrypto-shortertimeouts.patch
|
||||
Patch1: libpqcrypto-gnu-stack.patch
|
||||
Patch2: libpqcrypto-generic-compiler.patch
|
||||
BuildRequires: libopenssl-devel
|
||||
BuildRequires: gmp-devel
|
||||
BuildRequires: clang
|
||||
BuildRequires: python3
|
||||
|
||||
%description
|
||||
libpqcrypto is a new cryptographic software library produced by the PQCRYPTO project.
|
||||
libpqcrypto is a cryptographic software library with software from
|
||||
the PQCRYPTO NIST proposals.
|
||||
|
||||
PQCRYPTO, working jointly with many other researchers around the world,
|
||||
submitted 22 proposals to NIST's ongoing post-quantum standardization
|
||||
project. Each submission specifies a family of cryptographic systems,
|
||||
offering various tradeoffs between performance and security. Each
|
||||
submission includes software: a (portable) reference C implementation,
|
||||
and in many cases additional (not necessarily portable) implementations
|
||||
providing better performance (often using assembly language or
|
||||
"intrinsics"). libpqcrypto includes software for the following 77
|
||||
cryptographic systems (50 signature systems and 27 encryption systems)
|
||||
from 19 of the 22 PQCRYPTO submissions:
|
||||
%package -n libpqcrypto1
|
||||
Summary: Cryptographic software library produced by the PQCRYPTO project
|
||||
Group: System/Libraries
|
||||
Provides: %{name} = %{version}-%{release}
|
||||
Obsoletes: %{name} < %{version}-%{release}
|
||||
|
||||
%description -n libpqcrypto1
|
||||
libpqcrypto is a cryptographic software library with software from
|
||||
the PQCRYPTO NIST proposals, with:
|
||||
|
||||
- BIG QUAKE: crypto_kem_bigquake{1,3,5}
|
||||
- Classic McEliece: crypto_kem_mceliece{6960119,8192128}
|
||||
@@ -65,60 +67,34 @@ from 19 of the 22 PQCRYPTO submissions:
|
||||
- SABER: crypto_kem_{firesaber,lightsaber,saber}
|
||||
- SPHINCS+: crypto_sign_sphincs{f,s}{128,192,256}{haraka,sha256,shake256}
|
||||
|
||||
libpqcrypto collects this software into an integrated library, with
|
||||
|
||||
- a unified compilation framework,
|
||||
- an automatic test framework,
|
||||
- automatic selection of the fastest implementation of each system,
|
||||
- a unified C interface following the NaCl/TweetNaCl/SUPERCOP/libsodium API,
|
||||
- a unified Python interface,
|
||||
- command-line signature/verification/encryption/decryption tools, and
|
||||
- command-line benchmarking tools.
|
||||
|
||||
libpqcrypto also integrates some symmetric-crypto software from
|
||||
SUPERCOP, including the AES-256-CTR stream cipher (an OpenSSL wrapper
|
||||
and a separate implementation from Romain Dolbeau), the Salsa20-256 and
|
||||
ChaCha20-256 stream ciphers (implementations from Daniel J. Bernstein,
|
||||
Romain Dolbeau, Martin Goll, Shay Gueron, Ted Krovetz, Tanja Lange, Andrew
|
||||
Moon, Samuel Neves, and Peter Schwabe), the Poly1305 MAC (implementations
|
||||
from Daniel J. Bernstein, Billy Brumley, Andrew Moon, and Peter Schwabe),
|
||||
the SHA-512 hash function (an OpenSSL wrapper, a separate implementation
|
||||
from Daniel J. Bernstein, and a separate implementation from Thomas Pornin
|
||||
via sphlib), portions of the Keccak Code Package (from Guido Bertoni,
|
||||
Joan Daemen, Michaël Peeters, Gilles Van Assche, and Ronny Van Keer),
|
||||
and the SHAKE256 hash function (a KCP wrapper and implementations from
|
||||
David Leon Gil). For credits regarding the public-key software, see the
|
||||
individual submission packages to NIST.
|
||||
|
||||
Beware that the components of libpqcrypto vary in licenses. Some parts are in the public domain, but others are not.
|
||||
|
||||
%package -n libpqcrypto1
|
||||
Summary: Cryptographic software library produced by the PQCRYPTO project
|
||||
Group: System/Libraries
|
||||
Provides: %{name} = %{version}-%{release}
|
||||
Obsoletes: %{name} < %{version}-%{release}
|
||||
|
||||
%description -n libpqcrypto1
|
||||
libpqcrypto is a new cryptographic software library produced by the PQCRYPTO project.
|
||||
libpqcrypto integrates some symmetric-crypto software from SUPERCOP,
|
||||
including AES-256-CTR, Salsa20-256, ChaCha20-256, Poly1305, SHA-512,
|
||||
portions of Keccak, and SHAKE256.
|
||||
|
||||
This is the shared library of the pqcrypto package.
|
||||
|
||||
|
||||
%package devel
|
||||
Summary: Cryptographic software library produced by the PQCRYPTO project
|
||||
Group: Development/Languages/C and C++
|
||||
Requires: libpqcrypto1 = %{version}
|
||||
|
||||
%description devel
|
||||
libpqcrypto is a new cryptographic software library produced by the PQCRYPTO project.
|
||||
libpqcrypto is a cryptographic software library with software from
|
||||
the PQCRYPTO NIST proposals.
|
||||
|
||||
This is the development package of the pqcrypto package.
|
||||
%package examples
|
||||
Summary: Examples for the library produced by the PQCRYPTO project
|
||||
Group: Development/Languages/C and C++
|
||||
Requires: libpqcrypto1 = %{version}
|
||||
|
||||
%description examples
|
||||
libpqcrypto is a cryptographic software library with software from
|
||||
the PQCRYPTO NIST proposals.
|
||||
|
||||
This packages contain example tools using the library.
|
||||
|
||||
%prep
|
||||
%setup -q
|
||||
%patch0 -p1
|
||||
%patch1 -p1
|
||||
%autosetup -p1
|
||||
|
||||
%build
|
||||
./do
|
||||
@@ -137,14 +113,14 @@ mv link-install/run-20180314/*/lib/0/lib* %buildroot/%_libdir
|
||||
%postun -n libpqcrypto1 -p /sbin/ldconfig
|
||||
|
||||
%files -n libpqcrypto1
|
||||
%defattr(-,root,root)
|
||||
/%{_libdir}/libpqcrypto.so.1
|
||||
|
||||
%files devel
|
||||
%defattr(-,root,root)
|
||||
%{_includedir}/*
|
||||
/%{_libdir}/libpqcrypto.so
|
||||
/%{_libdir}/libpqcrypto.a
|
||||
|
||||
#files examples
|
||||
#dir /%{_libdir}/%name
|
||||
#/%{_libdir}/%name/*
|
||||
|
||||
|
Reference in New Issue
Block a user