s2n-tls
s2n-tls copied to clipboard
Nix libcrypto helpers
Resolved issues:
none
Description of changes:
Some of our tests expect environment variables to alternative libcrypto's to just work, and when entering a devShell interactively- it would be great to remind the user of what's available.
Note that regardless of what libcrypto CMAKE is pointing at, the other binaries should always be there, in this example openssl102 is the CMAKE target and we're still able to execute the 3.0 binary:
% nix develop .#openssl102
Setting up openssl-1.0.2 enviornment from flake.nix...
nix/shell.sh: Entering a devShell
Libcrypto /nix/store/7mkz730iixhcjicykm4q8wljy40z72dn-openssl-1.0.2/bin/openssl available as openssl102
Libcrypto /nix/store/8dz8a4bs351h2dsdp23sm4qf994rbah4-openssl-1.1.1/bin/openssl available as openssl111
Libcrypto /nix/store/m8gcym1r6l4pnpzjlv5fkaskyzwvqp86-openssl-3.0.7/bin/openssl available as openssl30
Libcrypto /nix/store/49ivhb6z3k23qhx2vj3n53w4md1111as-aws-lc/bin/bssl available as bssl
Libcrypto /nix/store/bjqjkm7217x2grpkxbvdzchl8v52hxgl-libressl-3.6.1/bin/openssl available as libressl
Libcrypto /nix/store/n5vq52hf204vy5khz4vl7xks8khsfrbf-gnutls-3.7.8-bin/bin/gnutls-cli available as gnutls-cli
[nix openssl-1.0.2] dougch@cusco:~/gitrepos/s2n-tls$ openssl30 version
OpenSSL 3.0.7 1 Nov 2022 (Library: OpenSSL 3.0.7 1 Nov 2022)
Call-outs:
This extends and replaces #4252
Testing:
How is this change tested (unit tests, fuzz tests, etc.)? local
Is this a refactor change? If so, how have you proved that the intended behavior hasn't changed?
By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.