From 0f7428c5abb9f64363c50f37f25dfbf833cf80e4 Mon Sep 17 00:00:00 2001 From: Doug Chapman Date: Thu, 30 May 2024 17:52:41 +0000 Subject: [PATCH] Move some utility path manipulation out of the pq integ test --- codebuild/bin/s2n_setup_env.sh | 4 +++- flake.lock | 8 ++++---- flake.nix | 4 ++-- tests/integrationv2/test_pq_handshake.py | 8 -------- 4 files changed, 9 insertions(+), 15 deletions(-) diff --git a/codebuild/bin/s2n_setup_env.sh b/codebuild/bin/s2n_setup_env.sh index 9f78662db33..a629c09ef8a 100755 --- a/codebuild/bin/s2n_setup_env.sh +++ b/codebuild/bin/s2n_setup_env.sh @@ -157,8 +157,10 @@ fi export LIBFUZZER_ROOT=$LIBFUZZER_INSTALL_DIR #check if the path contains test dep X, if not and X exists, add to path -path_overrides="$PYTHON_INSTALL_DIR/bin +path_overrides="$AWSLC_INSTALL_DIR/bin +$PYTHON_INSTALL_DIR/bin $OPENSSL_1_1_1_INSTALL_DIR/bin +$OQS_OPENSSL_1_1_1_INSTALL_DIR/bin $SAW_INSTALL_DIR/bin $Z3_INSTALL_DIR/bin $SCAN_BUILD_INSTALL_DIR/bin diff --git a/flake.lock b/flake.lock index e291e6e33e1..5febdda6be8 100644 --- a/flake.lock +++ b/flake.lock @@ -7,16 +7,16 @@ "nixpkgs": "nixpkgs_2" }, "locked": { - "lastModified": 1682462803, - "narHash": "sha256-qKA3iGUzU44Tim9v8HlBn0YIQOVI6hGSDDSZK0NDgGw=", + "lastModified": 1717024791, + "narHash": "sha256-iexbdh5oFLyqORor19II03e34SCH1LtR0po8oTB4zJM=", "owner": "dougch", "repo": "aws-lc", - "rev": "1b841e7ccda1b8cd9cf43ce9152b4a9d7ece54f1", + "rev": "f0ff570c1d098f94155ff14465be0212d4153369", "type": "github" }, "original": { "owner": "dougch", - "ref": "nix", + "ref": "nixv1.17.4", "repo": "aws-lc", "type": "github" } diff --git a/flake.nix b/flake.nix index 92fcbd69e5d..aa4f8200d28 100644 --- a/flake.nix +++ b/flake.nix @@ -3,7 +3,7 @@ inputs.nixpkgs.url = "github:NixOS/nixpkgs/nixos-22.11"; # TODO: https://github.com/aws/aws-lc/pull/830 - inputs.awslc.url = "github:dougch/aws-lc?ref=nix"; + inputs.awslc.url = "github:dougch/aws-lc?ref=nixv1.17.4"; outputs = { self, nix, nixpkgs, awslc, flake-utils }: flake-utils.lib.eachDefaultSystem (system: @@ -69,7 +69,7 @@ cmake -S . -B./build \ -DBUILD_SHARED_LIBS=ON \ -DCMAKE_BUILD_TYPE=RelWithDebInfo \ - -DS2N_NO_PQ=1 + -DS2N_NO_PQ=0 ''; # TODO: set when system like aarch64/mips,etc buildPhase = '' diff --git a/tests/integrationv2/test_pq_handshake.py b/tests/integrationv2/test_pq_handshake.py index dd33a7fe1fe..d91176fafad 100644 --- a/tests/integrationv2/test_pq_handshake.py +++ b/tests/integrationv2/test_pq_handshake.py @@ -283,9 +283,6 @@ def test_s2nc_to_awslc_pq_handshake(managed_process, s2n_client_policy, awslc_se port = next(available_ports) - awslc_env_vars = dict() - awslc_env_vars["PATH"] = os.path.abspath("../../test-deps/awslc/bin") - s2nc_client_options = ProviderOptions( mode=Provider.ClientMode, port=port, @@ -297,7 +294,6 @@ def test_s2nc_to_awslc_pq_handshake(managed_process, s2n_client_policy, awslc_se mode=Provider.ServerMode, port=port, protocol=Protocols.TLS13, - env_overrides=awslc_env_vars, curve=Curves.from_name(awslc_server_group.oqs_name)) awslc_server = managed_process(BoringSSL, awslc_server_options, timeout=5) @@ -326,9 +322,6 @@ def test_s2nd_to_awslc_pq_handshake(managed_process, s2n_server_policy, awslc_cl port = next(available_ports) - awslc_env_vars = dict() - awslc_env_vars["PATH"] = os.path.abspath("../../test-deps/awslc/bin") - s2nd_server_options = ProviderOptions( mode=Provider.ServerMode, port=port, @@ -340,7 +333,6 @@ def test_s2nd_to_awslc_pq_handshake(managed_process, s2n_server_policy, awslc_cl mode=Provider.ClientMode, port=port, protocol=Protocols.TLS13, - env_overrides=awslc_env_vars, curve=Curves.from_name(awslc_client_group.oqs_name)) s2nd_server = managed_process(S2N, s2nd_server_options, timeout=5)