aws / s2n-tls

An implementation of the TLS/SSL protocols
https://aws.github.io/s2n-tls/usage-guide/
Apache License 2.0
4.53k stars 706 forks source link

CRT cmake failure #4881

Open dougch opened 1 week ago

dougch commented 1 week ago

Security issue notifications

If you discover a potential security issue in s2n we ask that you notify AWS Security via our vulnerability reporting page. Please do not create a public github issue.

Problem:

CMake is failing to find @PROJECT_NAME@-targets.cmake

-- LibCrypto Include Dir: /tmp/tmp.C3vZpVFExW/build/deps/AWSLC/install/include
-- LibCrypto Shared Lib:  /usr/lib/x86_64-linux-gnu/libcrypto.so
-- LibCrypto Static Lib:  /tmp/tmp.C3vZpVFExW/build/deps/AWSLC/install/lib/libcrypto.a
CMake Error at /opt/s2n-tls/cmake/s2n-config.cmake:23 (include):
  include could not find load file:
    /opt/s2n-tls/cmake/shared/@PROJECT_NAME@-targets.cmake
Call Stack (most recent call first):
  crt/aws-c-io/CMakeLists.txt:157 (find_package)
-- Using prebuilt libcrypto from AWS-LC
-- LibCrypto Include Dir: /tmp/tmp.C3vZpVFExW/build/deps/AWSLC/install/include
-- LibCrypto Shared Lib:  /usr/lib/x86_64-linux-gnu/libcrypto.so
-- LibCrypto Static Lib:  /tmp/tmp.C3vZpVFExW/build/deps/AWSLC/install/lib/libcrypto.a
-- Configuring incomplete, errors occurred!

example run from a schedule test against main: https://us-west-2.console.aws.amazon.com/codesuite/codebuild/024603541914/projects/s2nGeneralBatch/build/s2nGeneralBatch%3A13253f48-3ee0-46e2-918b-b60cbcffd40f?region=us-west-2

Solution:

A description of the possible solution in terms of S2N architecture. Highlight and explain any potentially controversial design decisions taken.

Requirements / Acceptance Criteria:

What must a solution address in order to solve the problem? How do we know the solution is complete?

Out of scope:

Is there anything the solution will intentionally NOT address?

dougch commented 1 week ago

Related changes? #4876, #4465 and https://github.com/awslabs/aws-crt-cpp/pull/677

dougch commented 1 week ago

It would be nice to understand how CMake is finding this path, a worthwhile investigation might be forcefully pair down these search paths, so we aren't surprised when it pulls in system files or random other git clones.