|
| 1 | +name: FIPS Ready Bundle Test |
| 2 | + |
| 3 | +# START OF COMMON SECTION |
| 4 | +on: |
| 5 | + push: |
| 6 | + branches: [ 'master', 'main', 'release/**' ] |
| 7 | + pull_request: |
| 8 | + branches: [ '*' ] |
| 9 | + |
| 10 | +concurrency: |
| 11 | + group: ${{ github.workflow }}-${{ github.ref }} |
| 12 | + cancel-in-progress: true |
| 13 | +# END OF COMMON SECTION |
| 14 | + |
| 15 | +jobs: |
| 16 | + fips_ready_test: |
| 17 | + name: FIPS Ready Bundle Test |
| 18 | + runs-on: ubuntu-22.04 |
| 19 | + timeout-minutes: 20 |
| 20 | + strategy: |
| 21 | + matrix: |
| 22 | + wolfssl_bundle_ref: [ '5.8.2' ] |
| 23 | + openssl_ref: [ 'openssl-3.5.0' ] |
| 24 | + force_fail: ['WOLFPROV_FORCE_FAIL=1', ''] |
| 25 | + steps: |
| 26 | + - name: Checkout wolfProvider |
| 27 | + uses: actions/checkout@v4 |
| 28 | + with: |
| 29 | + fetch-depth: 1 |
| 30 | + |
| 31 | + - name: Download FIPS Ready Bundle |
| 32 | + run: | |
| 33 | + # Download FIPS ready bundle from wolfSSL website |
| 34 | + BUNDLE_URL="https://www.wolfssl.com/wolfssl-${{matrix.wolfssl_bundle_ref}}-gplv3-fips-ready.zip" |
| 35 | + |
| 36 | + wget -O wolfssl-fips-ready.zip "$BUNDLE_URL" |
| 37 | + unzip wolfssl-fips-ready.zip |
| 38 | +
|
| 39 | + # Find the extracted directory (build script requires directory, not zip) |
| 40 | + BUNDLE_DIR=$(find . -maxdepth 1 -type d -name "*fips-ready*" | head -n 1) |
| 41 | + if [ -z "$BUNDLE_DIR" ]; then |
| 42 | + echo "ERROR: Could not find FIPS ready bundle directory after extraction" |
| 43 | + ls -la |
| 44 | + exit 1 |
| 45 | + fi |
| 46 | +
|
| 47 | + echo "FIPS_BUNDLE_PATH=$(pwd)/$BUNDLE_DIR" >> $GITHUB_ENV |
| 48 | + echo "Found FIPS bundle directory at: $BUNDLE_DIR" |
| 49 | +
|
| 50 | + - name: Build wolfProvider with FIPS Ready Bundle |
| 51 | + run: | |
| 52 | + ./scripts/build-wolfprovider.sh --fips-bundle="$FIPS_BUNDLE_PATH" \ |
| 53 | + --fips-version=ready --wolfssl-ver=v${{matrix.wolfssl_bundle_ref}}-stable |
| 54 | +
|
| 55 | + - name: Run FIPS Command Tests |
| 56 | + run: | |
| 57 | + # Run cmd tests to verify functionality |
| 58 | + export WOLFSSL_ISFIPS=1 |
| 59 | + export ${{matrix.force_fail}} |
| 60 | +
|
| 61 | + ${{ matrix.force_fail }} ./scripts/cmd_test/do-cmd-tests.sh |
0 commit comments