-
Notifications
You must be signed in to change notification settings - Fork 0
/
test.sh
executable file
·47 lines (31 loc) · 1006 Bytes
/
test.sh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
#!/bin/bash
# generate shared library object
make lib
# ---
mkdir -p tmp
pushd tmp
# download compressed NIST LWC submission of TinyJambu
wget -O tinyjambu.zip https://csrc.nist.gov/CSRC/media/Projects/lightweight-cryptography/documents/finalist-round/updated-submissions/tinyjambu.zip
# uncomress
unzip tinyjambu.zip
# copy Known Answer Tests outside of uncompressed NIST LWC submission directory
cp tinyjambu/Implementations/crypto_aead/tinyjambu128v2/LWC_AEAD_KAT_128_96.txt ../
cp tinyjambu/Implementations/crypto_aead/tinyjambu192v2/LWC_AEAD_KAT_192_96.txt ../
cp tinyjambu/Implementations/crypto_aead/tinyjambu256v2/LWC_AEAD_KAT_256_96.txt ../
popd
# ---
# remove NIST LWC submission zip
rm -rf tmp
# move Known Answer Tests to execution directory
mv LWC_AEAD_KAT_128_96.txt wrapper/python/
mv LWC_AEAD_KAT_192_96.txt wrapper/python/
mv LWC_AEAD_KAT_256_96.txt wrapper/python/
# ---
pushd wrapper/python
# run tests
pytest -v
# clean up
rm LWC_AEAD_KAT_*_96.txt
popd
make clean
# ---