-
Notifications
You must be signed in to change notification settings - Fork 102
Add more CI workflows for wolfSSH #884
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
Merged
Merged
Changes from all commits
Commits
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,26 @@ | ||
| name: Codespell | ||
|
|
||
| on: | ||
| push: | ||
| branches: [ 'master', 'main', 'release/**' ] | ||
| pull_request: | ||
| branches: [ '*' ] | ||
|
|
||
| concurrency: | ||
| group: ${{ github.workflow }}-${{ github.ref }} | ||
| cancel-in-progress: true | ||
|
|
||
| jobs: | ||
| codespell: | ||
| name: Check spelling | ||
| runs-on: ubuntu-latest | ||
| timeout-minutes: 5 | ||
| steps: | ||
| - name: Checkout wolfSSH | ||
| uses: actions/checkout@v4 | ||
|
|
||
| - name: Run codespell | ||
| uses: codespell-project/actions-codespell@v2 | ||
| with: | ||
| skip: .git,./ide,./keys,./certs,./m4,*.der,*.pem,*.pub | ||
| ignore_words_list: inout,keypair,nd,parm,ser,rcv,inh,bu,fo,te,ans,pendin,anormal,dne |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,99 @@ | ||
| name: Multiple Compilers | ||
|
|
||
| on: | ||
| push: | ||
| branches: [ 'master', 'main', 'release/**' ] | ||
| pull_request: | ||
| branches: [ '*' ] | ||
|
|
||
| concurrency: | ||
| group: ${{ github.workflow }}-${{ github.ref }} | ||
| cancel-in-progress: true | ||
|
|
||
| jobs: | ||
| build_wolfssl: | ||
| name: Build wolfSSL | ||
| runs-on: ubuntu-latest | ||
| timeout-minutes: 5 | ||
| steps: | ||
| - name: Checkout wolfSSL | ||
| uses: actions/checkout@v4 | ||
| with: | ||
| repository: wolfssl/wolfssl | ||
| path: wolfssl | ||
|
|
||
| - name: Build wolfSSL | ||
| working-directory: ./wolfssl | ||
| run: | | ||
| ./autogen.sh | ||
| ./configure --enable-wolfssh --enable-keygen --enable-pkcallbacks | ||
| make -j$(nproc) | ||
| sudo make install | ||
| sudo ldconfig | ||
|
|
||
| - name: tar build-dir | ||
| run: tar -zcf wolfssl-install.tgz /usr/local/lib/libwolfssl* /usr/local/include/wolfssl | ||
|
|
||
| - name: Upload built lib | ||
| uses: actions/upload-artifact@v4 | ||
| with: | ||
| name: wolfssl-multi-compiler | ||
| path: wolfssl-install.tgz | ||
| retention-days: 5 | ||
|
|
||
| compiler_test: | ||
| name: ${{ matrix.cc }} | ||
| runs-on: ubuntu-latest | ||
| timeout-minutes: 10 | ||
| needs: build_wolfssl | ||
| strategy: | ||
| fail-fast: false | ||
| matrix: | ||
| include: | ||
| - cc: gcc-11 | ||
| cxx: g++-11 | ||
| - cc: gcc-12 | ||
| cxx: g++-12 | ||
| - cc: gcc-13 | ||
| cxx: g++-13 | ||
| - cc: clang-14 | ||
| cxx: clang++-14 | ||
| - cc: clang-15 | ||
| cxx: clang++-15 | ||
| - cc: clang-17 | ||
| cxx: clang++-17 | ||
|
|
||
| steps: | ||
| - name: Install compiler | ||
| run: | | ||
| sudo apt-get update | ||
| sudo apt-get install -y ${{ matrix.cc }} | ||
|
|
||
| - name: Checkout wolfSSH | ||
| uses: actions/checkout@v4 | ||
|
|
||
| - name: Download wolfSSL | ||
| uses: actions/download-artifact@v4 | ||
| with: | ||
| name: wolfssl-multi-compiler | ||
|
|
||
| - name: Install wolfSSL | ||
| run: | | ||
| sudo tar -xzf wolfssl-install.tgz -C / | ||
| sudo ldconfig | ||
|
|
||
| - name: Build wolfSSH with ${{ matrix.cc }} | ||
| env: | ||
| CC: ${{ matrix.cc }} | ||
| CXX: ${{ matrix.cxx }} | ||
| run: | | ||
| ./autogen.sh | ||
| ./configure CFLAGS="-Wall -Wextra -Wpedantic" | ||
| make -j$(nproc) | ||
|
|
||
| - name: Make dist | ||
| run: make dist | ||
|
|
||
| - name: Show log on errors | ||
| if: failure() | ||
| run: cat config.log | ||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,104 @@ | ||
| name: Sanitizer Tests | ||
|
|
||
| on: | ||
| push: | ||
| branches: [ 'master', 'main', 'release/**' ] | ||
| pull_request: | ||
| branches: [ '*' ] | ||
|
|
||
| concurrency: | ||
| group: ${{ github.workflow }}-${{ github.ref }} | ||
| cancel-in-progress: true | ||
|
|
||
| jobs: | ||
| build_wolfssl: | ||
| name: Build wolfSSL | ||
| runs-on: ubuntu-latest | ||
| timeout-minutes: 5 | ||
| steps: | ||
| - name: Checkout wolfSSL | ||
| uses: actions/checkout@v4 | ||
| with: | ||
| repository: wolfssl/wolfssl | ||
| path: wolfssl | ||
|
|
||
| - name: Build wolfSSL | ||
| working-directory: ./wolfssl | ||
| run: | | ||
| ./autogen.sh | ||
| ./configure --enable-wolfssh --enable-keygen --enable-pkcallbacks | ||
| make -j$(nproc) | ||
| sudo make install | ||
| sudo ldconfig | ||
|
|
||
| - name: tar build-dir | ||
| run: tar -zcf wolfssl-install.tgz /usr/local/lib/libwolfssl* /usr/local/include/wolfssl | ||
|
|
||
| - name: Upload built lib | ||
| uses: actions/upload-artifact@v4 | ||
| with: | ||
| name: wolfssl-sanitizer | ||
| path: wolfssl-install.tgz | ||
| retention-days: 5 | ||
|
|
||
| sanitizer_test: | ||
| name: ${{ matrix.name }} | ||
| runs-on: ubuntu-latest | ||
| timeout-minutes: 15 | ||
| needs: build_wolfssl | ||
| strategy: | ||
| fail-fast: false | ||
| matrix: | ||
| include: | ||
| - name: "ASan" | ||
| cflags: "-fsanitize=address -fno-omit-frame-pointer -g -O1" | ||
| ldflags: "-fsanitize=address" | ||
| - name: "UBSan" | ||
| cflags: "-fsanitize=undefined -fno-sanitize-recover=all -fno-omit-frame-pointer -g" | ||
| ldflags: "-fsanitize=undefined" | ||
|
|
||
| steps: | ||
| - name: Workaround high-entropy ASLR | ||
| run: sudo sysctl vm.mmap_rnd_bits=28 | ||
|
|
||
| - name: Checkout wolfSSH | ||
| uses: actions/checkout@v4 | ||
|
|
||
| - name: Download wolfSSL | ||
| uses: actions/download-artifact@v4 | ||
| with: | ||
| name: wolfssl-sanitizer | ||
|
|
||
| - name: Install wolfSSL | ||
| run: | | ||
| sudo tar -xzf wolfssl-install.tgz -C / | ||
| sudo ldconfig | ||
|
|
||
| - name: Build wolfSSH with ${{ matrix.name }} | ||
| run: | | ||
| ./autogen.sh | ||
| ./configure --enable-all \ | ||
| CFLAGS="${{ matrix.cflags }}" LDFLAGS="${{ matrix.ldflags }}" | ||
| make -j$(nproc) | ||
|
|
||
| - name: Run tests | ||
| run: make check | ||
|
|
||
| - name: Show test logs on failure | ||
| if: failure() | ||
| run: | | ||
| echo "=== test-suite.log ===" | ||
| cat test-suite.log || true | ||
| echo "" | ||
| echo "=== tests/api.log ===" | ||
| cat tests/api.log || true | ||
|
|
||
| - name: Upload failure logs | ||
| if: failure() | ||
| uses: actions/upload-artifact@v4 | ||
| with: | ||
| name: wolfssh-${{ matrix.name }}-logs | ||
| path: | | ||
| test-suite.log | ||
| config.log | ||
| retention-days: 5 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.