Skip to content

Commit 2b4fe22

Browse files
committed
Cleaned x2
Signed-off-by: Pablo Gutiérrez <pablogf@uma.es>
1 parent 08435be commit 2b4fe22

3 files changed

Lines changed: 8 additions & 70 deletions

File tree

.github/workflows/ct-tooling.yml

Lines changed: 6 additions & 63 deletions
Original file line numberDiff line numberDiff line change
@@ -15,69 +15,21 @@ on:
1515
jobs:
1616
resolve-matrix:
1717
runs-on: ubuntu-latest
18-
<<<<<<< HEAD
19-
permissions:
20-
contents: write
21-
actions: write
22-
steps:
23-
- name: Checkout code
24-
uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # pin@v4
25-
26-
- name: Install Python deps
27-
run: python -m pip install pytest requests
28-
29-
- name: Generate algorithm list
30-
id: set
31-
run: |
32-
python3 - <<'PY'
33-
import os, sys
34-
sys.path.insert(0, 'tests')
35-
import helpers
36-
algs = helpers.available_kems_by_name() + helpers.available_sigs_by_name()
37-
interactive_yaml = (
38-
"fields:\n"
39-
" - label: runtime-options\n"
40-
" properties:\n"
41-
" description: Choose one or more algorithms to execute constant-time testing on\n"
42-
" display: Select the algorithm(s) to execute constant-time testing on\n"
43-
" type: multiselect\n"
44-
" choices:\n"
45-
)
46-
for a in algs:
47-
interactive_yaml += f" - {a}\n"
48-
interactive_yaml += " required: true\n"
49-
with open(os.environ['GITHUB_OUTPUT'], 'a') as gout:
50-
gout.write('interactive<<EOF\n')
51-
gout.write(interactive_yaml)
52-
gout.write('EOF\n')
53-
PY
54-
55-
- name: Example Interactive Inputs Step
56-
id: interactive-inputs
57-
uses: boasiHQ/interactive-inputs@v2
58-
with:
59-
timeout: 300
60-
title: Select algorithm(s) for CT Testing
61-
interactive: ${{ steps.set.outputs.interactive }}
62-
notifier-slack-enabled: "false"
63-
notifier-discord-enabled: "false"
64-
github-token: ${{ github.token }}
65-
ngrok-authtoken: ${{ secrets.NGROK_AUTHTOKEN }}
66-
=======
67-
>>>>>>> user-chooses
6818
outputs:
6919
matrix: ${{ steps.algs.outputs.matrix }}
7020
steps:
7121
- uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # pin@v4
7222
- run: python -m pip install pytest requests
7323
- name: Resolve algorithm list
7424
id: algs
25+
env:
26+
ALGORITHMS_INPUT: ${{ github.event.inputs.algorithms }}
7527
run: |
7628
python3 - <<'PY'
7729
import os, sys, json
7830
sys.path.insert(0, 'tests')
7931
import helpers
80-
requested = "${{ github.event.inputs.algorithms }}".strip()
32+
requested = os.environ["ALGORITHMS_INPUT"].strip()
8133
all_algs = helpers.available_kems_by_name() + helpers.available_sigs_by_name()
8234
requested_set = { a.strip() for a in requested.split(',')}
8335
invalid_algorithms = requested_set - set(all_algs)
@@ -99,24 +51,15 @@ jobs:
9951
algorithm: ${{ fromJson(needs.resolve-matrix.outputs.matrix) }}
10052
compiler: [gcc, clang]
10153
liboqs_build: [generic, auto]
102-
opt_flag: [-O0, -O1, -O2, -O3, -Os, -Ofast, "-O2 -fno-tree-vectorize", "-O3 -fno-tree-vectorize"]
54+
opt_flag: [-O0, -O1, -O2, -O3, -Os, -Ofast, "-O2 -fno-tree-vectorize", "-O3 -fno-tree-vectorize", "-O2 -fno-vectorize", "-O3 -fno-vectorize"]
10355
exclude:
10456
- compiler: clang
10557
opt_flag: "-O2 -fno-tree-vectorize"
10658
- compiler: clang
10759
opt_flag: "-O3 -fno-tree-vectorize"
108-
include:
109-
- compiler: clang
110-
liboqs_build: generic
60+
- compiler: gcc
11161
opt_flag: "-O2 -fno-vectorize"
112-
- compiler: clang
113-
liboqs_build: auto
114-
opt_flag: "-O2 -fno-vectorize"
115-
- compiler: clang
116-
liboqs_build: generic
117-
opt_flag: "-O3 -fno-vectorize"
118-
- compiler: clang
119-
liboqs_build: auto
62+
- compiler: gcc
12063
opt_flag: "-O3 -fno-vectorize"
12164
max-parallel: 5
12265
steps:

CONFIGURE.md

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -19,13 +19,8 @@ The following options can be passed to CMake before the build file generation pr
1919
- [OQS_SPEED_USE_ARM_PMU](#OQS_SPEED_USE_ARM_PMU)
2020
- [USE_COVERAGE](#USE_COVERAGE)
2121
- [USE_SANITIZER](#USE_SANITIZER)
22-
<<<<<<< HEAD
23-
- [OQS_ENABLE_TEST_CONSTANT_TIME](#OQS_ENABLE_TEST_CONSTANT_TIME/OQS_ENABLE_TEST_CONSTANT_TIME_MEMSAN)
24-
- [OQS_ENABLE_TEST_CONSTANT_TIME_MEMSAN](#OQS_ENABLE_TEST_CONSTANT_TIME/OQS_ENABLE_TEST_CONSTANT_TIME_MEMSAN)
25-
=======
2622
- [OQS_ENABLE_TEST_CONSTANT_TIME](#OQS_ENABLE_TEST_CONSTANT_TIME)
2723
- [OQS_ENABLE_TEST_CONSTANT_TIME_MEMSAN](#OQS_ENABLE_TEST_CONSTANT_TIME_MEMSAN)
28-
>>>>>>> user-chooses
2924
- [OQS_STRICT_WARNINGS](#OQS_STRICT_WARNINGS)
3025
- [OQS_EMBEDDED_BUILD](#OQS_EMBEDDED_BUILD)
3126
- [OQS_MEMOPT_BUILD](#OQS_MEMOPT_BUILD)
@@ -244,7 +239,7 @@ This has an effect when the compiler is Clang and when [CMAKE_BUILD_TYPE](#CMAKE
244239

245240
**Default**: Unset.
246241

247-
## OQS_ENABLE_TEST_CONSTANT_TIME/OQS_ENABLE_TEST_CONSTANT_TIME_MEMSAN
242+
## OQS_ENABLE_TEST_CONSTANT_TIME
248243

249244
This is used in conjunction with `tests/test_constant_time.py` to use Valgrind to look for instances of secret-dependent control flow. liboqs must also be compiled with [CMAKE_BUILD_TYPE](#CMAKE_BUILD_TYPE) set to `Debug`.
250245

tests/test_sig.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -163,7 +163,7 @@ static OQS_STATUS sig_test_correctness(const char *method_name, bool bitflips_al
163163
fprintf(stderr, "ERROR: OQS_SIG_verify_with_ctx_str failed\n");
164164
goto err;
165165
}
166-
#endif
166+
167167
if (extended_tests) {
168168
rc = test_sig_bitflip(sig, message, message_len, signature, signature_len, public_key, bitflips_all, bitflips, true, ctx, i);
169169
OQS_TEST_CT_DECLASSIFY(&rc, sizeof rc);

0 commit comments

Comments
 (0)