Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

test: Adds SSLv3 integ test #4372

Merged
merged 9 commits into from
Jan 26, 2024
Merged

test: Adds SSLv3 integ test #4372

merged 9 commits into from
Jan 26, 2024

Conversation

maddeleine
Copy link
Contributor

@maddeleine maddeleine commented Jan 22, 2024

Resolved issues:

Resolves #3810

Description of changes:

Adds an integ sslv3 test to our happy_path_test cases. I created a new provider called SSLv3Provider that only negotiates SSLv3. It's openssl 1.0.2, and I overrode the PATH and LD_LIBRARY env variables to get the test to actually use that version instead of the libssl default, openssl 1.1.1.

Call-outs:

The curves P-384 and P-521 can't be negotiated in SSLv3. This is because Openssl doesn't send any extensions in SSLv3 and so there's no way for the peer to know which curve is being negotiated. The curve P-256 will work however as it is the default.

Testing:

Link to the run that contains the passing SSLv3 tests. It's kind of hard to find since our codebuild jobs don't have descriptive names. You might have to search for "SSLv3Provider" to find the passing tests that I added.

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.

@github-actions github-actions bot added the s2n-core team label Jan 22, 2024
tests/integrationv2/providers.py Fixed Show fixed Hide fixed
tests/integrationv2/providers.py Fixed Show fixed Hide fixed
tests/integrationv2/common.py Outdated Show resolved Hide resolved
tests/integrationv2/common.py Show resolved Hide resolved
Copy link
Contributor

@dougch dougch left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm


override_env_vars = dict()
override_env_vars["PATH"] = install_dir + "/bin"
override_env_vars["LD_LIBRARY_PATH"] = install_dir + "/lib"
Copy link
Contributor

@dougch dougch Jan 25, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Normally over-writing this is fraught with peril, but it looks like the framework gets away with it, so long as the process/ManagedProcess code only runs one binary and doesn't mess with the top level environment.

@@ -5,7 +5,7 @@ skipsdist = True
[testenv]
# install pytest in the virtualenv where commands will be executed
setenv = S2N_INTEG_TEST = 1
passenv = DYLD_LIBRARY_PATH, LD_LIBRARY_PATH, OQS_OPENSSL_1_1_1_INSTALL_DIR, HOME, TOX_TEST_NAME
passenv = DYLD_LIBRARY_PATH, LD_LIBRARY_PATH, OQS_OPENSSL_1_1_1_INSTALL_DIR, OPENSSL_1_0_2_INSTALL_DIR, HOME, TOX_TEST_NAME
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The equivalent in nix will be an addition to the shellHook stanza, but let's do this as a future change.

@maddeleine maddeleine merged commit b515726 into main Jan 26, 2024
34 checks passed
@maddeleine maddeleine deleted the sslv3 branch January 26, 2024 20:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Missing SSLv3 integration test
3 participants