diff options
133 files changed, 3358 insertions, 1347 deletions
diff --git a/.github/workflows/android.yml b/.github/workflows/android.yml index d095d6d..976f2d3 100644 --- a/.github/workflows/android.yml +++ b/.github/workflows/android.yml | |||
| @@ -10,7 +10,7 @@ concurrency: | |||
| 10 | jobs: | 10 | jobs: |
| 11 | test: | 11 | test: |
| 12 | name: "Test ${{ matrix.name }}" | 12 | name: "Test ${{ matrix.name }}" |
| 13 | runs-on: ubuntu-latest | 13 | runs-on: ubuntu-24.04 |
| 14 | permissions: | 14 | permissions: |
| 15 | contents: read | 15 | contents: read |
| 16 | strategy: | 16 | strategy: |
| @@ -25,7 +25,7 @@ jobs: | |||
| 25 | max-nal: 30 | 25 | max-nal: 30 |
| 26 | steps: | 26 | steps: |
| 27 | - name: "Checkout repository" | 27 | - name: "Checkout repository" |
| 28 | uses: actions/checkout@v4 | 28 | uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1 |
| 29 | 29 | ||
| 30 | - name: "Run CI script" | 30 | - name: "Run CI script" |
| 31 | run: ./scripts/test | 31 | run: ./scripts/test |
diff --git a/.github/workflows/cifuzz.yml b/.github/workflows/cifuzz.yml index 966d92a..eaa0681 100644 --- a/.github/workflows/cifuzz.yml +++ b/.github/workflows/cifuzz.yml | |||
| @@ -9,7 +9,7 @@ concurrency: | |||
| 9 | 9 | ||
| 10 | jobs: | 10 | jobs: |
| 11 | Fuzzing: | 11 | Fuzzing: |
| 12 | runs-on: ubuntu-latest | 12 | runs-on: ubuntu-24.04 |
| 13 | steps: | 13 | steps: |
| 14 | - name: Build Fuzzers | 14 | - name: Build Fuzzers |
| 15 | id: build | 15 | id: build |
| @@ -26,7 +26,7 @@ jobs: | |||
| 26 | dry-run: false | 26 | dry-run: false |
| 27 | language: c++ | 27 | language: c++ |
| 28 | - name: Upload Crash | 28 | - name: Upload Crash |
| 29 | uses: actions/upload-artifact@v3 | 29 | uses: actions/upload-artifact@b7c566a772e6b6bfb58ed0dc250532a479d7789f # v6.0.0 |
| 30 | if: failure() && steps.build.outcome == 'success' | 30 | if: failure() && steps.build.outcome == 'success' |
| 31 | with: | 31 | with: |
| 32 | name: artifacts | 32 | name: artifacts |
diff --git a/.github/workflows/cmake-config.yml b/.github/workflows/cmake-config.yml new file mode 100644 index 0000000..0de7b4f --- /dev/null +++ b/.github/workflows/cmake-config.yml | |||
| @@ -0,0 +1,98 @@ | |||
| 1 | # GitHub Actions workflow to check CMake config. | ||
| 2 | name: "CMake Check" | ||
| 3 | |||
| 4 | on: | ||
| 5 | push: {} | ||
| 6 | pull_request: {} | ||
| 7 | |||
| 8 | concurrency: | ||
| 9 | group: "${{ github.workflow }}-${{ github.event.number || github.ref }}" | ||
| 10 | cancel-in-progress: true | ||
| 11 | |||
| 12 | jobs: | ||
| 13 | check: | ||
| 14 | name: "${{ matrix.os }}" | ||
| 15 | runs-on: "${{ matrix.os }}" | ||
| 16 | strategy: | ||
| 17 | fail-fast: true | ||
| 18 | matrix: | ||
| 19 | os: [ "windows-2022", "macos-14", "ubuntu-24.04" ] | ||
| 20 | defaults: | ||
| 21 | run: | ||
| 22 | shell: "bash" | ||
| 23 | permissions: | ||
| 24 | contents: read | ||
| 25 | steps: | ||
| 26 | - name: "Checkout repository" | ||
| 27 | uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1 | ||
| 28 | |||
| 29 | - name: "Setup Windows dependencies" | ||
| 30 | if: runner.os == 'Windows' | ||
| 31 | uses: msys2/setup-msys2@4f806de0a5a7294ffabaff804b38a9b435a73bda # v2.30.0 | ||
| 32 | with: | ||
| 33 | update: true | ||
| 34 | install: >- | ||
| 35 | autoconf | ||
| 36 | automake | ||
| 37 | diffutils | ||
| 38 | libtool | ||
| 39 | gcc | ||
| 40 | git | ||
| 41 | patch | ||
| 42 | perl | ||
| 43 | |||
| 44 | - name: "Setup macOS dependencies" | ||
| 45 | if: runner.os == 'macOS' | ||
| 46 | run: brew install automake libtool | ||
| 47 | |||
| 48 | - name: "Prepare source tree for build (Windows)" | ||
| 49 | if: runner.os == 'Windows' | ||
| 50 | shell: "msys2 {0}" | ||
| 51 | run: ./autogen.sh | ||
| 52 | |||
| 53 | - name: "Prepare source tree for build (Unix)" | ||
| 54 | if: runner.os != 'Windows' | ||
| 55 | run: ./autogen.sh | ||
| 56 | |||
| 57 | - name: "Configure" | ||
| 58 | run: | | ||
| 59 | cmake -S . \ | ||
| 60 | -B build \ | ||
| 61 | -D CMAKE_BUILD_TYPE=Release \ | ||
| 62 | -D CMAKE_INSTALL_PREFIX=$GITHUB_WORKSPACE/../local | ||
| 63 | |||
| 64 | - name: "Build" | ||
| 65 | run: cmake --build build --config Release --verbose | ||
| 66 | |||
| 67 | - name: "Install" | ||
| 68 | run: cmake --install build --config Release | ||
| 69 | |||
| 70 | - name: "Consume from the build directory - Configure" | ||
| 71 | run: | | ||
| 72 | cmake -S tests/cmake \ | ||
| 73 | -B consumer-build \ | ||
| 74 | -D CMAKE_BUILD_TYPE=Release \ | ||
| 75 | -D LibreSSL_DIR=$GITHUB_WORKSPACE/build | ||
| 76 | |||
| 77 | - name: "Consume from the build directory - Build" | ||
| 78 | run: cmake --build consumer-build --config Release --verbose | ||
| 79 | |||
| 80 | - name: "Consume from the install directory (CMAKE_PREFIX_PATH) - Configure" | ||
| 81 | run: | | ||
| 82 | cmake -S tests/cmake \ | ||
| 83 | -B consumer-install-prefix \ | ||
| 84 | -D CMAKE_BUILD_TYPE=Release \ | ||
| 85 | -D CMAKE_PREFIX_PATH=$GITHUB_WORKSPACE/../local | ||
| 86 | |||
| 87 | - name: "Consume from the install directory (CMAKE_PREFIX_PATH) - Build" | ||
| 88 | run: cmake --build consumer-install-prefix --config Release --verbose | ||
| 89 | |||
| 90 | - name: "Consume from the install directory (LibreSSL_DIR) - Configure" | ||
| 91 | run: | | ||
| 92 | cmake -S tests/cmake \ | ||
| 93 | -B consumer-install-dir \ | ||
| 94 | -D CMAKE_BUILD_TYPE=Release \ | ||
| 95 | -D LibreSSL_DIR=$GITHUB_WORKSPACE/../local/lib/cmake/LibreSSL | ||
| 96 | |||
| 97 | - name: "Consume from the install directory (LibreSSL_DIR) - Build" | ||
| 98 | run: cmake --build consumer-install-dir --config Release --verbose | ||
diff --git a/.github/workflows/cmake_config.yml b/.github/workflows/cmake_config.yml deleted file mode 100644 index be9f114..0000000 --- a/.github/workflows/cmake_config.yml +++ /dev/null | |||
| @@ -1,89 +0,0 @@ | |||
| 1 | name: cmake_config | ||
| 2 | |||
| 3 | on: [push, pull_request] | ||
| 4 | |||
| 5 | concurrency: | ||
| 6 | group: "${{ github.workflow }}-${{ github.event.number || github.ref }}" | ||
| 7 | cancel-in-progress: true | ||
| 8 | |||
| 9 | jobs: | ||
| 10 | cmake-check: | ||
| 11 | defaults: | ||
| 12 | run: | ||
| 13 | shell: bash | ||
| 14 | strategy: | ||
| 15 | matrix: | ||
| 16 | os: [windows-latest, macos-latest, ubuntu-latest] | ||
| 17 | runs-on: ${{ matrix.os }} | ||
| 18 | continue-on-error: false | ||
| 19 | name: ${{ matrix.os }} | ||
| 20 | steps: | ||
| 21 | - name: Setup Windows dependencies | ||
| 22 | if: runner.os == 'Windows' | ||
| 23 | uses: msys2/setup-msys2@v2 | ||
| 24 | with: | ||
| 25 | update: true | ||
| 26 | install: >- | ||
| 27 | autoconf | ||
| 28 | automake | ||
| 29 | diffutils | ||
| 30 | libtool | ||
| 31 | gcc | ||
| 32 | git | ||
| 33 | patch | ||
| 34 | perl | ||
| 35 | |||
| 36 | - name: Setup macOS dependencies | ||
| 37 | if: runner.os == 'macOS' | ||
| 38 | run: brew install automake libtool | ||
| 39 | |||
| 40 | - uses: actions/checkout@main | ||
| 41 | |||
| 42 | - name: Prepare source tree for build (Windows) | ||
| 43 | if: runner.os == 'Windows' | ||
| 44 | run: ./autogen.sh | ||
| 45 | shell: msys2 {0} | ||
| 46 | |||
| 47 | - name: Prepare source tree for build (Unix) | ||
| 48 | if: runner.os != 'Windows' | ||
| 49 | run: ./autogen.sh | ||
| 50 | |||
| 51 | - name: Configure | ||
| 52 | run: | | ||
| 53 | cmake -S . \ | ||
| 54 | -B build \ | ||
| 55 | -D CMAKE_BUILD_TYPE=Release \ | ||
| 56 | -D CMAKE_INSTALL_PREFIX=$GITHUB_WORKSPACE/../local | ||
| 57 | |||
| 58 | - name: Build | ||
| 59 | run: cmake --build build --config Release --verbose | ||
| 60 | |||
| 61 | - name: Install | ||
| 62 | run: cmake --install build --config Release | ||
| 63 | |||
| 64 | - name: Consume from the build directory - Configure | ||
| 65 | run: | | ||
| 66 | cmake -S tests/cmake \ | ||
| 67 | -B consumer-build \ | ||
| 68 | -D CMAKE_BUILD_TYPE=Release \ | ||
| 69 | -D LibreSSL_DIR=$GITHUB_WORKSPACE/build | ||
| 70 | - name: Consume from the build directory - Build | ||
| 71 | run: cmake --build consumer-build --config Release --verbose | ||
| 72 | |||
| 73 | - name: Consume from the install directory (CMAKE_PREFIX_PATH) - Configure | ||
| 74 | run: | | ||
| 75 | cmake -S tests/cmake \ | ||
| 76 | -B consumer-install-prefix \ | ||
| 77 | -D CMAKE_BUILD_TYPE=Release \ | ||
| 78 | -D CMAKE_PREFIX_PATH=$GITHUB_WORKSPACE/../local | ||
| 79 | - name: Consume from the install directory (CMAKE_PREFIX_PATH) - Build | ||
| 80 | run: cmake --build consumer-install-prefix --config Release --verbose | ||
| 81 | |||
| 82 | - name: Consume from the install directory (LibreSSL_DIR) - Configure | ||
| 83 | run: | | ||
| 84 | cmake -S tests/cmake \ | ||
| 85 | -B consumer-install-dir \ | ||
| 86 | -D CMAKE_BUILD_TYPE=Release \ | ||
| 87 | -D LibreSSL_DIR=$GITHUB_WORKSPACE/../local/lib/cmake/LibreSSL | ||
| 88 | - name: Consume from the install directory (LibreSSL_DIR) - Build | ||
| 89 | run: cmake --build consumer-install-dir --config Release --verbose | ||
diff --git a/.github/workflows/coverity.yml b/.github/workflows/coverity.yml index 112678f..3cc0560 100644 --- a/.github/workflows/coverity.yml +++ b/.github/workflows/coverity.yml | |||
| @@ -13,13 +13,13 @@ concurrency: | |||
| 13 | jobs: | 13 | jobs: |
| 14 | scan: | 14 | scan: |
| 15 | name: "Scan" | 15 | name: "Scan" |
| 16 | runs-on: "ubuntu-latest" | 16 | runs-on: "ubuntu-24.04" |
| 17 | if: github.repository_owner == 'libressl' # Prevent running on forks | 17 | if: github.repository_owner == 'libressl' # Prevent running on forks |
| 18 | permissions: | 18 | permissions: |
| 19 | contents: read | 19 | contents: read |
| 20 | steps: | 20 | steps: |
| 21 | - name: "Checkout repository" | 21 | - name: "Checkout repository" |
| 22 | uses: actions/checkout@v4 | 22 | uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1 |
| 23 | 23 | ||
| 24 | - name: "Install dependencies" | 24 | - name: "Install dependencies" |
| 25 | run: | | 25 | run: | |
| @@ -31,7 +31,7 @@ jobs: | |||
| 31 | PROJECT: "libressl-portable%2Fportable" | 31 | PROJECT: "libressl-portable%2Fportable" |
| 32 | COVERITY_SCAN_TOKEN: "${{ secrets.COVERITY_SCAN_TOKEN }}" | 32 | COVERITY_SCAN_TOKEN: "${{ secrets.COVERITY_SCAN_TOKEN }}" |
| 33 | run: | | 33 | run: | |
| 34 | wget -c -N https://scan.coverity.com/download/linux64 --post-data "token=$COVERITY_SCAN_TOKEN&project=$PROJECT" -O coverity_tool.tar.gz | 34 | wget -nv https://scan.coverity.com/download/linux64 --post-data "token=$COVERITY_SCAN_TOKEN&project=$PROJECT" -O coverity_tool.tar.gz |
| 35 | mkdir coverity_tool | 35 | mkdir coverity_tool |
| 36 | tar xzf coverity_tool.tar.gz --strip 1 -C coverity_tool | 36 | tar xzf coverity_tool.tar.gz --strip 1 -C coverity_tool |
| 37 | 37 | ||
diff --git a/.github/workflows/emscripten.yml b/.github/workflows/emscripten.yml index 07f140d..2de51e0 100644 --- a/.github/workflows/emscripten.yml +++ b/.github/workflows/emscripten.yml | |||
| @@ -14,16 +14,16 @@ concurrency: | |||
| 14 | jobs: | 14 | jobs: |
| 15 | test: | 15 | test: |
| 16 | name: "Emscripten" | 16 | name: "Emscripten" |
| 17 | runs-on: "ubuntu-latest" | 17 | runs-on: "ubuntu-24.04" |
| 18 | if: ${{ github.repository_owner == 'libressl' || github.event_name != 'schedule' }} | 18 | if: ${{ github.repository_owner == 'libressl' || github.event_name != 'schedule' }} |
| 19 | permissions: | 19 | permissions: |
| 20 | contents: read | 20 | contents: read |
| 21 | steps: | 21 | steps: |
| 22 | - name: "Checkout repository" | 22 | - name: "Checkout repository" |
| 23 | uses: actions/checkout@v4 | 23 | uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1 |
| 24 | 24 | ||
| 25 | - name: "Setup emsdk" | 25 | - name: "Setup emsdk" |
| 26 | uses: mymindstorm/setup-emsdk@v14 | 26 | uses: mymindstorm/setup-emsdk@6ab9eb1bda2574c4ddb79809fc9247783eaf9021 # v14 |
| 27 | with: | 27 | with: |
| 28 | version: "3.1.60" | 28 | version: "3.1.60" |
| 29 | 29 | ||
| @@ -42,16 +42,16 @@ jobs: | |||
| 42 | # Test ASAN with and without ASM enabled. | 42 | # Test ASAN with and without ASM enabled. |
| 43 | test-asan: | 43 | test-asan: |
| 44 | name: "ASAN (no-asm)" | 44 | name: "ASAN (no-asm)" |
| 45 | runs-on: "ubuntu-latest" | 45 | runs-on: "ubuntu-24.04" |
| 46 | if: ${{ github.repository_owner == 'libressl' || github.event_name != 'schedule' }} | 46 | if: ${{ github.repository_owner == 'libressl' || github.event_name != 'schedule' }} |
| 47 | permissions: | 47 | permissions: |
| 48 | contents: read | 48 | contents: read |
| 49 | steps: | 49 | steps: |
| 50 | - name: "Checkout repository" | 50 | - name: "Checkout repository" |
| 51 | uses: actions/checkout@v4 | 51 | uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1 |
| 52 | 52 | ||
| 53 | - name: "Setup emsdk" | 53 | - name: "Setup emsdk" |
| 54 | uses: mymindstorm/setup-emsdk@v14 | 54 | uses: mymindstorm/setup-emsdk@6ab9eb1bda2574c4ddb79809fc9247783eaf9021 # v14 |
| 55 | with: | 55 | with: |
| 56 | version: "3.1.60" | 56 | version: "3.1.60" |
| 57 | 57 | ||
diff --git a/.github/workflows/fedora-rawhide.yml b/.github/workflows/fedora-rawhide.yml index ec3c63d..fbcf055 100644 --- a/.github/workflows/fedora-rawhide.yml +++ b/.github/workflows/fedora-rawhide.yml | |||
| @@ -18,15 +18,15 @@ jobs: | |||
| 18 | matrix: | 18 | matrix: |
| 19 | cc: [ gcc, clang ] | 19 | cc: [ gcc, clang ] |
| 20 | name: ${{ matrix.cc }} | 20 | name: ${{ matrix.cc }} |
| 21 | runs-on: ubuntu-latest | 21 | runs-on: ubuntu-24.04 |
| 22 | if: ${{ github.repository_owner == 'libressl' || github.event_name != 'schedule' }} | 22 | if: ${{ github.repository_owner == 'libressl' || github.event_name != 'schedule' }} |
| 23 | container: | 23 | container: |
| 24 | image: fedora:rawhide | 24 | image: fedora:rawhide |
| 25 | steps: | 25 | steps: |
| 26 | - uses: actions/checkout@v3 | 26 | - uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1 |
| 27 | - name: Install dependencies | 27 | - name: Install dependencies |
| 28 | run: | | 28 | run: | |
| 29 | dnf -y install git make clang cmake ninja-build autoconf automake libtool diffutils patch | 29 | dnf -y install git make clang cmake ninja-build autoconf automake libtool diffutils patch gawk |
| 30 | - name: Pull upstream source | 30 | - name: Pull upstream source |
| 31 | run: | | 31 | run: | |
| 32 | ./update.sh | 32 | ./update.sh |
diff --git a/.github/workflows/freebsd.yml b/.github/workflows/freebsd.yml new file mode 100644 index 0000000..fe6c258 --- /dev/null +++ b/.github/workflows/freebsd.yml | |||
| @@ -0,0 +1,71 @@ | |||
| 1 | # GitHub Actions workflow to run tests on a FreeBSD VM. | ||
| 2 | name: "FreeBSD" | ||
| 3 | |||
| 4 | on: | ||
| 5 | workflow_dispatch: | ||
| 6 | schedule: | ||
| 7 | - cron: "0 0 * * *" # At 00:00 daily. | ||
| 8 | |||
| 9 | concurrency: | ||
| 10 | group: "${{ github.workflow }}-${{ github.event.number || github.ref }}" | ||
| 11 | cancel-in-progress: true | ||
| 12 | |||
| 13 | env: | ||
| 14 | FREEBSD_VERSION: "14.1" | ||
| 15 | |||
| 16 | jobs: | ||
| 17 | autoconf: | ||
| 18 | name: "autoconf" | ||
| 19 | runs-on: ubuntu-24.04 | ||
| 20 | if: github.repository_owner == 'libressl' || github.event_name != 'schedule' | ||
| 21 | permissions: | ||
| 22 | contents: read | ||
| 23 | steps: | ||
| 24 | - name: "Checkout repository" | ||
| 25 | uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1 | ||
| 26 | |||
| 27 | - name: "Setup" | ||
| 28 | run: | | ||
| 29 | sudo apt-get update | ||
| 30 | sudo apt-get install -y automake autoconf libtool | ||
| 31 | ./autogen.sh | ||
| 32 | |||
| 33 | - name: "Build on VM" | ||
| 34 | uses: vmactions/freebsd-vm@670398e4236735b8b65805c3da44b7a511fb8b27 # v1.3.0 | ||
| 35 | with: | ||
| 36 | release: "${{ env.FREEBSD_VERSION }}" | ||
| 37 | copyback: false | ||
| 38 | prepare: | | ||
| 39 | pkg install -y autoconf automake libtool | ||
| 40 | run: | | ||
| 41 | ./configure | ||
| 42 | make -j2 check || (cat tests/test-suite.log && exit 1) | ||
| 43 | |||
| 44 | cmake: | ||
| 45 | name: "cmake" | ||
| 46 | runs-on: ubuntu-24.04 | ||
| 47 | if: github.repository_owner == 'libressl' || github.event_name != 'schedule' | ||
| 48 | permissions: | ||
| 49 | contents: read | ||
| 50 | steps: | ||
| 51 | - name: "Checkout repository" | ||
| 52 | uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1 | ||
| 53 | |||
| 54 | - name: "Setup" | ||
| 55 | run: | | ||
| 56 | sudo apt-get update | ||
| 57 | sudo apt-get install -y automake autoconf libtool | ||
| 58 | ./autogen.sh | ||
| 59 | |||
| 60 | - name: "Build on VM" | ||
| 61 | uses: vmactions/freebsd-vm@670398e4236735b8b65805c3da44b7a511fb8b27 # v1.3.0 | ||
| 62 | with: | ||
| 63 | release: "${{ env.FREEBSD_VERSION }}" | ||
| 64 | copyback: false | ||
| 65 | prepare: | | ||
| 66 | pkg install -y cmake ninja | ||
| 67 | run: | | ||
| 68 | export CTEST_OUTPUT_ON_FAILURE=1 | ||
| 69 | cmake -G Ninja -B build | ||
| 70 | ninja -C build | ||
| 71 | ninja -C build test | ||
diff --git a/.github/workflows/linux.yml b/.github/workflows/linux.yml index 5c85d4b..d901cf9 100644 --- a/.github/workflows/linux.yml +++ b/.github/workflows/linux.yml | |||
| @@ -22,30 +22,40 @@ jobs: | |||
| 22 | strategy: | 22 | strategy: |
| 23 | fail-fast: false | 23 | fail-fast: false |
| 24 | matrix: | 24 | matrix: |
| 25 | os: ["ubuntu-20.04", "ubuntu-22.04", "ubuntu-24.04"] | 25 | os: ["ubuntu-22.04", "ubuntu-24.04"] |
| 26 | arch: ["native", "arm32", "arm64", "mingw32", "mingw64", "mips32", "mips64"] | 26 | arch: ["native", "arm32", "arm64", "mingw32", "mingw64", "mips32", "mips64"] |
| 27 | compiler: ["gcc"] | 27 | compiler: ["gcc"] |
| 28 | include: | 28 | include: |
| 29 | - os: "ubuntu-20.04" | 29 | - os: "ubuntu-22.04" |
| 30 | arch: "native" | 30 | arch: "native" |
| 31 | compiler: "clang" | 31 | compiler: "clang" |
| 32 | - os: "ubuntu-22.04" | 32 | - os: "ubuntu-24.04" |
| 33 | arch: "native" | ||
| 34 | compiler: "clang" | ||
| 35 | - os: "ubuntu-24.04" # loong64 | ||
| 36 | arch: "loong64" | ||
| 37 | compiler: "gcc" | ||
| 38 | - os: "ubuntu-24.04-arm" | ||
| 39 | arch: "native" | ||
| 40 | compiler: "gcc" | ||
| 41 | - os: "ubuntu-24.04-arm" | ||
| 33 | arch: "native" | 42 | arch: "native" |
| 34 | compiler: "clang" | 43 | compiler: "clang" |
| 44 | |||
| 35 | steps: | 45 | steps: |
| 36 | - name: "Checkout repository" | 46 | - name: "Checkout repository" |
| 37 | uses: actions/checkout@v4 | 47 | uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1 |
| 38 | 48 | ||
| 39 | - name: "Run tests" | 49 | - name: "Run tests" |
| 40 | run: ./scripts/test | 50 | run: ./scripts/test || (status=$?; cat tests/test-suite.log; exit $status) |
| 41 | env: | 51 | env: |
| 42 | ARCH: "${{ matrix.arch }}" | 52 | ARCH: "${{ matrix.arch }}" |
| 43 | CC: "${{ matrix.compiler }}" | 53 | CC: "${{ matrix.compiler }}" |
| 44 | 54 | ||
| 45 | # Test ASAN with and without ASM enabled. | 55 | # Test ASAN with and without ASM enabled. |
| 46 | test-asan: | 56 | test-asan: |
| 47 | name: "ASAN (${{ matrix.asm == 'ON' && 'asm' || 'no-asm' }})" | 57 | name: "${{ matrix.os }} - ASAN (${{ matrix.asm == 'ON' && 'asm' || 'no-asm' }})" |
| 48 | runs-on: "ubuntu-latest" | 58 | runs-on: "${{ matrix.os }}" |
| 49 | if: ${{ github.repository_owner == 'libressl' || github.event_name != 'schedule' }} | 59 | if: ${{ github.repository_owner == 'libressl' || github.event_name != 'schedule' }} |
| 50 | permissions: | 60 | permissions: |
| 51 | contents: read | 61 | contents: read |
| @@ -53,9 +63,10 @@ jobs: | |||
| 53 | fail-fast: false | 63 | fail-fast: false |
| 54 | matrix: | 64 | matrix: |
| 55 | asm: [ON, OFF] | 65 | asm: [ON, OFF] |
| 66 | os: ["ubuntu-24.04", "ubuntu-24.04-arm"] | ||
| 56 | steps: | 67 | steps: |
| 57 | - name: "Checkout repository" | 68 | - name: "Checkout repository" |
| 58 | uses: actions/checkout@v4 | 69 | uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1 |
| 59 | 70 | ||
| 60 | - name: "Run tests" | 71 | - name: "Run tests" |
| 61 | run: ./scripts/test | 72 | run: ./scripts/test |
diff --git a/.github/workflows/macos.yml b/.github/workflows/macos.yml index d5dd3eb..dad91e3 100644 --- a/.github/workflows/macos.yml +++ b/.github/workflows/macos.yml | |||
| @@ -21,14 +21,14 @@ jobs: | |||
| 21 | strategy: | 21 | strategy: |
| 22 | fail-fast: false | 22 | fail-fast: false |
| 23 | matrix: | 23 | matrix: |
| 24 | os: ["macos-14", "macos-13", "macos-12"] | 24 | os: ["macos-15", "macos-14"] |
| 25 | arch: ["arm64", "x86_64"] | 25 | arch: ["arm64", "x86_64"] |
| 26 | steps: | 26 | steps: |
| 27 | - name: "Install required packages" | 27 | - name: "Install required packages" |
| 28 | run: brew install automake libtool | 28 | run: brew install automake libtool |
| 29 | 29 | ||
| 30 | - name: "Checkout repository" | 30 | - name: "Checkout repository" |
| 31 | uses: actions/checkout@v4 | 31 | uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1 |
| 32 | 32 | ||
| 33 | - name: "Run tests" | 33 | - name: "Run tests" |
| 34 | run: ./scripts/test | 34 | run: ./scripts/test |
diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index c2e94b8..a20bf7d 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml | |||
| @@ -15,12 +15,12 @@ permissions: | |||
| 15 | jobs: | 15 | jobs: |
| 16 | release: | 16 | release: |
| 17 | name: "Release" | 17 | name: "Release" |
| 18 | runs-on: "ubuntu-latest" | 18 | runs-on: "ubuntu-24.04" |
| 19 | outputs: | 19 | outputs: |
| 20 | upload_url: "${{ steps.create_release.outputs.upload_url }}" | 20 | upload_url: "${{ steps.create_release.outputs.upload_url }}" |
| 21 | steps: | 21 | steps: |
| 22 | - name: "Checkout repository" | 22 | - name: "Checkout repository" |
| 23 | uses: actions/checkout@v4 | 23 | uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1 |
| 24 | 24 | ||
| 25 | - name: "Generate version changelog" | 25 | - name: "Generate version changelog" |
| 26 | run: .github/scripts/changelog.sh "$VERSION" > release-changelog.txt | 26 | run: .github/scripts/changelog.sh "$VERSION" > release-changelog.txt |
| @@ -29,7 +29,7 @@ jobs: | |||
| 29 | 29 | ||
| 30 | - name: "Create GitHub release" | 30 | - name: "Create GitHub release" |
| 31 | id: create_release | 31 | id: create_release |
| 32 | uses: softprops/action-gh-release@v1 | 32 | uses: softprops/action-gh-release@a06a81a03ee405af7f2048a818ed3f03bbf83c7b # v2.5.0 |
| 33 | with: | 33 | with: |
| 34 | body_path: "${{ github.workspace }}/release-changelog.txt" | 34 | body_path: "${{ github.workspace }}/release-changelog.txt" |
| 35 | 35 | ||
| @@ -43,10 +43,10 @@ jobs: | |||
| 43 | arch: [ "Win32", "x64", "ARM64" ] | 43 | arch: [ "Win32", "x64", "ARM64" ] |
| 44 | steps: | 44 | steps: |
| 45 | - name: "Checkout repository" | 45 | - name: "Checkout repository" |
| 46 | uses: actions/checkout@v4 | 46 | uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1 |
| 47 | 47 | ||
| 48 | - name: "Setup MSYS2" | 48 | - name: "Setup MSYS2" |
| 49 | uses: msys2/setup-msys2@v2 | 49 | uses: msys2/setup-msys2@4f806de0a5a7294ffabaff804b38a9b435a73bda # v2.30.0 |
| 50 | with: | 50 | with: |
| 51 | update: true | 51 | update: true |
| 52 | install: >- | 52 | install: >- |
| @@ -72,14 +72,10 @@ jobs: | |||
| 72 | run: cmake --install build --config Release | 72 | run: cmake --install build --config Release |
| 73 | 73 | ||
| 74 | - shell: pwsh | 74 | - shell: pwsh |
| 75 | run: Compress-Archive -Path local\* local.zip | 75 | run: Compress-Archive -Path local\* "libressl_${{ github.ref_name }}_windows_${{ matrix.arch }}.zip" |
| 76 | 76 | ||
| 77 | - name: "Upload release artifact" | 77 | - name: "Upload release artifact" |
| 78 | uses: actions/upload-release-asset@v1 | 78 | uses: softprops/action-gh-release@a06a81a03ee405af7f2048a818ed3f03bbf83c7b # v2.5.0 |
| 79 | env: | ||
| 80 | GITHUB_TOKEN: "${{ github.token }}" | ||
| 81 | with: | 79 | with: |
| 82 | upload_url: "${{ needs.release.outputs.upload_url }}" | 80 | files: | |
| 83 | asset_path: "local.zip" | 81 | libressl_${{ github.ref_name }}_windows_${{ matrix.arch }}.zip |
| 84 | asset_name: "libressl_${{ github.ref_name }}_windows_${{ matrix.arch }}.zip" | ||
| 85 | asset_content_type: "application/zip" | ||
diff --git a/.github/workflows/rust-openssl.yml b/.github/workflows/rust-openssl.yml index b707c4b..ed77dbb 100644 --- a/.github/workflows/rust-openssl.yml +++ b/.github/workflows/rust-openssl.yml | |||
| @@ -13,13 +13,13 @@ concurrency: | |||
| 13 | jobs: | 13 | jobs: |
| 14 | test: | 14 | test: |
| 15 | name: "Test" | 15 | name: "Test" |
| 16 | runs-on: "ubuntu-latest" | 16 | runs-on: "ubuntu-24.04" |
| 17 | if: ${{ github.repository_owner == 'libressl' || github.event_name != 'schedule' }} | 17 | if: ${{ github.repository_owner == 'libressl' || github.event_name != 'schedule' }} |
| 18 | permissions: | 18 | permissions: |
| 19 | contents: read | 19 | contents: read |
| 20 | steps: | 20 | steps: |
| 21 | - name: "Checkout repository" | 21 | - name: "Checkout repository" |
| 22 | uses: actions/checkout@v4 | 22 | uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1 |
| 23 | 23 | ||
| 24 | - name: "Build LibreSSL" | 24 | - name: "Build LibreSSL" |
| 25 | run: | | 25 | run: | |
diff --git a/.github/workflows/solaris.yml b/.github/workflows/solaris.yml index f68a2aa..a4355d0 100644 --- a/.github/workflows/solaris.yml +++ b/.github/workflows/solaris.yml | |||
| @@ -13,13 +13,13 @@ concurrency: | |||
| 13 | jobs: | 13 | jobs: |
| 14 | test: | 14 | test: |
| 15 | name: "Solaris" | 15 | name: "Solaris" |
| 16 | runs-on: ubuntu-latest | 16 | runs-on: ubuntu-24.04 |
| 17 | if: ${{ github.repository_owner == 'libressl' || github.event_name != 'schedule' }} | 17 | if: ${{ github.repository_owner == 'libressl' || github.event_name != 'schedule' }} |
| 18 | permissions: | 18 | permissions: |
| 19 | contents: read | 19 | contents: read |
| 20 | steps: | 20 | steps: |
| 21 | - name: "Checkout repository" | 21 | - name: "Checkout repository" |
| 22 | uses: actions/checkout@v4 | 22 | uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1 |
| 23 | 23 | ||
| 24 | - name: "Setup" | 24 | - name: "Setup" |
| 25 | run: | | 25 | run: | |
| @@ -28,7 +28,7 @@ jobs: | |||
| 28 | ./autogen.sh | 28 | ./autogen.sh |
| 29 | 29 | ||
| 30 | - name: "Build on VM" | 30 | - name: "Build on VM" |
| 31 | uses: vmactions/solaris-vm@v1 | 31 | uses: vmactions/solaris-vm@47bea106d03acaf91084e52548ee460556011602 # v1.1.8 |
| 32 | with: | 32 | with: |
| 33 | prepare: | | 33 | prepare: | |
| 34 | pkg install gcc make | 34 | pkg install gcc make |
diff --git a/.github/workflows/windows.yml b/.github/workflows/windows.yml index 6aca153..3880a7b 100644 --- a/.github/workflows/windows.yml +++ b/.github/workflows/windows.yml | |||
| @@ -21,20 +21,21 @@ jobs: | |||
| 21 | strategy: | 21 | strategy: |
| 22 | fail-fast: false | 22 | fail-fast: false |
| 23 | matrix: | 23 | matrix: |
| 24 | os: ["windows-2022", "windows-2019"] | 24 | os: ["windows-2022", "windows-2025"] |
| 25 | arch: ["ARM64", "x64", "Win32"] | 25 | arch: ["ARM64", "x64", "Win32"] |
| 26 | shared: ["ON", "OFF"] | 26 | shared: ["ON", "OFF"] |
| 27 | include: | 27 | include: |
| 28 | - os: "windows-2022" | 28 | - os: "windows-2022" |
| 29 | generator: "Visual Studio 17 2022" | 29 | generator: "Visual Studio 17 2022" |
| 30 | - os: "windows-2019" | 30 | - os: "windows-2025" |
| 31 | generator: "Visual Studio 16 2019" | 31 | # XXX - use appropriate value |
| 32 | generator: "Visual Studio 17 2022" | ||
| 32 | steps: | 33 | steps: |
| 33 | - name: "Checkout repository" | 34 | - name: "Checkout repository" |
| 34 | uses: actions/checkout@v4 | 35 | uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1 |
| 35 | 36 | ||
| 36 | - name: "Setup MSYS2" | 37 | - name: "Setup MSYS2" |
| 37 | uses: msys2/setup-msys2@v2 | 38 | uses: msys2/setup-msys2@4f806de0a5a7294ffabaff804b38a9b435a73bda # v2.30.0 |
| 38 | with: | 39 | with: |
| 39 | update: true | 40 | update: true |
| 40 | install: >- | 41 | install: >- |
| @@ -50,7 +51,7 @@ jobs: | |||
| 50 | 51 | ||
| 51 | - name: "Configure CMake" | 52 | - name: "Configure CMake" |
| 52 | shell: cmd | 53 | shell: cmd |
| 53 | run: cmake -Bbuild -G "${{ matrix.generator }}" -A ${{ matrix.arch }} DBUILD_SHARED_LIBS=${{ matrix.shared }} -DCMAKE_INSTALL_PREFIX=../local | 54 | run: cmake -Bbuild -G "${{ matrix.generator }}" -A ${{ matrix.arch }} -D BUILD_SHARED_LIBS=${{ matrix.shared }} -D CMAKE_INSTALL_PREFIX=../local |
| 54 | 55 | ||
| 55 | - name: "Build" | 56 | - name: "Build" |
| 56 | shell: cmd | 57 | shell: cmd |
| @@ -63,7 +64,7 @@ jobs: | |||
| 63 | 64 | ||
| 64 | - name: "Upload build artifacts" | 65 | - name: "Upload build artifacts" |
| 65 | if: always() | 66 | if: always() |
| 66 | uses: actions/upload-artifact@v4 | 67 | uses: actions/upload-artifact@b7c566a772e6b6bfb58ed0dc250532a479d7789f # v6.0.0 |
| 67 | with: | 68 | with: |
| 68 | name: "${{ matrix.os }}-${{ matrix.arch }}${{ matrix.shared == 'ON' && '-shared' || '' }}-build-results" | 69 | name: "${{ matrix.os }}-${{ matrix.arch }}${{ matrix.shared == 'ON' && '-shared' || '' }}-build-results" |
| 69 | path: "build" | 70 | path: "build" |
| @@ -38,7 +38,8 @@ Makefile | |||
| 38 | Makefile.in | 38 | Makefile.in |
| 39 | 39 | ||
| 40 | # CMake stuff | 40 | # CMake stuff |
| 41 | build | 41 | build* |
| 42 | cmake-build-debug/ | ||
| 42 | 43 | ||
| 43 | # Libtool stuff | 44 | # Libtool stuff |
| 44 | .libs | 45 | .libs |
| @@ -86,6 +87,7 @@ tests/bn_add_sub* | |||
| 86 | tests/bn_bits* | 87 | tests/bn_bits* |
| 87 | tests/bn_cmp* | 88 | tests/bn_cmp* |
| 88 | tests/bn_convert* | 89 | tests/bn_convert* |
| 90 | tests/bn_ffdh* | ||
| 89 | tests/bn_gcd* | 91 | tests/bn_gcd* |
| 90 | tests/bn_isqrt* | 92 | tests/bn_isqrt* |
| 91 | tests/bn_mod_exp* | 93 | tests/bn_mod_exp* |
| @@ -107,17 +109,20 @@ tests/constraints* | |||
| 107 | tests/crypto_test* | 109 | tests/crypto_test* |
| 108 | tests/ctlog.conf | 110 | tests/ctlog.conf |
| 109 | tests/*.crt | 111 | tests/*.crt |
| 112 | tests/ec_arithmetic* | ||
| 110 | tests/ec_point_conversion* | 113 | tests/ec_point_conversion* |
| 111 | tests/ecc_cdh* | 114 | tests/ecc_cdh* |
| 112 | tests/evp_pkey_check* | ||
| 113 | tests/evp_pkey_cleanup* | 115 | tests/evp_pkey_cleanup* |
| 114 | tests/explicit_bzero* | 116 | tests/explicit_bzero* |
| 115 | tests/freenull* | 117 | tests/freenull* |
| 116 | tests/gost2814789t* | 118 | tests/gost2814789t* |
| 117 | tests/key_schedule* | 119 | tests/key_schedule* |
| 118 | tests/lhash_test* | 120 | tests/lhash_test* |
| 121 | tests/mlkem* | ||
| 119 | tests/mont* | 122 | tests/mont* |
| 123 | tests/parse* | ||
| 120 | tests/policy* | 124 | tests/policy* |
| 125 | tests/renegotiation_test* | ||
| 121 | tests/rfc3779* | 126 | tests/rfc3779* |
| 122 | tests/rfc5280time* | 127 | tests/rfc5280time* |
| 123 | tests/ssl_get_shared_ciphers* | 128 | tests/ssl_get_shared_ciphers* |
| @@ -130,6 +135,7 @@ tests/tls_ext_alpn* | |||
| 130 | tests/tls_prf* | 135 | tests/tls_prf* |
| 131 | tests/*test | 136 | tests/*test |
| 132 | tests/tests.h | 137 | tests/tests.h |
| 138 | tests/test.h | ||
| 133 | tests/*test.c | 139 | tests/*test.c |
| 134 | tests/pbkdf2* | 140 | tests/pbkdf2* |
| 135 | tests/*.pem | 141 | tests/*.pem |
| @@ -141,6 +147,7 @@ tests/x509_algor* | |||
| 141 | tests/x509_asn1* | 147 | tests/x509_asn1* |
| 142 | tests/x509_extensions_test* | 148 | tests/x509_extensions_test* |
| 143 | tests/x509_info* | 149 | tests/x509_info* |
| 150 | tests/x509_name_test* | ||
| 144 | tests/x509attribute* | 151 | tests/x509attribute* |
| 145 | tests/x509name* | 152 | tests/x509name* |
| 146 | tests/x509req_ext* | 153 | tests/x509req_ext* |
| @@ -149,7 +156,7 @@ tests/x509req_ext* | |||
| 149 | tests/client.c | 156 | tests/client.c |
| 150 | tests/init_pledge.c | 157 | tests/init_pledge.c |
| 151 | tests/server.c | 158 | tests/server.c |
| 152 | tests/util.c | 159 | tests/*util.c |
| 153 | tests/valid_handshakes_terminate* | 160 | tests/valid_handshakes_terminate* |
| 154 | tests/handshake_table* | 161 | tests/handshake_table* |
| 155 | 162 | ||
| @@ -169,7 +176,6 @@ autom4te.cache | |||
| 169 | 176 | ||
| 170 | # Libtool adds these, at least sometimes | 177 | # Libtool adds these, at least sometimes |
| 171 | INSTALL | 178 | INSTALL |
| 172 | /COPYING | ||
| 173 | !m4/check*.m4 | 179 | !m4/check*.m4 |
| 174 | m4/l* | 180 | m4/l* |
| 175 | 181 | ||
| @@ -200,6 +206,7 @@ ssl/VERSION | |||
| 200 | tls/VERSION | 206 | tls/VERSION |
| 201 | libtls-standalone/VERSION | 207 | libtls-standalone/VERSION |
| 202 | 208 | ||
| 209 | crypto/*.mk | ||
| 203 | ssl/hidden | 210 | ssl/hidden |
| 204 | ssl/*.c | 211 | ssl/*.c |
| 205 | ssl/*.h | 212 | ssl/*.h |
| @@ -233,29 +240,89 @@ include/openssl/*.h | |||
| 233 | !/apps/openssl/apps_win.c | 240 | !/apps/openssl/apps_win.c |
| 234 | !/apps/openssl/certhash_win.c | 241 | !/apps/openssl/certhash_win.c |
| 235 | 242 | ||
| 236 | /crypto/* | 243 | /crypto/*.c |
| 237 | !/crypto/Makefile.am.* | 244 | /crypto/*.h |
| 238 | !/crypto/compat/arc4random.h | 245 | /crypto/aes/ |
| 239 | !/crypto/compat/b_win.c | 246 | /crypto/arch/aarch64/crypto_arch.h |
| 240 | !/crypto/compat/explicit_bzero_win.c | 247 | /crypto/arch/aarch64/crypto_cpu_caps.c |
| 241 | !/crypto/compat/freezero.c | 248 | /crypto/arch/alpha/ |
| 242 | !/crypto/compat/getpagesize.c | 249 | /crypto/arch/amd64/ |
| 243 | !/crypto/compat/posix_win.c | 250 | /crypto/arch/arm/ |
| 244 | !/crypto/compat/bsd_asprintf.c | 251 | /crypto/arch/hppa/ |
| 245 | !/crypto/compat/ui_openssl_win.c | 252 | /crypto/arch/i386/ |
| 246 | !/crypto/compat/crypto_lock_win.c | 253 | /crypto/arch/m88k/ |
| 247 | !/crypto/CMakeLists.txt | 254 | /crypto/arch/mips64/ |
| 248 | 255 | /crypto/arch/powerpc/ | |
| 249 | !/libtls-standalone/compat/Makefile.am | 256 | /crypto/arch/powerpc64/ |
| 250 | /libtls-standalone/include/*.h | 257 | /crypto/arch/riscv64/ |
| 251 | /libtls-standalone/src/*.c | 258 | /crypto/arch/sh/ |
| 252 | /libtls-standalone/src/*.h | 259 | /crypto/arch/sparc64/ |
| 253 | /libtls-standalone/src | 260 | /crypto/asn1/ |
| 254 | /libtls-standalone/tests/test | 261 | /crypto/bf/ |
| 255 | /libtls-standalone/compat | 262 | /crypto/bio/ |
| 256 | /libtls-standalone/VERSION | 263 | /crypto/bn/*.c |
| 257 | /libtls-standalone/m4 | 264 | /crypto/bn/*.h |
| 258 | /libtls-standalone/man | 265 | /crypto/bn/arch/aarch64/ |
| 266 | /crypto/bn/arch/alpha/ | ||
| 267 | /crypto/bn/arch/amd64/ | ||
| 268 | /crypto/bn/arch/arm/ | ||
| 269 | /crypto/bn/arch/hppa/ | ||
| 270 | /crypto/bn/arch/i386/ | ||
| 271 | /crypto/bn/arch/m88k/ | ||
| 272 | /crypto/bn/arch/mips64/ | ||
| 273 | /crypto/bn/arch/powerpc/ | ||
| 274 | /crypto/bn/arch/powerpc64/ | ||
| 275 | /crypto/bn/arch/riscv64/ | ||
| 276 | /crypto/bn/arch/sh/ | ||
| 277 | /crypto/bn/arch/sparc64/ | ||
| 278 | /crypto/buffer/ | ||
| 279 | /crypto/bytestring/ | ||
| 280 | /crypto/camellia/ | ||
| 281 | /crypto/cast/ | ||
| 282 | /crypto/chacha/ | ||
| 283 | /crypto/cmac/ | ||
| 284 | /crypto/cms/ | ||
| 285 | /crypto/conf/ | ||
| 286 | /crypto/ct/ | ||
| 287 | /crypto/curve25519/ | ||
| 288 | /crypto/des/ | ||
| 289 | /crypto/dh/ | ||
| 290 | /crypto/dsa/ | ||
| 291 | /crypto/ec/ | ||
| 292 | /crypto/ecdh/ | ||
| 293 | /crypto/ecdsa/ | ||
| 294 | /crypto/engine/ | ||
| 295 | /crypto/err/ | ||
| 296 | /crypto/evp/ | ||
| 297 | /crypto/hidden/ | ||
| 298 | /crypto/hkdf/ | ||
| 299 | /crypto/hmac/ | ||
| 300 | /crypto/idea/ | ||
| 301 | /crypto/kdf/ | ||
| 302 | /crypto/lhash/ | ||
| 303 | /crypto/md4/ | ||
| 304 | /crypto/md5/ | ||
| 305 | /crypto/mlkem/ | ||
| 306 | /crypto/modes/ | ||
| 307 | /crypto/objects/ | ||
| 308 | /crypto/ocsp/ | ||
| 309 | /crypto/pem/ | ||
| 310 | /crypto/pkcs12/ | ||
| 311 | /crypto/pkcs7/ | ||
| 312 | /crypto/poly1305/ | ||
| 313 | /crypto/rand/ | ||
| 314 | /crypto/rc2/ | ||
| 315 | /crypto/rc4/ | ||
| 316 | /crypto/ripemd/ | ||
| 317 | /crypto/rsa/ | ||
| 318 | /crypto/sha/ | ||
| 319 | /crypto/sm3/ | ||
| 320 | /crypto/sm4/ | ||
| 321 | /crypto/stack/ | ||
| 322 | /crypto/ts/ | ||
| 323 | /crypto/txt_db/ | ||
| 324 | /crypto/ui/ | ||
| 325 | /crypto/x509/ | ||
| 259 | 326 | ||
| 260 | openbsd/ | 327 | openbsd/ |
| 261 | 328 | ||
diff --git a/CMakeLists.txt b/CMakeLists.txt index c496ad9..7ab04ab 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt | |||
| @@ -1,9 +1,25 @@ | |||
| 1 | # | ||
| 2 | # Copyright (c) 2014 Brent Cook | ||
| 3 | # | ||
| 4 | # Permission to use, copy, modify, and distribute this software for any | ||
| 5 | # purpose with or without fee is hereby granted, provided that the above | ||
| 6 | # copyright notice and this permission notice appear in all copies. | ||
| 7 | # | ||
| 8 | # THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES | ||
| 9 | # WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF | ||
| 10 | # MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR | ||
| 11 | # ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES | ||
| 12 | # WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN | ||
| 13 | # ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF | ||
| 14 | # OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. | ||
| 15 | |||
| 1 | cmake_minimum_required (VERSION 3.16.4) | 16 | cmake_minimum_required (VERSION 3.16.4) |
| 17 | |||
| 2 | if(MSVC) | 18 | if(MSVC) |
| 3 | cmake_policy(SET CMP0091 NEW) | 19 | cmake_policy(SET CMP0091 NEW) |
| 4 | endif() | 20 | endif() |
| 5 | 21 | ||
| 6 | project (LibreSSL C ASM) | 22 | project(LibreSSL LANGUAGES C ASM) |
| 7 | 23 | ||
| 8 | include(CheckFunctionExists) | 24 | include(CheckFunctionExists) |
| 9 | include(CheckSymbolExists) | 25 | include(CheckSymbolExists) |
| @@ -72,10 +88,6 @@ endforeach() | |||
| 72 | 88 | ||
| 73 | set(BUILD_NC true) | 89 | set(BUILD_NC true) |
| 74 | 90 | ||
| 75 | if(CMAKE_SYSTEM_NAME MATCHES "Darwin") | ||
| 76 | add_definitions(-fno-common) | ||
| 77 | endif() | ||
| 78 | |||
| 79 | if(CMAKE_SYSTEM_NAME MATCHES "OpenBSD") | 91 | if(CMAKE_SYSTEM_NAME MATCHES "OpenBSD") |
| 80 | add_definitions(-DHAVE_ATTRIBUTE__BOUNDED__) | 92 | add_definitions(-DHAVE_ATTRIBUTE__BOUNDED__) |
| 81 | add_definitions(-DHAVE_ATTRIBUTE__DEAD__) | 93 | add_definitions(-DHAVE_ATTRIBUTE__DEAD__) |
| @@ -89,6 +101,10 @@ if(CMAKE_SYSTEM_NAME MATCHES "Linux") | |||
| 89 | set(PLATFORM_LIBS ${PLATFORM_LIBS} pthread) | 101 | set(PLATFORM_LIBS ${PLATFORM_LIBS} pthread) |
| 90 | endif() | 102 | endif() |
| 91 | 103 | ||
| 104 | if(CMAKE_SYSTEM_NAME MATCHES "FreeBSD") | ||
| 105 | set(PLATFORM_LIBS ${PLATFORM_LIBS} pthread) | ||
| 106 | endif() | ||
| 107 | |||
| 92 | if(WIN32) | 108 | if(WIN32) |
| 93 | set(BUILD_NC false) | 109 | set(BUILD_NC false) |
| 94 | if(MINGW) | 110 | if(MINGW) |
| @@ -127,7 +143,7 @@ add_definitions(-D__END_HIDDEN_DECLS=) | |||
| 127 | set(CMAKE_POSITION_INDEPENDENT_CODE true) | 143 | set(CMAKE_POSITION_INDEPENDENT_CODE true) |
| 128 | 144 | ||
| 129 | if (CMAKE_COMPILER_IS_GNUCC OR CMAKE_C_COMPILER_ID MATCHES "Clang") | 145 | if (CMAKE_COMPILER_IS_GNUCC OR CMAKE_C_COMPILER_ID MATCHES "Clang") |
| 130 | add_definitions(-Wno-pointer-sign) | 146 | add_compile_options($<$<COMPILE_LANGUAGE:C>:-Wno-pointer-sign>) |
| 131 | endif() | 147 | endif() |
| 132 | 148 | ||
| 133 | if(WIN32) | 149 | if(WIN32) |
| @@ -158,17 +174,21 @@ if(MSVC) | |||
| 158 | set(MSVC_DISABLED_WARNINGS_LIST | 174 | set(MSVC_DISABLED_WARNINGS_LIST |
| 159 | "C4018" # 'expression' : signed/unsigned mismatch | 175 | "C4018" # 'expression' : signed/unsigned mismatch |
| 160 | "C4057" # 'operator' : 'identifier1' indirection to | 176 | "C4057" # 'operator' : 'identifier1' indirection to |
| 161 | # slightly different base types from 'identifier2' | 177 | # slightly different base types from 'identifier2' |
| 162 | "C4100" # 'identifier' : unreferenced formal parameter | 178 | "C4100" # 'identifier' : unreferenced formal parameter |
| 163 | "C4127" # conditional expression is constant | 179 | "C4127" # conditional expression is constant |
| 180 | "C4132" # 'object' : const object should be initialized | ||
| 164 | "C4146" # unary minus operator applied to unsigned type, | 181 | "C4146" # unary minus operator applied to unsigned type, |
| 165 | # result still unsigned | 182 | # result still unsigned |
| 183 | "C4206" # nonstandard extension used : translation unit is empty | ||
| 166 | "C4244" # 'argument' : conversion from 'type1' to 'type2', | 184 | "C4244" # 'argument' : conversion from 'type1' to 'type2', |
| 167 | # possible loss of data | 185 | # possible loss of data |
| 168 | "C4245" # 'conversion' : conversion from 'type1' to 'type2', | 186 | "C4245" # 'conversion' : conversion from 'type1' to 'type2', |
| 169 | # signed/unsigned mismatch | 187 | # signed/unsigned mismatch |
| 170 | "C4267" # 'var' : conversion from 'size_t' to 'type', | 188 | "C4267" # 'var' : conversion from 'size_t' to 'type', |
| 171 | # possible loss of data | 189 | # possible loss of data |
| 190 | "C4295" # 'array' : array is too small to include a terminating | ||
| 191 | # null character | ||
| 172 | "C4389" # 'operator' : signed/unsigned mismatch | 192 | "C4389" # 'operator' : signed/unsigned mismatch |
| 173 | "C4706" # assignment within conditional expression | 193 | "C4706" # assignment within conditional expression |
| 174 | "C4996" # The POSIX name for this item is deprecated. | 194 | "C4996" # The POSIX name for this item is deprecated. |
| @@ -200,21 +220,38 @@ else() | |||
| 200 | set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wall") | 220 | set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wall") |
| 201 | endif() | 221 | endif() |
| 202 | 222 | ||
| 223 | # XXX - needs _GNU_SOURCE on linux | ||
| 203 | check_function_exists(asprintf HAVE_ASPRINTF) | 224 | check_function_exists(asprintf HAVE_ASPRINTF) |
| 204 | if(HAVE_ASPRINTF) | 225 | if(HAVE_ASPRINTF) |
| 205 | add_definitions(-DHAVE_ASPRINTF) | 226 | add_definitions(-DHAVE_ASPRINTF) |
| 206 | endif() | 227 | endif() |
| 207 | 228 | ||
| 208 | check_function_exists(getopt HAVE_GETOPT) | 229 | check_symbol_exists(ftruncate "unistd.h" HAVE_FTRUNCATE) |
| 230 | if(HAVE_FTRUNCATE) | ||
| 231 | add_definitions(-DHAVE_FTRUNCATE) | ||
| 232 | endif() | ||
| 233 | |||
| 234 | check_symbol_exists(getdelim "stdio.h" HAVE_GETDELIM) | ||
| 235 | if(HAVE_GETDELIM) | ||
| 236 | add_definitions(-DHAVE_GETDELIM) | ||
| 237 | endif() | ||
| 238 | |||
| 239 | check_symbol_exists(getline "stdio.h" HAVE_GETLINE) | ||
| 240 | if(HAVE_GETLINE) | ||
| 241 | add_definitions(-DHAVE_GETLINE) | ||
| 242 | endif() | ||
| 243 | |||
| 244 | check_symbol_exists(getopt "unistd.h" HAVE_GETOPT) | ||
| 209 | if(HAVE_GETOPT) | 245 | if(HAVE_GETOPT) |
| 210 | add_definitions(-DHAVE_GETOPT) | 246 | add_definitions(-DHAVE_GETOPT) |
| 211 | endif() | 247 | endif() |
| 212 | 248 | ||
| 213 | check_function_exists(reallocarray HAVE_REALLOCARRAY) | 249 | check_symbol_exists(reallocarray "stdlib.h" HAVE_REALLOCARRAY) |
| 214 | if(HAVE_REALLOCARRAY) | 250 | if(HAVE_REALLOCARRAY) |
| 215 | add_definitions(-DHAVE_REALLOCARRAY) | 251 | add_definitions(-DHAVE_REALLOCARRAY) |
| 216 | endif() | 252 | endif() |
| 217 | 253 | ||
| 254 | # XXX strcasecmp() is in strings.h which isn't available everywhere | ||
| 218 | check_function_exists(strcasecmp HAVE_STRCASECMP) | 255 | check_function_exists(strcasecmp HAVE_STRCASECMP) |
| 219 | if(HAVE_STRCASECMP) | 256 | if(HAVE_STRCASECMP) |
| 220 | add_definitions(-DHAVE_STRCASECMP) | 257 | add_definitions(-DHAVE_STRCASECMP) |
| @@ -222,18 +259,18 @@ endif() | |||
| 222 | 259 | ||
| 223 | # Emscripten's strlcat and strlcpy triggers ASAN errors | 260 | # Emscripten's strlcat and strlcpy triggers ASAN errors |
| 224 | if(NOT EMSCRIPTEN) | 261 | if(NOT EMSCRIPTEN) |
| 225 | check_function_exists(strlcat HAVE_STRLCAT) | 262 | check_symbol_exists(strlcat "string.h" HAVE_STRLCAT) |
| 226 | if(HAVE_STRLCAT) | 263 | if(HAVE_STRLCAT) |
| 227 | add_definitions(-DHAVE_STRLCAT) | 264 | add_definitions(-DHAVE_STRLCAT) |
| 228 | endif() | 265 | endif() |
| 229 | 266 | ||
| 230 | check_function_exists(strlcpy HAVE_STRLCPY) | 267 | check_symbol_exists(strlcpy "string.h" HAVE_STRLCPY) |
| 231 | if(HAVE_STRLCPY) | 268 | if(HAVE_STRLCPY) |
| 232 | add_definitions(-DHAVE_STRLCPY) | 269 | add_definitions(-DHAVE_STRLCPY) |
| 233 | endif() | 270 | endif() |
| 234 | endif() | 271 | endif() |
| 235 | 272 | ||
| 236 | check_function_exists(strndup HAVE_STRNDUP) | 273 | check_symbol_exists(strndup "string.h" HAVE_STRNDUP) |
| 237 | if(HAVE_STRNDUP) | 274 | if(HAVE_STRNDUP) |
| 238 | add_definitions(-DHAVE_STRNDUP) | 275 | add_definitions(-DHAVE_STRNDUP) |
| 239 | endif() | 276 | endif() |
| @@ -242,62 +279,64 @@ if(WIN32) | |||
| 242 | set(HAVE_STRNLEN true) | 279 | set(HAVE_STRNLEN true) |
| 243 | add_definitions(-DHAVE_STRNLEN) | 280 | add_definitions(-DHAVE_STRNLEN) |
| 244 | else() | 281 | else() |
| 245 | check_function_exists(strnlen HAVE_STRNLEN) | 282 | check_symbol_exists(strnlen "string.h" HAVE_STRNLEN) |
| 246 | if(HAVE_STRNLEN) | 283 | if(HAVE_STRNLEN) |
| 247 | add_definitions(-DHAVE_STRNLEN) | 284 | add_definitions(-DHAVE_STRNLEN) |
| 248 | endif() | 285 | endif() |
| 249 | endif() | 286 | endif() |
| 250 | 287 | ||
| 251 | check_function_exists(strsep HAVE_STRSEP) | 288 | check_symbol_exists(strsep "string.h" HAVE_STRSEP) |
| 252 | if(HAVE_STRSEP) | 289 | if(HAVE_STRSEP) |
| 253 | add_definitions(-DHAVE_STRSEP) | 290 | add_definitions(-DHAVE_STRSEP) |
| 254 | endif() | 291 | endif() |
| 255 | 292 | ||
| 256 | check_function_exists(strtonum HAVE_STRTONUM) | 293 | check_symbol_exists(strtonum "stdlib.h" HAVE_STRTONUM) |
| 257 | if(HAVE_STRTONUM) | 294 | if(HAVE_STRTONUM) |
| 258 | add_definitions(-DHAVE_STRTONUM) | 295 | add_definitions(-DHAVE_STRTONUM) |
| 259 | endif() | 296 | endif() |
| 260 | 297 | ||
| 261 | check_function_exists(arc4random_buf HAVE_ARC4RANDOM_BUF) | 298 | check_symbol_exists(arc4random_buf "stdlib.h" HAVE_ARC4RANDOM_BUF) |
| 262 | if(HAVE_ARC4RANDOM_BUF) | 299 | if(HAVE_ARC4RANDOM_BUF) |
| 263 | add_definitions(-DHAVE_ARC4RANDOM_BUF) | 300 | add_definitions(-DHAVE_ARC4RANDOM_BUF) |
| 264 | endif() | 301 | endif() |
| 265 | 302 | ||
| 266 | check_function_exists(arc4random_uniform HAVE_ARC4RANDOM_UNIFORM) | 303 | check_symbol_exists(arc4random_uniform "stdlib.h" HAVE_ARC4RANDOM_UNIFORM) |
| 267 | if(HAVE_ARC4RANDOM_UNIFORM) | 304 | if(HAVE_ARC4RANDOM_UNIFORM) |
| 268 | add_definitions(-DHAVE_ARC4RANDOM_UNIFORM) | 305 | add_definitions(-DHAVE_ARC4RANDOM_UNIFORM) |
| 269 | endif() | 306 | endif() |
| 270 | 307 | ||
| 271 | check_function_exists(explicit_bzero HAVE_EXPLICIT_BZERO) | 308 | check_symbol_exists(explicit_bzero "string.h" HAVE_EXPLICIT_BZERO) |
| 272 | if(HAVE_EXPLICIT_BZERO) | 309 | if(HAVE_EXPLICIT_BZERO) |
| 273 | add_definitions(-DHAVE_EXPLICIT_BZERO) | 310 | add_definitions(-DHAVE_EXPLICIT_BZERO) |
| 274 | endif() | 311 | endif() |
| 275 | 312 | ||
| 276 | check_function_exists(getauxval HAVE_GETAUXVAL) | 313 | check_symbol_exists(getauxval "sys/auxv.h" HAVE_GETAUXVAL) |
| 277 | if(HAVE_GETAUXVAL) | 314 | if(HAVE_GETAUXVAL) |
| 278 | add_definitions(-DHAVE_GETAUXVAL) | 315 | add_definitions(-DHAVE_GETAUXVAL) |
| 279 | endif() | 316 | endif() |
| 280 | 317 | ||
| 318 | # XXX macos fails to find getentropy with check_symbol_exists() | ||
| 281 | check_function_exists(getentropy HAVE_GETENTROPY) | 319 | check_function_exists(getentropy HAVE_GETENTROPY) |
| 282 | if(HAVE_GETENTROPY) | 320 | if(HAVE_GETENTROPY) |
| 283 | add_definitions(-DHAVE_GETENTROPY) | 321 | add_definitions(-DHAVE_GETENTROPY) |
| 284 | endif() | 322 | endif() |
| 285 | 323 | ||
| 286 | check_symbol_exists(getpagesize unistd.h HAVE_GETPAGESIZE) | 324 | check_symbol_exists(getpagesize "unistd.h" HAVE_GETPAGESIZE) |
| 287 | if(HAVE_GETPAGESIZE) | 325 | if(HAVE_GETPAGESIZE) |
| 288 | add_definitions(-DHAVE_GETPAGESIZE) | 326 | add_definitions(-DHAVE_GETPAGESIZE) |
| 289 | endif() | 327 | endif() |
| 290 | 328 | ||
| 291 | check_function_exists(getprogname HAVE_GETPROGNAME) | 329 | check_symbol_exists(getprogname "stdlib.h" HAVE_GETPROGNAME) |
| 292 | if(HAVE_GETPROGNAME) | 330 | if(HAVE_GETPROGNAME) |
| 293 | add_definitions(-DHAVE_GETPROGNAME) | 331 | add_definitions(-DHAVE_GETPROGNAME) |
| 294 | endif() | 332 | endif() |
| 295 | 333 | ||
| 296 | check_function_exists(syslog_r HAVE_SYSLOG_R) | 334 | check_symbol_exists(syslog_r "syslog.h;stdarg.h" HAVE_SYSLOG_R) |
| 297 | if(HAVE_SYSLOG_R) | 335 | if(HAVE_SYSLOG_R) |
| 298 | add_definitions(-DHAVE_SYSLOG_R) | 336 | add_definitions(-DHAVE_SYSLOG_R) |
| 299 | endif() | 337 | endif() |
| 300 | 338 | ||
| 339 | # XXX - needs _GNU_SOURCE on linux | ||
| 301 | check_function_exists(syslog HAVE_SYSLOG) | 340 | check_function_exists(syslog HAVE_SYSLOG) |
| 302 | if(HAVE_SYSLOG) | 341 | if(HAVE_SYSLOG) |
| 303 | add_definitions(-DHAVE_SYSLOG) | 342 | add_definitions(-DHAVE_SYSLOG) |
| @@ -308,16 +347,17 @@ if(HAVE_TIMESPECSUB) | |||
| 308 | add_definitions(-DHAVE_TIMESPECSUB) | 347 | add_definitions(-DHAVE_TIMESPECSUB) |
| 309 | endif() | 348 | endif() |
| 310 | 349 | ||
| 311 | check_function_exists(timingsafe_bcmp HAVE_TIMINGSAFE_BCMP) | 350 | check_symbol_exists(timingsafe_bcmp "string.h" HAVE_TIMINGSAFE_BCMP) |
| 312 | if(HAVE_TIMINGSAFE_BCMP) | 351 | if(HAVE_TIMINGSAFE_BCMP) |
| 313 | add_definitions(-DHAVE_TIMINGSAFE_BCMP) | 352 | add_definitions(-DHAVE_TIMINGSAFE_BCMP) |
| 314 | endif() | 353 | endif() |
| 315 | 354 | ||
| 316 | check_function_exists(timingsafe_memcmp HAVE_TIMINGSAFE_MEMCMP) | 355 | check_symbol_exists(timingsafe_memcmp "string.h" HAVE_TIMINGSAFE_MEMCMP) |
| 317 | if(HAVE_TIMINGSAFE_MEMCMP) | 356 | if(HAVE_TIMINGSAFE_MEMCMP) |
| 318 | add_definitions(-DHAVE_TIMINGSAFE_MEMCMP) | 357 | add_definitions(-DHAVE_TIMINGSAFE_MEMCMP) |
| 319 | endif() | 358 | endif() |
| 320 | 359 | ||
| 360 | # XXX - needs _GNU_SOURCE on linux | ||
| 321 | check_function_exists(memmem HAVE_MEMMEM) | 361 | check_function_exists(memmem HAVE_MEMMEM) |
| 322 | if(HAVE_MEMMEM) | 362 | if(HAVE_MEMMEM) |
| 323 | add_definitions(-DHAVE_MEMMEM) | 363 | add_definitions(-DHAVE_MEMMEM) |
| @@ -343,6 +383,16 @@ if(HAVE_NETINET_IP_H) | |||
| 343 | add_definitions(-DHAVE_NETINET_IP_H) | 383 | add_definitions(-DHAVE_NETINET_IP_H) |
| 344 | endif() | 384 | endif() |
| 345 | 385 | ||
| 386 | check_include_files(resolv.h HAVE_RESOLV_H) | ||
| 387 | if(HAVE_RESOLV_H) | ||
| 388 | add_definitions(-DHAVE_RESOLV_H) | ||
| 389 | endif() | ||
| 390 | |||
| 391 | check_include_files(arpa/nameser.h HAVE_ARPA_NAMESER_H) | ||
| 392 | if(HAVE_ARPA_NAMESER_H) | ||
| 393 | add_definitions(-DHAVE_ARPA_NAMESER_H) | ||
| 394 | endif() | ||
| 395 | |||
| 346 | # This isn't ready for universal binaries yet, since we do conditional | 396 | # This isn't ready for universal binaries yet, since we do conditional |
| 347 | # compilation based on the architecture, but this makes cross compiling for a | 397 | # compilation based on the architecture, but this makes cross compiling for a |
| 348 | # single architecture work on macOS at least. | 398 | # single architecture work on macOS at least. |
| @@ -352,20 +402,30 @@ if(APPLE AND (NOT CMAKE_OSX_ARCHITECTURES STREQUAL "")) | |||
| 352 | set(CMAKE_SYSTEM_PROCESSOR "${CMAKE_OSX_ARCHITECTURES}") | 402 | set(CMAKE_SYSTEM_PROCESSOR "${CMAKE_OSX_ARCHITECTURES}") |
| 353 | endif() | 403 | endif() |
| 354 | 404 | ||
| 405 | # CMAKE_SYSTEM_PROCESSOR is not consistently set to the target architecture. | ||
| 406 | # https://cmake.org/cmake/help/latest/variable/CMAKE_SYSTEM_PROCESSOR.html | ||
| 407 | if (WIN32 AND (NOT CMAKE_GENERATOR_PLATFORM STREQUAL "")) | ||
| 408 | message("CMAKE_SYSTEM_PROCESSOR: ${CMAKE_SYSTEM_PROCESSOR}") | ||
| 409 | message("CMAKE_GENERATOR_PLATFORM: ${CMAKE_GENERATOR_PLATFORM}") | ||
| 410 | set(CMAKE_SYSTEM_PROCESSOR "${CMAKE_GENERATOR_PLATFORM}") | ||
| 411 | endif() | ||
| 412 | |||
| 355 | if(CMAKE_SYSTEM_PROCESSOR MATCHES "(aarch64|arm64|ARM64)") | 413 | if(CMAKE_SYSTEM_PROCESSOR MATCHES "(aarch64|arm64|ARM64)") |
| 356 | set(HOST_AARCH64 true) | 414 | set(HOST_AARCH64 true) |
| 357 | if(WIN32) | ||
| 358 | set(ENABLE_ASM false) | ||
| 359 | endif() | ||
| 360 | elseif(CMAKE_SYSTEM_PROCESSOR MATCHES "arm") | 415 | elseif(CMAKE_SYSTEM_PROCESSOR MATCHES "arm") |
| 361 | set(HOST_ARM true) | 416 | set(HOST_ARM true) |
| 417 | if(APPLE) | ||
| 418 | set(ENABLE_ASM false) | ||
| 419 | endif() | ||
| 362 | elseif(CMAKE_SYSTEM_NAME STREQUAL "SunOS" AND CMAKE_SYSTEM_PROCESSOR MATCHES "i386") | 420 | elseif(CMAKE_SYSTEM_NAME STREQUAL "SunOS" AND CMAKE_SYSTEM_PROCESSOR MATCHES "i386") |
| 363 | set(HOST_X86_64 true) | 421 | set(HOST_X86_64 true) |
| 364 | elseif(CMAKE_SYSTEM_PROCESSOR MATCHES "(x86_64|amd64|AMD64)") | 422 | elseif(CMAKE_SYSTEM_PROCESSOR MATCHES "(x86_64|x64|amd64|AMD64)") |
| 365 | set(HOST_X86_64 true) | 423 | set(HOST_X86_64 true) |
| 366 | elseif(CMAKE_SYSTEM_PROCESSOR MATCHES "(i[3-6]86|[xX]86)") | 424 | elseif(CMAKE_SYSTEM_PROCESSOR MATCHES "(i[3-6]86|[xX]86|Win32)") |
| 367 | set(ENABLE_ASM false) | 425 | set(ENABLE_ASM false) |
| 368 | set(HOST_I386 true) | 426 | set(HOST_I386 true) |
| 427 | elseif(CMAKE_SYSTEM_PROCESSOR MATCHES "loongarch64") | ||
| 428 | set(HOST_LOONGARCH64 true) | ||
| 369 | elseif(CMAKE_SYSTEM_PROCESSOR MATCHES "mips64") | 429 | elseif(CMAKE_SYSTEM_PROCESSOR MATCHES "mips64") |
| 370 | set(HOST_MIPS64 true) | 430 | set(HOST_MIPS64 true) |
| 371 | elseif(CMAKE_SYSTEM_PROCESSOR MATCHES "mips") | 431 | elseif(CMAKE_SYSTEM_PROCESSOR MATCHES "mips") |
| @@ -373,7 +433,7 @@ elseif(CMAKE_SYSTEM_PROCESSOR MATCHES "mips") | |||
| 373 | elseif(CMAKE_SYSTEM_PROCESSOR MATCHES "powerpc") | 433 | elseif(CMAKE_SYSTEM_PROCESSOR MATCHES "powerpc") |
| 374 | set(HOST_POWERPC true) | 434 | set(HOST_POWERPC true) |
| 375 | elseif(CMAKE_SYSTEM_PROCESSOR MATCHES "ppc64") | 435 | elseif(CMAKE_SYSTEM_PROCESSOR MATCHES "ppc64") |
| 376 | set(HOST_PPC64 true) | 436 | set(HOST_POWERPC64 true) |
| 377 | elseif(CMAKE_SYSTEM_PROCESSOR MATCHES "riscv64") | 437 | elseif(CMAKE_SYSTEM_PROCESSOR MATCHES "riscv64") |
| 378 | set(HOST_RISCV64 true) | 438 | set(HOST_RISCV64 true) |
| 379 | elseif(CMAKE_SYSTEM_PROCESSOR MATCHES "sparc64") | 439 | elseif(CMAKE_SYSTEM_PROCESSOR MATCHES "sparc64") |
| @@ -384,21 +444,18 @@ endif() | |||
| 384 | 444 | ||
| 385 | if(ENABLE_ASM) | 445 | if(ENABLE_ASM) |
| 386 | if(CMAKE_C_COMPILER_ABI STREQUAL "ELF") | 446 | if(CMAKE_C_COMPILER_ABI STREQUAL "ELF") |
| 387 | if(CMAKE_SYSTEM_PROCESSOR MATCHES "(x86_64|amd64)") | 447 | if(HOST_X86_64) |
| 388 | set(HOST_ASM_ELF_X86_64 true) | 448 | set(HOST_ASM_ELF_X86_64 true) |
| 389 | elseif(CMAKE_SYSTEM_PROCESSOR MATCHES "arm" AND | 449 | elseif(CMAKE_SYSTEM_NAME STREQUAL "SunOS" AND HOST_I386) |
| 390 | NOT CMAKE_SYSTEM_PROCESSOR MATCHES "arm64") | ||
| 391 | set(HOST_ASM_ELF_ARMV4 true) | ||
| 392 | elseif(CMAKE_SYSTEM_NAME STREQUAL "SunOS" AND CMAKE_SYSTEM_PROCESSOR MATCHES "i386") | ||
| 393 | set(HOST_ASM_ELF_X86_64 true) | 450 | set(HOST_ASM_ELF_X86_64 true) |
| 394 | endif() | 451 | endif() |
| 395 | add_definitions(-DHAVE_GNU_STACK) | 452 | add_definitions(-DHAVE_GNU_STACK) |
| 396 | elseif(APPLE AND CMAKE_SYSTEM_PROCESSOR MATCHES "x86_64") | 453 | elseif(APPLE AND HOST_X86_64) |
| 397 | set(HOST_ASM_MACOSX_X86_64 true) | 454 | set(HOST_ASM_MACOSX_X86_64 true) |
| 398 | elseif(MSVC AND (CMAKE_GENERATOR MATCHES "Win64" OR CMAKE_GENERATOR_PLATFORM STREQUAL "x64")) | 455 | elseif(MSVC AND (CMAKE_GENERATOR MATCHES "Win64" OR CMAKE_GENERATOR_PLATFORM STREQUAL "x64")) |
| 399 | set(HOST_ASM_MASM_X86_64 true) | 456 | set(HOST_ASM_MASM_X86_64 true) |
| 400 | ENABLE_LANGUAGE(ASM_MASM) | 457 | ENABLE_LANGUAGE(ASM_MASM) |
| 401 | elseif(MINGW AND CMAKE_SYSTEM_PROCESSOR MATCHES "x86_64") | 458 | elseif(MINGW AND HOST_X86_64) |
| 402 | set(HOST_ASM_MINGW64_X86_64 true) | 459 | set(HOST_ASM_MINGW64_X86_64 true) |
| 403 | endif() | 460 | endif() |
| 404 | endif() | 461 | endif() |
| @@ -441,10 +498,10 @@ if(OPENSSLDIR STREQUAL "") | |||
| 441 | if(WIN32) | 498 | if(WIN32) |
| 442 | set(OPENSSLDIR "C:/Windows/libressl/ssl") | 499 | set(OPENSSLDIR "C:/Windows/libressl/ssl") |
| 443 | else() | 500 | else() |
| 444 | set(OPENSSLDIR "${CMAKE_INSTALL_PREFIX}/etc/ssl") | 501 | set(OPENSSLDIR "${CMAKE_INSTALL_SYSCONFDIR}/ssl") |
| 445 | endif() | 502 | endif() |
| 446 | 503 | ||
| 447 | set(CONF_DIR "${CMAKE_INSTALL_PREFIX}/etc/ssl") | 504 | set(CONF_DIR "${CMAKE_INSTALL_SYSCONFDIR}/ssl") |
| 448 | else() | 505 | else() |
| 449 | set(CONF_DIR "${OPENSSLDIR}") | 506 | set(CONF_DIR "${OPENSSLDIR}") |
| 450 | endif() | 507 | endif() |
| @@ -512,8 +569,16 @@ if(ENABLE_LIBRESSL_INSTALL) | |||
| 512 | # Create pkgconfig files. | 569 | # Create pkgconfig files. |
| 513 | set(prefix ${CMAKE_INSTALL_PREFIX}) | 570 | set(prefix ${CMAKE_INSTALL_PREFIX}) |
| 514 | set(exec_prefix \${prefix}) | 571 | set(exec_prefix \${prefix}) |
| 515 | set(libdir \${exec_prefix}/${CMAKE_INSTALL_LIBDIR}) | 572 | if(IS_ABSOLUTE ${CMAKE_INSTALL_LIBDIR}) |
| 516 | set(includedir \${prefix}/include) | 573 | set(libdir ${CMAKE_INSTALL_LIBDIR}) |
| 574 | else() | ||
| 575 | set(libdir \${exec_prefix}/${CMAKE_INSTALL_LIBDIR}) | ||
| 576 | endif() | ||
| 577 | if(IS_ABSOLUTE ${CMAKE_INSTALL_INCLUDEDIR}) | ||
| 578 | set(includedir ${CMAKE_INSTALL_INCLUDEDIR}) | ||
| 579 | else() | ||
| 580 | set(includedir \${prefix}/${CMAKE_INSTALL_INCLUDEDIR}) | ||
| 581 | endif() | ||
| 517 | if(PLATFORM_LIBS) | 582 | if(PLATFORM_LIBS) |
| 518 | string(REGEX REPLACE ";" " -l" PLATFORM_LDADD ";${PLATFORM_LIBS}") | 583 | string(REGEX REPLACE ";" " -l" PLATFORM_LDADD ";${PLATFORM_LIBS}") |
| 519 | endif() | 584 | endif() |
| @@ -0,0 +1,133 @@ | |||
| 1 | |||
| 2 | LibreSSL files are retained under the copyright of the authors. New | ||
| 3 | additions are ISC licensed as per OpenBSD's normal licensing policy, | ||
| 4 | or are placed in the public domain. | ||
| 5 | |||
| 6 | The OpenSSL code is distributed under the terms of the original OpenSSL | ||
| 7 | licenses which follow: | ||
| 8 | |||
| 9 | LICENSE ISSUES | ||
| 10 | ============== | ||
| 11 | |||
| 12 | The OpenSSL toolkit stays under a dual license, i.e. both the conditions of | ||
| 13 | the OpenSSL License and the original SSLeay license apply to the toolkit. | ||
| 14 | See below for the actual license texts. In case of any license issues | ||
| 15 | related to OpenSSL please contact openssl-core@openssl.org. | ||
| 16 | |||
| 17 | OpenSSL License | ||
| 18 | --------------- | ||
| 19 | |||
| 20 | /* ==================================================================== | ||
| 21 | * Copyright (c) 1998-2011 The OpenSSL Project. All rights reserved. | ||
| 22 | * | ||
| 23 | * Redistribution and use in source and binary forms, with or without | ||
| 24 | * modification, are permitted provided that the following conditions | ||
| 25 | * are met: | ||
| 26 | * | ||
| 27 | * 1. Redistributions of source code must retain the above copyright | ||
| 28 | * notice, this list of conditions and the following disclaimer. | ||
| 29 | * | ||
| 30 | * 2. Redistributions in binary form must reproduce the above copyright | ||
| 31 | * notice, this list of conditions and the following disclaimer in | ||
| 32 | * the documentation and/or other materials provided with the | ||
| 33 | * distribution. | ||
| 34 | * | ||
| 35 | * 3. All advertising materials mentioning features or use of this | ||
| 36 | * software must display the following acknowledgment: | ||
| 37 | * "This product includes software developed by the OpenSSL Project | ||
| 38 | * for use in the OpenSSL Toolkit. (http://www.openssl.org/)" | ||
| 39 | * | ||
| 40 | * 4. The names "OpenSSL Toolkit" and "OpenSSL Project" must not be used to | ||
| 41 | * endorse or promote products derived from this software without | ||
| 42 | * prior written permission. For written permission, please contact | ||
| 43 | * openssl-core@openssl.org. | ||
| 44 | * | ||
| 45 | * 5. Products derived from this software may not be called "OpenSSL" | ||
| 46 | * nor may "OpenSSL" appear in their names without prior written | ||
| 47 | * permission of the OpenSSL Project. | ||
| 48 | * | ||
| 49 | * 6. Redistributions of any form whatsoever must retain the following | ||
| 50 | * acknowledgment: | ||
| 51 | * "This product includes software developed by the OpenSSL Project | ||
| 52 | * for use in the OpenSSL Toolkit (http://www.openssl.org/)" | ||
| 53 | * | ||
| 54 | * THIS SOFTWARE IS PROVIDED BY THE OpenSSL PROJECT ``AS IS'' AND ANY | ||
| 55 | * EXPRESSED OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE | ||
| 56 | * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR | ||
| 57 | * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE OpenSSL PROJECT OR | ||
| 58 | * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, | ||
| 59 | * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT | ||
| 60 | * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; | ||
| 61 | * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) | ||
| 62 | * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, | ||
| 63 | * STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) | ||
| 64 | * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED | ||
| 65 | * OF THE POSSIBILITY OF SUCH DAMAGE. | ||
| 66 | * ==================================================================== | ||
| 67 | * | ||
| 68 | * This product includes cryptographic software written by Eric Young | ||
| 69 | * (eay@cryptsoft.com). This product includes software written by Tim | ||
| 70 | * Hudson (tjh@cryptsoft.com). | ||
| 71 | * | ||
| 72 | */ | ||
| 73 | |||
| 74 | Original SSLeay License | ||
| 75 | ----------------------- | ||
| 76 | |||
| 77 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) | ||
| 78 | * All rights reserved. | ||
| 79 | * | ||
| 80 | * This package is an SSL implementation written | ||
| 81 | * by Eric Young (eay@cryptsoft.com). | ||
| 82 | * The implementation was written so as to conform with Netscapes SSL. | ||
| 83 | * | ||
| 84 | * This library is free for commercial and non-commercial use as long as | ||
| 85 | * the following conditions are aheared to. The following conditions | ||
| 86 | * apply to all code found in this distribution, be it the RC4, RSA, | ||
| 87 | * lhash, DES, etc., code; not just the SSL code. The SSL documentation | ||
| 88 | * included with this distribution is covered by the same copyright terms | ||
| 89 | * except that the holder is Tim Hudson (tjh@cryptsoft.com). | ||
| 90 | * | ||
| 91 | * Copyright remains Eric Young's, and as such any Copyright notices in | ||
| 92 | * the code are not to be removed. | ||
| 93 | * If this package is used in a product, Eric Young should be given attribution | ||
| 94 | * as the author of the parts of the library used. | ||
| 95 | * This can be in the form of a textual message at program startup or | ||
| 96 | * in documentation (online or textual) provided with the package. | ||
| 97 | * | ||
| 98 | * Redistribution and use in source and binary forms, with or without | ||
| 99 | * modification, are permitted provided that the following conditions | ||
| 100 | * are met: | ||
| 101 | * 1. Redistributions of source code must retain the copyright | ||
| 102 | * notice, this list of conditions and the following disclaimer. | ||
| 103 | * 2. Redistributions in binary form must reproduce the above copyright | ||
| 104 | * notice, this list of conditions and the following disclaimer in the | ||
| 105 | * documentation and/or other materials provided with the distribution. | ||
| 106 | * 3. All advertising materials mentioning features or use of this software | ||
| 107 | * must display the following acknowledgement: | ||
| 108 | * "This product includes cryptographic software written by | ||
| 109 | * Eric Young (eay@cryptsoft.com)" | ||
| 110 | * The word 'cryptographic' can be left out if the rouines from the library | ||
| 111 | * being used are not cryptographic related :-). | ||
| 112 | * 4. If you include any Windows specific code (or a derivative thereof) from | ||
| 113 | * the apps directory (application code) you must include an acknowledgement: | ||
| 114 | * "This product includes software written by Tim Hudson (tjh@cryptsoft.com)" | ||
| 115 | * | ||
| 116 | * THIS SOFTWARE IS PROVIDED BY ERIC YOUNG ``AS IS'' AND | ||
| 117 | * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE | ||
| 118 | * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE | ||
| 119 | * ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE | ||
| 120 | * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL | ||
| 121 | * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS | ||
| 122 | * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) | ||
| 123 | * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT | ||
| 124 | * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY | ||
| 125 | * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF | ||
| 126 | * SUCH DAMAGE. | ||
| 127 | * | ||
| 128 | * The licence and distribution terms for any publically available version or | ||
| 129 | * derivative of this code cannot be changed. i.e. this code cannot simply be | ||
| 130 | * copied and put under another distribution licence | ||
| 131 | * [including the GNU Public Licence.] | ||
| 132 | */ | ||
| 133 | |||
| @@ -1,7 +1,7 @@ | |||
| 1 | Because this project is maintained both in the OpenBSD tree using CVS and in | 1 | Because this project is maintained both in the OpenBSD tree using CVS and in |
| 2 | Git, it can be confusing following all of the changes. | 2 | Git, it can be confusing following all of the changes. |
| 3 | 3 | ||
| 4 | Most of the libssl and libcrypto source code is is here in OpenBSD CVS: | 4 | Most of the libssl and libcrypto source code is here in OpenBSD CVS: |
| 5 | 5 | ||
| 6 | https://cvsweb.openbsd.org/cgi-bin/cvsweb/src/lib/libssl/ | 6 | https://cvsweb.openbsd.org/cgi-bin/cvsweb/src/lib/libssl/ |
| 7 | 7 | ||
| @@ -28,12 +28,181 @@ history is also available from Git. | |||
| 28 | 28 | ||
| 29 | LibreSSL Portable Release Notes: | 29 | LibreSSL Portable Release Notes: |
| 30 | 30 | ||
| 31 | 4.0.0 - In development | 31 | 4.3.0 - In development |
| 32 | |||
| 33 | * Internal improvements | ||
| 34 | - Remove the unused sequence number from X509_REVOKED. | ||
| 35 | - Replace a call to atoi() with strtonum() in nc(1) and replace a | ||
| 36 | misleading use of ntohs() with htons(). | ||
| 37 | * Compatibility changes | ||
| 38 | - Expose X509_VERIFY_PARAM_set_hostflags() as a public symbol. | ||
| 39 | - Provide SSL_SESSION_dup(). | ||
| 40 | * New features: support for MLKEM768_X25519 keyshare in TLS. | ||
| 41 | https://datatracker.ietf.org/doc/draft-ietf-tls-ecdhe-mlkem/ | ||
| 42 | * Bug fixes | ||
| 43 | - Ensure the group selected by a TLSv1.3 server for a | ||
| 44 | HelloRetryRequest is not one for which the client has | ||
| 45 | already sent a key share. | ||
| 46 | |||
| 47 | 4.2.0 - Stable release | ||
| 48 | |||
| 49 | * Portable changes | ||
| 50 | - Added explicit OpenBSD/ISC license to build system / scripts. | ||
| 51 | - Fixed compilation on more CPU targets by removing architecture-specific | ||
| 52 | definitions from header files. | ||
| 53 | - Fixed builds in deep paths by using relative paths for linking. | ||
| 54 | - Fixed Windows builds with Clang and CMake. | ||
| 55 | - Fixed Windows error handling accepting connections with nc. | ||
| 56 | - Fixed 32-bit ARM builds on Darwin. | ||
| 57 | * Internal improvements | ||
| 58 | - Cleaned up code implementing block cipher modes of operation. | ||
| 59 | Includes untangling a horrible #ifdef mess and removing a few | ||
| 60 | instances of undefined behavior. | ||
| 61 | - Removed assembly implementations of AES using bit slicing (BS-AES) | ||
| 62 | and vector permutation (VP-AES). | ||
| 63 | - Removed OPENSSL_SMALL_FOOTPRINT and OPENSSL_FIPSAPI. | ||
| 64 | - Implemented constant time EC field element operations to allow | ||
| 65 | elliptic curve operations without bignum arithmetic. | ||
| 66 | - Implemented an EC method using homogeneous projective coordinates. | ||
| 67 | This will allow exception-free elliptic curve arithmetic in | ||
| 68 | constant time in future releases. | ||
| 69 | - Started cleaning up the openssl speed implementation. | ||
| 70 | - The last SIGILL-based CPU capability detection was removed. | ||
| 71 | Instead, capabilities are now detected using a constructor on | ||
| 72 | library load, which improves the incomplete coverage by calls | ||
| 73 | to OPENSSL_init_crypto() on various entry points. | ||
| 74 | - Rework and simplify AES handling in EVP. In particular, AES-NI | ||
| 75 | is now handled in the AES internal code and no longer requires | ||
| 76 | the use of EVP. | ||
| 77 | - Added a public API for ML-KEM. This is not yet documented in a | ||
| 78 | manpage and may not be in its final form. This will be used to | ||
| 79 | support X25519MLKEM768 in libssl. | ||
| 80 | * Compatibility changes | ||
| 81 | - Removed the -msie_hack option from the openssl(1) ca subcommand. | ||
| 82 | - Removed parameters of the 239-bit prime curves from X9.62, H.5.2: | ||
| 83 | prime239v1, prime239v2, prime239v3. | ||
| 84 | - Increased default MAC salt length used by PKCS12_set_mac(3) to 16 | ||
| 85 | per recommendation of NIST SP 800-132. | ||
| 86 | - Encrypted PKCS#8 key files now use a default password-based key | ||
| 87 | derivation function that is acceptable in the present millenium. | ||
| 88 | - const corrected EVP_PKEY_get{0,1}_{DH,DSA,EC_KEY,RSA}(). | ||
| 89 | - X509_CRL_verify() now checks that the AlgorithmIdentifiers in the | ||
| 90 | signature and the tbsCertList are identical. | ||
| 91 | - Of the old *err() only PEMerr(), RSAerr(), and SSLerr() remain. | ||
| 92 | - Removed BIO_s_log(), X509_PKEY_{new,free}(), PEM_X509_INFO_read() | ||
| 93 | and PEM_X509_INFO_write_bio(). | ||
| 94 | - Re-expose the ASN.1 Boolean template items. | ||
| 95 | - opensslconf.h is now machine-independent. | ||
| 96 | * New features | ||
| 97 | - Allow specifying ALPN in nc(1) via -Talpn="http/1.1,http:/1.0". | ||
| 98 | * Bug fixes | ||
| 99 | - Avoid pointer arithmetic on NULL for memory BIOs. | ||
| 100 | - Fix leaks and use-after-frees in PKCS7 attribute handling. | ||
| 101 | - Ensure p and q in RSA private key have a minimum distance of | ||
| 102 | 2^(bits/2 - 100) as specified in NIST SP 800-56B Revision 2. | ||
| 103 | * Security fixes | ||
| 104 | - Fix out-of-bounds read and write, memory leaks and incorrect | ||
| 105 | error check for CMS enveloped data. | ||
| 106 | * Documentation | ||
| 107 | - Rewrote most of the EC documentation from scratch to be at least | ||
| 108 | somewhat accurate and intelligible. | ||
| 109 | - Updated documentation for SMIME_{read,write}* to match reality. | ||
| 110 | * Testing and proactive security | ||
| 111 | - Added a testing framework that will help deduplicating lots of | ||
| 112 | ad-hoc code in the regression tests. | ||
| 113 | - Converted the Wycheproof testing framework to use testvectors_v1. | ||
| 114 | This in combination with a few new tests significantly increases | ||
| 115 | regress coverage. | ||
| 116 | |||
| 117 | 4.1.0 - Stable release | ||
| 32 | 118 | ||
| 33 | * Portable changes | 119 | * Portable changes |
| 34 | - Added initial Emscripten support in CMake builds | 120 | - Added initial experimental support for loongarch64. |
| 121 | - Fixed compilation for mips32 and reenable CI. | ||
| 122 | - Fixed CMake builds on FreeBSD. | ||
| 123 | - Fixed the --prefix option for cmake --install. | ||
| 124 | - Fixed tests for MinGW due to missing sh(1). | ||
| 125 | * Internal improvements | ||
| 126 | - Cleaned up the error implementation. | ||
| 127 | - Many bug fixes and simplifications in the EC ASN.1 code. | ||
| 128 | - Corrected DER encoding for EC keys and parameters. | ||
| 129 | - Polished EC_POINT_{oct2point,point2oct}() internals. | ||
| 130 | - Rewrote the wNAF code for fast ECDSA verification. | ||
| 131 | - Improved the code setting compressed coordinates for EC points. | ||
| 132 | - Reworked CPU capabilities detection for amd64 and aarch64. | ||
| 133 | - New SHA-1, SHA-256 and SHA-512 assembly implementations for amd64. | ||
| 134 | These make use of the SHA-NI instruction if it is available and | ||
| 135 | replace the perl-generated assembly optimized for museum pieces. | ||
| 136 | These are not yet enabled in libressl-portable. | ||
| 137 | - New SHA-256 and SHA-512 assembly implementations for aarch64 | ||
| 138 | making use of the ARM Cryptographic Extension (CE). Not yet | ||
| 139 | enabled in libressl-portable. | ||
| 140 | - New simplified, readable MD5 implementation for amd64. | ||
| 141 | - Rewrote BN_bn2binpad() and its lebin siblings. | ||
| 142 | - The BIGNUMs in EC_GROUP and EC_POINT are now heap allocated. | ||
| 143 | - Rewrote TS_ASN1_INTEGER_print_bio(). | ||
| 144 | - Improved bit counter handling in MD5. | ||
| 145 | - Simplified and cleaned up the BN_RECP_CTX internals. | ||
| 146 | - Improved SM4 to match other symmetric ciphers more closely. | ||
| 147 | - Rewrote X509_NAME_oneline() and X509_NAME_print() using CBS/CBB. | ||
| 148 | - CRLs are now cached in the issuer cache like certificates. | ||
| 149 | - Replaced combinations of BN_MONT_CTX_new/set with an internal | ||
| 150 | BN_MONT_CTX_create(). | ||
| 151 | - Replaced BN_bn2hex() reimplementation in openssl(1) ca with | ||
| 152 | a proper API call. | ||
| 153 | - Fixed integer overflows due to signed shift in obj_dat.c. | ||
| 154 | - Improved some X509_VERIFY_PARAM internals and avoid an out of | ||
| 155 | bounds read from public API. | ||
| 156 | - Imported ML-KEM 768 and 1024 from BoringSSL (not yet public API). | ||
| 157 | * Compatibility changes | ||
| 158 | - Added an OPENSSL_INIT_NO_ATEXIT flag for OPENSSL_init_crypto(). | ||
| 159 | It has no effect since LibreSSL doesn't call atexit(). | ||
| 160 | - Elliptic curve parameters are only accepted if they encode a | ||
| 161 | built-in curve. | ||
| 162 | - EC_METHOD is no longer public and the API exposing it has been | ||
| 163 | removed. This includes EC_GROUP_new(), EC_GFp_mont_method(), | ||
| 164 | EC_GROUP_method_of() and EC_METHOD_get_field_type(). | ||
| 165 | - The precomputation stubs for EC_GROUP were removed. | ||
| 166 | - The API setting Jacobian projective coordinates for a point was | ||
| 167 | removed as were EC_POINTs_{mul,make_affine}(). | ||
| 168 | - All elliptic curves over fields with less than 224 bits and a | ||
| 169 | few more were removed from the built-in curves. This includes | ||
| 170 | all WTLS curves and P-192. | ||
| 171 | - It is no longer necessary to set RSA_FLAG_SIGN_VER to use the | ||
| 172 | sign and verify handlers set with RSA_meth_set_{sign,verify}. | ||
| 173 | - Removed the -C option to generate "C code" from the openssl(1) | ||
| 174 | dh, dhparam, dsaparam, ecparam, and x509 subcommands. | ||
| 175 | - Removed #error in headers when OPENSSL_NO_* is defined. | ||
| 176 | - CRYPTO_set_mem_functions() now matches OpenSSL 1.1 and | ||
| 177 | CRYPTO_set_mem_ex_functions() was removed. | ||
| 178 | - The tls_session_secret_cb_fn type now matches OpenSSL 1.1. | ||
| 179 | - Unexport X509_NAME_print() and X509_OBJECT_up_ref_count(). | ||
| 180 | - const corrected UI_OpenSSL() and BN_MONT_CTX_copy(). | ||
| 181 | - Support OPENSSL_NO_FILENAMES. | ||
| 182 | - Support SSL_OP_NO_RENEGOTIATION and SSL_OP_ALLOW_CLIENT_RENEGOTIATION. | ||
| 183 | - Export PKCS12_key_gen_uni() again. | ||
| 184 | * New features | ||
| 185 | - libtls has a new tls_peer_cert_common_name() API call to retrieve | ||
| 186 | the peer's common name without having to inspect the PEM. | ||
| 187 | * Bug fixes | ||
| 188 | - Plugged a leak in eckey_compute_pubkey(). | ||
| 189 | - Again allow the magic values -1, -2 and -3 for the salt length | ||
| 190 | of an RSA-PSS key in the EVP_PKEY_CTX_ctrl_str() interface. | ||
| 191 | - Fixed a few memory leaks in legacy code. | ||
| 192 | * Documentation | ||
| 193 | - The remaining undocumented public EVP API is now documented. | ||
| 194 | - Reorganization of existing documentation for clarity and accuracy. | ||
| 195 | * Testing and proactive security | ||
| 196 | - Improved regress coverage of the EC code. | ||
| 197 | |||
| 198 | 4.0.0 - Stable release | ||
| 199 | |||
| 200 | * Portable changes | ||
| 201 | - Added initial Emscripten support in CMake builds. | ||
| 35 | - Removed timegm() compatibility layer since all uses were replaced | 202 | - Removed timegm() compatibility layer since all uses were replaced |
| 36 | with OPENSSL_timegm(). Cleaned up the corresponding test harness. | 203 | with OPENSSL_timegm(). Cleaned up the corresponding test harness. |
| 204 | - The mips32 platform is no longer actively supported. | ||
| 205 | - Fixed Windows support for dates beyond 2038. | ||
| 37 | * Internal improvements | 206 | * Internal improvements |
| 38 | - Cleaned up parts of the conf directory. Simplified some logic, | 207 | - Cleaned up parts of the conf directory. Simplified some logic, |
| 39 | fixed memory leaks. | 208 | fixed memory leaks. |
| @@ -66,29 +235,68 @@ LibreSSL Portable Release Notes: | |||
| 66 | - Made most error string tables const. | 235 | - Made most error string tables const. |
| 67 | - Removed handling for SSLv2 client hello messages. | 236 | - Removed handling for SSLv2 client hello messages. |
| 68 | - Improvements in the openssl(1) speed app's signal handler. | 237 | - Improvements in the openssl(1) speed app's signal handler. |
| 69 | - Added support for TLS PRF in the EVP KDF API. | 238 | - Cleaned up various X509v3_* extension API. |
| 239 | - Unified the X.509v3 extension methods. | ||
| 240 | - Cleaned up cipher handling in SSL_SESSION. | ||
| 241 | - Removed get_cipher from SSL_METHOD. | ||
| 242 | - Rewrote CRYPTO_EX_DATA from scratch. The only intentional change of | ||
| 243 | behavior is that there is now a hard limit on the number of indexes | ||
| 244 | that can be allocated. | ||
| 245 | - Removed bogus connect() call from netcat. | ||
| 246 | - Uses of atoi() and strtol() in libcrypto were replaced with | ||
| 247 | strtonum(). | ||
| 248 | - Introduced crypto_arch.h which will contain the architecture | ||
| 249 | dependent code and defines rather than the public opensslconf.h. | ||
| 250 | - OPENSSL_cpu_caps() is now architecture independent. | ||
| 251 | - Reorganized the DES implementation to use fewer files and removed | ||
| 252 | optimizations for ancient processors and compilers. | ||
| 253 | * New features | ||
| 254 | - Added CRLfile option to the cms command of openssl(1) to specify | ||
| 255 | additional CRLs for use during verification. | ||
| 70 | * Documentation improvements | 256 | * Documentation improvements |
| 71 | - Removed documentation of no longer existing API. | 257 | - Removed documentation of no longer existing API. |
| 258 | - Unified the description of the obsolete ENGINE parameter that | ||
| 259 | needs to remain in many functions and should always be NULL. | ||
| 72 | * Testing and proactive security | 260 | * Testing and proactive security |
| 73 | - Switched the remaining tests to new certs. | 261 | - Switched the remaining tests to new certs. |
| 74 | * Compatibility changes | 262 | * Compatibility changes |
| 263 | - Protocol parsing in libtls was changed. The unsupported TLSv1.1 | ||
| 264 | and TLSv1.0 protocols are ignored and no longer enable or disable | ||
| 265 | TLSv1.2 in surprising ways. | ||
| 266 | - The dangerous EVP_PKEY*_check(3) family of functions was removed. | ||
| 267 | The openssl(1) pkey and pkeyparam commands no longer support the | ||
| 268 | -check and -pubcheck flags. | ||
| 75 | - The one-step hashing functions, MD4(), MD5(), RIPEMD160(), SHA1(), | 269 | - The one-step hashing functions, MD4(), MD5(), RIPEMD160(), SHA1(), |
| 76 | all SHA-2, and HMAC() no longer support returning a static buffer. | 270 | all SHA-2, and HMAC() no longer support returning a static buffer. |
| 77 | Callers must pass in a correctly sized buffer. | 271 | Callers must pass in a correctly sized buffer. |
| 272 | - Support for Whirlpool was removed. Applications still using this | ||
| 273 | should honor OPENSSL_NO_WHIRLPOOL. | ||
| 78 | - Removed workaround for F5 middle boxes. | 274 | - Removed workaround for F5 middle boxes. |
| 79 | - Removed the useless pem2.h, a public header that was added since | 275 | - Removed the useless pem2.h, a public header that was added since |
| 80 | it was too hard to add a prototype to one file. | 276 | it was too hard to add a single prototype to one file. |
| 277 | - Removed conf_api.h and the public API therein. | ||
| 278 | - Removed ssl2.h, ssl23.h and ui_compat.h. | ||
| 279 | - Numerous conf and attribute functions were removed. Some unused | ||
| 280 | types were removed, others were made opaque. | ||
| 281 | - Removed the deprecated HMAC_Init() function. | ||
| 282 | - Removed OPENSSL_load_builtin_modules(). | ||
| 283 | - Removed X509_REQ_{get,set}_extension_nids(). | ||
| 284 | - X509_check_trust() and was removed, X509_VAL was made opaque. | ||
| 81 | - Only specified versions can be set on certs, CRLs and CSRs. | 285 | - Only specified versions can be set on certs, CRLs and CSRs. |
| 82 | - Prepared X509_REQ_{get,set}_extension_nids() for removal. | ||
| 83 | - Removed unused PEM_USER and PEM_CTX types from pem.h. | 286 | - Removed unused PEM_USER and PEM_CTX types from pem.h. |
| 84 | - Removed typdefs for COMP_CTX, COMP_METHOD, X509_CRL_METHOD, STORE, | 287 | - Removed typdefs for COMP_CTX, COMP_METHOD, X509_CRL_METHOD, STORE, |
| 85 | STORE_METHOD, and SSL_AEAD_CTX. | 288 | STORE_METHOD, and SSL_AEAD_CTX. |
| 86 | - i2d_ASN1_OBJECT() now returns -1 on error like most other i2d_*. | 289 | - i2d_ASN1_OBJECT() now returns -1 on error like most other i2d_*. |
| 87 | - SPKAC support was removed from openssl(1) | 290 | - SPKAC support was removed from openssl(1). |
| 88 | - Added TLS1-PRF support to the EVP interface. | 291 | - Added TLS1-PRF support to the EVP interface. |
| 89 | - Cleaned up various X509v3_* extension API. | 292 | - Support for attributes in EVP_PKEYs was removed. |
| 90 | - Unified the X.509v3 extension methods. | 293 | - The X509at_* API is no longer public. |
| 91 | - Removed ssl2.h and ssl23.h. | 294 | - SSL_CTX_set1_cert_store() and SSL_CIPHER_get_handshake_digest() |
| 295 | were added to libssl. | ||
| 296 | - The completely broken UI_UTIL password API was removed. | ||
| 297 | - The OpenSSL pkcs12 command and PKCS12_create() no longer support | ||
| 298 | setting the Microsoft-specific Local Key Set and Cryptographic | ||
| 299 | Service Provider attributes. | ||
| 92 | * Bug fixes | 300 | * Bug fixes |
| 93 | - Made ASN1_TIME_set_string() and ASN1_TIME_set_string_X509() match | 301 | - Made ASN1_TIME_set_string() and ASN1_TIME_set_string_X509() match |
| 94 | their documentation. They always set an RFC 5280 conformant time. | 302 | their documentation. They always set an RFC 5280 conformant time. |
| @@ -115,6 +323,20 @@ LibreSSL Portable Release Notes: | |||
| 115 | ALPN callback. | 323 | ALPN callback. |
| 116 | - Avoid pushing a spurious error onto the error stack in | 324 | - Avoid pushing a spurious error onto the error stack in |
| 117 | ssl_sigalg_select(). | 325 | ssl_sigalg_select(). |
| 326 | - Made fatal alerts fatal in QUIC. | ||
| 327 | |||
| 328 | 3.9.2 - Stable release | ||
| 329 | |||
| 330 | * Bugfixes | ||
| 331 | - OpenBSD 7.5 errata 003. A missing bounds check could lead to a crash | ||
| 332 | due to dereferencing a zero-sized allocation. | ||
| 333 | |||
| 334 | 3.9.1 - Stable release | ||
| 335 | |||
| 336 | * Portable changes | ||
| 337 | - Updated tests with expiring certificates | ||
| 338 | - CET-related build fixes for Windows and macOS targets | ||
| 339 | - update libtls linker script to include libssl and libcrypto again | ||
| 118 | 340 | ||
| 119 | 3.9.0 - Development release | 341 | 3.9.0 - Development release |
| 120 | 342 | ||
| @@ -193,6 +415,13 @@ LibreSSL Portable Release Notes: | |||
| 193 | stack. | 415 | stack. |
| 194 | - Made in-place decryption work for EVP_chacha20_poly1305(). | 416 | - Made in-place decryption work for EVP_chacha20_poly1305(). |
| 195 | 417 | ||
| 418 | 3.8.4 - Stable release | ||
| 419 | |||
| 420 | * Portable changes | ||
| 421 | - Updated tests with expiring certificates | ||
| 422 | - CET-related build fixes for Windows and macOS targets | ||
| 423 | - update libtls linker script to include libssl and libcrypto again | ||
| 424 | |||
| 196 | 3.8.3 - Stable release | 425 | 3.8.3 - Stable release |
| 197 | 426 | ||
| 198 | * Portable changes | 427 | * Portable changes |
diff --git a/FindLibreSSL.cmake b/FindLibreSSL.cmake index 6bdc069..6779371 100644 --- a/FindLibreSSL.cmake +++ b/FindLibreSSL.cmake | |||
| @@ -81,6 +81,11 @@ if (WIN32) | |||
| 81 | "${_programfiles}/LibreSSL" | 81 | "${_programfiles}/LibreSSL" |
| 82 | ) | 82 | ) |
| 83 | unset(_programfiles) | 83 | unset(_programfiles) |
| 84 | elseif(APPLE) | ||
| 85 | # Homebrew installs LibreSSL here | ||
| 86 | set(_LIBRESSL_ROOT_PATHS | ||
| 87 | "/usr/local/opt/libressl" | ||
| 88 | ) | ||
| 84 | else() | 89 | else() |
| 85 | set(_LIBRESSL_ROOT_PATHS | 90 | set(_LIBRESSL_ROOT_PATHS |
| 86 | "/usr/local/" | 91 | "/usr/local/" |
diff --git a/Makefile.am b/Makefile.am index 3f62cd9..eca5a27 100644 --- a/Makefile.am +++ b/Makefile.am | |||
| @@ -1,3 +1,18 @@ | |||
| 1 | # | ||
| 2 | # Copyright (c) 2014 Brent Cook | ||
| 3 | # | ||
| 4 | # Permission to use, copy, modify, and distribute this software for any | ||
| 5 | # purpose with or without fee is hereby granted, provided that the above | ||
| 6 | # copyright notice and this permission notice appear in all copies. | ||
| 7 | # | ||
| 8 | # THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES | ||
| 9 | # WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF | ||
| 10 | # MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR | ||
| 11 | # ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES | ||
| 12 | # WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN | ||
| 13 | # ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF | ||
| 14 | # OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. | ||
| 15 | |||
| 1 | SUBDIRS = include crypto ssl tls apps man | 16 | SUBDIRS = include crypto ssl tls apps man |
| 2 | if ENABLE_TESTS | 17 | if ENABLE_TESTS |
| 3 | SUBDIRS += tests | 18 | SUBDIRS += tests |
diff --git a/Makefile.am.common b/Makefile.am.common index 5405704..4257cf8 100644 --- a/Makefile.am.common +++ b/Makefile.am.common | |||
| @@ -1,3 +1,18 @@ | |||
| 1 | # | ||
| 2 | # Copyright (c) 2014 Brent Cook | ||
| 3 | # | ||
| 4 | # Permission to use, copy, modify, and distribute this software for any | ||
| 5 | # purpose with or without fee is hereby granted, provided that the above | ||
| 6 | # copyright notice and this permission notice appear in all copies. | ||
| 7 | # | ||
| 8 | # THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES | ||
| 9 | # WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF | ||
| 10 | # MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR | ||
| 11 | # ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES | ||
| 12 | # WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN | ||
| 13 | # ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF | ||
| 14 | # OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. | ||
| 15 | |||
| 1 | AM_CFLAGS = | 16 | AM_CFLAGS = |
| 2 | AM_CPPFLAGS = -I$(top_srcdir)/include | 17 | AM_CPPFLAGS = -I$(top_srcdir)/include |
| 3 | AM_CPPFLAGS += -I$(abs_top_builddir)/include | 18 | AM_CPPFLAGS += -I$(abs_top_builddir)/include |
diff --git a/apps/CMakeLists.txt b/apps/CMakeLists.txt index 08a5a41..754990a 100644 --- a/apps/CMakeLists.txt +++ b/apps/CMakeLists.txt | |||
| @@ -1,3 +1,18 @@ | |||
| 1 | # | ||
| 2 | # Copyright (c) 2014 Brent Cook | ||
| 3 | # | ||
| 4 | # Permission to use, copy, modify, and distribute this software for any | ||
| 5 | # purpose with or without fee is hereby granted, provided that the above | ||
| 6 | # copyright notice and this permission notice appear in all copies. | ||
| 7 | # | ||
| 8 | # THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES | ||
| 9 | # WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF | ||
| 10 | # MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR | ||
| 11 | # ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES | ||
| 12 | # WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN | ||
| 13 | # ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF | ||
| 14 | # OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. | ||
| 15 | |||
| 1 | add_subdirectory(ocspcheck) | 16 | add_subdirectory(ocspcheck) |
| 2 | add_subdirectory(openssl) | 17 | add_subdirectory(openssl) |
| 3 | add_subdirectory(nc) | 18 | add_subdirectory(nc) |
diff --git a/apps/nc/CMakeLists.txt b/apps/nc/CMakeLists.txt index 7bbdb02..b1eed1b 100644 --- a/apps/nc/CMakeLists.txt +++ b/apps/nc/CMakeLists.txt | |||
| @@ -1,3 +1,18 @@ | |||
| 1 | # | ||
| 2 | # Copyright (c) 2016 Kinichiro Inoguchi | ||
| 3 | # | ||
| 4 | # Permission to use, copy, modify, and distribute this software for any | ||
| 5 | # purpose with or without fee is hereby granted, provided that the above | ||
| 6 | # copyright notice and this permission notice appear in all copies. | ||
| 7 | # | ||
| 8 | # THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES | ||
| 9 | # WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF | ||
| 10 | # MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR | ||
| 11 | # ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES | ||
| 12 | # WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN | ||
| 13 | # ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF | ||
| 14 | # OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. | ||
| 15 | |||
| 1 | if(BUILD_NC) | 16 | if(BUILD_NC) |
| 2 | 17 | ||
| 3 | set( | 18 | set( |
| @@ -22,7 +37,7 @@ else() | |||
| 22 | set(NC_SRC ${NC_SRC} compat/accept4.c) | 37 | set(NC_SRC ${NC_SRC} compat/accept4.c) |
| 23 | endif() | 38 | endif() |
| 24 | 39 | ||
| 25 | check_function_exists(readpassphrase HAVE_READPASSPHRASE) | 40 | check_symbol_exists(readpassphrase "readpassphrase.h" HAVE_READPASSPHRASE) |
| 26 | if(HAVE_READPASSPHRASE) | 41 | if(HAVE_READPASSPHRASE) |
| 27 | add_definitions(-DHAVE_READPASSPHRASE) | 42 | add_definitions(-DHAVE_READPASSPHRASE) |
| 28 | else() | 43 | else() |
diff --git a/apps/nc/Makefile.am b/apps/nc/Makefile.am index aba306e..a3911a2 100644 --- a/apps/nc/Makefile.am +++ b/apps/nc/Makefile.am | |||
| @@ -1,3 +1,18 @@ | |||
| 1 | # | ||
| 2 | # Copyright (c) 2015 Brent Cook | ||
| 3 | # | ||
| 4 | # Permission to use, copy, modify, and distribute this software for any | ||
| 5 | # purpose with or without fee is hereby granted, provided that the above | ||
| 6 | # copyright notice and this permission notice appear in all copies. | ||
| 7 | # | ||
| 8 | # THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES | ||
| 9 | # WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF | ||
| 10 | # MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR | ||
| 11 | # ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES | ||
| 12 | # WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN | ||
| 13 | # ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF | ||
| 14 | # OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. | ||
| 15 | |||
| 1 | include $(top_srcdir)/Makefile.am.common | 16 | include $(top_srcdir)/Makefile.am.common |
| 2 | 17 | ||
| 3 | -include $(abs_top_builddir)/crypto/libcrypto_la_objects.mk | 18 | -include $(abs_top_builddir)/crypto/libcrypto_la_objects.mk |
diff --git a/apps/nc/compat/accept4.c b/apps/nc/compat/accept4.c index 278198b..dca42e9 100644 --- a/apps/nc/compat/accept4.c +++ b/apps/nc/compat/accept4.c | |||
| @@ -6,10 +6,10 @@ accept4(int s, struct sockaddr *addr, socklen_t *addrlen, int flags) | |||
| 6 | { | 6 | { |
| 7 | int rets = accept(s, addr, addrlen); | 7 | int rets = accept(s, addr, addrlen); |
| 8 | if (rets == -1) | 8 | if (rets == -1) |
| 9 | return s; | 9 | return rets; |
| 10 | 10 | ||
| 11 | if (flags & SOCK_CLOEXEC) { | 11 | if (flags & SOCK_CLOEXEC) { |
| 12 | flags = fcntl(s, F_GETFD); | 12 | flags = fcntl(rets, F_GETFD); |
| 13 | fcntl(rets, F_SETFD, flags | FD_CLOEXEC); | 13 | fcntl(rets, F_SETFD, flags | FD_CLOEXEC); |
| 14 | } | 14 | } |
| 15 | 15 | ||
diff --git a/apps/ocspcheck/CMakeLists.txt b/apps/ocspcheck/CMakeLists.txt index 778e837..ed2ec1b 100644 --- a/apps/ocspcheck/CMakeLists.txt +++ b/apps/ocspcheck/CMakeLists.txt | |||
| @@ -1,3 +1,18 @@ | |||
| 1 | # | ||
| 2 | # Copyright (c) 2017 Brent Cook | ||
| 3 | # | ||
| 4 | # Permission to use, copy, modify, and distribute this software for any | ||
| 5 | # purpose with or without fee is hereby granted, provided that the above | ||
| 6 | # copyright notice and this permission notice appear in all copies. | ||
| 7 | # | ||
| 8 | # THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES | ||
| 9 | # WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF | ||
| 10 | # MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR | ||
| 11 | # ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES | ||
| 12 | # WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN | ||
| 13 | # ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF | ||
| 14 | # OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. | ||
| 15 | |||
| 1 | set( | 16 | set( |
| 2 | OCSPCHECK_SRC | 17 | OCSPCHECK_SRC |
| 3 | http.c | 18 | http.c |
diff --git a/apps/ocspcheck/Makefile.am b/apps/ocspcheck/Makefile.am index e6f3c54..554bd5c 100644 --- a/apps/ocspcheck/Makefile.am +++ b/apps/ocspcheck/Makefile.am | |||
| @@ -1,3 +1,18 @@ | |||
| 1 | # | ||
| 2 | # Copyright (c) 2017 Brent Cook | ||
| 3 | # | ||
| 4 | # Permission to use, copy, modify, and distribute this software for any | ||
| 5 | # purpose with or without fee is hereby granted, provided that the above | ||
| 6 | # copyright notice and this permission notice appear in all copies. | ||
| 7 | # | ||
| 8 | # THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES | ||
| 9 | # WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF | ||
| 10 | # MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR | ||
| 11 | # ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES | ||
| 12 | # WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN | ||
| 13 | # ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF | ||
| 14 | # OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. | ||
| 15 | |||
| 1 | include $(top_srcdir)/Makefile.am.common | 16 | include $(top_srcdir)/Makefile.am.common |
| 2 | 17 | ||
| 3 | -include $(abs_top_builddir)/crypto/libcrypto_la_objects.mk | 18 | -include $(abs_top_builddir)/crypto/libcrypto_la_objects.mk |
diff --git a/apps/openssl/CMakeLists.txt b/apps/openssl/CMakeLists.txt index bca60e1..3040d01 100644 --- a/apps/openssl/CMakeLists.txt +++ b/apps/openssl/CMakeLists.txt | |||
| @@ -1,3 +1,18 @@ | |||
| 1 | # | ||
| 2 | # Copyright (c) 2016 Kinichiro Inoguchi | ||
| 3 | # | ||
| 4 | # Permission to use, copy, modify, and distribute this software for any | ||
| 5 | # purpose with or without fee is hereby granted, provided that the above | ||
| 6 | # copyright notice and this permission notice appear in all copies. | ||
| 7 | # | ||
| 8 | # THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES | ||
| 9 | # WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF | ||
| 10 | # MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR | ||
| 11 | # ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES | ||
| 12 | # WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN | ||
| 13 | # ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF | ||
| 14 | # OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. | ||
| 15 | |||
| 1 | set( | 16 | set( |
| 2 | OPENSSL_SRC | 17 | OPENSSL_SRC |
| 3 | apps.c | 18 | apps.c |
diff --git a/apps/openssl/Makefile.am b/apps/openssl/Makefile.am index 810408d..40804c5 100644 --- a/apps/openssl/Makefile.am +++ b/apps/openssl/Makefile.am | |||
| @@ -1,3 +1,18 @@ | |||
| 1 | # | ||
| 2 | # Copyright (c) 2015 Brent Cook | ||
| 3 | # | ||
| 4 | # Permission to use, copy, modify, and distribute this software for any | ||
| 5 | # purpose with or without fee is hereby granted, provided that the above | ||
| 6 | # copyright notice and this permission notice appear in all copies. | ||
| 7 | # | ||
| 8 | # THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES | ||
| 9 | # WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF | ||
| 10 | # MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR | ||
| 11 | # ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES | ||
| 12 | # WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN | ||
| 13 | # ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF | ||
| 14 | # OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. | ||
| 15 | |||
| 1 | include $(top_srcdir)/Makefile.am.common | 16 | include $(top_srcdir)/Makefile.am.common |
| 2 | 17 | ||
| 3 | -include $(abs_top_builddir)/crypto/libcrypto_la_objects.mk | 18 | -include $(abs_top_builddir)/crypto/libcrypto_la_objects.mk |
| @@ -88,11 +103,6 @@ endif | |||
| 88 | endif | 103 | endif |
| 89 | 104 | ||
| 90 | noinst_HEADERS = apps.h | 105 | noinst_HEADERS = apps.h |
| 91 | noinst_HEADERS += progs.h | ||
| 92 | noinst_HEADERS += s_apps.h | ||
| 93 | noinst_HEADERS += testdsa.h | ||
| 94 | noinst_HEADERS += testrsa.h | ||
| 95 | noinst_HEADERS += timeouts.h | ||
| 96 | 106 | ||
| 97 | EXTRA_DIST = CMakeLists.txt | 107 | EXTRA_DIST = CMakeLists.txt |
| 98 | 108 | ||
diff --git a/apps/openssl/compat/poll_win.c b/apps/openssl/compat/poll_win.c index c9422b9..30f6b60 100644 --- a/apps/openssl/compat/poll_win.c +++ b/apps/openssl/compat/poll_win.c | |||
| @@ -248,12 +248,12 @@ poll(struct pollfd *pfds, nfds_t nfds, int timeout_ms) | |||
| 248 | timespent_ms = 0; | 248 | timespent_ms = 0; |
| 249 | wait_rc = WAIT_FAILED; | 249 | wait_rc = WAIT_FAILED; |
| 250 | 250 | ||
| 251 | if (timeout_ms < 0) | 251 | looptime_ms = (timeout_ms > 100 || timeout_ms == -1) ? 100 : timeout_ms; |
| 252 | if (timeout_ms == -1) | ||
| 252 | timeout_ms = INFINITE; | 253 | timeout_ms = INFINITE; |
| 253 | looptime_ms = timeout_ms > 100 ? 100 : timeout_ms; | ||
| 254 | 254 | ||
| 255 | do { | 255 | do { |
| 256 | struct timeval tv; | 256 | TIMEVAL tv; |
| 257 | tv.tv_sec = 0; | 257 | tv.tv_sec = 0; |
| 258 | tv.tv_usec = looptime_ms * 1000; | 258 | tv.tv_usec = looptime_ms * 1000; |
| 259 | int handle_signaled = 0; | 259 | int handle_signaled = 0; |
diff --git a/check-release.sh b/check-release.sh index c5f9c5f..723a051 100755 --- a/check-release.sh +++ b/check-release.sh | |||
| @@ -1,4 +1,19 @@ | |||
| 1 | #!/bin/sh | 1 | #!/bin/sh |
| 2 | # | ||
| 3 | # Copyright (c) 2014 Brent Cook | ||
| 4 | # | ||
| 5 | # Permission to use, copy, modify, and distribute this software for any | ||
| 6 | # purpose with or without fee is hereby granted, provided that the above | ||
| 7 | # copyright notice and this permission notice appear in all copies. | ||
| 8 | # | ||
| 9 | # THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES | ||
| 10 | # WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF | ||
| 11 | # MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR | ||
| 12 | # ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES | ||
| 13 | # WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN | ||
| 14 | # ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF | ||
| 15 | # OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. | ||
| 16 | |||
| 2 | set -e | 17 | set -e |
| 3 | 18 | ||
| 4 | ver=$1 | 19 | ver=$1 |
diff --git a/cmake_export_symbol.cmake b/cmake_export_symbol.cmake index 0883001..9fe61f2 100644 --- a/cmake_export_symbol.cmake +++ b/cmake_export_symbol.cmake | |||
| @@ -1,3 +1,18 @@ | |||
| 1 | # | ||
| 2 | # Copyright (c) 2017 Kinichiro Inoguchi | ||
| 3 | # | ||
| 4 | # Permission to use, copy, modify, and distribute this software for any | ||
| 5 | # purpose with or without fee is hereby granted, provided that the above | ||
| 6 | # copyright notice and this permission notice appear in all copies. | ||
| 7 | # | ||
| 8 | # THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES | ||
| 9 | # WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF | ||
| 10 | # MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR | ||
| 11 | # ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES | ||
| 12 | # WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN | ||
| 13 | # ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF | ||
| 14 | # OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. | ||
| 15 | |||
| 1 | macro(export_symbol TARGET SYMBOLS_PATH) | 16 | macro(export_symbol TARGET SYMBOLS_PATH) |
| 2 | 17 | ||
| 3 | set(FLAG "") | 18 | set(FLAG "") |
diff --git a/cmake_uninstall.cmake.in b/cmake_uninstall.cmake.in index bb8055d..2887382 100644 --- a/cmake_uninstall.cmake.in +++ b/cmake_uninstall.cmake.in | |||
| @@ -1,3 +1,18 @@ | |||
| 1 | # | ||
| 2 | # Copyright (c) 2016 Kinichiro Inoguchi | ||
| 3 | # | ||
| 4 | # Permission to use, copy, modify, and distribute this software for any | ||
| 5 | # purpose with or without fee is hereby granted, provided that the above | ||
| 6 | # copyright notice and this permission notice appear in all copies. | ||
| 7 | # | ||
| 8 | # THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES | ||
| 9 | # WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF | ||
| 10 | # MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR | ||
| 11 | # ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES | ||
| 12 | # WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN | ||
| 13 | # ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF | ||
| 14 | # OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. | ||
| 15 | |||
| 1 | if(NOT EXISTS "@CMAKE_CURRENT_BINARY_DIR@/install_manifest.txt") | 16 | if(NOT EXISTS "@CMAKE_CURRENT_BINARY_DIR@/install_manifest.txt") |
| 2 | message(FATAL_ERROR "Cannot find install manifest: @CMAKE_CURRENT_BINARY_DIR@/install_manifest.txt") | 17 | message(FATAL_ERROR "Cannot find install manifest: @CMAKE_CURRENT_BINARY_DIR@/install_manifest.txt") |
| 3 | endif(NOT EXISTS "@CMAKE_CURRENT_BINARY_DIR@/install_manifest.txt") | 18 | endif(NOT EXISTS "@CMAKE_CURRENT_BINARY_DIR@/install_manifest.txt") |
diff --git a/configure.ac b/configure.ac index 87a80cc..eb2b9ce 100644 --- a/configure.ac +++ b/configure.ac | |||
| @@ -1,3 +1,4 @@ | |||
| 1 | # | ||
| 1 | # Copyright (c) 2014-2015 Brent Cook | 2 | # Copyright (c) 2014-2015 Brent Cook |
| 2 | # | 3 | # |
| 3 | # Permission to use, copy, modify, and distribute this software for any | 4 | # Permission to use, copy, modify, and distribute this software for any |
| @@ -32,10 +33,6 @@ LT_INIT([pic-only]) | |||
| 32 | 33 | ||
| 33 | CHECK_OS_OPTIONS | 34 | CHECK_OS_OPTIONS |
| 34 | 35 | ||
| 35 | if test "$HOST_OS" = "unsupported"; then | ||
| 36 | AC_MSG_ERROR([unsupported platform: $host_os]) | ||
| 37 | fi | ||
| 38 | |||
| 39 | CHECK_C_HARDENING_OPTIONS | 36 | CHECK_C_HARDENING_OPTIONS |
| 40 | 37 | ||
| 41 | DISABLE_AS_EXECUTABLE_STACK | 38 | DISABLE_AS_EXECUTABLE_STACK |
| @@ -90,16 +87,17 @@ AS_CASE([$host_cpu], | |||
| 90 | ) | 87 | ) |
| 91 | AM_CONDITIONAL([HOST_CPU_IS_INTEL], [test "x$HOSTARCH" = "xintel"]) | 88 | AM_CONDITIONAL([HOST_CPU_IS_INTEL], [test "x$HOSTARCH" = "xintel"]) |
| 92 | 89 | ||
| 93 | AM_CONDITIONAL([HOST_AARCH64], [test "$host_cpu" = "aarch64"]) | 90 | AM_CONDITIONAL([HOST_AARCH64], [test "$host_cpu" = "aarch64"]) |
| 94 | AM_CONDITIONAL([HOST_ARM], [test "$host_cpu" = "arm"]) | 91 | AM_CONDITIONAL([HOST_ARM], [test "$host_cpu" = "arm"]) |
| 95 | AM_CONDITIONAL([HOST_I386], [test "$host_cpu" = "i386"]) | 92 | AM_CONDITIONAL([HOST_I386], [test "$host_cpu" = "i386"]) |
| 96 | AM_CONDITIONAL([HOST_MIPS], [test "$host_cpu" = "mips"]) | 93 | AM_CONDITIONAL([HOST_LOONGARCH64], [test "$host_cpu" = "loongarch64"]) |
| 97 | AM_CONDITIONAL([HOST_MIPS64], [test "$host_cpu" = "mips64"]) | 94 | AM_CONDITIONAL([HOST_MIPS], [test "$host_cpu" = "mips"]) |
| 98 | AM_CONDITIONAL([HOST_POWERPC], [test "$host_cpu" = "powerpc"]) | 95 | AM_CONDITIONAL([HOST_MIPS64], [test "$host_cpu" = "mips64"]) |
| 99 | AM_CONDITIONAL([HOST_POWERPC64], [test "$host_cpu" = "ppc64"]) | 96 | AM_CONDITIONAL([HOST_POWERPC], [test "$host_cpu" = "powerpc"]) |
| 100 | AM_CONDITIONAL([HOST_RISCV64], [test "$host_cpu" = "riscv64"]) | 97 | AM_CONDITIONAL([HOST_POWERPC64], [test "$host_cpu" = "ppc64"]) |
| 101 | AM_CONDITIONAL([HOST_SPARC64], [test "$host_cpu" = "sparc64"]) | 98 | AM_CONDITIONAL([HOST_RISCV64], [test "$host_cpu" = "riscv64"]) |
| 102 | AM_CONDITIONAL([HOST_X86_64], [test "$host_cpu" = "x86_64"]) | 99 | AM_CONDITIONAL([HOST_SPARC64], [test "$host_cpu" = "sparc64"]) |
| 100 | AM_CONDITIONAL([HOST_X86_64], [test "$host_cpu" = "x86_64"]) | ||
| 103 | 101 | ||
| 104 | AC_MSG_CHECKING([if .gnu.warning accepts long strings]) | 102 | AC_MSG_CHECKING([if .gnu.warning accepts long strings]) |
| 105 | AC_LINK_IFELSE([AC_LANG_SOURCE([[ | 103 | AC_LINK_IFELSE([AC_LANG_SOURCE([[ |
| @@ -117,8 +115,8 @@ AC_ARG_ENABLE([asm], AS_HELP_STRING([--disable-asm], [Disable assembly])) | |||
| 117 | AM_CONDITIONAL([OPENSSL_NO_ASM], [test "x$enable_asm" = "xno"]) | 115 | AM_CONDITIONAL([OPENSSL_NO_ASM], [test "x$enable_asm" = "xno"]) |
| 118 | 116 | ||
| 119 | # Conditionally enable assembly by default | 117 | # Conditionally enable assembly by default |
| 120 | AM_CONDITIONAL([HOST_ASM_ELF_ARM], | 118 | AM_CONDITIONAL([HOST_ASM_ELF_AARCH64], |
| 121 | [test "x$HOST_ABI" = "xelf" -a "$host_cpu" = "arm" -a "x$enable_asm" != "xno"]) | 119 | [test "x$HOST_ABI" = "xelf" -a "$host_cpu" = "aarch64" -a "x$enable_asm" != "xno"]) |
| 122 | AM_CONDITIONAL([HOST_ASM_ELF_MIPS], | 120 | AM_CONDITIONAL([HOST_ASM_ELF_MIPS], |
| 123 | [test "x$HOST_ABI" = "xelf" -a "$host_cpu" = "mips" -a "x$enable_asm" != "xno"]) | 121 | [test "x$HOST_ABI" = "xelf" -a "$host_cpu" = "mips" -a "x$enable_asm" != "xno"]) |
| 124 | AM_CONDITIONAL([HOST_ASM_ELF_MIPS64], | 122 | AM_CONDITIONAL([HOST_ASM_ELF_MIPS64], |
| @@ -163,3 +161,7 @@ AM_CONDITIONAL([ENABLE_LIBTLS_ONLY], [test "x$enable_libtls_only" = xyes]) | |||
| 163 | AC_REQUIRE_AUX_FILE([tap-driver.sh]) | 161 | AC_REQUIRE_AUX_FILE([tap-driver.sh]) |
| 164 | 162 | ||
| 165 | AC_OUTPUT | 163 | AC_OUTPUT |
| 164 | |||
| 165 | if test "$HOST_OS" = "unsupported"; then | ||
| 166 | AC_MSG_WARN([unsupported platform: $host_os]) | ||
| 167 | fi | ||
diff --git a/crypto/CMakeLists.txt b/crypto/CMakeLists.txt index 5ee20ff..d566182 100644 --- a/crypto/CMakeLists.txt +++ b/crypto/CMakeLists.txt | |||
| @@ -1,236 +1,210 @@ | |||
| 1 | # | ||
| 2 | # Copyright (c) 2014 Brent Cook | ||
| 3 | # | ||
| 4 | # Permission to use, copy, modify, and distribute this software for any | ||
| 5 | # purpose with or without fee is hereby granted, provided that the above | ||
| 6 | # copyright notice and this permission notice appear in all copies. | ||
| 7 | # | ||
| 8 | # THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES | ||
| 9 | # WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF | ||
| 10 | # MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR | ||
| 11 | # ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES | ||
| 12 | # WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN | ||
| 13 | # ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF | ||
| 14 | # OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. | ||
| 15 | |||
| 1 | add_definitions(-DLIBRESSL_CRYPTO_INTERNAL) | 16 | add_definitions(-DLIBRESSL_CRYPTO_INTERNAL) |
| 2 | 17 | ||
| 3 | if(HOST_ASM_ELF_ARMV4) | 18 | if(HOST_ASM_ELF_AARCH64) |
| 19 | set(CRYPTO_SRC ${CRYPTO_SRC} sha/sha1_aarch64.c sha/sha256_aarch64.c sha/sha512_aarch64.c) | ||
| 20 | |||
| 4 | set( | 21 | set( |
| 5 | ASM_ARMV4_ELF_SRC | 22 | ASM_AARCH64_ELF_SRC |
| 6 | aes/aes-elf-armv4.S | 23 | sha/sha1_aarch64_ce.S |
| 7 | bn/mont-elf-armv4.S | 24 | sha/sha256_aarch64_ce.S |
| 8 | sha/sha1-elf-armv4.S | 25 | sha/sha256_aarch64_ce.S |
| 9 | sha/sha512-elf-armv4.S | ||
| 10 | sha/sha256-elf-armv4.S | ||
| 11 | modes/ghash-elf-armv4.S | ||
| 12 | armv4cpuid.S | ||
| 13 | armcap.c | ||
| 14 | ) | 26 | ) |
| 15 | add_definitions(-DAES_ASM) | 27 | set(CRYPTO_SRC ${CRYPTO_SRC} ${ASM_AARCH64_ELF_SRC}) |
| 16 | add_definitions(-DOPENSSL_BN_ASM_MONT) | ||
| 17 | add_definitions(-DGHASH_ASM) | ||
| 18 | add_definitions(-DSHA1_ASM) | ||
| 19 | add_definitions(-DSHA256_ASM) | ||
| 20 | add_definitions(-DSHA512_ASM) | ||
| 21 | add_definitions(-DOPENSSL_CPUID_OBJ) | ||
| 22 | set_property(SOURCE ${ASM_ARMV4_ELF_SRC} PROPERTY LANGUAGE C) | ||
| 23 | set(CRYPTO_SRC ${CRYPTO_SRC} ${ASM_ARMV4_ELF_SRC}) | ||
| 24 | endif() | 28 | endif() |
| 25 | 29 | ||
| 26 | if(HOST_ASM_ELF_X86_64) | 30 | if(HOST_ASM_ELF_X86_64) |
| 31 | set(CRYPTO_SRC ${CRYPTO_SRC} aes/aes_amd64.c) | ||
| 32 | set(CRYPTO_SRC ${CRYPTO_SRC} bn/arch/amd64/bn_arch.c) | ||
| 33 | set(CRYPTO_SRC ${CRYPTO_SRC} modes/gcm128_amd64.c) | ||
| 34 | set(CRYPTO_SRC ${CRYPTO_SRC} sha/sha1_amd64.c sha/sha256_amd64.c sha/sha512_amd64.c) | ||
| 35 | |||
| 27 | set( | 36 | set( |
| 28 | ASM_X86_64_ELF_SRC | 37 | ASM_X86_64_ELF_SRC |
| 29 | aes/aes-elf-x86_64.S | 38 | aes/aes-elf-x86_64.S |
| 30 | aes/bsaes-elf-x86_64.S | ||
| 31 | aes/vpaes-elf-x86_64.S | ||
| 32 | aes/aesni-elf-x86_64.S | 39 | aes/aesni-elf-x86_64.S |
| 33 | bn/modexp512-elf-x86_64.S | 40 | bn/modexp512-elf-x86_64.S |
| 34 | bn/mont-elf-x86_64.S | 41 | bn/mont-elf-x86_64.S |
| 35 | bn/mont5-elf-x86_64.S | 42 | bn/mont5-elf-x86_64.S |
| 36 | md5/md5-elf-x86_64.S | ||
| 37 | modes/ghash-elf-x86_64.S | 43 | modes/ghash-elf-x86_64.S |
| 38 | rc4/rc4-elf-x86_64.S | 44 | rc4/rc4-elf-x86_64.S |
| 39 | sha/sha1-elf-x86_64.S | ||
| 40 | sha/sha256-elf-x86_64.S | ||
| 41 | sha/sha512-elf-x86_64.S | ||
| 42 | cpuid-elf-x86_64.S | ||
| 43 | 45 | ||
| 44 | bn/arch/amd64/bignum_add.S | 46 | bn/arch/amd64/bignum_add.S |
| 45 | bn/arch/amd64/bignum_cmadd.S | 47 | bn/arch/amd64/bignum_cmadd.S |
| 46 | bn/arch/amd64/bignum_cmul.S | 48 | bn/arch/amd64/bignum_cmul.S |
| 49 | bn/arch/amd64/bignum_modadd.S | ||
| 50 | bn/arch/amd64/bignum_modsub.S | ||
| 47 | bn/arch/amd64/bignum_mul.S | 51 | bn/arch/amd64/bignum_mul.S |
| 52 | bn/arch/amd64/bignum_mul_4_8.S | ||
| 48 | bn/arch/amd64/bignum_mul_4_8_alt.S | 53 | bn/arch/amd64/bignum_mul_4_8_alt.S |
| 54 | bn/arch/amd64/bignum_mul_6_12.S | ||
| 55 | bn/arch/amd64/bignum_mul_6_12_alt.S | ||
| 56 | bn/arch/amd64/bignum_mul_8_16.S | ||
| 49 | bn/arch/amd64/bignum_mul_8_16_alt.S | 57 | bn/arch/amd64/bignum_mul_8_16_alt.S |
| 50 | bn/arch/amd64/bignum_sqr.S | 58 | bn/arch/amd64/bignum_sqr.S |
| 59 | bn/arch/amd64/bignum_sqr_4_8.S | ||
| 51 | bn/arch/amd64/bignum_sqr_4_8_alt.S | 60 | bn/arch/amd64/bignum_sqr_4_8_alt.S |
| 61 | bn/arch/amd64/bignum_sqr_6_12.S | ||
| 62 | bn/arch/amd64/bignum_sqr_6_12_alt.S | ||
| 63 | bn/arch/amd64/bignum_sqr_8_16.S | ||
| 52 | bn/arch/amd64/bignum_sqr_8_16_alt.S | 64 | bn/arch/amd64/bignum_sqr_8_16_alt.S |
| 53 | bn/arch/amd64/bignum_sub.S | 65 | bn/arch/amd64/bignum_sub.S |
| 54 | bn/arch/amd64/word_clz.S | 66 | bn/arch/amd64/word_clz.S |
| 55 | bn/arch/amd64/bn_arch.c | 67 | |
| 68 | sha/sha1_amd64_shani.S | ||
| 69 | sha/sha1_amd64_generic.S | ||
| 70 | sha/sha256_amd64_generic.S | ||
| 71 | sha/sha256_amd64_shani.S | ||
| 72 | sha/sha512_amd64_generic.S | ||
| 56 | ) | 73 | ) |
| 57 | add_definitions(-DAES_ASM) | 74 | add_definitions(-DLIBRESSL_USE_AES_ASSEMBLY) |
| 58 | add_definitions(-DBSAES_ASM) | 75 | add_definitions(-DLIBRESSL_USE_BN_ASSEMBLY) |
| 59 | add_definitions(-DVPAES_ASM) | 76 | add_definitions(-DLIBRESSL_USE_GCM_ASSEMBLY) |
| 60 | add_definitions(-DHAVE_AES_CBC_ENCRYPT_INTERNAL) | 77 | add_definitions(-DLIBRESSL_USE_RC4_ASSEMBLY) |
| 61 | add_definitions(-DHAVE_AES_SET_ENCRYPT_KEY_INTERNAL) | 78 | add_definitions(-DLIBRESSL_USE_SHA_ASSEMBLY) |
| 62 | add_definitions(-DHAVE_AES_SET_DECRYPT_KEY_INTERNAL) | ||
| 63 | add_definitions(-DHAVE_AES_ENCRYPT_INTERNAL) | ||
| 64 | add_definitions(-DHAVE_AES_DECRYPT_INTERNAL) | ||
| 65 | add_definitions(-DOPENSSL_IA32_SSE2) | ||
| 66 | add_definitions(-DOPENSSL_BN_ASM_MONT) | 79 | add_definitions(-DOPENSSL_BN_ASM_MONT) |
| 67 | add_definitions(-DOPENSSL_BN_ASM_MONT5) | 80 | add_definitions(-DOPENSSL_BN_ASM_MONT5) |
| 68 | add_definitions(-DMD5_ASM) | ||
| 69 | add_definitions(-DGHASH_ASM) | ||
| 70 | add_definitions(-DRSA_ASM) | ||
| 71 | add_definitions(-DSHA1_ASM) | ||
| 72 | add_definitions(-DSHA256_ASM) | ||
| 73 | add_definitions(-DSHA512_ASM) | ||
| 74 | add_definitions(-DWHIRLPOOL_ASM) | ||
| 75 | add_definitions(-DOPENSSL_CPUID_OBJ) | ||
| 76 | set(CRYPTO_SRC ${CRYPTO_SRC} ${ASM_X86_64_ELF_SRC}) | 81 | set(CRYPTO_SRC ${CRYPTO_SRC} ${ASM_X86_64_ELF_SRC}) |
| 77 | set_property(SOURCE ${ASM_X86_64_ELF_SRC} PROPERTY LANGUAGE C) | ||
| 78 | endif() | 82 | endif() |
| 79 | 83 | ||
| 80 | if(HOST_ASM_MACOSX_X86_64) | 84 | if(HOST_ASM_MACOSX_X86_64) |
| 85 | set(CRYPTO_SRC ${CRYPTO_SRC} aes/aes_amd64.c) | ||
| 86 | set(CRYPTO_SRC ${CRYPTO_SRC} bn/arch/amd64/bn_arch.c) | ||
| 87 | set(CRYPTO_SRC ${CRYPTO_SRC} modes/gcm128_amd64.c) | ||
| 88 | |||
| 81 | set( | 89 | set( |
| 82 | ASM_X86_64_MACOSX_SRC | 90 | ASM_X86_64_MACOSX_SRC |
| 83 | aes/aes-macosx-x86_64.S | 91 | aes/aes-macosx-x86_64.S |
| 84 | aes/bsaes-macosx-x86_64.S | ||
| 85 | aes/vpaes-macosx-x86_64.S | ||
| 86 | aes/aesni-macosx-x86_64.S | 92 | aes/aesni-macosx-x86_64.S |
| 87 | bn/modexp512-macosx-x86_64.S | 93 | bn/modexp512-macosx-x86_64.S |
| 88 | bn/mont-macosx-x86_64.S | 94 | bn/mont-macosx-x86_64.S |
| 89 | bn/mont5-macosx-x86_64.S | 95 | bn/mont5-macosx-x86_64.S |
| 90 | md5/md5-macosx-x86_64.S | ||
| 91 | modes/ghash-macosx-x86_64.S | 96 | modes/ghash-macosx-x86_64.S |
| 92 | rc4/rc4-macosx-x86_64.S | 97 | rc4/rc4-macosx-x86_64.S |
| 93 | sha/sha1-macosx-x86_64.S | ||
| 94 | sha/sha256-macosx-x86_64.S | ||
| 95 | sha/sha512-macosx-x86_64.S | ||
| 96 | cpuid-macosx-x86_64.S | ||
| 97 | 98 | ||
| 98 | bn/arch/amd64/bignum_add.S | 99 | bn/arch/amd64/bignum_add.S |
| 99 | bn/arch/amd64/bignum_cmadd.S | 100 | bn/arch/amd64/bignum_cmadd.S |
| 100 | bn/arch/amd64/bignum_cmul.S | 101 | bn/arch/amd64/bignum_cmul.S |
| 102 | bn/arch/amd64/bignum_modadd.S | ||
| 103 | bn/arch/amd64/bignum_modsub.S | ||
| 101 | bn/arch/amd64/bignum_mul.S | 104 | bn/arch/amd64/bignum_mul.S |
| 105 | bn/arch/amd64/bignum_mul_4_8.S | ||
| 102 | bn/arch/amd64/bignum_mul_4_8_alt.S | 106 | bn/arch/amd64/bignum_mul_4_8_alt.S |
| 107 | bn/arch/amd64/bignum_mul_6_12.S | ||
| 108 | bn/arch/amd64/bignum_mul_6_12_alt.S | ||
| 109 | bn/arch/amd64/bignum_mul_8_16.S | ||
| 103 | bn/arch/amd64/bignum_mul_8_16_alt.S | 110 | bn/arch/amd64/bignum_mul_8_16_alt.S |
| 104 | bn/arch/amd64/bignum_sqr.S | 111 | bn/arch/amd64/bignum_sqr.S |
| 112 | bn/arch/amd64/bignum_sqr_4_8.S | ||
| 105 | bn/arch/amd64/bignum_sqr_4_8_alt.S | 113 | bn/arch/amd64/bignum_sqr_4_8_alt.S |
| 114 | bn/arch/amd64/bignum_sqr_6_12.S | ||
| 115 | bn/arch/amd64/bignum_sqr_6_12_alt.S | ||
| 116 | bn/arch/amd64/bignum_sqr_8_16.S | ||
| 106 | bn/arch/amd64/bignum_sqr_8_16_alt.S | 117 | bn/arch/amd64/bignum_sqr_8_16_alt.S |
| 107 | bn/arch/amd64/bignum_sub.S | 118 | bn/arch/amd64/bignum_sub.S |
| 108 | bn/arch/amd64/word_clz.S | 119 | bn/arch/amd64/word_clz.S |
| 109 | bn/arch/amd64/bn_arch.c | ||
| 110 | ) | 120 | ) |
| 111 | add_definitions(-DAES_ASM) | 121 | add_definitions(-DLIBRESSL_USE_AES_ASSEMBLY) |
| 112 | add_definitions(-DBSAES_ASM) | 122 | add_definitions(-DLIBRESSL_USE_BN_ASSEMBLY) |
| 113 | add_definitions(-DVPAES_ASM) | 123 | add_definitions(-DLIBRESSL_USE_GCM_ASSEMBLY) |
| 114 | add_definitions(-DHAVE_AES_CBC_ENCRYPT_INTERNAL) | 124 | add_definitions(-DLIBRESSL_USE_RC4_ASSEMBLY) |
| 115 | add_definitions(-DHAVE_AES_SET_ENCRYPT_KEY_INTERNAL) | ||
| 116 | add_definitions(-DHAVE_AES_SET_DECRYPT_KEY_INTERNAL) | ||
| 117 | add_definitions(-DHAVE_AES_ENCRYPT_INTERNAL) | ||
| 118 | add_definitions(-DHAVE_AES_DECRYPT_INTERNAL) | ||
| 119 | add_definitions(-DOPENSSL_IA32_SSE2) | ||
| 120 | add_definitions(-DOPENSSL_BN_ASM_MONT) | 125 | add_definitions(-DOPENSSL_BN_ASM_MONT) |
| 121 | add_definitions(-DOPENSSL_BN_ASM_MONT5) | 126 | add_definitions(-DOPENSSL_BN_ASM_MONT5) |
| 122 | add_definitions(-DMD5_ASM) | ||
| 123 | add_definitions(-DGHASH_ASM) | ||
| 124 | add_definitions(-DRSA_ASM) | ||
| 125 | add_definitions(-DSHA1_ASM) | ||
| 126 | add_definitions(-DSHA256_ASM) | ||
| 127 | add_definitions(-DSHA512_ASM) | ||
| 128 | add_definitions(-DWHIRLPOOL_ASM) | ||
| 129 | add_definitions(-DOPENSSL_CPUID_OBJ) | ||
| 130 | set(CRYPTO_SRC ${CRYPTO_SRC} ${ASM_X86_64_MACOSX_SRC}) | 127 | set(CRYPTO_SRC ${CRYPTO_SRC} ${ASM_X86_64_MACOSX_SRC}) |
| 131 | set_property(SOURCE ${ASM_X86_64_MACOSX_SRC} PROPERTY LANGUAGE C) | ||
| 132 | set_property(SOURCE ${ASM_X86_64_MACOSX_SRC} PROPERTY XCODE_EXPLICIT_FILE_TYPE "sourcecode.asm") | 128 | set_property(SOURCE ${ASM_X86_64_MACOSX_SRC} PROPERTY XCODE_EXPLICIT_FILE_TYPE "sourcecode.asm") |
| 133 | endif() | 129 | endif() |
| 134 | 130 | ||
| 135 | if(HOST_ASM_MASM_X86_64) | 131 | if(HOST_ASM_MASM_X86_64) |
| 132 | set(CRYPTO_SRC ${CRYPTO_SRC} aes/aes_amd64.c) | ||
| 133 | set(CRYPTO_SRC ${CRYPTO_SRC} modes/gcm128_amd64.c) | ||
| 134 | |||
| 136 | set( | 135 | set( |
| 137 | ASM_X86_64_MASM_SRC | 136 | ASM_X86_64_MASM_SRC |
| 138 | aes/aes-masm-x86_64.S | 137 | aes/aes-masm-x86_64.S |
| 139 | aes/bsaes-masm-x86_64.S | ||
| 140 | aes/vpaes-masm-x86_64.S | ||
| 141 | aes/aesni-masm-x86_64.S | 138 | aes/aesni-masm-x86_64.S |
| 142 | #bn/modexp512-masm-x86_64.S | 139 | #bn/modexp512-masm-x86_64.S |
| 143 | #bn/mont-masm-x86_64.S | 140 | #bn/mont-masm-x86_64.S |
| 144 | #bn/mont5-masm-x86_64.S | 141 | #bn/mont5-masm-x86_64.S |
| 145 | md5/md5-masm-x86_64.S | ||
| 146 | modes/ghash-masm-x86_64.S | 142 | modes/ghash-masm-x86_64.S |
| 147 | rc4/rc4-masm-x86_64.S | 143 | rc4/rc4-masm-x86_64.S |
| 148 | sha/sha1-masm-x86_64.S | ||
| 149 | sha/sha256-masm-x86_64.S | ||
| 150 | sha/sha512-masm-x86_64.S | ||
| 151 | cpuid-masm-x86_64.S | ||
| 152 | ) | 144 | ) |
| 153 | add_definitions(-Dendbr64=) | 145 | add_definitions(-Dendbr64=) |
| 154 | add_definitions(-DAES_ASM) | 146 | add_definitions(-DLIBRESSL_USE_AES_ASSEMBLY) |
| 155 | add_definitions(-DBSAES_ASM) | 147 | #add_definitions(-DLIBRESSL_USE_BN_ASSEMBLY) |
| 156 | add_definitions(-DVPAES_ASM) | 148 | add_definitions(-DLIBRESSL_USE_GCM_ASSEMBLY) |
| 157 | add_definitions(-DHAVE_AES_CBC_ENCRYPT_INTERNAL) | 149 | add_definitions(-DLIBRESSL_USE_RC4_ASSEMBLY) |
| 158 | add_definitions(-DHAVE_AES_SET_ENCRYPT_KEY_INTERNAL) | ||
| 159 | add_definitions(-DHAVE_AES_SET_DECRYPT_KEY_INTERNAL) | ||
| 160 | add_definitions(-DHAVE_AES_ENCRYPT_INTERNAL) | ||
| 161 | add_definitions(-DHAVE_AES_DECRYPT_INTERNAL) | ||
| 162 | add_definitions(-DOPENSSL_IA32_SSE2) | ||
| 163 | #add_definitions(-DOPENSSL_BN_ASM_MONT) | 150 | #add_definitions(-DOPENSSL_BN_ASM_MONT) |
| 164 | #add_definitions(-DOPENSSL_BN_ASM_MONT5) | 151 | #add_definitions(-DOPENSSL_BN_ASM_MONT5) |
| 165 | add_definitions(-DMD5_ASM) | ||
| 166 | add_definitions(-DGHASH_ASM) | ||
| 167 | add_definitions(-DRSA_ASM) | ||
| 168 | add_definitions(-DSHA1_ASM) | ||
| 169 | add_definitions(-DSHA256_ASM) | ||
| 170 | add_definitions(-DSHA512_ASM) | ||
| 171 | add_definitions(-DWHIRLPOOL_ASM) | ||
| 172 | add_definitions(-DOPENSSL_CPUID_OBJ) | ||
| 173 | set(CRYPTO_SRC ${CRYPTO_SRC} ${ASM_X86_64_MASM_SRC}) | 152 | set(CRYPTO_SRC ${CRYPTO_SRC} ${ASM_X86_64_MASM_SRC}) |
| 174 | set_property(SOURCE ${ASM_X86_64_MASM_SRC} PROPERTY LANGUAGE ASM_MASM) | 153 | set_property(SOURCE ${ASM_X86_64_MASM_SRC} PROPERTY LANGUAGE ASM_MASM) |
| 175 | endif() | 154 | endif() |
| 176 | 155 | ||
| 177 | if(HOST_ASM_MINGW64_X86_64) | 156 | if(HOST_ASM_MINGW64_X86_64) |
| 157 | set(CRYPTO_SRC ${CRYPTO_SRC} aes/aes_amd64.c) | ||
| 158 | set(CRYPTO_SRC ${CRYPTO_SRC} modes/gcm128_amd64.c) | ||
| 159 | |||
| 178 | set( | 160 | set( |
| 179 | ASM_X86_64_MINGW64_SRC | 161 | ASM_X86_64_MINGW64_SRC |
| 180 | aes/aes-mingw64-x86_64.S | 162 | aes/aes-mingw64-x86_64.S |
| 181 | aes/bsaes-mingw64-x86_64.S | ||
| 182 | aes/vpaes-mingw64-x86_64.S | ||
| 183 | aes/aesni-mingw64-x86_64.S | 163 | aes/aesni-mingw64-x86_64.S |
| 184 | #bn/modexp512-mingw64-x86_64.S | 164 | #bn/modexp512-mingw64-x86_64.S |
| 185 | #bn/mont-mingw64-x86_64.S | 165 | #bn/mont-mingw64-x86_64.S |
| 186 | #bn/mont5-mingw64-x86_64.S | 166 | #bn/mont5-mingw64-x86_64.S |
| 187 | md5/md5-mingw64-x86_64.S | ||
| 188 | modes/ghash-mingw64-x86_64.S | 167 | modes/ghash-mingw64-x86_64.S |
| 189 | rc4/rc4-mingw64-x86_64.S | 168 | rc4/rc4-mingw64-x86_64.S |
| 190 | sha/sha1-mingw64-x86_64.S | ||
| 191 | sha/sha256-mingw64-x86_64.S | ||
| 192 | sha/sha512-mingw64-x86_64.S | ||
| 193 | cpuid-mingw64-x86_64.S | ||
| 194 | ) | 169 | ) |
| 195 | add_definitions(-Dendbr32=endbr64) | 170 | add_definitions(-Dendbr32=endbr64) |
| 196 | add_definitions(-DAES_ASM) | 171 | add_definitions(-DLIBRESSL_USE_AES_ASSEMBLY) |
| 197 | add_definitions(-DBSAES_ASM) | 172 | #add_definitions(-DLIBRESSL_USE_BN_ASSEMBLY) |
| 198 | add_definitions(-DVPAES_ASM) | 173 | add_definitions(-DLIBRESSL_USE_GCM_ASSEMBLY) |
| 199 | add_definitions(-DHAVE_AES_CBC_ENCRYPT_INTERNAL) | 174 | add_definitions(-DLIBRESSL_USE_RC4_ASSEMBLY) |
| 200 | add_definitions(-DHAVE_AES_SET_ENCRYPT_KEY_INTERNAL) | ||
| 201 | add_definitions(-DHAVE_AES_SET_DECRYPT_KEY_INTERNAL) | ||
| 202 | add_definitions(-DHAVE_AES_ENCRYPT_INTERNAL) | ||
| 203 | add_definitions(-DHAVE_AES_DECRYPT_INTERNAL) | ||
| 204 | add_definitions(-DOPENSSL_IA32_SSE2) | ||
| 205 | #add_definitions(-DOPENSSL_BN_ASM_MONT) | 175 | #add_definitions(-DOPENSSL_BN_ASM_MONT) |
| 206 | #add_definitions(-DOPENSSL_BN_ASM_MONT5) | 176 | #add_definitions(-DOPENSSL_BN_ASM_MONT5) |
| 207 | add_definitions(-DMD5_ASM) | ||
| 208 | add_definitions(-DGHASH_ASM) | ||
| 209 | add_definitions(-DRSA_ASM) | ||
| 210 | add_definitions(-DSHA1_ASM) | ||
| 211 | add_definitions(-DSHA256_ASM) | ||
| 212 | add_definitions(-DSHA512_ASM) | ||
| 213 | add_definitions(-DWHIRLPOOL_ASM) | ||
| 214 | add_definitions(-DOPENSSL_CPUID_OBJ) | ||
| 215 | set(CRYPTO_SRC ${CRYPTO_SRC} ${ASM_X86_64_MINGW64_SRC}) | 177 | set(CRYPTO_SRC ${CRYPTO_SRC} ${ASM_X86_64_MINGW64_SRC}) |
| 216 | set_property(SOURCE ${ASM_X86_64_MINGW64_SRC} PROPERTY LANGUAGE C) | 178 | endif() |
| 179 | |||
| 180 | if(HOST_AARCH64) | ||
| 181 | if(APPLE) | ||
| 182 | set(CRYPTO_SRC ${CRYPTO_SRC} arch/aarch64/crypto_cpu_caps_darwin.c) | ||
| 183 | elseif(LINUX) | ||
| 184 | set(CRYPTO_SRC ${CRYPTO_SRC} arch/aarch64/crypto_cpu_caps_linux.c) | ||
| 185 | elseif(CMAKE_SYSTEM_NAME STREQUAL "OpenBSD") | ||
| 186 | set(CRYPTO_SRC ${CRYPTO_SRC} arch/aarch64/crypto_cpu_caps.c) | ||
| 187 | elseif(WIN32) | ||
| 188 | set(CRYPTO_SRC ${CRYPTO_SRC} arch/aarch64/crypto_cpu_caps_windows.c) | ||
| 189 | else() | ||
| 190 | set(CRYPTO_SRC ${CRYPTO_SRC} arch/aarch64/crypto_cpu_caps_none.c) | ||
| 191 | endif() | ||
| 192 | elseif(HOST_X86_64) | ||
| 193 | set(CRYPTO_SRC ${CRYPTO_SRC} arch/amd64/crypto_cpu_caps.c) | ||
| 194 | elseif(HOST_I386) | ||
| 195 | set(CRYPTO_SRC ${CRYPTO_SRC} arch/i386/crypto_cpu_caps.c) | ||
| 217 | endif() | 196 | endif() |
| 218 | 197 | ||
| 219 | set( | 198 | set( |
| 220 | CRYPTO_SRC | 199 | CRYPTO_SRC |
| 221 | ${CRYPTO_SRC} | 200 | ${CRYPTO_SRC} |
| 222 | cpt_err.c | 201 | crypto_err.c |
| 223 | cryptlib.c | 202 | crypto_ex_data.c |
| 224 | crypto_init.c | 203 | crypto_init.c |
| 225 | cversion.c | 204 | crypto_legacy.c |
| 226 | ex_data.c | 205 | crypto_memory.c |
| 227 | malloc-wrapper.c | ||
| 228 | mem_clr.c | ||
| 229 | mem_dbg.c | ||
| 230 | o_fips.c | ||
| 231 | aes/aes.c | 206 | aes/aes.c |
| 232 | aes/aes_core.c | 207 | aes/aes_core.c |
| 233 | aes/aes_ige.c | ||
| 234 | asn1/a_bitstr.c | 208 | asn1/a_bitstr.c |
| 235 | asn1/a_enum.c | 209 | asn1/a_enum.c |
| 236 | asn1/a_int.c | 210 | asn1/a_int.c |
| @@ -280,10 +254,8 @@ set( | |||
| 280 | asn1/x_bignum.c | 254 | asn1/x_bignum.c |
| 281 | asn1/x_crl.c | 255 | asn1/x_crl.c |
| 282 | asn1/x_exten.c | 256 | asn1/x_exten.c |
| 283 | asn1/x_info.c | ||
| 284 | asn1/x_long.c | 257 | asn1/x_long.c |
| 285 | asn1/x_name.c | 258 | asn1/x_name.c |
| 286 | asn1/x_pkey.c | ||
| 287 | asn1/x_pubkey.c | 259 | asn1/x_pubkey.c |
| 288 | asn1/x_req.c | 260 | asn1/x_req.c |
| 289 | asn1/x_sig.c | 261 | asn1/x_sig.c |
| @@ -312,6 +284,7 @@ set( | |||
| 312 | bio/bss_null.c | 284 | bio/bss_null.c |
| 313 | bio/bss_sock.c | 285 | bio/bss_sock.c |
| 314 | bn/bn_add.c | 286 | bn/bn_add.c |
| 287 | bn/bn_add_sub.c | ||
| 315 | bn/bn_bpsw.c | 288 | bn/bn_bpsw.c |
| 316 | bn/bn_const.c | 289 | bn/bn_const.c |
| 317 | bn/bn_convert.c | 290 | bn/bn_convert.c |
| @@ -325,6 +298,7 @@ set( | |||
| 325 | bn/bn_lib.c | 298 | bn/bn_lib.c |
| 326 | bn/bn_mod.c | 299 | bn/bn_mod.c |
| 327 | bn/bn_mod_sqrt.c | 300 | bn/bn_mod_sqrt.c |
| 301 | bn/bn_mod_words.c | ||
| 328 | bn/bn_mont.c | 302 | bn/bn_mont.c |
| 329 | bn/bn_mul.c | 303 | bn/bn_mul.c |
| 330 | bn/bn_prime.c | 304 | bn/bn_prime.c |
| @@ -364,7 +338,6 @@ set( | |||
| 364 | conf/conf_def.c | 338 | conf/conf_def.c |
| 365 | conf/conf_err.c | 339 | conf/conf_err.c |
| 366 | conf/conf_lib.c | 340 | conf/conf_lib.c |
| 367 | conf/conf_mall.c | ||
| 368 | conf/conf_mod.c | 341 | conf/conf_mod.c |
| 369 | conf/conf_sap.c | 342 | conf/conf_sap.c |
| 370 | ct/ct_b64.c | 343 | ct/ct_b64.c |
| @@ -379,26 +352,11 @@ set( | |||
| 379 | ct/ct_x509v3.c | 352 | ct/ct_x509v3.c |
| 380 | curve25519/curve25519-generic.c | 353 | curve25519/curve25519-generic.c |
| 381 | curve25519/curve25519.c | 354 | curve25519/curve25519.c |
| 382 | des/cbc_cksm.c | 355 | des/des.c |
| 383 | des/cbc_enc.c | 356 | des/des_cksum.c |
| 384 | des/cfb64ede.c | ||
| 385 | des/cfb64enc.c | ||
| 386 | des/cfb_enc.c | ||
| 387 | des/des_enc.c | 357 | des/des_enc.c |
| 388 | des/ecb3_enc.c | 358 | des/des_fcrypt.c |
| 389 | des/ecb_enc.c | 359 | des/des_key.c |
| 390 | des/ede_cbcm_enc.c | ||
| 391 | des/enc_read.c | ||
| 392 | des/fcrypt.c | ||
| 393 | des/fcrypt_b.c | ||
| 394 | des/ofb64ede.c | ||
| 395 | des/ofb64enc.c | ||
| 396 | des/ofb_enc.c | ||
| 397 | des/pcbc_enc.c | ||
| 398 | des/qud_cksm.c | ||
| 399 | des/set_key.c | ||
| 400 | des/str2key.c | ||
| 401 | des/xcbc_enc.c | ||
| 402 | dh/dh_ameth.c | 360 | dh/dh_ameth.c |
| 403 | dh/dh_asn1.c | 361 | dh/dh_asn1.c |
| 404 | dh/dh_check.c | 362 | dh/dh_check.c |
| @@ -419,21 +377,17 @@ set( | |||
| 419 | dsa/dsa_prn.c | 377 | dsa/dsa_prn.c |
| 420 | ec/ec_ameth.c | 378 | ec/ec_ameth.c |
| 421 | ec/ec_asn1.c | 379 | ec/ec_asn1.c |
| 422 | ec/ec_check.c | 380 | ec/ec_convert.c |
| 423 | ec/ec_curve.c | 381 | ec/ec_curve.c |
| 424 | ec/ec_cvt.c | ||
| 425 | ec/ec_err.c | 382 | ec/ec_err.c |
| 383 | ec/ec_field.c | ||
| 426 | ec/ec_key.c | 384 | ec/ec_key.c |
| 427 | ec/ec_kmeth.c | ||
| 428 | ec/ec_lib.c | 385 | ec/ec_lib.c |
| 429 | ec/ec_mult.c | 386 | ec/ec_mult.c |
| 430 | ec/ec_oct.c | ||
| 431 | ec/ec_pmeth.c | 387 | ec/ec_pmeth.c |
| 432 | ec/ec_print.c | ||
| 433 | ec/eck_prn.c | 388 | ec/eck_prn.c |
| 434 | ec/ecp_mont.c | 389 | ec/ecp_hp_methods.c |
| 435 | ec/ecp_oct.c | 390 | ec/ecp_methods.c |
| 436 | ec/ecp_smpl.c | ||
| 437 | ec/ecx_methods.c | 391 | ec/ecx_methods.c |
| 438 | ecdh/ecdh.c | 392 | ecdh/ecdh.c |
| 439 | ecdsa/ecdsa.c | 393 | ecdsa/ecdsa.c |
| @@ -476,7 +430,6 @@ set( | |||
| 476 | evp/m_sha3.c | 430 | evp/m_sha3.c |
| 477 | evp/m_sigver.c | 431 | evp/m_sigver.c |
| 478 | evp/m_sm3.c | 432 | evp/m_sm3.c |
| 479 | evp/m_wp.c | ||
| 480 | evp/p_legacy.c | 433 | evp/p_legacy.c |
| 481 | evp/p_lib.c | 434 | evp/p_lib.c |
| 482 | evp/p_sign.c | 435 | evp/p_sign.c |
| @@ -495,6 +448,9 @@ set( | |||
| 495 | lhash/lhash.c | 448 | lhash/lhash.c |
| 496 | md4/md4.c | 449 | md4/md4.c |
| 497 | md5/md5.c | 450 | md5/md5.c |
| 451 | mlkem/mlkem.c | ||
| 452 | mlkem/mlkem_internal.c | ||
| 453 | mlkem/mlkem_key.c | ||
| 498 | modes/cbc128.c | 454 | modes/cbc128.c |
| 499 | modes/ccm128.c | 455 | modes/ccm128.c |
| 500 | modes/cfb128.c | 456 | modes/cfb128.c |
| @@ -552,11 +508,7 @@ set( | |||
| 552 | rand/rand_err.c | 508 | rand/rand_err.c |
| 553 | rand/rand_lib.c | 509 | rand/rand_lib.c |
| 554 | rand/randfile.c | 510 | rand/randfile.c |
| 555 | rc2/rc2_cbc.c | 511 | rc2/rc2.c |
| 556 | rc2/rc2_ecb.c | ||
| 557 | rc2/rc2_skey.c | ||
| 558 | rc2/rc2cfb64.c | ||
| 559 | rc2/rc2ofb64.c | ||
| 560 | rc4/rc4.c | 512 | rc4/rc4.c |
| 561 | ripemd/ripemd.c | 513 | ripemd/ripemd.c |
| 562 | rsa/rsa_ameth.c | 514 | rsa/rsa_ameth.c |
| @@ -599,8 +551,6 @@ set( | |||
| 599 | ui/ui_err.c | 551 | ui/ui_err.c |
| 600 | ui/ui_lib.c | 552 | ui/ui_lib.c |
| 601 | ui/ui_null.c | 553 | ui/ui_null.c |
| 602 | ui/ui_util.c | ||
| 603 | whrlpool/whirlpool.c | ||
| 604 | x509/by_dir.c | 554 | x509/by_dir.c |
| 605 | x509/by_file.c | 555 | x509/by_file.c |
| 606 | x509/by_mem.c | 556 | x509/by_mem.c |
| @@ -641,6 +591,7 @@ set( | |||
| 641 | x509/x509_r2x.c | 591 | x509/x509_r2x.c |
| 642 | x509/x509_req.c | 592 | x509/x509_req.c |
| 643 | x509/x509_set.c | 593 | x509/x509_set.c |
| 594 | x509/x509_siginfo.c | ||
| 644 | x509/x509_skey.c | 595 | x509/x509_skey.c |
| 645 | x509/x509_trs.c | 596 | x509/x509_trs.c |
| 646 | x509/x509_txt.c | 597 | x509/x509_txt.c |
| @@ -659,17 +610,17 @@ set( | |||
| 659 | 610 | ||
| 660 | set(COMPAT_SRC empty.c) | 611 | set(COMPAT_SRC empty.c) |
| 661 | 612 | ||
| 613 | set(CRYPTO_UNEXPORT ${CRYPTO_UNEXPORT} BIO_s_log) | ||
| 614 | |||
| 662 | if(UNIX) | 615 | if(UNIX) |
| 663 | set(CRYPTO_SRC ${CRYPTO_SRC} crypto_lock.c) | 616 | set(CRYPTO_SRC ${CRYPTO_SRC} crypto_lock.c) |
| 664 | set(CRYPTO_SRC ${CRYPTO_SRC} bio/b_posix.c) | 617 | set(CRYPTO_SRC ${CRYPTO_SRC} bio/b_posix.c) |
| 665 | set(CRYPTO_SRC ${CRYPTO_SRC} bio/bss_log.c) | ||
| 666 | set(CRYPTO_SRC ${CRYPTO_SRC} ui/ui_openssl.c) | 618 | set(CRYPTO_SRC ${CRYPTO_SRC} ui/ui_openssl.c) |
| 667 | endif() | 619 | endif() |
| 668 | 620 | ||
| 669 | if(WIN32) | 621 | if(WIN32) |
| 670 | set(CRYPTO_SRC ${CRYPTO_SRC} compat/crypto_lock_win.c) | 622 | set(CRYPTO_SRC ${CRYPTO_SRC} compat/crypto_lock_win.c) |
| 671 | set(CRYPTO_SRC ${CRYPTO_SRC} bio/b_win.c) | 623 | set(CRYPTO_SRC ${CRYPTO_SRC} bio/b_win.c) |
| 672 | set(CRYPTO_UNEXPORT ${CRYPTO_UNEXPORT} BIO_s_log) | ||
| 673 | set(CRYPTO_SRC ${CRYPTO_SRC} ui/ui_openssl_win.c) | 624 | set(CRYPTO_SRC ${CRYPTO_SRC} ui/ui_openssl_win.c) |
| 674 | endif() | 625 | endif() |
| 675 | 626 | ||
| @@ -685,6 +636,18 @@ if(NOT HAVE_FREEZERO) | |||
| 685 | set(COMPAT_SRC ${COMPAT_SRC} compat/freezero.c) | 636 | set(COMPAT_SRC ${COMPAT_SRC} compat/freezero.c) |
| 686 | endif() | 637 | endif() |
| 687 | 638 | ||
| 639 | if(NOT HAVE_FTRUNCATE) | ||
| 640 | set(COMPAT_SRC ${COMPAT_SRC} compat/ftruncate.c) | ||
| 641 | endif() | ||
| 642 | |||
| 643 | if(NOT HAVE_GETDELIM) | ||
| 644 | set(COMPAT_SRC ${COMPAT_SRC} compat/getdelim.c) | ||
| 645 | endif() | ||
| 646 | |||
| 647 | if(NOT HAVE_GETLINE) | ||
| 648 | set(COMPAT_SRC ${COMPAT_SRC} compat/getline.c) | ||
| 649 | endif() | ||
| 650 | |||
| 688 | if(NOT HAVE_GETOPT) | 651 | if(NOT HAVE_GETOPT) |
| 689 | set(COMPAT_SRC ${COMPAT_SRC} compat/getopt_long.c) | 652 | set(COMPAT_SRC ${COMPAT_SRC} compat/getopt_long.c) |
| 690 | endif() | 653 | endif() |
| @@ -817,10 +780,12 @@ add_library(crypto_obj OBJECT ${CRYPTO_SRC}) | |||
| 817 | target_include_directories(crypto_obj | 780 | target_include_directories(crypto_obj |
| 818 | PRIVATE | 781 | PRIVATE |
| 819 | . | 782 | . |
| 783 | aes | ||
| 820 | asn1 | 784 | asn1 |
| 821 | bio | 785 | bio |
| 822 | bn | 786 | bn |
| 823 | bytestring | 787 | bytestring |
| 788 | conf | ||
| 824 | dh | 789 | dh |
| 825 | dsa | 790 | dsa |
| 826 | curve25519 | 791 | curve25519 |
| @@ -832,6 +797,7 @@ target_include_directories(crypto_obj | |||
| 832 | hidden | 797 | hidden |
| 833 | hmac | 798 | hmac |
| 834 | lhash | 799 | lhash |
| 800 | mlkem | ||
| 835 | modes | 801 | modes |
| 836 | ocsp | 802 | ocsp |
| 837 | pkcs12 | 803 | pkcs12 |
| @@ -845,41 +811,65 @@ target_include_directories(crypto_obj | |||
| 845 | ${CMAKE_BINARY_DIR}/include) | 811 | ${CMAKE_BINARY_DIR}/include) |
| 846 | 812 | ||
| 847 | if(HOST_AARCH64) | 813 | if(HOST_AARCH64) |
| 814 | target_include_directories(crypto_obj PRIVATE arch/aarch64/) | ||
| 848 | target_include_directories(crypto_obj PRIVATE bn/arch/aarch64/) | 815 | target_include_directories(crypto_obj PRIVATE bn/arch/aarch64/) |
| 849 | elseif(HOST_ARM) | 816 | elseif(HOST_ARM) |
| 817 | target_include_directories(crypto_obj PRIVATE arch/arm/) | ||
| 850 | target_include_directories(crypto_obj PRIVATE bn/arch/arm/) | 818 | target_include_directories(crypto_obj PRIVATE bn/arch/arm/) |
| 851 | elseif(HOST_I386) | 819 | elseif(HOST_I386) |
| 820 | target_include_directories(crypto_obj PRIVATE arch/i386/) | ||
| 852 | target_include_directories(crypto_obj PRIVATE bn/arch/i386/) | 821 | target_include_directories(crypto_obj PRIVATE bn/arch/i386/) |
| 822 | elseif(HOST_LOONGARCH64) | ||
| 823 | target_include_directories(crypto_obj PRIVATE arch/loongarch64) | ||
| 824 | target_include_directories(crypto_obj PRIVATE bn/arch/loongarch64) | ||
| 853 | elseif(HOST_MIPS64) | 825 | elseif(HOST_MIPS64) |
| 826 | target_include_directories(crypto_obj PRIVATE arch/mips64) | ||
| 854 | target_include_directories(crypto_obj PRIVATE bn/arch/mips64) | 827 | target_include_directories(crypto_obj PRIVATE bn/arch/mips64) |
| 855 | elseif(HOST_MIPS) | 828 | elseif(HOST_MIPS) |
| 829 | target_include_directories(crypto_obj PRIVATE arch/mips) | ||
| 856 | target_include_directories(crypto_obj PRIVATE bn/arch/mips) | 830 | target_include_directories(crypto_obj PRIVATE bn/arch/mips) |
| 857 | elseif(HOST_POWERPC) | 831 | elseif(HOST_POWERPC) |
| 832 | target_include_directories(crypto_obj PRIVATE arch/powerpc) | ||
| 858 | target_include_directories(crypto_obj PRIVATE bn/arch/powerpc) | 833 | target_include_directories(crypto_obj PRIVATE bn/arch/powerpc) |
| 859 | elseif(HOST_POWERPC64) | 834 | elseif(HOST_POWERPC64) |
| 835 | target_include_directories(crypto_obj PRIVATE arch/powerpc64) | ||
| 860 | target_include_directories(crypto_obj PRIVATE bn/arch/powerpc64) | 836 | target_include_directories(crypto_obj PRIVATE bn/arch/powerpc64) |
| 861 | elseif(HOST_RISCV64) | 837 | elseif(HOST_RISCV64) |
| 838 | target_include_directories(crypto_obj PRIVATE arch/riscv64) | ||
| 862 | target_include_directories(crypto_obj PRIVATE bn/arch/riscv64) | 839 | target_include_directories(crypto_obj PRIVATE bn/arch/riscv64) |
| 863 | elseif(HOST_SPARC64) | 840 | elseif(HOST_SPARC64) |
| 841 | target_include_directories(crypto_obj PRIVATE arch/sparc64) | ||
| 864 | target_include_directories(crypto_obj PRIVATE bn/arch/sparc64) | 842 | target_include_directories(crypto_obj PRIVATE bn/arch/sparc64) |
| 865 | elseif(HOST_X86_64) | 843 | elseif(HOST_X86_64) |
| 844 | target_include_directories(crypto_obj PRIVATE arch/amd64) | ||
| 866 | target_include_directories(crypto_obj PRIVATE bn/arch/amd64) | 845 | target_include_directories(crypto_obj PRIVATE bn/arch/amd64) |
| 867 | endif() | 846 | endif() |
| 868 | 847 | ||
| 848 | if(MSVC) | ||
| 849 | # "C4701" - Potentially uninitialized local variable 'name' used | ||
| 850 | set_source_files_properties(bn/bn_convert.c pem/pem_lib.c PROPERTIES | ||
| 851 | COMPILE_OPTIONS /wd4701 | ||
| 852 | ) | ||
| 853 | # "C4702" - unreachable code | ||
| 854 | set_source_files_properties(pkcs7/pk7_doit.c PROPERTIES | ||
| 855 | COMPILE_OPTIONS /wd4702 | ||
| 856 | ) | ||
| 857 | endif() | ||
| 858 | |||
| 869 | add_library(crypto $<TARGET_OBJECTS:crypto_obj> $<TARGET_OBJECTS:compat_obj> empty.c) | 859 | add_library(crypto $<TARGET_OBJECTS:crypto_obj> $<TARGET_OBJECTS:compat_obj> empty.c) |
| 870 | 860 | ||
| 871 | export_symbol(crypto ${CMAKE_CURRENT_BINARY_DIR}/crypto_p.sym) | 861 | export_symbol(crypto ${CMAKE_CURRENT_BINARY_DIR}/crypto_p.sym) |
| 872 | target_link_libraries(crypto ${PLATFORM_LIBS}) | 862 | target_link_libraries(crypto ${PLATFORM_LIBS}) |
| 873 | if (WIN32) | ||
| 874 | set(CRYPTO_POSTFIX -${CRYPTO_MAJOR_VERSION} PARENT_SCOPE) | ||
| 875 | endif() | ||
| 876 | set_target_properties(crypto PROPERTIES | 863 | set_target_properties(crypto PROPERTIES |
| 877 | OUTPUT_NAME crypto${CRYPTO_POSTFIX} | 864 | OUTPUT_NAME crypto |
| 878 | ARCHIVE_OUTPUT_NAME crypto${CRYPTO_POSTFIX} | 865 | ARCHIVE_OUTPUT_NAME crypto |
| 879 | EXPORT_NAME Crypto | 866 | EXPORT_NAME Crypto |
| 880 | VERSION ${CRYPTO_VERSION} | 867 | VERSION ${CRYPTO_VERSION} |
| 881 | SOVERSION ${CRYPTO_MAJOR_VERSION} | 868 | SOVERSION ${CRYPTO_MAJOR_VERSION} |
| 882 | ) | 869 | ) |
| 870 | if(NOT CMAKE_VERSION VERSION_LESS 3.27.0) | ||
| 871 | set_target_properties(crypto PROPERTIES DLL_NAME_WITH_SOVERSION TRUE) | ||
| 872 | endif() | ||
| 883 | 873 | ||
| 884 | target_include_directories( | 874 | target_include_directories( |
| 885 | crypto | 875 | crypto |
| @@ -919,4 +909,3 @@ if(BUILD_SHARED_LIBS) | |||
| 919 | add_library(crypto-static STATIC $<TARGET_OBJECTS:crypto_obj>) | 909 | add_library(crypto-static STATIC $<TARGET_OBJECTS:crypto_obj>) |
| 920 | target_link_libraries(crypto-static ${PLATFORM_LIBS}) | 910 | target_link_libraries(crypto-static ${PLATFORM_LIBS}) |
| 921 | endif() | 911 | endif() |
| 922 | |||
diff --git a/crypto/Makefile.am b/crypto/Makefile.am index 6e1e975..b03347a 100644 --- a/crypto/Makefile.am +++ b/crypto/Makefile.am | |||
| @@ -1,10 +1,27 @@ | |||
| 1 | # | ||
| 2 | # Copyright (c) 2014 Brent Cook | ||
| 3 | # | ||
| 4 | # Permission to use, copy, modify, and distribute this software for any | ||
| 5 | # purpose with or without fee is hereby granted, provided that the above | ||
| 6 | # copyright notice and this permission notice appear in all copies. | ||
| 7 | # | ||
| 8 | # THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES | ||
| 9 | # WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF | ||
| 10 | # MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR | ||
| 11 | # ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES | ||
| 12 | # WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN | ||
| 13 | # ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF | ||
| 14 | # OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. | ||
| 15 | |||
| 1 | include $(top_srcdir)/Makefile.am.common | 16 | include $(top_srcdir)/Makefile.am.common |
| 2 | 17 | ||
| 3 | AM_CPPFLAGS += -DLIBRESSL_CRYPTO_INTERNAL | 18 | AM_CPPFLAGS += -DLIBRESSL_CRYPTO_INTERNAL |
| 19 | AM_CPPFLAGS += -I$(top_srcdir)/crypto/aes | ||
| 4 | AM_CPPFLAGS += -I$(top_srcdir)/crypto/asn1 | 20 | AM_CPPFLAGS += -I$(top_srcdir)/crypto/asn1 |
| 5 | AM_CPPFLAGS += -I$(top_srcdir)/crypto/bio | 21 | AM_CPPFLAGS += -I$(top_srcdir)/crypto/bio |
| 6 | AM_CPPFLAGS += -I$(top_srcdir)/crypto/bn | 22 | AM_CPPFLAGS += -I$(top_srcdir)/crypto/bn |
| 7 | AM_CPPFLAGS += -I$(top_srcdir)/crypto/bytestring | 23 | AM_CPPFLAGS += -I$(top_srcdir)/crypto/bytestring |
| 24 | AM_CPPFLAGS += -I$(top_srcdir)/crypto/conf | ||
| 8 | AM_CPPFLAGS += -I$(top_srcdir)/crypto/curve25519 | 25 | AM_CPPFLAGS += -I$(top_srcdir)/crypto/curve25519 |
| 9 | AM_CPPFLAGS += -I$(top_srcdir)/crypto/dh | 26 | AM_CPPFLAGS += -I$(top_srcdir)/crypto/dh |
| 10 | AM_CPPFLAGS += -I$(top_srcdir)/crypto/dsa | 27 | AM_CPPFLAGS += -I$(top_srcdir)/crypto/dsa |
| @@ -15,6 +32,7 @@ AM_CPPFLAGS += -I$(top_srcdir)/crypto/err | |||
| 15 | AM_CPPFLAGS += -I$(top_srcdir)/crypto/evp | 32 | AM_CPPFLAGS += -I$(top_srcdir)/crypto/evp |
| 16 | AM_CPPFLAGS += -I$(top_srcdir)/crypto/hmac | 33 | AM_CPPFLAGS += -I$(top_srcdir)/crypto/hmac |
| 17 | AM_CPPFLAGS += -I$(top_srcdir)/crypto/lhash | 34 | AM_CPPFLAGS += -I$(top_srcdir)/crypto/lhash |
| 35 | AM_CPPFLAGS += -I$(top_srcdir)/crypto/mlkem | ||
| 18 | AM_CPPFLAGS += -I$(top_srcdir)/crypto/modes | 36 | AM_CPPFLAGS += -I$(top_srcdir)/crypto/modes |
| 19 | AM_CPPFLAGS += -I$(top_srcdir)/crypto/ocsp | 37 | AM_CPPFLAGS += -I$(top_srcdir)/crypto/ocsp |
| 20 | AM_CPPFLAGS += -I$(top_srcdir)/crypto/pkcs12 | 38 | AM_CPPFLAGS += -I$(top_srcdir)/crypto/pkcs12 |
| @@ -49,20 +67,18 @@ crypto_portable.sym: crypto.sym Makefile | |||
| 49 | -echo "generating crypto_portable.sym ..." | 67 | -echo "generating crypto_portable.sym ..." |
| 50 | -cp $(top_srcdir)/crypto/crypto.sym crypto_portable.sym | 68 | -cp $(top_srcdir)/crypto/crypto.sym crypto_portable.sym |
| 51 | -chmod u+w crypto_portable.sym | 69 | -chmod u+w crypto_portable.sym |
| 52 | if HOST_WIN | ||
| 53 | -grep -v BIO_s_log crypto_portable.sym > crypto_portable.sym.tmp | 70 | -grep -v BIO_s_log crypto_portable.sym > crypto_portable.sym.tmp |
| 54 | -mv crypto_portable.sym.tmp crypto_portable.sym | 71 | -mv crypto_portable.sym.tmp crypto_portable.sym |
| 55 | endif | ||
| 56 | 72 | ||
| 57 | libcrypto_la_objects.mk: Makefile | 73 | libcrypto_la_objects.mk: Makefile |
| 58 | @echo "libcrypto_la_objects= $(libcrypto_la_OBJECTS)" \ | 74 | @echo "libcrypto_la_objects= $(libcrypto_la_OBJECTS)" \ |
| 59 | | sed 's/ */ $$\(abs_top_builddir\)\/crypto\//g' \ | 75 | | sed 's/ */ $$\(top_builddir\)\/crypto\//g' \ |
| 60 | > libcrypto_la_objects.mk | 76 | > libcrypto_la_objects.mk |
| 61 | @echo "libcompat_la_objects= $(libcompat_la_OBJECTS)" \ | 77 | @echo "libcompat_la_objects= $(libcompat_la_OBJECTS)" \ |
| 62 | | sed 's/compat\// $$\(abs_top_builddir\)\/crypto\/&/g' \ | 78 | | sed 's/compat\// $$\(top_builddir\)\/crypto\/&/g' \ |
| 63 | >> libcrypto_la_objects.mk | 79 | >> libcrypto_la_objects.mk |
| 64 | @echo "libcompatnoopt_la_objects= $(libcompatnoopt_la_OBJECTS)" \ | 80 | @echo "libcompatnoopt_la_objects= $(libcompatnoopt_la_OBJECTS)" \ |
| 65 | | sed 's/compat\// $$\(abs_top_builddir\)\/crypto\/&/g' \ | 81 | | sed 's/compat\// $$\(top_builddir\)\/crypto\/&/g' \ |
| 66 | >> libcrypto_la_objects.mk | 82 | >> libcrypto_la_objects.mk |
| 67 | 83 | ||
| 68 | libcrypto_la_LDFLAGS = -version-info @LIBCRYPTO_VERSION@ -no-undefined -export-symbols crypto_portable.sym | 84 | libcrypto_la_LDFLAGS = -version-info @LIBCRYPTO_VERSION@ -no-undefined -export-symbols crypto_portable.sym |
| @@ -132,6 +148,18 @@ if !HAVE_FREEZERO | |||
| 132 | libcompat_la_SOURCES += compat/freezero.c | 148 | libcompat_la_SOURCES += compat/freezero.c |
| 133 | endif | 149 | endif |
| 134 | 150 | ||
| 151 | if !HAVE_FTRUNCATE | ||
| 152 | libcompat_la_SOURCES += compat/ftruncate.c | ||
| 153 | endif | ||
| 154 | |||
| 155 | if !HAVE_GETDELIM | ||
| 156 | libcompat_la_SOURCES += compat/getdelim.c | ||
| 157 | endif | ||
| 158 | |||
| 159 | if !HAVE_GETLINE | ||
| 160 | libcompat_la_SOURCES += compat/getline.c | ||
| 161 | endif | ||
| 162 | |||
| 135 | if !HAVE_GETPAGESIZE | 163 | if !HAVE_GETPAGESIZE |
| 136 | libcompat_la_SOURCES += compat/getpagesize.c | 164 | libcompat_la_SOURCES += compat/getpagesize.c |
| 137 | endif | 165 | endif |
| @@ -177,7 +205,7 @@ include Makefile.am.arc4random | |||
| 177 | libcrypto_la_SOURCES = | 205 | libcrypto_la_SOURCES = |
| 178 | EXTRA_libcrypto_la_SOURCES = | 206 | EXTRA_libcrypto_la_SOURCES = |
| 179 | 207 | ||
| 180 | include Makefile.am.elf-arm | 208 | include Makefile.am.elf-aarch64 |
| 181 | include Makefile.am.elf-mips | 209 | include Makefile.am.elf-mips |
| 182 | include Makefile.am.elf-mips64 | 210 | include Makefile.am.elf-mips64 |
| 183 | include Makefile.am.elf-x86_64 | 211 | include Makefile.am.elf-x86_64 |
| @@ -185,7 +213,7 @@ include Makefile.am.macosx-x86_64 | |||
| 185 | include Makefile.am.masm-x86_64 | 213 | include Makefile.am.masm-x86_64 |
| 186 | include Makefile.am.mingw64-x86_64 | 214 | include Makefile.am.mingw64-x86_64 |
| 187 | 215 | ||
| 188 | if !HOST_ASM_ELF_ARM | 216 | if !HOST_ASM_ELF_AARCH64 |
| 189 | if !HOST_ASM_ELF_MIPS | 217 | if !HOST_ASM_ELF_MIPS |
| 190 | if !HOST_ASM_ELF_MIPS64 | 218 | if !HOST_ASM_ELF_MIPS64 |
| 191 | if !HOST_ASM_ELF_X86_64 | 219 | if !HOST_ASM_ELF_X86_64 |
| @@ -201,23 +229,44 @@ endif | |||
| 201 | endif | 229 | endif |
| 202 | endif | 230 | endif |
| 203 | 231 | ||
| 204 | libcrypto_la_SOURCES += cpt_err.c | 232 | if HOST_AARCH64 |
| 205 | libcrypto_la_SOURCES += cryptlib.c | 233 | if HOST_DARWIN |
| 234 | libcrypto_la_SOURCES += arch/aarch64/crypto_cpu_caps_darwin.c | ||
| 235 | else | ||
| 236 | if HOST_LINUX | ||
| 237 | libcrypto_la_SOURCES += arch/aarch64/crypto_cpu_caps_linux.c | ||
| 238 | else | ||
| 239 | if HOST_WIN | ||
| 240 | libcrypto_la_SOURCES += arch/aarch64/crypto_cpu_caps_windows.c | ||
| 241 | else | ||
| 242 | if HOST_OPENBSD | ||
| 243 | libcrypto_la_SOURCES += arch/aarch64/crypto_cpu_caps.c | ||
| 244 | else | ||
| 245 | libcrypto_la_SOURCES += arch/aarch64/crypto_cpu_caps_none.c | ||
| 246 | endif | ||
| 247 | endif | ||
| 248 | endif | ||
| 249 | endif | ||
| 250 | endif | ||
| 251 | |||
| 252 | if HOST_X86_64 | ||
| 253 | libcrypto_la_SOURCES += arch/amd64/crypto_cpu_caps.c | ||
| 254 | endif | ||
| 255 | if HOST_I386 | ||
| 256 | libcrypto_la_SOURCES += arch/i386/crypto_cpu_caps.c | ||
| 257 | endif | ||
| 258 | |||
| 259 | libcrypto_la_SOURCES += crypto_err.c | ||
| 260 | libcrypto_la_SOURCES += crypto_ex_data.c | ||
| 206 | libcrypto_la_SOURCES += crypto_init.c | 261 | libcrypto_la_SOURCES += crypto_init.c |
| 262 | libcrypto_la_SOURCES += crypto_legacy.c | ||
| 207 | if !HOST_WIN | 263 | if !HOST_WIN |
| 208 | libcrypto_la_SOURCES += crypto_lock.c | 264 | libcrypto_la_SOURCES += crypto_lock.c |
| 209 | else | 265 | else |
| 210 | libcrypto_la_SOURCES += compat/crypto_lock_win.c | 266 | libcrypto_la_SOURCES += compat/crypto_lock_win.c |
| 211 | endif | 267 | endif |
| 212 | libcrypto_la_SOURCES += cversion.c | 268 | libcrypto_la_SOURCES += crypto_memory.c |
| 213 | libcrypto_la_SOURCES += ex_data.c | ||
| 214 | libcrypto_la_SOURCES += malloc-wrapper.c | ||
| 215 | libcrypto_la_SOURCES += mem_clr.c | ||
| 216 | libcrypto_la_SOURCES += mem_dbg.c | ||
| 217 | libcrypto_la_SOURCES += o_fips.c | ||
| 218 | noinst_HEADERS += arm_arch.h | ||
| 219 | noinst_HEADERS += constant_time.h | 269 | noinst_HEADERS += constant_time.h |
| 220 | noinst_HEADERS += cryptlib.h | ||
| 221 | noinst_HEADERS += crypto_internal.h | 270 | noinst_HEADERS += crypto_internal.h |
| 222 | noinst_HEADERS += crypto_local.h | 271 | noinst_HEADERS += crypto_local.h |
| 223 | noinst_HEADERS += x86_arch.h | 272 | noinst_HEADERS += x86_arch.h |
| @@ -225,7 +274,6 @@ noinst_HEADERS += x86_arch.h | |||
| 225 | # aes | 274 | # aes |
| 226 | libcrypto_la_SOURCES += aes/aes.c | 275 | libcrypto_la_SOURCES += aes/aes.c |
| 227 | libcrypto_la_SOURCES += aes/aes_core.c | 276 | libcrypto_la_SOURCES += aes/aes_core.c |
| 228 | libcrypto_la_SOURCES += aes/aes_ige.c | ||
| 229 | noinst_HEADERS += aes/aes_local.h | 277 | noinst_HEADERS += aes/aes_local.h |
| 230 | 278 | ||
| 231 | # asn1 | 279 | # asn1 |
| @@ -278,10 +326,8 @@ libcrypto_la_SOURCES += asn1/x_attrib.c | |||
| 278 | libcrypto_la_SOURCES += asn1/x_bignum.c | 326 | libcrypto_la_SOURCES += asn1/x_bignum.c |
| 279 | libcrypto_la_SOURCES += asn1/x_crl.c | 327 | libcrypto_la_SOURCES += asn1/x_crl.c |
| 280 | libcrypto_la_SOURCES += asn1/x_exten.c | 328 | libcrypto_la_SOURCES += asn1/x_exten.c |
| 281 | libcrypto_la_SOURCES += asn1/x_info.c | ||
| 282 | libcrypto_la_SOURCES += asn1/x_long.c | 329 | libcrypto_la_SOURCES += asn1/x_long.c |
| 283 | libcrypto_la_SOURCES += asn1/x_name.c | 330 | libcrypto_la_SOURCES += asn1/x_name.c |
| 284 | libcrypto_la_SOURCES += asn1/x_pkey.c | ||
| 285 | libcrypto_la_SOURCES += asn1/x_pubkey.c | 331 | libcrypto_la_SOURCES += asn1/x_pubkey.c |
| 286 | libcrypto_la_SOURCES += asn1/x_req.c | 332 | libcrypto_la_SOURCES += asn1/x_req.c |
| 287 | libcrypto_la_SOURCES += asn1/x_sig.c | 333 | libcrypto_la_SOURCES += asn1/x_sig.c |
| @@ -319,9 +365,6 @@ libcrypto_la_SOURCES += bio/bss_conn.c | |||
| 319 | libcrypto_la_SOURCES += bio/bss_dgram.c | 365 | libcrypto_la_SOURCES += bio/bss_dgram.c |
| 320 | libcrypto_la_SOURCES += bio/bss_fd.c | 366 | libcrypto_la_SOURCES += bio/bss_fd.c |
| 321 | libcrypto_la_SOURCES += bio/bss_file.c | 367 | libcrypto_la_SOURCES += bio/bss_file.c |
| 322 | if !HOST_WIN | ||
| 323 | libcrypto_la_SOURCES += bio/bss_log.c | ||
| 324 | endif | ||
| 325 | libcrypto_la_SOURCES += bio/bss_mem.c | 368 | libcrypto_la_SOURCES += bio/bss_mem.c |
| 326 | libcrypto_la_SOURCES += bio/bss_null.c | 369 | libcrypto_la_SOURCES += bio/bss_null.c |
| 327 | libcrypto_la_SOURCES += bio/bss_sock.c | 370 | libcrypto_la_SOURCES += bio/bss_sock.c |
| @@ -329,6 +372,7 @@ noinst_HEADERS += bio/bio_local.h | |||
| 329 | 372 | ||
| 330 | # bn | 373 | # bn |
| 331 | libcrypto_la_SOURCES += bn/bn_add.c | 374 | libcrypto_la_SOURCES += bn/bn_add.c |
| 375 | libcrypto_la_SOURCES += bn/bn_add_sub.c | ||
| 332 | libcrypto_la_SOURCES += bn/bn_bpsw.c | 376 | libcrypto_la_SOURCES += bn/bn_bpsw.c |
| 333 | libcrypto_la_SOURCES += bn/bn_const.c | 377 | libcrypto_la_SOURCES += bn/bn_const.c |
| 334 | libcrypto_la_SOURCES += bn/bn_convert.c | 378 | libcrypto_la_SOURCES += bn/bn_convert.c |
| @@ -342,6 +386,7 @@ libcrypto_la_SOURCES += bn/bn_kron.c | |||
| 342 | libcrypto_la_SOURCES += bn/bn_lib.c | 386 | libcrypto_la_SOURCES += bn/bn_lib.c |
| 343 | libcrypto_la_SOURCES += bn/bn_mod.c | 387 | libcrypto_la_SOURCES += bn/bn_mod.c |
| 344 | libcrypto_la_SOURCES += bn/bn_mod_sqrt.c | 388 | libcrypto_la_SOURCES += bn/bn_mod_sqrt.c |
| 389 | libcrypto_la_SOURCES += bn/bn_mod_words.c | ||
| 345 | libcrypto_la_SOURCES += bn/bn_mont.c | 390 | libcrypto_la_SOURCES += bn/bn_mont.c |
| 346 | libcrypto_la_SOURCES += bn/bn_mul.c | 391 | libcrypto_la_SOURCES += bn/bn_mul.c |
| 347 | libcrypto_la_SOURCES += bn/bn_prime.c | 392 | libcrypto_la_SOURCES += bn/bn_prime.c |
| @@ -359,55 +404,82 @@ noinst_HEADERS += bn/bn_prime.h | |||
| 359 | noinst_HEADERS += bn/s2n_bignum.h | 404 | noinst_HEADERS += bn/s2n_bignum.h |
| 360 | noinst_HEADERS += bn/s2n_bignum_internal.h | 405 | noinst_HEADERS += bn/s2n_bignum_internal.h |
| 361 | 406 | ||
| 362 | # bn/arch | 407 | # arch, bn/arch |
| 363 | if HOST_AARCH64 | 408 | if HOST_AARCH64 |
| 409 | libcrypto_la_CPPFLAGS += -I$(top_srcdir)/crypto/arch/aarch64/ | ||
| 364 | libcrypto_la_CPPFLAGS += -I$(top_srcdir)/crypto/bn/arch/aarch64/ | 410 | libcrypto_la_CPPFLAGS += -I$(top_srcdir)/crypto/bn/arch/aarch64/ |
| 365 | endif | 411 | endif |
| 412 | noinst_HEADERS += arch/aarch64/crypto_arch.h | ||
| 366 | noinst_HEADERS += bn/arch/aarch64/bn_arch.h | 413 | noinst_HEADERS += bn/arch/aarch64/bn_arch.h |
| 367 | 414 | ||
| 368 | if HOST_ARM | 415 | if HOST_ARM |
| 416 | libcrypto_la_CPPFLAGS += -I$(top_srcdir)/crypto/arch/arm/ | ||
| 369 | libcrypto_la_CPPFLAGS += -I$(top_srcdir)/crypto/bn/arch/arm/ | 417 | libcrypto_la_CPPFLAGS += -I$(top_srcdir)/crypto/bn/arch/arm/ |
| 370 | endif | 418 | endif |
| 419 | noinst_HEADERS += arch/arm/crypto_arch.h | ||
| 371 | noinst_HEADERS += bn/arch/arm/bn_arch.h | 420 | noinst_HEADERS += bn/arch/arm/bn_arch.h |
| 372 | 421 | ||
| 373 | if HOST_I386 | 422 | if HOST_I386 |
| 423 | libcrypto_la_CPPFLAGS += -I$(top_srcdir)/crypto/arch/i386/ | ||
| 374 | libcrypto_la_CPPFLAGS += -I$(top_srcdir)/crypto/bn/arch/i386/ | 424 | libcrypto_la_CPPFLAGS += -I$(top_srcdir)/crypto/bn/arch/i386/ |
| 375 | endif | 425 | endif |
| 426 | noinst_HEADERS += arch/i386/crypto_arch.h | ||
| 376 | noinst_HEADERS += bn/arch/i386/bn_arch.h | 427 | noinst_HEADERS += bn/arch/i386/bn_arch.h |
| 377 | 428 | ||
| 429 | if HOST_LOONGARCH64 | ||
| 430 | libcrypto_la_CPPFLAGS += -I$(top_srcdir)/crypto/arch/loongarch64/ | ||
| 431 | libcrypto_la_CPPFLAGS += -I$(top_srcdir)/crypto/bn/arch/loongarch64/ | ||
| 432 | endif | ||
| 433 | noinst_HEADERS += arch/loongarch64/crypto_arch.h | ||
| 434 | noinst_HEADERS += bn/arch/loongarch64/bn_arch.h | ||
| 435 | |||
| 378 | if HOST_MIPS | 436 | if HOST_MIPS |
| 437 | libcrypto_la_CPPFLAGS += -I$(top_srcdir)/crypto/arch/mips/ | ||
| 379 | libcrypto_la_CPPFLAGS += -I$(top_srcdir)/crypto/bn/arch/mips/ | 438 | libcrypto_la_CPPFLAGS += -I$(top_srcdir)/crypto/bn/arch/mips/ |
| 380 | endif | 439 | endif |
| 440 | noinst_HEADERS += arch/mips/crypto_arch.h | ||
| 381 | noinst_HEADERS += bn/arch/mips/bn_arch.h | 441 | noinst_HEADERS += bn/arch/mips/bn_arch.h |
| 382 | 442 | ||
| 383 | if HOST_MIPS64 | 443 | if HOST_MIPS64 |
| 444 | libcrypto_la_CPPFLAGS += -I$(top_srcdir)/crypto/arch/mips64/ | ||
| 384 | libcrypto_la_CPPFLAGS += -I$(top_srcdir)/crypto/bn/arch/mips64/ | 445 | libcrypto_la_CPPFLAGS += -I$(top_srcdir)/crypto/bn/arch/mips64/ |
| 385 | endif | 446 | endif |
| 447 | noinst_HEADERS += arch/mips64/crypto_arch.h | ||
| 386 | noinst_HEADERS += bn/arch/mips64/bn_arch.h | 448 | noinst_HEADERS += bn/arch/mips64/bn_arch.h |
| 387 | 449 | ||
| 388 | if HOST_POWERPC | 450 | if HOST_POWERPC |
| 451 | libcrypto_la_CPPFLAGS += -I$(top_srcdir)/crypto/arch/powerpc/ | ||
| 389 | libcrypto_la_CPPFLAGS += -I$(top_srcdir)/crypto/bn/arch/powerpc/ | 452 | libcrypto_la_CPPFLAGS += -I$(top_srcdir)/crypto/bn/arch/powerpc/ |
| 390 | endif | 453 | endif |
| 454 | noinst_HEADERS += arch/powerpc/crypto_arch.h | ||
| 391 | noinst_HEADERS += bn/arch/powerpc/bn_arch.h | 455 | noinst_HEADERS += bn/arch/powerpc/bn_arch.h |
| 392 | 456 | ||
| 393 | if HOST_POWERPC64 | 457 | if HOST_POWERPC64 |
| 458 | libcrypto_la_CPPFLAGS += -I$(top_srcdir)/crypto/arch/powerpc64/ | ||
| 394 | libcrypto_la_CPPFLAGS += -I$(top_srcdir)/crypto/bn/arch/powerpc64/ | 459 | libcrypto_la_CPPFLAGS += -I$(top_srcdir)/crypto/bn/arch/powerpc64/ |
| 395 | endif | 460 | endif |
| 461 | noinst_HEADERS += arch/powerpc64/crypto_arch.h | ||
| 396 | noinst_HEADERS += bn/arch/powerpc64/bn_arch.h | 462 | noinst_HEADERS += bn/arch/powerpc64/bn_arch.h |
| 397 | 463 | ||
| 398 | if HOST_RISCV64 | 464 | if HOST_RISCV64 |
| 465 | libcrypto_la_CPPFLAGS += -I$(top_srcdir)/crypto/arch/riscv64/ | ||
| 399 | libcrypto_la_CPPFLAGS += -I$(top_srcdir)/crypto/bn/arch/riscv64/ | 466 | libcrypto_la_CPPFLAGS += -I$(top_srcdir)/crypto/bn/arch/riscv64/ |
| 400 | endif | 467 | endif |
| 468 | noinst_HEADERS += arch/riscv64/crypto_arch.h | ||
| 401 | noinst_HEADERS += bn/arch/riscv64/bn_arch.h | 469 | noinst_HEADERS += bn/arch/riscv64/bn_arch.h |
| 402 | 470 | ||
| 403 | if HOST_SPARC64 | 471 | if HOST_SPARC64 |
| 472 | libcrypto_la_CPPFLAGS += -I$(top_srcdir)/crypto/arch/sparc64/ | ||
| 404 | libcrypto_la_CPPFLAGS += -I$(top_srcdir)/crypto/bn/arch/sparc64/ | 473 | libcrypto_la_CPPFLAGS += -I$(top_srcdir)/crypto/bn/arch/sparc64/ |
| 405 | endif | 474 | endif |
| 475 | noinst_HEADERS += arch/sparc64/crypto_arch.h | ||
| 406 | noinst_HEADERS += bn/arch/sparc64/bn_arch.h | 476 | noinst_HEADERS += bn/arch/sparc64/bn_arch.h |
| 407 | 477 | ||
| 408 | if HOST_X86_64 | 478 | if HOST_X86_64 |
| 479 | libcrypto_la_CPPFLAGS += -I$(top_srcdir)/crypto/arch/amd64/ | ||
| 409 | libcrypto_la_CPPFLAGS += -I$(top_srcdir)/crypto/bn/arch/amd64/ | 480 | libcrypto_la_CPPFLAGS += -I$(top_srcdir)/crypto/bn/arch/amd64/ |
| 410 | endif | 481 | endif |
| 482 | noinst_HEADERS += arch/amd64/crypto_arch.h | ||
| 411 | noinst_HEADERS += bn/arch/amd64/bn_arch.h | 483 | noinst_HEADERS += bn/arch/amd64/bn_arch.h |
| 412 | 484 | ||
| 413 | # buffer | 485 | # buffer |
| @@ -458,10 +530,10 @@ libcrypto_la_SOURCES += conf/conf_api.c | |||
| 458 | libcrypto_la_SOURCES += conf/conf_def.c | 530 | libcrypto_la_SOURCES += conf/conf_def.c |
| 459 | libcrypto_la_SOURCES += conf/conf_err.c | 531 | libcrypto_la_SOURCES += conf/conf_err.c |
| 460 | libcrypto_la_SOURCES += conf/conf_lib.c | 532 | libcrypto_la_SOURCES += conf/conf_lib.c |
| 461 | libcrypto_la_SOURCES += conf/conf_mall.c | ||
| 462 | libcrypto_la_SOURCES += conf/conf_mod.c | 533 | libcrypto_la_SOURCES += conf/conf_mod.c |
| 463 | libcrypto_la_SOURCES += conf/conf_sap.c | 534 | libcrypto_la_SOURCES += conf/conf_sap.c |
| 464 | noinst_HEADERS += conf/conf_def.h | 535 | noinst_HEADERS += conf/conf_def.h |
| 536 | noinst_HEADERS += conf/conf_local.h | ||
| 465 | 537 | ||
| 466 | # ct | 538 | # ct |
| 467 | libcrypto_la_SOURCES += ct/ct_b64.c | 539 | libcrypto_la_SOURCES += ct/ct_b64.c |
| @@ -483,29 +555,12 @@ noinst_HEADERS += curve25519/curve25519_internal.h | |||
| 483 | 555 | ||
| 484 | 556 | ||
| 485 | # des | 557 | # des |
| 486 | libcrypto_la_SOURCES += des/cbc_cksm.c | 558 | libcrypto_la_SOURCES += des/des.c |
| 487 | libcrypto_la_SOURCES += des/cbc_enc.c | 559 | libcrypto_la_SOURCES += des/des_cksum.c |
| 488 | libcrypto_la_SOURCES += des/cfb64ede.c | ||
| 489 | libcrypto_la_SOURCES += des/cfb64enc.c | ||
| 490 | libcrypto_la_SOURCES += des/cfb_enc.c | ||
| 491 | libcrypto_la_SOURCES += des/des_enc.c | 560 | libcrypto_la_SOURCES += des/des_enc.c |
| 492 | libcrypto_la_SOURCES += des/ecb3_enc.c | 561 | libcrypto_la_SOURCES += des/des_fcrypt.c |
| 493 | libcrypto_la_SOURCES += des/ecb_enc.c | 562 | libcrypto_la_SOURCES += des/des_key.c |
| 494 | libcrypto_la_SOURCES += des/ede_cbcm_enc.c | ||
| 495 | libcrypto_la_SOURCES += des/enc_read.c | ||
| 496 | libcrypto_la_SOURCES += des/fcrypt.c | ||
| 497 | libcrypto_la_SOURCES += des/fcrypt_b.c | ||
| 498 | EXTRA_libcrypto_la_SOURCES += des/ncbc_enc.c | ||
| 499 | libcrypto_la_SOURCES += des/ofb64ede.c | ||
| 500 | libcrypto_la_SOURCES += des/ofb64enc.c | ||
| 501 | libcrypto_la_SOURCES += des/ofb_enc.c | ||
| 502 | libcrypto_la_SOURCES += des/pcbc_enc.c | ||
| 503 | libcrypto_la_SOURCES += des/qud_cksm.c | ||
| 504 | libcrypto_la_SOURCES += des/set_key.c | ||
| 505 | libcrypto_la_SOURCES += des/str2key.c | ||
| 506 | libcrypto_la_SOURCES += des/xcbc_enc.c | ||
| 507 | noinst_HEADERS += des/des_local.h | 563 | noinst_HEADERS += des/des_local.h |
| 508 | noinst_HEADERS += des/spr.h | ||
| 509 | 564 | ||
| 510 | # dh | 565 | # dh |
| 511 | libcrypto_la_SOURCES += dh/dh_ameth.c | 566 | libcrypto_la_SOURCES += dh/dh_ameth.c |
| @@ -534,22 +589,19 @@ noinst_HEADERS += dsa/dsa_local.h | |||
| 534 | # ec | 589 | # ec |
| 535 | libcrypto_la_SOURCES += ec/ec_ameth.c | 590 | libcrypto_la_SOURCES += ec/ec_ameth.c |
| 536 | libcrypto_la_SOURCES += ec/ec_asn1.c | 591 | libcrypto_la_SOURCES += ec/ec_asn1.c |
| 537 | libcrypto_la_SOURCES += ec/ec_check.c | 592 | libcrypto_la_SOURCES += ec/ec_convert.c |
| 538 | libcrypto_la_SOURCES += ec/ec_curve.c | 593 | libcrypto_la_SOURCES += ec/ec_curve.c |
| 539 | libcrypto_la_SOURCES += ec/ec_cvt.c | ||
| 540 | libcrypto_la_SOURCES += ec/ec_err.c | 594 | libcrypto_la_SOURCES += ec/ec_err.c |
| 595 | libcrypto_la_SOURCES += ec/ec_field.c | ||
| 541 | libcrypto_la_SOURCES += ec/ec_key.c | 596 | libcrypto_la_SOURCES += ec/ec_key.c |
| 542 | libcrypto_la_SOURCES += ec/ec_kmeth.c | ||
| 543 | libcrypto_la_SOURCES += ec/ec_lib.c | 597 | libcrypto_la_SOURCES += ec/ec_lib.c |
| 544 | libcrypto_la_SOURCES += ec/ec_mult.c | 598 | libcrypto_la_SOURCES += ec/ec_mult.c |
| 545 | libcrypto_la_SOURCES += ec/ec_oct.c | ||
| 546 | libcrypto_la_SOURCES += ec/ec_pmeth.c | 599 | libcrypto_la_SOURCES += ec/ec_pmeth.c |
| 547 | libcrypto_la_SOURCES += ec/ec_print.c | ||
| 548 | libcrypto_la_SOURCES += ec/eck_prn.c | 600 | libcrypto_la_SOURCES += ec/eck_prn.c |
| 549 | libcrypto_la_SOURCES += ec/ecp_mont.c | 601 | libcrypto_la_SOURCES += ec/ecp_hp_methods.c |
| 550 | libcrypto_la_SOURCES += ec/ecp_oct.c | 602 | libcrypto_la_SOURCES += ec/ecp_methods.c |
| 551 | libcrypto_la_SOURCES += ec/ecp_smpl.c | ||
| 552 | libcrypto_la_SOURCES += ec/ecx_methods.c | 603 | libcrypto_la_SOURCES += ec/ecx_methods.c |
| 604 | noinst_HEADERS += ec/ec_internal.h | ||
| 553 | noinst_HEADERS += ec/ec_local.h | 605 | noinst_HEADERS += ec/ec_local.h |
| 554 | 606 | ||
| 555 | # ecdh | 607 | # ecdh |
| @@ -604,7 +656,6 @@ libcrypto_la_SOURCES += evp/m_sha1.c | |||
| 604 | libcrypto_la_SOURCES += evp/m_sha3.c | 656 | libcrypto_la_SOURCES += evp/m_sha3.c |
| 605 | libcrypto_la_SOURCES += evp/m_sigver.c | 657 | libcrypto_la_SOURCES += evp/m_sigver.c |
| 606 | libcrypto_la_SOURCES += evp/m_sm3.c | 658 | libcrypto_la_SOURCES += evp/m_sm3.c |
| 607 | libcrypto_la_SOURCES += evp/m_wp.c | ||
| 608 | libcrypto_la_SOURCES += evp/p_legacy.c | 659 | libcrypto_la_SOURCES += evp/p_legacy.c |
| 609 | libcrypto_la_SOURCES += evp/p_lib.c | 660 | libcrypto_la_SOURCES += evp/p_lib.c |
| 610 | libcrypto_la_SOURCES += evp/p_sign.c | 661 | libcrypto_la_SOURCES += evp/p_sign.c |
| @@ -629,7 +680,6 @@ noinst_HEADERS += hidden/openssl/chacha.h | |||
| 629 | noinst_HEADERS += hidden/openssl/cmac.h | 680 | noinst_HEADERS += hidden/openssl/cmac.h |
| 630 | noinst_HEADERS += hidden/openssl/cms.h | 681 | noinst_HEADERS += hidden/openssl/cms.h |
| 631 | noinst_HEADERS += hidden/openssl/conf.h | 682 | noinst_HEADERS += hidden/openssl/conf.h |
| 632 | noinst_HEADERS += hidden/openssl/conf_api.h | ||
| 633 | noinst_HEADERS += hidden/openssl/crypto.h | 683 | noinst_HEADERS += hidden/openssl/crypto.h |
| 634 | noinst_HEADERS += hidden/openssl/ct.h | 684 | noinst_HEADERS += hidden/openssl/ct.h |
| 635 | noinst_HEADERS += hidden/openssl/curve25519.h | 685 | noinst_HEADERS += hidden/openssl/curve25519.h |
| @@ -646,6 +696,7 @@ noinst_HEADERS += hidden/openssl/idea.h | |||
| 646 | noinst_HEADERS += hidden/openssl/lhash.h | 696 | noinst_HEADERS += hidden/openssl/lhash.h |
| 647 | noinst_HEADERS += hidden/openssl/md4.h | 697 | noinst_HEADERS += hidden/openssl/md4.h |
| 648 | noinst_HEADERS += hidden/openssl/md5.h | 698 | noinst_HEADERS += hidden/openssl/md5.h |
| 699 | noinst_HEADERS += hidden/openssl/mlkem.h | ||
| 649 | noinst_HEADERS += hidden/openssl/modes.h | 700 | noinst_HEADERS += hidden/openssl/modes.h |
| 650 | noinst_HEADERS += hidden/openssl/objects.h | 701 | noinst_HEADERS += hidden/openssl/objects.h |
| 651 | noinst_HEADERS += hidden/openssl/ocsp.h | 702 | noinst_HEADERS += hidden/openssl/ocsp.h |
| @@ -666,7 +717,6 @@ noinst_HEADERS += hidden/openssl/stack.h | |||
| 666 | noinst_HEADERS += hidden/openssl/ts.h | 717 | noinst_HEADERS += hidden/openssl/ts.h |
| 667 | noinst_HEADERS += hidden/openssl/txt_db.h | 718 | noinst_HEADERS += hidden/openssl/txt_db.h |
| 668 | noinst_HEADERS += hidden/openssl/ui.h | 719 | noinst_HEADERS += hidden/openssl/ui.h |
| 669 | noinst_HEADERS += hidden/openssl/whrlpool.h | ||
| 670 | noinst_HEADERS += hidden/openssl/x509.h | 720 | noinst_HEADERS += hidden/openssl/x509.h |
| 671 | noinst_HEADERS += hidden/openssl/x509_vfy.h | 721 | noinst_HEADERS += hidden/openssl/x509_vfy.h |
| 672 | noinst_HEADERS += hidden/openssl/x509v3.h | 722 | noinst_HEADERS += hidden/openssl/x509v3.h |
| @@ -698,6 +748,12 @@ libcrypto_la_SOURCES += md4/md4.c | |||
| 698 | # md5 | 748 | # md5 |
| 699 | libcrypto_la_SOURCES += md5/md5.c | 749 | libcrypto_la_SOURCES += md5/md5.c |
| 700 | 750 | ||
| 751 | # mlkem | ||
| 752 | libcrypto_la_SOURCES += mlkem/mlkem.c | ||
| 753 | libcrypto_la_SOURCES += mlkem/mlkem_internal.c | ||
| 754 | libcrypto_la_SOURCES += mlkem/mlkem_key.c | ||
| 755 | noinst_HEADERS += mlkem/mlkem_internal.h | ||
| 756 | |||
| 701 | # modes | 757 | # modes |
| 702 | libcrypto_la_SOURCES += modes/cbc128.c | 758 | libcrypto_la_SOURCES += modes/cbc128.c |
| 703 | libcrypto_la_SOURCES += modes/ccm128.c | 759 | libcrypto_la_SOURCES += modes/ccm128.c |
| @@ -777,11 +833,7 @@ libcrypto_la_SOURCES += rand/rand_lib.c | |||
| 777 | libcrypto_la_SOURCES += rand/randfile.c | 833 | libcrypto_la_SOURCES += rand/randfile.c |
| 778 | 834 | ||
| 779 | # rc2 | 835 | # rc2 |
| 780 | libcrypto_la_SOURCES += rc2/rc2_cbc.c | 836 | libcrypto_la_SOURCES += rc2/rc2.c |
| 781 | libcrypto_la_SOURCES += rc2/rc2_ecb.c | ||
| 782 | libcrypto_la_SOURCES += rc2/rc2_skey.c | ||
| 783 | libcrypto_la_SOURCES += rc2/rc2cfb64.c | ||
| 784 | libcrypto_la_SOURCES += rc2/rc2ofb64.c | ||
| 785 | noinst_HEADERS += rc2/rc2_local.h | 837 | noinst_HEADERS += rc2/rc2_local.h |
| 786 | 838 | ||
| 787 | # rc4 | 839 | # rc4 |
| @@ -856,12 +908,8 @@ endif | |||
| 856 | if HOST_WIN | 908 | if HOST_WIN |
| 857 | libcrypto_la_SOURCES += ui/ui_openssl_win.c | 909 | libcrypto_la_SOURCES += ui/ui_openssl_win.c |
| 858 | endif | 910 | endif |
| 859 | libcrypto_la_SOURCES += ui/ui_util.c | ||
| 860 | noinst_HEADERS += ui/ui_local.h | 911 | noinst_HEADERS += ui/ui_local.h |
| 861 | 912 | ||
| 862 | # whrlpool | ||
| 863 | libcrypto_la_SOURCES += whrlpool/whirlpool.c | ||
| 864 | |||
| 865 | # x509 | 913 | # x509 |
| 866 | libcrypto_la_SOURCES += x509/by_dir.c | 914 | libcrypto_la_SOURCES += x509/by_dir.c |
| 867 | libcrypto_la_SOURCES += x509/by_file.c | 915 | libcrypto_la_SOURCES += x509/by_file.c |
| @@ -903,6 +951,7 @@ libcrypto_la_SOURCES += x509/x509_purp.c | |||
| 903 | libcrypto_la_SOURCES += x509/x509_r2x.c | 951 | libcrypto_la_SOURCES += x509/x509_r2x.c |
| 904 | libcrypto_la_SOURCES += x509/x509_req.c | 952 | libcrypto_la_SOURCES += x509/x509_req.c |
| 905 | libcrypto_la_SOURCES += x509/x509_set.c | 953 | libcrypto_la_SOURCES += x509/x509_set.c |
| 954 | libcrypto_la_SOURCES += x509/x509_siginfo.c | ||
| 906 | libcrypto_la_SOURCES += x509/x509_skey.c | 955 | libcrypto_la_SOURCES += x509/x509_skey.c |
| 907 | libcrypto_la_SOURCES += x509/x509_trs.c | 956 | libcrypto_la_SOURCES += x509/x509_trs.c |
| 908 | libcrypto_la_SOURCES += x509/x509_txt.c | 957 | libcrypto_la_SOURCES += x509/x509_txt.c |
diff --git a/crypto/Makefile.am.elf-aarch64 b/crypto/Makefile.am.elf-aarch64 new file mode 100644 index 0000000..650e6c6 --- /dev/null +++ b/crypto/Makefile.am.elf-aarch64 | |||
| @@ -0,0 +1,15 @@ | |||
| 1 | ASM_AARCH64_ELF = sha/sha1_aarch64_ce.S | ||
| 2 | ASM_AARCH64_ELF += sha/sha256_aarch64_ce.S | ||
| 3 | ASM_AARCH64_ELF += sha/sha512_aarch64_ce.S | ||
| 4 | |||
| 5 | EXTRA_DIST += $(ASM_AARCH64_ELF) | ||
| 6 | |||
| 7 | if HOST_ASM_ELF_AARCH64 | ||
| 8 | libcrypto_la_SOURCES += sha/sha1_aarch64.c | ||
| 9 | libcrypto_la_SOURCES += sha/sha256_aarch64.c | ||
| 10 | libcrypto_la_SOURCES += sha/sha512_aarch64.c | ||
| 11 | |||
| 12 | libcrypto_la_CPPFLAGS += -DLIBRESSL_USE_SHA_ASSEMBLY | ||
| 13 | |||
| 14 | libcrypto_la_SOURCES += $(ASM_AARCH64_ELF) | ||
| 15 | endif | ||
diff --git a/crypto/Makefile.am.elf-arm b/crypto/Makefile.am.elf-arm deleted file mode 100644 index 4f88994..0000000 --- a/crypto/Makefile.am.elf-arm +++ /dev/null | |||
| @@ -1,21 +0,0 @@ | |||
| 1 | ASM_ARM_ELF = aes/aes-elf-armv4.S | ||
| 2 | ASM_ARM_ELF += bn/mont-elf-armv4.S | ||
| 3 | ASM_ARM_ELF += sha/sha1-elf-armv4.S | ||
| 4 | ASM_ARM_ELF += sha/sha512-elf-armv4.S | ||
| 5 | ASM_ARM_ELF += sha/sha256-elf-armv4.S | ||
| 6 | ASM_ARM_ELF += modes/ghash-elf-armv4.S | ||
| 7 | ASM_ARM_ELF += armv4cpuid.S | ||
| 8 | ASM_ARM_ELF += armcap.c | ||
| 9 | |||
| 10 | EXTRA_DIST += $(ASM_ARM_ELF) | ||
| 11 | |||
| 12 | if HOST_ASM_ELF_ARM | ||
| 13 | libcrypto_la_CPPFLAGS += -DAES_ASM | ||
| 14 | libcrypto_la_CPPFLAGS += -DOPENSSL_BN_ASM_MONT | ||
| 15 | libcrypto_la_CPPFLAGS += -DGHASH_ASM | ||
| 16 | libcrypto_la_CPPFLAGS += -DSHA1_ASM | ||
| 17 | libcrypto_la_CPPFLAGS += -DSHA256_ASM | ||
| 18 | libcrypto_la_CPPFLAGS += -DSHA512_ASM | ||
| 19 | libcrypto_la_CPPFLAGS += -DOPENSSL_CPUID_OBJ | ||
| 20 | libcrypto_la_SOURCES += $(ASM_ARM_ELF) | ||
| 21 | endif | ||
diff --git a/crypto/Makefile.am.elf-mips b/crypto/Makefile.am.elf-mips index ea0a730..2276991 100644 --- a/crypto/Makefile.am.elf-mips +++ b/crypto/Makefile.am.elf-mips | |||
| @@ -8,10 +8,11 @@ ASM_MIPS_ELF += sha/sha256-mips.S | |||
| 8 | EXTRA_DIST += $(ASM_MIPS_ELF) | 8 | EXTRA_DIST += $(ASM_MIPS_ELF) |
| 9 | 9 | ||
| 10 | if HOST_ASM_ELF_MIPS | 10 | if HOST_ASM_ELF_MIPS |
| 11 | libcrypto_la_CPPFLAGS += -DAES_ASM | 11 | libcrypto_la_CPPFLAGS += -DLIBRESSL_USE_AES_ASSEMBLY |
| 12 | libcrypto_la_CPPFLAGS += -DLIBRESSL_USE_BN_ASSEMBLY | ||
| 13 | libcrypto_la_CPPFLAGS += -DLIBRESSL_USE_SHA_ASSEMBLY | ||
| 14 | |||
| 12 | libcrypto_la_CPPFLAGS += -DOPENSSL_BN_ASM_MONT | 15 | libcrypto_la_CPPFLAGS += -DOPENSSL_BN_ASM_MONT |
| 13 | libcrypto_la_CPPFLAGS += -DSHA1_ASM | 16 | |
| 14 | libcrypto_la_CPPFLAGS += -DSHA256_ASM | ||
| 15 | libcrypto_la_CPPFLAGS += -DSHA512_ASM | ||
| 16 | libcrypto_la_SOURCES += $(ASM_MIPS_ELF) | 17 | libcrypto_la_SOURCES += $(ASM_MIPS_ELF) |
| 17 | endif | 18 | endif |
diff --git a/crypto/Makefile.am.elf-mips64 b/crypto/Makefile.am.elf-mips64 index 8f851f3..c6727b3 100644 --- a/crypto/Makefile.am.elf-mips64 +++ b/crypto/Makefile.am.elf-mips64 | |||
| @@ -8,10 +8,11 @@ ASM_MIPS64_ELF += sha/sha256-mips.S | |||
| 8 | EXTRA_DIST += $(ASM_MIPS64_ELF) | 8 | EXTRA_DIST += $(ASM_MIPS64_ELF) |
| 9 | 9 | ||
| 10 | if HOST_ASM_ELF_MIPS64 | 10 | if HOST_ASM_ELF_MIPS64 |
| 11 | libcrypto_la_CPPFLAGS += -DAES_ASM | 11 | libcrypto_la_CPPFLAGS += -DLIBRESSL_USE_AES_ASSEMBLY |
| 12 | libcrypto_la_CPPFLAGS += -DLIBRESSL_USE_BN_ASSEMBLY | ||
| 13 | libcrypto_la_CPPFLAGS += -DLIBRESSL_USE_SHA_ASSEMBLY | ||
| 14 | |||
| 12 | libcrypto_la_CPPFLAGS += -DOPENSSL_BN_ASM_MONT | 15 | libcrypto_la_CPPFLAGS += -DOPENSSL_BN_ASM_MONT |
| 13 | libcrypto_la_CPPFLAGS += -DSHA1_ASM | 16 | |
| 14 | libcrypto_la_CPPFLAGS += -DSHA256_ASM | ||
| 15 | libcrypto_la_CPPFLAGS += -DSHA512_ASM | ||
| 16 | libcrypto_la_SOURCES += $(ASM_MIPS64_ELF) | 17 | libcrypto_la_SOURCES += $(ASM_MIPS64_ELF) |
| 17 | endif | 18 | endif |
diff --git a/crypto/Makefile.am.elf-x86_64 b/crypto/Makefile.am.elf-x86_64 index 6933a11..450e96a 100644 --- a/crypto/Makefile.am.elf-x86_64 +++ b/crypto/Makefile.am.elf-x86_64 | |||
| @@ -1,53 +1,58 @@ | |||
| 1 | 1 | ||
| 2 | ASM_X86_64_ELF = aes/aes-elf-x86_64.S | 2 | ASM_X86_64_ELF = aes/aes-elf-x86_64.S |
| 3 | ASM_X86_64_ELF += aes/bsaes-elf-x86_64.S | ||
| 4 | ASM_X86_64_ELF += aes/vpaes-elf-x86_64.S | ||
| 5 | ASM_X86_64_ELF += aes/aesni-elf-x86_64.S | 3 | ASM_X86_64_ELF += aes/aesni-elf-x86_64.S |
| 6 | ASM_X86_64_ELF += bn/modexp512-elf-x86_64.S | 4 | ASM_X86_64_ELF += bn/modexp512-elf-x86_64.S |
| 7 | ASM_X86_64_ELF += bn/mont-elf-x86_64.S | 5 | ASM_X86_64_ELF += bn/mont-elf-x86_64.S |
| 8 | ASM_X86_64_ELF += bn/mont5-elf-x86_64.S | 6 | ASM_X86_64_ELF += bn/mont5-elf-x86_64.S |
| 9 | ASM_X86_64_ELF += md5/md5-elf-x86_64.S | ||
| 10 | ASM_X86_64_ELF += modes/ghash-elf-x86_64.S | 7 | ASM_X86_64_ELF += modes/ghash-elf-x86_64.S |
| 11 | ASM_X86_64_ELF += rc4/rc4-elf-x86_64.S | 8 | ASM_X86_64_ELF += rc4/rc4-elf-x86_64.S |
| 12 | ASM_X86_64_ELF += sha/sha1-elf-x86_64.S | ||
| 13 | ASM_X86_64_ELF += sha/sha256-elf-x86_64.S | ||
| 14 | ASM_X86_64_ELF += sha/sha512-elf-x86_64.S | ||
| 15 | ASM_X86_64_ELF += cpuid-elf-x86_64.S | ||
| 16 | 9 | ||
| 17 | ASM_X86_64_ELF += bn/arch/amd64/bignum_add.S | 10 | ASM_X86_64_ELF += bn/arch/amd64/bignum_add.S |
| 18 | ASM_X86_64_ELF += bn/arch/amd64/bignum_cmadd.S | 11 | ASM_X86_64_ELF += bn/arch/amd64/bignum_cmadd.S |
| 19 | ASM_X86_64_ELF += bn/arch/amd64/bignum_cmul.S | 12 | ASM_X86_64_ELF += bn/arch/amd64/bignum_cmul.S |
| 13 | ASM_X86_64_ELF += bn/arch/amd64/bignum_modadd.S | ||
| 14 | ASM_X86_64_ELF += bn/arch/amd64/bignum_modsub.S | ||
| 20 | ASM_X86_64_ELF += bn/arch/amd64/bignum_mul.S | 15 | ASM_X86_64_ELF += bn/arch/amd64/bignum_mul.S |
| 16 | ASM_X86_64_ELF += bn/arch/amd64/bignum_mul_4_8.S | ||
| 21 | ASM_X86_64_ELF += bn/arch/amd64/bignum_mul_4_8_alt.S | 17 | ASM_X86_64_ELF += bn/arch/amd64/bignum_mul_4_8_alt.S |
| 18 | ASM_X86_64_ELF += bn/arch/amd64/bignum_mul_6_12.S | ||
| 19 | ASM_X86_64_ELF += bn/arch/amd64/bignum_mul_6_12_alt.S | ||
| 20 | ASM_X86_64_ELF += bn/arch/amd64/bignum_mul_8_16.S | ||
| 22 | ASM_X86_64_ELF += bn/arch/amd64/bignum_mul_8_16_alt.S | 21 | ASM_X86_64_ELF += bn/arch/amd64/bignum_mul_8_16_alt.S |
| 23 | ASM_X86_64_ELF += bn/arch/amd64/bignum_sqr.S | 22 | ASM_X86_64_ELF += bn/arch/amd64/bignum_sqr.S |
| 23 | ASM_X86_64_ELF += bn/arch/amd64/bignum_sqr_4_8.S | ||
| 24 | ASM_X86_64_ELF += bn/arch/amd64/bignum_sqr_4_8_alt.S | 24 | ASM_X86_64_ELF += bn/arch/amd64/bignum_sqr_4_8_alt.S |
| 25 | ASM_X86_64_ELF += bn/arch/amd64/bignum_sqr_6_12.S | ||
| 26 | ASM_X86_64_ELF += bn/arch/amd64/bignum_sqr_6_12_alt.S | ||
| 27 | ASM_X86_64_ELF += bn/arch/amd64/bignum_sqr_8_16.S | ||
| 25 | ASM_X86_64_ELF += bn/arch/amd64/bignum_sqr_8_16_alt.S | 28 | ASM_X86_64_ELF += bn/arch/amd64/bignum_sqr_8_16_alt.S |
| 26 | ASM_X86_64_ELF += bn/arch/amd64/bignum_sub.S | 29 | ASM_X86_64_ELF += bn/arch/amd64/bignum_sub.S |
| 27 | ASM_X86_64_ELF += bn/arch/amd64/word_clz.S | 30 | ASM_X86_64_ELF += bn/arch/amd64/word_clz.S |
| 28 | ASM_X86_64_ELF += bn/arch/amd64/bn_arch.c | 31 | |
| 32 | ASM_X86_64_ELF += sha/sha1_amd64_generic.S | ||
| 33 | ASM_X86_64_ELF += sha/sha1_amd64_shani.S | ||
| 34 | ASM_X86_64_ELF += sha/sha256_amd64_generic.S | ||
| 35 | ASM_X86_64_ELF += sha/sha256_amd64_shani.S | ||
| 36 | ASM_X86_64_ELF += sha/sha512_amd64_generic.S | ||
| 29 | 37 | ||
| 30 | EXTRA_DIST += $(ASM_X86_64_ELF) | 38 | EXTRA_DIST += $(ASM_X86_64_ELF) |
| 31 | 39 | ||
| 32 | if HOST_ASM_ELF_X86_64 | 40 | if HOST_ASM_ELF_X86_64 |
| 33 | libcrypto_la_CPPFLAGS += -DAES_ASM | 41 | libcrypto_la_SOURCES += aes/aes_amd64.c |
| 34 | libcrypto_la_CPPFLAGS += -DBSAES_ASM | 42 | libcrypto_la_SOURCES += bn/arch/amd64/bn_arch.c |
| 35 | libcrypto_la_CPPFLAGS += -DVPAES_ASM | 43 | libcrypto_la_SOURCES += modes/gcm128_amd64.c |
| 36 | libcrypto_la_CPPFLAGS += -DHAVE_AES_CBC_ENCRYPT_INTERNAL | 44 | libcrypto_la_SOURCES += sha/sha1_amd64.c |
| 37 | libcrypto_la_CPPFLAGS += -DHAVE_AES_SET_ENCRYPT_KEY_INTERNAL | 45 | libcrypto_la_SOURCES += sha/sha256_amd64.c |
| 38 | libcrypto_la_CPPFLAGS += -DHAVE_AES_SET_DECRYPT_KEY_INTERNAL | 46 | libcrypto_la_SOURCES += sha/sha512_amd64.c |
| 39 | libcrypto_la_CPPFLAGS += -DHAVE_AES_ENCRYPT_INTERNAL | 47 | |
| 40 | libcrypto_la_CPPFLAGS += -DHAVE_AES_DECRYPT_INTERNAL | 48 | libcrypto_la_CPPFLAGS += -DLIBRESSL_USE_AES_ASSEMBLY |
| 41 | libcrypto_la_CPPFLAGS += -DOPENSSL_IA32_SSE2 | 49 | libcrypto_la_CPPFLAGS += -DLIBRESSL_USE_BN_ASSEMBLY |
| 50 | libcrypto_la_CPPFLAGS += -DLIBRESSL_USE_GCM_ASSEMBLY | ||
| 51 | libcrypto_la_CPPFLAGS += -DLIBRESSL_USE_RC4_ASSEMBLY | ||
| 52 | libcrypto_la_CPPFLAGS += -DLIBRESSL_USE_SHA_ASSEMBLY | ||
| 53 | |||
| 42 | libcrypto_la_CPPFLAGS += -DOPENSSL_BN_ASM_MONT | 54 | libcrypto_la_CPPFLAGS += -DOPENSSL_BN_ASM_MONT |
| 43 | libcrypto_la_CPPFLAGS += -DOPENSSL_BN_ASM_MONT5 | 55 | libcrypto_la_CPPFLAGS += -DOPENSSL_BN_ASM_MONT5 |
| 44 | libcrypto_la_CPPFLAGS += -DMD5_ASM | 56 | |
| 45 | libcrypto_la_CPPFLAGS += -DGHASH_ASM | ||
| 46 | libcrypto_la_CPPFLAGS += -DRSA_ASM | ||
| 47 | libcrypto_la_CPPFLAGS += -DSHA1_ASM | ||
| 48 | libcrypto_la_CPPFLAGS += -DSHA256_ASM | ||
| 49 | libcrypto_la_CPPFLAGS += -DSHA512_ASM | ||
| 50 | libcrypto_la_CPPFLAGS += -DWHIRLPOOL_ASM | ||
| 51 | libcrypto_la_CPPFLAGS += -DOPENSSL_CPUID_OBJ | ||
| 52 | libcrypto_la_SOURCES += $(ASM_X86_64_ELF) | 57 | libcrypto_la_SOURCES += $(ASM_X86_64_ELF) |
| 53 | endif | 58 | endif |
diff --git a/crypto/Makefile.am.macosx-x86_64 b/crypto/Makefile.am.macosx-x86_64 index 1020567..7a26649 100644 --- a/crypto/Makefile.am.macosx-x86_64 +++ b/crypto/Makefile.am.macosx-x86_64 | |||
| @@ -1,53 +1,48 @@ | |||
| 1 | 1 | ||
| 2 | ASM_X86_64_MACOSX = aes/aes-macosx-x86_64.S | 2 | ASM_X86_64_MACOSX = aes/aes-macosx-x86_64.S |
| 3 | ASM_X86_64_MACOSX += aes/bsaes-macosx-x86_64.S | ||
| 4 | ASM_X86_64_MACOSX += aes/vpaes-macosx-x86_64.S | ||
| 5 | ASM_X86_64_MACOSX += aes/aesni-macosx-x86_64.S | 3 | ASM_X86_64_MACOSX += aes/aesni-macosx-x86_64.S |
| 6 | ASM_X86_64_MACOSX += bn/modexp512-macosx-x86_64.S | 4 | ASM_X86_64_MACOSX += bn/modexp512-macosx-x86_64.S |
| 7 | ASM_X86_64_MACOSX += bn/mont-macosx-x86_64.S | 5 | ASM_X86_64_MACOSX += bn/mont-macosx-x86_64.S |
| 8 | ASM_X86_64_MACOSX += bn/mont5-macosx-x86_64.S | 6 | ASM_X86_64_MACOSX += bn/mont5-macosx-x86_64.S |
| 9 | ASM_X86_64_MACOSX += md5/md5-macosx-x86_64.S | ||
| 10 | ASM_X86_64_MACOSX += modes/ghash-macosx-x86_64.S | 7 | ASM_X86_64_MACOSX += modes/ghash-macosx-x86_64.S |
| 11 | ASM_X86_64_MACOSX += rc4/rc4-macosx-x86_64.S | 8 | ASM_X86_64_MACOSX += rc4/rc4-macosx-x86_64.S |
| 12 | ASM_X86_64_MACOSX += sha/sha1-macosx-x86_64.S | ||
| 13 | ASM_X86_64_MACOSX += sha/sha256-macosx-x86_64.S | ||
| 14 | ASM_X86_64_MACOSX += sha/sha512-macosx-x86_64.S | ||
| 15 | ASM_X86_64_MACOSX += cpuid-macosx-x86_64.S | ||
| 16 | 9 | ||
| 17 | ASM_X86_64_MACOSX += bn/arch/amd64/bignum_add.S | 10 | ASM_X86_64_MACOSX += bn/arch/amd64/bignum_add.S |
| 18 | ASM_X86_64_MACOSX += bn/arch/amd64/bignum_cmadd.S | 11 | ASM_X86_64_MACOSX += bn/arch/amd64/bignum_cmadd.S |
| 19 | ASM_X86_64_MACOSX += bn/arch/amd64/bignum_cmul.S | 12 | ASM_X86_64_MACOSX += bn/arch/amd64/bignum_cmul.S |
| 13 | ASM_X86_64_MACOSX += bn/arch/amd64/bignum_modadd.S | ||
| 14 | ASM_X86_64_MACOSX += bn/arch/amd64/bignum_modsub.S | ||
| 20 | ASM_X86_64_MACOSX += bn/arch/amd64/bignum_mul.S | 15 | ASM_X86_64_MACOSX += bn/arch/amd64/bignum_mul.S |
| 16 | ASM_X86_64_MACOSX += bn/arch/amd64/bignum_mul_4_8.S | ||
| 21 | ASM_X86_64_MACOSX += bn/arch/amd64/bignum_mul_4_8_alt.S | 17 | ASM_X86_64_MACOSX += bn/arch/amd64/bignum_mul_4_8_alt.S |
| 18 | ASM_X86_64_MACOSX += bn/arch/amd64/bignum_mul_6_12.S | ||
| 19 | ASM_X86_64_MACOSX += bn/arch/amd64/bignum_mul_6_12_alt.S | ||
| 20 | ASM_X86_64_MACOSX += bn/arch/amd64/bignum_mul_8_16.S | ||
| 22 | ASM_X86_64_MACOSX += bn/arch/amd64/bignum_mul_8_16_alt.S | 21 | ASM_X86_64_MACOSX += bn/arch/amd64/bignum_mul_8_16_alt.S |
| 23 | ASM_X86_64_MACOSX += bn/arch/amd64/bignum_sqr.S | 22 | ASM_X86_64_MACOSX += bn/arch/amd64/bignum_sqr.S |
| 23 | ASM_X86_64_MACOSX += bn/arch/amd64/bignum_sqr_4_8.S | ||
| 24 | ASM_X86_64_MACOSX += bn/arch/amd64/bignum_sqr_4_8_alt.S | 24 | ASM_X86_64_MACOSX += bn/arch/amd64/bignum_sqr_4_8_alt.S |
| 25 | ASM_X86_64_MACOSX += bn/arch/amd64/bignum_sqr_6_12.S | ||
| 26 | ASM_X86_64_MACOSX += bn/arch/amd64/bignum_sqr_6_12_alt.S | ||
| 27 | ASM_X86_64_MACOSX += bn/arch/amd64/bignum_sqr_8_16.S | ||
| 25 | ASM_X86_64_MACOSX += bn/arch/amd64/bignum_sqr_8_16_alt.S | 28 | ASM_X86_64_MACOSX += bn/arch/amd64/bignum_sqr_8_16_alt.S |
| 26 | ASM_X86_64_MACOSX += bn/arch/amd64/bignum_sub.S | 29 | ASM_X86_64_MACOSX += bn/arch/amd64/bignum_sub.S |
| 27 | ASM_X86_64_MACOSX += bn/arch/amd64/word_clz.S | 30 | ASM_X86_64_MACOSX += bn/arch/amd64/word_clz.S |
| 28 | ASM_X86_64_MACOSX += bn/arch/amd64/bn_arch.c | ||
| 29 | 31 | ||
| 30 | EXTRA_DIST += $(ASM_X86_64_MACOSX) | 32 | EXTRA_DIST += $(ASM_X86_64_MACOSX) |
| 31 | 33 | ||
| 32 | if HOST_ASM_MACOSX_X86_64 | 34 | if HOST_ASM_MACOSX_X86_64 |
| 33 | libcrypto_la_CPPFLAGS += -DAES_ASM | 35 | libcrypto_la_SOURCES += aes/aes_amd64.c |
| 34 | libcrypto_la_CPPFLAGS += -DBSAES_ASM | 36 | libcrypto_la_SOURCES += bn/arch/amd64/bn_arch.c |
| 35 | libcrypto_la_CPPFLAGS += -DVPAES_ASM | 37 | libcrypto_la_SOURCES += modes/gcm128_amd64.c |
| 36 | libcrypto_la_CPPFLAGS += -DHAVE_AES_CBC_ENCRYPT_INTERNAL | 38 | |
| 37 | libcrypto_la_CPPFLAGS += -DHAVE_AES_SET_ENCRYPT_KEY_INTERNAL | 39 | libcrypto_la_CPPFLAGS += -DLIBRESSL_USE_AES_ASSEMBLY |
| 38 | libcrypto_la_CPPFLAGS += -DHAVE_AES_SET_DECRYPT_KEY_INTERNAL | 40 | libcrypto_la_CPPFLAGS += -DLIBRESSL_USE_BN_ASSEMBLY |
| 39 | libcrypto_la_CPPFLAGS += -DHAVE_AES_ENCRYPT_INTERNAL | 41 | libcrypto_la_CPPFLAGS += -DLIBRESSL_USE_GCM_ASSEMBLY |
| 40 | libcrypto_la_CPPFLAGS += -DHAVE_AES_DECRYPT_INTERNAL | 42 | libcrypto_la_CPPFLAGS += -DLIBRESSL_USE_RC4_ASSEMBLY |
| 41 | libcrypto_la_CPPFLAGS += -DOPENSSL_IA32_SSE2 | 43 | |
| 42 | libcrypto_la_CPPFLAGS += -DOPENSSL_BN_ASM_MONT | 44 | libcrypto_la_CPPFLAGS += -DOPENSSL_BN_ASM_MONT |
| 43 | libcrypto_la_CPPFLAGS += -DOPENSSL_BN_ASM_MONT5 | 45 | libcrypto_la_CPPFLAGS += -DOPENSSL_BN_ASM_MONT5 |
| 44 | libcrypto_la_CPPFLAGS += -DMD5_ASM | 46 | |
| 45 | libcrypto_la_CPPFLAGS += -DGHASH_ASM | ||
| 46 | libcrypto_la_CPPFLAGS += -DRSA_ASM | ||
| 47 | libcrypto_la_CPPFLAGS += -DSHA1_ASM | ||
| 48 | libcrypto_la_CPPFLAGS += -DSHA256_ASM | ||
| 49 | libcrypto_la_CPPFLAGS += -DSHA512_ASM | ||
| 50 | libcrypto_la_CPPFLAGS += -DWHIRLPOOL_ASM | ||
| 51 | libcrypto_la_CPPFLAGS += -DOPENSSL_CPUID_OBJ | ||
| 52 | libcrypto_la_SOURCES += $(ASM_X86_64_MACOSX) | 47 | libcrypto_la_SOURCES += $(ASM_X86_64_MACOSX) |
| 53 | endif | 48 | endif |
diff --git a/crypto/Makefile.am.masm-x86_64 b/crypto/Makefile.am.masm-x86_64 index 7da3cc2..249f86b 100644 --- a/crypto/Makefile.am.masm-x86_64 +++ b/crypto/Makefile.am.masm-x86_64 | |||
| @@ -1,40 +1,25 @@ | |||
| 1 | 1 | ||
| 2 | ASM_X86_64_MASM = aes/aes-masm-x86_64.S | 2 | ASM_X86_64_MASM = aes/aes-masm-x86_64.S |
| 3 | ASM_X86_64_MASM += aes/bsaes-masm-x86_64.S | ||
| 4 | ASM_X86_64_MASM += aes/vpaes-masm-x86_64.S | ||
| 5 | ASM_X86_64_MASM += aes/aesni-masm-x86_64.S | 3 | ASM_X86_64_MASM += aes/aesni-masm-x86_64.S |
| 6 | ASM_X86_64_MASM += bn/modexp512-masm-x86_64.S | 4 | ASM_X86_64_MASM += bn/modexp512-masm-x86_64.S |
| 7 | ASM_X86_64_MASM += bn/mont-masm-x86_64.S | 5 | ASM_X86_64_MASM += bn/mont-masm-x86_64.S |
| 8 | ASM_X86_64_MASM += bn/mont5-masm-x86_64.S | 6 | ASM_X86_64_MASM += bn/mont5-masm-x86_64.S |
| 9 | ASM_X86_64_MASM += md5/md5-masm-x86_64.S | ||
| 10 | ASM_X86_64_MASM += modes/ghash-masm-x86_64.S | 7 | ASM_X86_64_MASM += modes/ghash-masm-x86_64.S |
| 11 | ASM_X86_64_MASM += rc4/rc4-masm-x86_64.S | 8 | ASM_X86_64_MASM += rc4/rc4-masm-x86_64.S |
| 12 | ASM_X86_64_MASM += sha/sha1-masm-x86_64.S | ||
| 13 | ASM_X86_64_MASM += sha/sha256-masm-x86_64.S | ||
| 14 | ASM_X86_64_MASM += sha/sha512-masm-x86_64.S | ||
| 15 | ASM_X86_64_MASM += cpuid-masm-x86_64.S | ||
| 16 | 9 | ||
| 17 | EXTRA_DIST += $(ASM_X86_64_MASM) | 10 | EXTRA_DIST += $(ASM_X86_64_MASM) |
| 18 | 11 | ||
| 19 | if HOST_ASM_MASM_X86_64 | 12 | if HOST_ASM_MASM_X86_64 |
| 20 | libcrypto_la_CPPFLAGS += -DAES_ASM | 13 | libcrypto_la_SOURCES += aes/aes_amd64.c |
| 21 | libcrypto_la_CPPFLAGS += -DBSAES_ASM | 14 | libcrypto_la_SOURCES += modes/gcm128_amd64.c |
| 22 | libcrypto_la_CPPFLAGS += -DVPAES_ASM | 15 | |
| 23 | libcrypto_la_CPPFLAGS += -DHAVE_AES_CBC_ENCRYPT_INTERNAL | 16 | libcrypto_la_CPPFLAGS += -DLIBRESSL_USE_AES_ASSEMBLY |
| 24 | libcrypto_la_CPPFLAGS += -DHAVE_AES_SET_ENCRYPT_KEY_INTERNAL | 17 | libcrypto_la_CPPFLAGS += -DLIBRESSL_USE_BN_ASSEMBLY |
| 25 | libcrypto_la_CPPFLAGS += -DHAVE_AES_SET_DECRYPT_KEY_INTERNAL | 18 | libcrypto_la_CPPFLAGS += -DLIBRESSL_USE_GCM_ASSEMBLY |
| 26 | libcrypto_la_CPPFLAGS += -DHAVE_AES_ENCRYPT_INTERNAL | 19 | libcrypto_la_CPPFLAGS += -DLIBRESSL_USE_RC4_ASSEMBLY |
| 27 | libcrypto_la_CPPFLAGS += -DHAVE_AES_DECRYPT_INTERNAL | 20 | |
| 28 | libcrypto_la_CPPFLAGS += -DOPENSSL_IA32_SSE2 | ||
| 29 | libcrypto_la_CPPFLAGS += -DOPENSSL_BN_ASM_MONT | 21 | libcrypto_la_CPPFLAGS += -DOPENSSL_BN_ASM_MONT |
| 30 | libcrypto_la_CPPFLAGS += -DOPENSSL_BN_ASM_MONT5 | 22 | libcrypto_la_CPPFLAGS += -DOPENSSL_BN_ASM_MONT5 |
| 31 | libcrypto_la_CPPFLAGS += -DMD5_ASM | 23 | |
| 32 | libcrypto_la_CPPFLAGS += -DGHASH_ASM | ||
| 33 | libcrypto_la_CPPFLAGS += -DRSA_ASM | ||
| 34 | libcrypto_la_CPPFLAGS += -DSHA1_ASM | ||
| 35 | libcrypto_la_CPPFLAGS += -DSHA256_ASM | ||
| 36 | libcrypto_la_CPPFLAGS += -DSHA512_ASM | ||
| 37 | libcrypto_la_CPPFLAGS += -DWHIRLPOOL_ASM | ||
| 38 | libcrypto_la_CPPFLAGS += -DOPENSSL_CPUID_OBJ | ||
| 39 | libcrypto_la_SOURCES += $(ASM_X86_64_MASM) | 24 | libcrypto_la_SOURCES += $(ASM_X86_64_MASM) |
| 40 | endif | 25 | endif |
diff --git a/crypto/Makefile.am.mingw64-x86_64 b/crypto/Makefile.am.mingw64-x86_64 index 7d0d3f7..e725a05 100644 --- a/crypto/Makefile.am.mingw64-x86_64 +++ b/crypto/Makefile.am.mingw64-x86_64 | |||
| @@ -1,41 +1,27 @@ | |||
| 1 | 1 | ||
| 2 | ASM_X86_64_MINGW64 = aes/aes-mingw64-x86_64.S | 2 | ASM_X86_64_MINGW64 = aes/aes-mingw64-x86_64.S |
| 3 | ASM_X86_64_MINGW64 += aes/bsaes-mingw64-x86_64.S | ||
| 4 | ASM_X86_64_MINGW64 += aes/vpaes-mingw64-x86_64.S | ||
| 5 | ASM_X86_64_MINGW64 += aes/aesni-mingw64-x86_64.S | 3 | ASM_X86_64_MINGW64 += aes/aesni-mingw64-x86_64.S |
| 6 | #ASM_X86_64_MINGW64 += bn/modexp512-mingw64-x86_64.S | 4 | #ASM_X86_64_MINGW64 += bn/modexp512-mingw64-x86_64.S |
| 7 | #ASM_X86_64_MINGW64 += bn/mont-mingw64-x86_64.S | 5 | #ASM_X86_64_MINGW64 += bn/mont-mingw64-x86_64.S |
| 8 | #ASM_X86_64_MINGW64 += bn/mont5-mingw64-x86_64.S | 6 | #ASM_X86_64_MINGW64 += bn/mont5-mingw64-x86_64.S |
| 9 | ASM_X86_64_MINGW64 += md5/md5-mingw64-x86_64.S | ||
| 10 | ASM_X86_64_MINGW64 += modes/ghash-mingw64-x86_64.S | 7 | ASM_X86_64_MINGW64 += modes/ghash-mingw64-x86_64.S |
| 11 | ASM_X86_64_MINGW64 += rc4/rc4-mingw64-x86_64.S | 8 | ASM_X86_64_MINGW64 += rc4/rc4-mingw64-x86_64.S |
| 12 | ASM_X86_64_MINGW64 += sha/sha1-mingw64-x86_64.S | ||
| 13 | ASM_X86_64_MINGW64 += sha/sha256-mingw64-x86_64.S | ||
| 14 | ASM_X86_64_MINGW64 += sha/sha512-mingw64-x86_64.S | ||
| 15 | ASM_X86_64_MINGW64 += cpuid-mingw64-x86_64.S | ||
| 16 | 9 | ||
| 17 | EXTRA_DIST += $(ASM_X86_64_MINGW64) | 10 | EXTRA_DIST += $(ASM_X86_64_MINGW64) |
| 18 | 11 | ||
| 19 | if HOST_ASM_MINGW64_X86_64 | 12 | if HOST_ASM_MINGW64_X86_64 |
| 13 | libcrypto_la_SOURCES += aes/aes_amd64.c | ||
| 14 | libcrypto_la_SOURCES += modes/gcm128_amd64.c | ||
| 15 | |||
| 20 | libcrypto_la_CPPFLAGS += -Dendbr32=endbr64 | 16 | libcrypto_la_CPPFLAGS += -Dendbr32=endbr64 |
| 21 | libcrypto_la_CPPFLAGS += -DAES_ASM | 17 | |
| 22 | libcrypto_la_CPPFLAGS += -DBSAES_ASM | 18 | libcrypto_la_CPPFLAGS += -DLIBRESSL_USE_AES_ASSEMBLY |
| 23 | libcrypto_la_CPPFLAGS += -DVPAES_ASM | 19 | libcrypto_la_CPPFLAGS += -DLIBRESSL_USE_BN_ASSEMBLY |
| 24 | libcrypto_la_CPPFLAGS += -DHAVE_AES_CBC_ENCRYPT_INTERNAL | 20 | libcrypto_la_CPPFLAGS += -DLIBRESSL_USE_GCM_ASSEMBLY |
| 25 | libcrypto_la_CPPFLAGS += -DHAVE_AES_SET_ENCRYPT_KEY_INTERNAL | 21 | libcrypto_la_CPPFLAGS += -DLIBRESSL_USE_RC4_ASSEMBLY |
| 26 | libcrypto_la_CPPFLAGS += -DHAVE_AES_SET_DECRYPT_KEY_INTERNAL | 22 | |
| 27 | libcrypto_la_CPPFLAGS += -DHAVE_AES_ENCRYPT_INTERNAL | ||
| 28 | libcrypto_la_CPPFLAGS += -DHAVE_AES_DECRYPT_INTERNAL | ||
| 29 | libcrypto_la_CPPFLAGS += -DOPENSSL_IA32_SSE2 | ||
| 30 | #libcrypto_la_CPPFLAGS += -DOPENSSL_BN_ASM_MONT | 23 | #libcrypto_la_CPPFLAGS += -DOPENSSL_BN_ASM_MONT |
| 31 | #libcrypto_la_CPPFLAGS += -DOPENSSL_BN_ASM_MONT5 | 24 | #libcrypto_la_CPPFLAGS += -DOPENSSL_BN_ASM_MONT5 |
| 32 | libcrypto_la_CPPFLAGS += -DMD5_ASM | 25 | |
| 33 | libcrypto_la_CPPFLAGS += -DGHASH_ASM | ||
| 34 | libcrypto_la_CPPFLAGS += -DRSA_ASM | ||
| 35 | libcrypto_la_CPPFLAGS += -DSHA1_ASM | ||
| 36 | libcrypto_la_CPPFLAGS += -DSHA256_ASM | ||
| 37 | libcrypto_la_CPPFLAGS += -DSHA512_ASM | ||
| 38 | libcrypto_la_CPPFLAGS += -DWHIRLPOOL_ASM | ||
| 39 | libcrypto_la_CPPFLAGS += -DOPENSSL_CPUID_OBJ | ||
| 40 | libcrypto_la_SOURCES += $(ASM_X86_64_MINGW64) | 26 | libcrypto_la_SOURCES += $(ASM_X86_64_MINGW64) |
| 41 | endif | 27 | endif |
diff --git a/crypto/arch/aarch64/crypto_cpu_caps_darwin.c b/crypto/arch/aarch64/crypto_cpu_caps_darwin.c new file mode 100644 index 0000000..1dd91b2 --- /dev/null +++ b/crypto/arch/aarch64/crypto_cpu_caps_darwin.c | |||
| @@ -0,0 +1,60 @@ | |||
| 1 | /* $OpenBSD: crypto_cpu_caps.c,v 1.2 2024/11/12 13:52:31 jsing Exp $ */ | ||
| 2 | /* | ||
| 3 | * Copyright (c) 2025 Brent Cook <bcook@openbsd.org> | ||
| 4 | * | ||
| 5 | * Permission to use, copy, modify, and distribute this software for any | ||
| 6 | * purpose with or without fee is hereby granted, provided that the above | ||
| 7 | * copyright notice and this permission notice appear in all copies. | ||
| 8 | * | ||
| 9 | * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES | ||
| 10 | * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF | ||
| 11 | * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR | ||
| 12 | * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES | ||
| 13 | * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN | ||
| 14 | * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF | ||
| 15 | * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. | ||
| 16 | */ | ||
| 17 | |||
| 18 | #include <sys/sysctl.h> | ||
| 19 | |||
| 20 | #include "crypto_arch.h" | ||
| 21 | |||
| 22 | /* Machine dependent CPU capabilities. */ | ||
| 23 | uint64_t crypto_cpu_caps_aarch64; | ||
| 24 | |||
| 25 | static uint64_t | ||
| 26 | check_cpu_cap(const char *cap_name, uint64_t cap_flag) | ||
| 27 | { | ||
| 28 | int has_cap = 0; | ||
| 29 | size_t len = sizeof(has_cap); | ||
| 30 | |||
| 31 | sysctlbyname(cap_name, &has_cap, &len, NULL, 0); | ||
| 32 | |||
| 33 | return has_cap ? cap_flag : 0; | ||
| 34 | } | ||
| 35 | |||
| 36 | void | ||
| 37 | crypto_cpu_caps_init(void) | ||
| 38 | { | ||
| 39 | crypto_cpu_caps_aarch64 = 0; | ||
| 40 | |||
| 41 | /* from https://developer.apple.com/documentation/kernel/1387446-sysctlbyname/determining_instruction_set_characteristics#3918855 */ | ||
| 42 | |||
| 43 | crypto_cpu_caps_aarch64 |= check_cpu_cap("hw.optional.arm.FEAT_AES", | ||
| 44 | CRYPTO_CPU_CAPS_AARCH64_AES); | ||
| 45 | |||
| 46 | crypto_cpu_caps_aarch64 |= check_cpu_cap("hw.optional.arm.FEAT_PMULL", | ||
| 47 | CRYPTO_CPU_CAPS_AARCH64_PMULL); | ||
| 48 | |||
| 49 | crypto_cpu_caps_aarch64 |= check_cpu_cap("hw.optional.arm.FEAT_SHA1", | ||
| 50 | CRYPTO_CPU_CAPS_AARCH64_SHA1); | ||
| 51 | |||
| 52 | crypto_cpu_caps_aarch64 |= check_cpu_cap("hw.optional.arm.FEAT_SHA256", | ||
| 53 | CRYPTO_CPU_CAPS_AARCH64_SHA2); | ||
| 54 | |||
| 55 | crypto_cpu_caps_aarch64 |= check_cpu_cap("hw.optional.arm.FEAT_SHA512", | ||
| 56 | CRYPTO_CPU_CAPS_AARCH64_SHA512); | ||
| 57 | |||
| 58 | crypto_cpu_caps_aarch64 |= check_cpu_cap("hw.optional.arm.FEAT_SHA3", | ||
| 59 | CRYPTO_CPU_CAPS_AARCH64_SHA3); | ||
| 60 | } | ||
diff --git a/crypto/arch/aarch64/crypto_cpu_caps_linux.c b/crypto/arch/aarch64/crypto_cpu_caps_linux.c new file mode 100644 index 0000000..ae28120 --- /dev/null +++ b/crypto/arch/aarch64/crypto_cpu_caps_linux.c | |||
| @@ -0,0 +1,62 @@ | |||
| 1 | /* $OpenBSD: crypto_cpu_caps.c,v 1.2 2024/11/12 13:52:31 jsing Exp $ */ | ||
| 2 | /* | ||
| 3 | * Copyright (c) 2025 Brent Cook <bcook@openbsd.org> | ||
| 4 | * | ||
| 5 | * Permission to use, copy, modify, and distribute this software for any | ||
| 6 | * purpose with or without fee is hereby granted, provided that the above | ||
| 7 | * copyright notice and this permission notice appear in all copies. | ||
| 8 | * | ||
| 9 | * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES | ||
| 10 | * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF | ||
| 11 | * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR | ||
| 12 | * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES | ||
| 13 | * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN | ||
| 14 | * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF | ||
| 15 | * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. | ||
| 16 | */ | ||
| 17 | |||
| 18 | #include <sys/auxv.h> | ||
| 19 | |||
| 20 | /* from arch/arm64/include/uapi/asm/hwcap.h */ | ||
| 21 | #define HWCAP_AES (1 << 3) | ||
| 22 | #define HWCAP_PMULL (1 << 4) | ||
| 23 | #define HWCAP_SHA1 (1 << 5) | ||
| 24 | #define HWCAP_SHA2 (1 << 6) | ||
| 25 | #define HWCAP_CRC32 (1 << 7) | ||
| 26 | #define HWCAP_SHA3 (1 << 17) | ||
| 27 | #define HWCAP_SHA512 (1 << 21) | ||
| 28 | |||
| 29 | #include "crypto_arch.h" | ||
| 30 | |||
| 31 | /* Machine dependent CPU capabilities. */ | ||
| 32 | uint64_t crypto_cpu_caps_aarch64; | ||
| 33 | |||
| 34 | static uint64_t | ||
| 35 | check_cpu_cap(unsigned long hwcap, uint64_t cap_flag) | ||
| 36 | { | ||
| 37 | return (getauxval(AT_HWCAP) & hwcap) ? cap_flag : 0; | ||
| 38 | } | ||
| 39 | |||
| 40 | void | ||
| 41 | crypto_cpu_caps_init(void) | ||
| 42 | { | ||
| 43 | crypto_cpu_caps_aarch64 = 0; | ||
| 44 | |||
| 45 | crypto_cpu_caps_aarch64 |= check_cpu_cap(HWCAP_AES, | ||
| 46 | CRYPTO_CPU_CAPS_AARCH64_AES); | ||
| 47 | |||
| 48 | crypto_cpu_caps_aarch64 |= check_cpu_cap(HWCAP_PMULL, | ||
| 49 | CRYPTO_CPU_CAPS_AARCH64_PMULL); | ||
| 50 | |||
| 51 | crypto_cpu_caps_aarch64 |= check_cpu_cap(HWCAP_SHA1, | ||
| 52 | CRYPTO_CPU_CAPS_AARCH64_SHA1); | ||
| 53 | |||
| 54 | crypto_cpu_caps_aarch64 |= check_cpu_cap(HWCAP_SHA2, | ||
| 55 | CRYPTO_CPU_CAPS_AARCH64_SHA2); | ||
| 56 | |||
| 57 | crypto_cpu_caps_aarch64 |= check_cpu_cap(HWCAP_SHA512, | ||
| 58 | CRYPTO_CPU_CAPS_AARCH64_SHA512); | ||
| 59 | |||
| 60 | crypto_cpu_caps_aarch64 |= check_cpu_cap(HWCAP_SHA3, | ||
| 61 | CRYPTO_CPU_CAPS_AARCH64_SHA3); | ||
| 62 | } | ||
diff --git a/crypto/arch/aarch64/crypto_cpu_caps_none.c b/crypto/arch/aarch64/crypto_cpu_caps_none.c new file mode 100644 index 0000000..dcd96b7 --- /dev/null +++ b/crypto/arch/aarch64/crypto_cpu_caps_none.c | |||
| @@ -0,0 +1,26 @@ | |||
| 1 | /* | ||
| 2 | * Copyright (c) 2025 Brent Cook <bcook@openbsd.org> | ||
| 3 | * | ||
| 4 | * Permission to use, copy, modify, and distribute this software for any | ||
| 5 | * purpose with or without fee is hereby granted, provided that the above | ||
| 6 | * copyright notice and this permission notice appear in all copies. | ||
| 7 | * | ||
| 8 | * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES | ||
| 9 | * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF | ||
| 10 | * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR | ||
| 11 | * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES | ||
| 12 | * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN | ||
| 13 | * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF | ||
| 14 | * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. | ||
| 15 | */ | ||
| 16 | |||
| 17 | #include "crypto_arch.h" | ||
| 18 | |||
| 19 | /* Machine dependent CPU capabilities. */ | ||
| 20 | uint64_t crypto_cpu_caps_aarch64; | ||
| 21 | |||
| 22 | void | ||
| 23 | crypto_cpu_caps_init(void) | ||
| 24 | { | ||
| 25 | crypto_cpu_caps_aarch64 = 0; | ||
| 26 | } | ||
diff --git a/crypto/arch/aarch64/crypto_cpu_caps_windows.c b/crypto/arch/aarch64/crypto_cpu_caps_windows.c new file mode 100644 index 0000000..e7cdded --- /dev/null +++ b/crypto/arch/aarch64/crypto_cpu_caps_windows.c | |||
| @@ -0,0 +1,36 @@ | |||
| 1 | /* $OpenBSD: crypto_cpu_caps.c,v 1.2 2024/11/12 13:52:31 jsing Exp $ */ | ||
| 2 | /* | ||
| 3 | * Copyright (c) 2025 Brent Cook <bcook@openbsd.org> | ||
| 4 | * | ||
| 5 | * Permission to use, copy, modify, and distribute this software for any | ||
| 6 | * purpose with or without fee is hereby granted, provided that the above | ||
| 7 | * copyright notice and this permission notice appear in all copies. | ||
| 8 | * | ||
| 9 | * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES | ||
| 10 | * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF | ||
| 11 | * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR | ||
| 12 | * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES | ||
| 13 | * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN | ||
| 14 | * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF | ||
| 15 | * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. | ||
| 16 | */ | ||
| 17 | |||
| 18 | #include <windows.h> | ||
| 19 | |||
| 20 | #include "crypto_arch.h" | ||
| 21 | |||
| 22 | /* Machine dependent CPU capabilities. */ | ||
| 23 | uint64_t crypto_cpu_caps_aarch64; | ||
| 24 | |||
| 25 | void | ||
| 26 | crypto_cpu_caps_init(void) | ||
| 27 | { | ||
| 28 | crypto_cpu_caps_aarch64 = 0; | ||
| 29 | |||
| 30 | if (IsProcessorFeaturePresent(PF_ARM_V8_CRYPTO_INSTRUCTIONS_AVAILABLE)) { | ||
| 31 | crypto_cpu_caps_aarch64 |= CRYPTO_CPU_CAPS_AARCH64_AES; | ||
| 32 | crypto_cpu_caps_aarch64 |= CRYPTO_CPU_CAPS_AARCH64_PMULL; | ||
| 33 | crypto_cpu_caps_aarch64 |= CRYPTO_CPU_CAPS_AARCH64_SHA1; | ||
| 34 | crypto_cpu_caps_aarch64 |= CRYPTO_CPU_CAPS_AARCH64_SHA2; | ||
| 35 | } | ||
| 36 | } | ||
diff --git a/crypto/arch/loongarch64/crypto_arch.h b/crypto/arch/loongarch64/crypto_arch.h new file mode 100644 index 0000000..a3dd98d --- /dev/null +++ b/crypto/arch/loongarch64/crypto_arch.h | |||
| @@ -0,0 +1,21 @@ | |||
| 1 | /* $OpenBSD: crypto_arch.h,v 1.1 2024/08/11 13:02:39 jsing Exp $ */ | ||
| 2 | /* | ||
| 3 | * Copyright (c) 2024 Joel Sing <jsing@openbsd.org> | ||
| 4 | * | ||
| 5 | * Permission to use, copy, modify, and distribute this software for any | ||
| 6 | * purpose with or without fee is hereby granted, provided that the above | ||
| 7 | * copyright notice and this permission notice appear in all copies. | ||
| 8 | * | ||
| 9 | * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES | ||
| 10 | * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF | ||
| 11 | * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR | ||
| 12 | * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES | ||
| 13 | * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN | ||
| 14 | * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF | ||
| 15 | * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. | ||
| 16 | */ | ||
| 17 | |||
| 18 | #ifndef HEADER_CRYPTO_ARCH_H | ||
| 19 | #define HEADER_CRYPTO_ARCH_H | ||
| 20 | |||
| 21 | #endif | ||
diff --git a/crypto/arch/mips/crypto_arch.h b/crypto/arch/mips/crypto_arch.h new file mode 100644 index 0000000..274879c --- /dev/null +++ b/crypto/arch/mips/crypto_arch.h | |||
| @@ -0,0 +1,21 @@ | |||
| 1 | /* $OpenBSD$ */ | ||
| 2 | /* | ||
| 3 | * Copyright (c) 2024 Joel Sing <jsing@openbsd.org> | ||
| 4 | * | ||
| 5 | * Permission to use, copy, modify, and distribute this software for any | ||
| 6 | * purpose with or without fee is hereby granted, provided that the above | ||
| 7 | * copyright notice and this permission notice appear in all copies. | ||
| 8 | * | ||
| 9 | * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES | ||
| 10 | * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF | ||
| 11 | * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR | ||
| 12 | * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES | ||
| 13 | * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN | ||
| 14 | * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF | ||
| 15 | * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. | ||
| 16 | */ | ||
| 17 | |||
| 18 | #ifndef HEADER_CRYPTO_ARCH_H | ||
| 19 | #define HEADER_CRYPTO_ARCH_H | ||
| 20 | |||
| 21 | #endif | ||
diff --git a/crypto/bn/arch/loongarch64/bn_arch.h b/crypto/bn/arch/loongarch64/bn_arch.h new file mode 100644 index 0000000..672ac12 --- /dev/null +++ b/crypto/bn/arch/loongarch64/bn_arch.h | |||
| @@ -0,0 +1,23 @@ | |||
| 1 | /* $OpenBSD: bn_arch.h,v 1.7 2023/07/09 10:37:32 jsing Exp $ */ | ||
| 2 | /* | ||
| 3 | * Copyright (c) 2023 Joel Sing <jsing@openbsd.org> | ||
| 4 | * | ||
| 5 | * Permission to use, copy, modify, and distribute this software for any | ||
| 6 | * purpose with or without fee is hereby granted, provided that the above | ||
| 7 | * copyright notice and this permission notice appear in all copies. | ||
| 8 | * | ||
| 9 | * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES | ||
| 10 | * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF | ||
| 11 | * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR | ||
| 12 | * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES | ||
| 13 | * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN | ||
| 14 | * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF | ||
| 15 | * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. | ||
| 16 | */ | ||
| 17 | |||
| 18 | #include <openssl/bn.h> | ||
| 19 | |||
| 20 | #ifndef HEADER_BN_ARCH_H | ||
| 21 | #define HEADER_BN_ARCH_H | ||
| 22 | |||
| 23 | #endif | ||
diff --git a/crypto/compat/.gitignore b/crypto/compat/.gitignore new file mode 100644 index 0000000..7f05049 --- /dev/null +++ b/crypto/compat/.gitignore | |||
| @@ -0,0 +1,31 @@ | |||
| 1 | arc4random.c | ||
| 2 | arc4random_aix.h | ||
| 3 | arc4random_freebsd.h | ||
| 4 | arc4random_hpux.h | ||
| 5 | arc4random_linux.h | ||
| 6 | arc4random_netbsd.h | ||
| 7 | arc4random_osx.h | ||
| 8 | arc4random_solaris.h | ||
| 9 | arc4random_uniform.c | ||
| 10 | arc4random_win.h | ||
| 11 | chacha_private.h | ||
| 12 | explicit_bzero.c | ||
| 13 | getentropy_aix.c | ||
| 14 | getentropy_freebsd.c | ||
| 15 | getentropy_hpux.c | ||
| 16 | getentropy_linux.c | ||
| 17 | getentropy_netbsd.c | ||
| 18 | getentropy_osx.c | ||
| 19 | getentropy_solaris.c | ||
| 20 | getentropy_win.c | ||
| 21 | reallocarray.c | ||
| 22 | recallocarray.c | ||
| 23 | strcasecmp.c | ||
| 24 | strlcat.c | ||
| 25 | strlcpy.c | ||
| 26 | strndup.c | ||
| 27 | strnlen.c | ||
| 28 | strsep.c | ||
| 29 | strtonum.c | ||
| 30 | timingsafe_bcmp.c | ||
| 31 | timingsafe_memcmp.c | ||
diff --git a/crypto/compat/b_win.c b/crypto/compat/b_win.c index e261cd2..45af839 100644 --- a/crypto/compat/b_win.c +++ b/crypto/compat/b_win.c | |||
| @@ -8,7 +8,8 @@ | |||
| 8 | #include <ws2tcpip.h> | 8 | #include <ws2tcpip.h> |
| 9 | 9 | ||
| 10 | #include <openssl/bio.h> | 10 | #include <openssl/bio.h> |
| 11 | #include <openssl/err.h> | 11 | |
| 12 | #include "err_local.h" | ||
| 12 | 13 | ||
| 13 | int | 14 | int |
| 14 | BIO_sock_init(void) | 15 | BIO_sock_init(void) |
| @@ -29,7 +30,7 @@ BIO_sock_init(void) | |||
| 29 | } | 30 | } |
| 30 | wsa_init_done = 1; | 31 | wsa_init_done = 1; |
| 31 | } | 32 | } |
| 32 | return (1); | 33 | return (1); |
| 33 | } | 34 | } |
| 34 | 35 | ||
| 35 | void | 36 | void |
diff --git a/tls/compat/ftruncate.c b/crypto/compat/ftruncate.c index e825e50..e825e50 100644 --- a/tls/compat/ftruncate.c +++ b/crypto/compat/ftruncate.c | |||
diff --git a/crypto/compat/getdelim.c b/crypto/compat/getdelim.c new file mode 100644 index 0000000..caec3f2 --- /dev/null +++ b/crypto/compat/getdelim.c | |||
| @@ -0,0 +1,78 @@ | |||
| 1 | /*- | ||
| 2 | * Copyright (c) 2011 The NetBSD Foundation, Inc. | ||
| 3 | * All rights reserved. | ||
| 4 | * | ||
| 5 | * This code is derived from software contributed to The NetBSD Foundation | ||
| 6 | * by Christos Zoulas. | ||
| 7 | * | ||
| 8 | * Redistribution and use in source and binary forms, with or without | ||
| 9 | * modification, are permitted provided that the following conditions | ||
| 10 | * are met: | ||
| 11 | * 1. Redistributions of source code must retain the above copyright | ||
| 12 | * notice, this list of conditions and the following disclaimer. | ||
| 13 | * 2. Redistributions in binary form must reproduce the above copyright | ||
| 14 | * notice, this list of conditions and the following disclaimer in the | ||
| 15 | * documentation and/or other materials provided with the distribution. | ||
| 16 | * | ||
| 17 | * THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND CONTRIBUTORS | ||
| 18 | * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED | ||
| 19 | * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR | ||
| 20 | * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS | ||
| 21 | * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR | ||
| 22 | * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF | ||
| 23 | * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS | ||
| 24 | * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN | ||
| 25 | * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) | ||
| 26 | * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE | ||
| 27 | * POSSIBILITY OF SUCH DAMAGE. | ||
| 28 | */ | ||
| 29 | |||
| 30 | #include <stdio.h> | ||
| 31 | #include <stdlib.h> | ||
| 32 | |||
| 33 | #ifndef HAVE_GETDELIM | ||
| 34 | |||
| 35 | ssize_t | ||
| 36 | getdelim(char **buf, size_t *bufsiz, int delimiter, FILE *fp) | ||
| 37 | { | ||
| 38 | char *ptr, *eptr; | ||
| 39 | |||
| 40 | |||
| 41 | if (*buf == NULL || *bufsiz == 0) { | ||
| 42 | *bufsiz = BUFSIZ; | ||
| 43 | if ((*buf = malloc(*bufsiz)) == NULL) | ||
| 44 | return -1; | ||
| 45 | } | ||
| 46 | |||
| 47 | for (ptr = *buf, eptr = *buf + *bufsiz;;) { | ||
| 48 | int c = fgetc(fp); | ||
| 49 | if (c == -1) { | ||
| 50 | if (feof(fp)) { | ||
| 51 | ssize_t diff = (ssize_t)(ptr - *buf); | ||
| 52 | if (diff != 0) { | ||
| 53 | *ptr = '\0'; | ||
| 54 | return diff; | ||
| 55 | } | ||
| 56 | } | ||
| 57 | return -1; | ||
| 58 | } | ||
| 59 | *ptr++ = c; | ||
| 60 | if (c == delimiter) { | ||
| 61 | *ptr = '\0'; | ||
| 62 | return ptr - *buf; | ||
| 63 | } | ||
| 64 | if (ptr + 2 >= eptr) { | ||
| 65 | char *nbuf; | ||
| 66 | size_t nbufsiz = *bufsiz * 2; | ||
| 67 | ssize_t d = ptr - *buf; | ||
| 68 | if ((nbuf = realloc(*buf, nbufsiz)) == NULL) | ||
| 69 | return -1; | ||
| 70 | *buf = nbuf; | ||
| 71 | *bufsiz = nbufsiz; | ||
| 72 | eptr = nbuf + nbufsiz; | ||
| 73 | ptr = nbuf + d; | ||
| 74 | } | ||
| 75 | } | ||
| 76 | } | ||
| 77 | |||
| 78 | #endif /* HAVE_GETDELIM */ | ||
diff --git a/crypto/compat/getline.c b/crypto/compat/getline.c new file mode 100644 index 0000000..e6ecde0 --- /dev/null +++ b/crypto/compat/getline.c | |||
| @@ -0,0 +1,40 @@ | |||
| 1 | /*- | ||
| 2 | * Copyright (c) 2011 The NetBSD Foundation, Inc. | ||
| 3 | * All rights reserved. | ||
| 4 | * | ||
| 5 | * This code is derived from software contributed to The NetBSD Foundation | ||
| 6 | * by Christos Zoulas. | ||
| 7 | * | ||
| 8 | * Redistribution and use in source and binary forms, with or without | ||
| 9 | * modification, are permitted provided that the following conditions | ||
| 10 | * are met: | ||
| 11 | * 1. Redistributions of source code must retain the above copyright | ||
| 12 | * notice, this list of conditions and the following disclaimer. | ||
| 13 | * 2. Redistributions in binary form must reproduce the above copyright | ||
| 14 | * notice, this list of conditions and the following disclaimer in the | ||
| 15 | * documentation and/or other materials provided with the distribution. | ||
| 16 | * | ||
| 17 | * THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND CONTRIBUTORS | ||
| 18 | * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED | ||
| 19 | * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR | ||
| 20 | * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS | ||
| 21 | * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR | ||
| 22 | * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF | ||
| 23 | * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS | ||
| 24 | * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN | ||
| 25 | * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) | ||
| 26 | * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE | ||
| 27 | * POSSIBILITY OF SUCH DAMAGE. | ||
| 28 | */ | ||
| 29 | |||
| 30 | #include <stdio.h> | ||
| 31 | |||
| 32 | #ifndef HAVE_GETLINE | ||
| 33 | |||
| 34 | ssize_t | ||
| 35 | getline(char **buf, size_t *bufsiz, FILE *fp) | ||
| 36 | { | ||
| 37 | return getdelim(buf, bufsiz, '\n', fp); | ||
| 38 | } | ||
| 39 | |||
| 40 | #endif /* HAVE_GETLINE */ | ||
diff --git a/crypto/compat/posix_win.c b/crypto/compat/posix_win.c index bb3e653..572e527 100644 --- a/crypto/compat/posix_win.c +++ b/crypto/compat/posix_win.c | |||
| @@ -9,6 +9,8 @@ | |||
| 9 | 9 | ||
| 10 | #define NO_REDEF_POSIX_FUNCTIONS | 10 | #define NO_REDEF_POSIX_FUNCTIONS |
| 11 | 11 | ||
| 12 | #include <sys/time.h> | ||
| 13 | |||
| 12 | #include <ws2tcpip.h> | 14 | #include <ws2tcpip.h> |
| 13 | #include <windows.h> | 15 | #include <windows.h> |
| 14 | 16 | ||
| @@ -20,6 +22,25 @@ | |||
| 20 | #include <string.h> | 22 | #include <string.h> |
| 21 | #include <unistd.h> | 23 | #include <unistd.h> |
| 22 | 24 | ||
| 25 | #include <sys/stat.h> | ||
| 26 | |||
| 27 | static int | ||
| 28 | is_socket(int fd) | ||
| 29 | { | ||
| 30 | // Border case: Don't break std* file descriptors | ||
| 31 | if (fd < 3) | ||
| 32 | return 0; | ||
| 33 | |||
| 34 | // All locally-allocated file descriptors will have the high bit set | ||
| 35 | return (fd & 0x80000000) == 0; | ||
| 36 | } | ||
| 37 | |||
| 38 | static int | ||
| 39 | get_real_fd(int fd) | ||
| 40 | { | ||
| 41 | return (fd & 0x7fffffff); | ||
| 42 | } | ||
| 43 | |||
| 23 | void | 44 | void |
| 24 | posix_perror(const char *s) | 45 | posix_perror(const char *s) |
| 25 | { | 46 | { |
| @@ -42,6 +63,12 @@ posix_fopen(const char *path, const char *mode) | |||
| 42 | } | 63 | } |
| 43 | 64 | ||
| 44 | int | 65 | int |
| 66 | libressl_fstat(int fd, struct stat *statbuf) | ||
| 67 | { | ||
| 68 | return fstat(get_real_fd(fd), statbuf); | ||
| 69 | } | ||
| 70 | |||
| 71 | int | ||
| 45 | posix_open(const char *path, ...) | 72 | posix_open(const char *path, ...) |
| 46 | { | 73 | { |
| 47 | va_list ap; | 74 | va_list ap; |
| @@ -60,7 +87,11 @@ posix_open(const char *path, ...) | |||
| 60 | flags |= O_NOINHERIT; | 87 | flags |= O_NOINHERIT; |
| 61 | } | 88 | } |
| 62 | flags &= ~O_NONBLOCK; | 89 | flags &= ~O_NONBLOCK; |
| 63 | return open(path, flags, mode); | 90 | |
| 91 | const int fh = open(path, flags, mode); | ||
| 92 | |||
| 93 | // Set high bit to mark file descriptor as a file handle | ||
| 94 | return fh + 0x80000000; | ||
| 64 | } | 95 | } |
| 65 | 96 | ||
| 66 | char * | 97 | char * |
| @@ -148,52 +179,6 @@ wsa_errno(int err) | |||
| 148 | return -1; | 179 | return -1; |
| 149 | } | 180 | } |
| 150 | 181 | ||
| 151 | /* | ||
| 152 | * Employ a similar trick to cpython (pycore_fileutils.h) where the CRT report | ||
| 153 | * handler is disabled while checking if a descriptor is a socket or a file | ||
| 154 | */ | ||
| 155 | #if defined _MSC_VER && _MSC_VER >= 1900 | ||
| 156 | |||
| 157 | #include <crtdbg.h> | ||
| 158 | #include <stdlib.h> | ||
| 159 | |||
| 160 | static void noop_handler(const wchar_t *expression, const wchar_t *function, | ||
| 161 | const wchar_t *file, unsigned int line, uintptr_t pReserved) | ||
| 162 | { | ||
| 163 | return; | ||
| 164 | } | ||
| 165 | |||
| 166 | #define BEGIN_SUPPRESS_IPH \ | ||
| 167 | const int old_report_mode = _CrtSetReportMode(_CRT_ASSERT, 0); \ | ||
| 168 | const _invalid_parameter_handler old_handler = _set_thread_local_invalid_parameter_handler(noop_handler) | ||
| 169 | #define END_SUPPRESS_IPH \ | ||
| 170 | (void)old_report_mode; /* Silence warning in release mode when _CrtSetReportMode compiles to void. */ \ | ||
| 171 | _CrtSetReportMode(_CRT_ASSERT, old_report_mode); \ | ||
| 172 | _set_thread_local_invalid_parameter_handler(old_handler) | ||
| 173 | |||
| 174 | #else | ||
| 175 | |||
| 176 | #define BEGIN_SUPPRESS_IPH | ||
| 177 | #define END_SUPPRESS_IPH | ||
| 178 | |||
| 179 | #endif | ||
| 180 | |||
| 181 | static int | ||
| 182 | is_socket(int fd) | ||
| 183 | { | ||
| 184 | intptr_t hd; | ||
| 185 | |||
| 186 | BEGIN_SUPPRESS_IPH; | ||
| 187 | hd = _get_osfhandle(fd); | ||
| 188 | END_SUPPRESS_IPH; | ||
| 189 | |||
| 190 | if (hd == (intptr_t)INVALID_HANDLE_VALUE) { | ||
| 191 | return 1; /* fd is not file descriptor */ | ||
| 192 | } | ||
| 193 | |||
| 194 | return 0; | ||
| 195 | } | ||
| 196 | |||
| 197 | int | 182 | int |
| 198 | posix_connect(int sockfd, const struct sockaddr *addr, socklen_t addrlen) | 183 | posix_connect(int sockfd, const struct sockaddr *addr, socklen_t addrlen) |
| 199 | { | 184 | { |
| @@ -207,14 +192,13 @@ int | |||
| 207 | posix_close(int fd) | 192 | posix_close(int fd) |
| 208 | { | 193 | { |
| 209 | int rc; | 194 | int rc; |
| 210 | |||
| 211 | if (is_socket(fd)) { | 195 | if (is_socket(fd)) { |
| 212 | if ((rc = closesocket(fd)) == SOCKET_ERROR) { | 196 | if ((rc = closesocket(fd)) == SOCKET_ERROR) { |
| 213 | int err = WSAGetLastError(); | 197 | int err = WSAGetLastError(); |
| 214 | rc = wsa_errno(err); | 198 | rc = wsa_errno(err); |
| 215 | } | 199 | } |
| 216 | } else { | 200 | } else { |
| 217 | rc = close(fd); | 201 | rc = close(get_real_fd(fd)); |
| 218 | } | 202 | } |
| 219 | return rc; | 203 | return rc; |
| 220 | } | 204 | } |
| @@ -223,14 +207,13 @@ ssize_t | |||
| 223 | posix_read(int fd, void *buf, size_t count) | 207 | posix_read(int fd, void *buf, size_t count) |
| 224 | { | 208 | { |
| 225 | ssize_t rc; | 209 | ssize_t rc; |
| 226 | |||
| 227 | if (is_socket(fd)) { | 210 | if (is_socket(fd)) { |
| 228 | if ((rc = recv(fd, buf, count, 0)) == SOCKET_ERROR) { | 211 | if ((rc = recv(fd, buf, count, 0)) == SOCKET_ERROR) { |
| 229 | int err = WSAGetLastError(); | 212 | int err = WSAGetLastError(); |
| 230 | rc = wsa_errno(err); | 213 | rc = wsa_errno(err); |
| 231 | } | 214 | } |
| 232 | } else { | 215 | } else { |
| 233 | rc = read(fd, buf, count); | 216 | rc = read(get_real_fd(fd), buf, count); |
| 234 | } | 217 | } |
| 235 | return rc; | 218 | return rc; |
| 236 | } | 219 | } |
| @@ -244,7 +227,7 @@ posix_write(int fd, const void *buf, size_t count) | |||
| 244 | rc = wsa_errno(WSAGetLastError()); | 227 | rc = wsa_errno(WSAGetLastError()); |
| 245 | } | 228 | } |
| 246 | } else { | 229 | } else { |
| 247 | rc = write(fd, buf, count); | 230 | rc = write(get_real_fd(fd), buf, count); |
| 248 | } | 231 | } |
| 249 | return rc; | 232 | return rc; |
| 250 | } | 233 | } |
| @@ -289,7 +272,7 @@ uid_t getuid(void) | |||
| 289 | 272 | ||
| 290 | #ifdef _MSC_VER | 273 | #ifdef _MSC_VER |
| 291 | struct timezone; | 274 | struct timezone; |
| 292 | int gettimeofday(struct timeval * tp, struct timezone * tzp) | 275 | int gettimeofday(struct timeval *tp, void *tzp) |
| 293 | { | 276 | { |
| 294 | /* | 277 | /* |
| 295 | * Note: some broken versions only have 8 trailing zero's, the correct | 278 | * Note: some broken versions only have 8 trailing zero's, the correct |
| @@ -306,7 +289,7 @@ int gettimeofday(struct timeval * tp, struct timezone * tzp) | |||
| 306 | time = ((uint64_t)file_time.dwLowDateTime); | 289 | time = ((uint64_t)file_time.dwLowDateTime); |
| 307 | time += ((uint64_t)file_time.dwHighDateTime) << 32; | 290 | time += ((uint64_t)file_time.dwHighDateTime) << 32; |
| 308 | 291 | ||
| 309 | tp->tv_sec = (long)((time - EPOCH) / 10000000L); | 292 | tp->tv_sec = (long long)((time - EPOCH) / 10000000L); |
| 310 | tp->tv_usec = (long)(system_time.wMilliseconds * 1000); | 293 | tp->tv_usec = (long)(system_time.wMilliseconds * 1000); |
| 311 | return 0; | 294 | return 0; |
| 312 | } | 295 | } |
diff --git a/crypto/compat/ui_openssl_win.c b/crypto/compat/ui_openssl_win.c index 09705e4..4ae2c5d 100644 --- a/crypto/compat/ui_openssl_win.c +++ b/crypto/compat/ui_openssl_win.c | |||
| @@ -146,7 +146,7 @@ static int echo_console(UI *ui); | |||
| 146 | static int noecho_console(UI *ui); | 146 | static int noecho_console(UI *ui); |
| 147 | static int close_console(UI *ui); | 147 | static int close_console(UI *ui); |
| 148 | 148 | ||
| 149 | static UI_METHOD ui_openssl = { | 149 | static const UI_METHOD ui_openssl = { |
| 150 | .name = "OpenSSL default user interface", | 150 | .name = "OpenSSL default user interface", |
| 151 | .ui_open_session = open_console, | 151 | .ui_open_session = open_console, |
| 152 | .ui_write_string = write_string, | 152 | .ui_write_string = write_string, |
| @@ -155,7 +155,7 @@ static UI_METHOD ui_openssl = { | |||
| 155 | }; | 155 | }; |
| 156 | 156 | ||
| 157 | /* The method with all the built-in thingies */ | 157 | /* The method with all the built-in thingies */ |
| 158 | UI_METHOD * | 158 | const UI_METHOD * |
| 159 | UI_OpenSSL(void) | 159 | UI_OpenSSL(void) |
| 160 | { | 160 | { |
| 161 | return &ui_openssl; | 161 | return &ui_openssl; |
| @@ -1,4 +1,19 @@ | |||
| 1 | #!/bin/sh | 1 | #!/bin/sh |
| 2 | # | ||
| 3 | # Copyright (c) 2014 Brent Cook | ||
| 4 | # | ||
| 5 | # Permission to use, copy, modify, and distribute this software for any | ||
| 6 | # purpose with or without fee is hereby granted, provided that the above | ||
| 7 | # copyright notice and this permission notice appear in all copies. | ||
| 8 | # | ||
| 9 | # THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES | ||
| 10 | # WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF | ||
| 11 | # MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR | ||
| 12 | # ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES | ||
| 13 | # WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN | ||
| 14 | # ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF | ||
| 15 | # OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. | ||
| 16 | # | ||
| 2 | set -e | 17 | set -e |
| 3 | 18 | ||
| 4 | rm -f man/*.[35] include/openssl/*.h | 19 | rm -f man/*.[35] include/openssl/*.h |
diff --git a/gen-coverage-report.sh b/gen-coverage-report.sh index b11f3f9..6453ecb 100755 --- a/gen-coverage-report.sh +++ b/gen-coverage-report.sh | |||
| @@ -1,3 +1,18 @@ | |||
| 1 | # | ||
| 2 | # Copyright (c) 2014 Brent Cook | ||
| 3 | # | ||
| 4 | # Permission to use, copy, modify, and distribute this software for any | ||
| 5 | # purpose with or without fee is hereby granted, provided that the above | ||
| 6 | # copyright notice and this permission notice appear in all copies. | ||
| 7 | # | ||
| 8 | # THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES | ||
| 9 | # WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF | ||
| 10 | # MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR | ||
| 11 | # ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES | ||
| 12 | # WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN | ||
| 13 | # ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF | ||
| 14 | # OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. | ||
| 15 | # | ||
| 1 | #!/bin/sh | 16 | #!/bin/sh |
| 2 | 17 | ||
| 3 | VERSION=$(cat VERSION) | 18 | VERSION=$(cat VERSION) |
diff --git a/include/CMakeLists.txt b/include/CMakeLists.txt index 9d015cd..4802d13 100644 --- a/include/CMakeLists.txt +++ b/include/CMakeLists.txt | |||
| @@ -1,13 +1,25 @@ | |||
| 1 | # | ||
| 2 | # Copyright (c) 2016 Jeff Davey | ||
| 3 | # | ||
| 4 | # Permission to use, copy, modify, and distribute this software for any | ||
| 5 | # purpose with or without fee is hereby granted, provided that the above | ||
| 6 | # copyright notice and this permission notice appear in all copies. | ||
| 7 | # | ||
| 8 | # THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES | ||
| 9 | # WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF | ||
| 10 | # MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR | ||
| 11 | # ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES | ||
| 12 | # WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN | ||
| 13 | # ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF | ||
| 14 | # OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. | ||
| 15 | |||
| 1 | if(ENABLE_LIBRESSL_INSTALL) | 16 | if(ENABLE_LIBRESSL_INSTALL) |
| 2 | install(DIRECTORY . | 17 | install(DIRECTORY . |
| 3 | DESTINATION ${CMAKE_INSTALL_INCLUDEDIR} | 18 | DESTINATION ${CMAKE_INSTALL_INCLUDEDIR} |
| 4 | PATTERN "CMakeLists.txt" EXCLUDE | 19 | PATTERN "CMakeLists.txt" EXCLUDE |
| 5 | PATTERN "compat" EXCLUDE | 20 | PATTERN "compat" EXCLUDE |
| 6 | PATTERN "pqueue.h" EXCLUDE | 21 | PATTERN "pqueue.h" EXCLUDE |
| 7 | PATTERN "Makefile*" EXCLUDE | 22 | PATTERN "Makefile*" EXCLUDE) |
| 8 | PATTERN "arch" EXCLUDE) | ||
| 9 | install(FILES ${CMAKE_BINARY_DIR}/include/openssl/opensslconf.h | ||
| 10 | DESTINATION "${CMAKE_INSTALL_INCLUDEDIR}/openssl") | ||
| 11 | endif(ENABLE_LIBRESSL_INSTALL) | 23 | endif(ENABLE_LIBRESSL_INSTALL) |
| 12 | 24 | ||
| 13 | file(COPY . | 25 | file(COPY . |
| @@ -17,26 +29,3 @@ file(COPY . | |||
| 17 | PATTERN "pqueue.h" EXCLUDE | 29 | PATTERN "pqueue.h" EXCLUDE |
| 18 | PATTERN "Makefile*" EXCLUDE | 30 | PATTERN "Makefile*" EXCLUDE |
| 19 | PATTERN "arch" EXCLUDE) | 31 | PATTERN "arch" EXCLUDE) |
| 20 | |||
| 21 | if(HOST_AARCH64) | ||
| 22 | file(READ arch/aarch64/opensslconf.h OPENSSLCONF) | ||
| 23 | elseif(HOST_ARM) | ||
| 24 | file(READ arch/arm/opensslconf.h OPENSSLCONF) | ||
| 25 | elseif(HOST_I386) | ||
| 26 | file(READ arch/i386/opensslconf.h OPENSSLCONF) | ||
| 27 | elseif(HOST_MIPS) | ||
| 28 | file(READ arch/mips/opensslconf.h OPENSSLCONF) | ||
| 29 | elseif(HOST_MIPS64) | ||
| 30 | file(READ arch/mips64/opensslconf.h OPENSSLCONF) | ||
| 31 | elseif(HOST_POWERPC) | ||
| 32 | file(READ arch/powerpc/opensslconf.h OPENSSLCONF) | ||
| 33 | elseif(HOST_POWERPC64) | ||
| 34 | file(READ arch/powerpc64/opensslconf.h OPENSSLCONF) | ||
| 35 | elseif(HOST_RISCV64) | ||
| 36 | file(READ arch/riscv64/opensslconf.h OPENSSLCONF) | ||
| 37 | elseif(HOST_SPARC64) | ||
| 38 | file(READ arch/sparc64/opensslconf.h OPENSSLCONF) | ||
| 39 | elseif(HOST_X86_64) | ||
| 40 | file(READ arch/amd64/opensslconf.h OPENSSLCONF) | ||
| 41 | endif() | ||
| 42 | file(WRITE ${CMAKE_BINARY_DIR}/include/openssl/opensslconf.h "${OPENSSLCONF}") | ||
diff --git a/include/Makefile.am b/include/Makefile.am index feaaa60..04c9ea2 100644 --- a/include/Makefile.am +++ b/include/Makefile.am | |||
| @@ -1,3 +1,18 @@ | |||
| 1 | # | ||
| 2 | # Copyright (c) 2014 Brent Cook | ||
| 3 | # | ||
| 4 | # Permission to use, copy, modify, and distribute this software for any | ||
| 5 | # purpose with or without fee is hereby granted, provided that the above | ||
| 6 | # copyright notice and this permission notice appear in all copies. | ||
| 7 | # | ||
| 8 | # THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES | ||
| 9 | # WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF | ||
| 10 | # MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR | ||
| 11 | # ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES | ||
| 12 | # WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN | ||
| 13 | # ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF | ||
| 14 | # OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. | ||
| 15 | |||
| 1 | include $(top_srcdir)/Makefile.am.common | 16 | include $(top_srcdir)/Makefile.am.common |
| 2 | 17 | ||
| 3 | EXTRA_DIST = CMakeLists.txt | 18 | EXTRA_DIST = CMakeLists.txt |
| @@ -46,19 +61,4 @@ noinst_HEADERS += compat/sys/time.h | |||
| 46 | noinst_HEADERS += compat/sys/types.h | 61 | noinst_HEADERS += compat/sys/types.h |
| 47 | noinst_HEADERS += compat/sys/uio.h | 62 | noinst_HEADERS += compat/sys/uio.h |
| 48 | 63 | ||
| 49 | noinst_HEADERS += arch/aarch64/opensslconf.h | ||
| 50 | noinst_HEADERS += arch/alpha/opensslconf.h | ||
| 51 | noinst_HEADERS += arch/amd64/opensslconf.h | ||
| 52 | noinst_HEADERS += arch/arm/opensslconf.h | ||
| 53 | noinst_HEADERS += arch/hppa/opensslconf.h | ||
| 54 | noinst_HEADERS += arch/i386/opensslconf.h | ||
| 55 | noinst_HEADERS += arch/m88k/opensslconf.h | ||
| 56 | noinst_HEADERS += arch/mips/opensslconf.h | ||
| 57 | noinst_HEADERS += arch/mips64/opensslconf.h | ||
| 58 | noinst_HEADERS += arch/powerpc/opensslconf.h | ||
| 59 | noinst_HEADERS += arch/powerpc64/opensslconf.h | ||
| 60 | noinst_HEADERS += arch/riscv64/opensslconf.h | ||
| 61 | noinst_HEADERS += arch/sh/opensslconf.h | ||
| 62 | noinst_HEADERS += arch/sparc64/opensslconf.h | ||
| 63 | |||
| 64 | include_HEADERS = tls.h | 64 | include_HEADERS = tls.h |
diff --git a/include/arch/mips/opensslconf.h b/include/arch/mips/opensslconf.h deleted file mode 100644 index f17d3d2..0000000 --- a/include/arch/mips/opensslconf.h +++ /dev/null | |||
| @@ -1,154 +0,0 @@ | |||
| 1 | #include <openssl/opensslfeatures.h> | ||
| 2 | /* crypto/opensslconf.h.in */ | ||
| 3 | |||
| 4 | #if defined(HEADER_CRYPTLIB_H) && !defined(OPENSSLDIR) | ||
| 5 | #define OPENSSLDIR "/etc/ssl" | ||
| 6 | #endif | ||
| 7 | |||
| 8 | #undef OPENSSL_UNISTD | ||
| 9 | #define OPENSSL_UNISTD <unistd.h> | ||
| 10 | |||
| 11 | #undef OPENSSL_EXPORT_VAR_AS_FUNCTION | ||
| 12 | |||
| 13 | #if defined(HEADER_IDEA_H) && !defined(IDEA_INT) | ||
| 14 | #define IDEA_INT unsigned int | ||
| 15 | #endif | ||
| 16 | |||
| 17 | #if defined(HEADER_MD2_H) && !defined(MD2_INT) | ||
| 18 | #define MD2_INT unsigned int | ||
| 19 | #endif | ||
| 20 | |||
| 21 | #if defined(HEADER_RC2_H) && !defined(RC2_INT) | ||
| 22 | /* I need to put in a mod for the alpha - eay */ | ||
| 23 | #define RC2_INT unsigned int | ||
| 24 | #endif | ||
| 25 | |||
| 26 | #if defined(HEADER_RC4_H) | ||
| 27 | #if !defined(RC4_INT) | ||
| 28 | /* using int types make the structure larger but make the code faster | ||
| 29 | * on most boxes I have tested - up to %20 faster. */ | ||
| 30 | /* | ||
| 31 | * I don't know what does "most" mean, but declaring "int" is a must on: | ||
| 32 | * - Intel P6 because partial register stalls are very expensive; | ||
| 33 | * - elder Alpha because it lacks byte load/store instructions; | ||
| 34 | */ | ||
| 35 | #define RC4_INT unsigned int | ||
| 36 | #endif | ||
| 37 | #if !defined(RC4_CHUNK) | ||
| 38 | /* | ||
| 39 | * This enables code handling data aligned at natural CPU word | ||
| 40 | * boundary. See crypto/rc4/rc4_enc.c for further details. | ||
| 41 | */ | ||
| 42 | #undef RC4_CHUNK | ||
| 43 | #endif | ||
| 44 | #endif | ||
| 45 | |||
| 46 | #if (defined(HEADER_NEW_DES_H) || defined(HEADER_DES_H)) && !defined(DES_LONG) | ||
| 47 | /* If this is set to 'unsigned int' on a DEC Alpha, this gives about a | ||
| 48 | * %20 speed up (longs are 8 bytes, int's are 4). */ | ||
| 49 | #ifndef DES_LONG | ||
| 50 | #define DES_LONG unsigned int | ||
| 51 | #endif | ||
| 52 | #endif | ||
| 53 | |||
| 54 | #if defined(HEADER_BN_H) && !defined(CONFIG_HEADER_BN_H) | ||
| 55 | #define CONFIG_HEADER_BN_H | ||
| 56 | #define BN_LLONG | ||
| 57 | |||
| 58 | /* Should we define BN_DIV2W here? */ | ||
| 59 | |||
| 60 | /* Only one for the following should be defined */ | ||
| 61 | /* The prime number generation stuff may not work when | ||
| 62 | * EIGHT_BIT but I don't care since I've only used this mode | ||
| 63 | * for debugging the bignum libraries */ | ||
| 64 | #undef SIXTY_FOUR_BIT_LONG | ||
| 65 | #undef SIXTY_FOUR_BIT | ||
| 66 | #define THIRTY_TWO_BIT | ||
| 67 | #undef SIXTEEN_BIT | ||
| 68 | #undef EIGHT_BIT | ||
| 69 | #endif | ||
| 70 | |||
| 71 | #if defined(HEADER_RC4_LOCL_H) && !defined(CONFIG_HEADER_RC4_LOCL_H) | ||
| 72 | #define CONFIG_HEADER_RC4_LOCL_H | ||
| 73 | /* if this is defined data[i] is used instead of *data, this is a %20 | ||
| 74 | * speedup on x86 */ | ||
| 75 | #define RC4_INDEX | ||
| 76 | #endif | ||
| 77 | |||
| 78 | #if defined(HEADER_BF_LOCL_H) && !defined(CONFIG_HEADER_BF_LOCL_H) | ||
| 79 | #define CONFIG_HEADER_BF_LOCL_H | ||
| 80 | #undef BF_PTR | ||
| 81 | #endif /* HEADER_BF_LOCL_H */ | ||
| 82 | |||
| 83 | #if defined(HEADER_DES_LOCL_H) && !defined(CONFIG_HEADER_DES_LOCL_H) | ||
| 84 | #define CONFIG_HEADER_DES_LOCL_H | ||
| 85 | #ifndef DES_DEFAULT_OPTIONS | ||
| 86 | /* the following is tweaked from a config script, that is why it is a | ||
| 87 | * protected undef/define */ | ||
| 88 | #ifndef DES_PTR | ||
| 89 | #undef DES_PTR | ||
| 90 | #endif | ||
| 91 | |||
| 92 | /* This helps C compiler generate the correct code for multiple functional | ||
| 93 | * units. It reduces register dependencies at the expense of 2 more | ||
| 94 | * registers */ | ||
| 95 | #ifndef DES_RISC1 | ||
| 96 | #undef DES_RISC1 | ||
| 97 | #endif | ||
| 98 | |||
| 99 | #ifndef DES_RISC2 | ||
| 100 | #undef DES_RISC2 | ||
| 101 | #endif | ||
| 102 | |||
| 103 | #if defined(DES_RISC1) && defined(DES_RISC2) | ||
| 104 | YOU SHOULD NOT HAVE BOTH DES_RISC1 AND DES_RISC2 DEFINED!!!!! | ||
| 105 | #endif | ||
| 106 | |||
| 107 | /* Unroll the inner loop, this sometimes helps, sometimes hinders. | ||
| 108 | * Very much CPU dependent */ | ||
| 109 | #ifndef DES_UNROLL | ||
| 110 | #define DES_UNROLL | ||
| 111 | #endif | ||
| 112 | |||
| 113 | /* These default values were supplied by | ||
| 114 | * Peter Gutman <pgut001@cs.auckland.ac.nz> | ||
| 115 | * They are only used if nothing else has been defined */ | ||
| 116 | #if !defined(DES_PTR) && !defined(DES_RISC1) && !defined(DES_RISC2) && !defined(DES_UNROLL) | ||
| 117 | /* Special defines which change the way the code is built depending on the | ||
| 118 | CPU and OS. For SGI machines you can use _MIPS_SZLONG (32 or 64) to find | ||
| 119 | even newer MIPS CPU's, but at the moment one size fits all for | ||
| 120 | optimization options. Older Sparc's work better with only UNROLL, but | ||
| 121 | there's no way to tell at compile time what it is you're running on */ | ||
| 122 | |||
| 123 | #if defined( sun ) /* Newer Sparc's */ | ||
| 124 | # define DES_PTR | ||
| 125 | # define DES_RISC1 | ||
| 126 | # define DES_UNROLL | ||
| 127 | #elif defined( __ultrix ) /* Older MIPS */ | ||
| 128 | # define DES_PTR | ||
| 129 | # define DES_RISC2 | ||
| 130 | # define DES_UNROLL | ||
| 131 | #elif defined( __osf1__ ) /* Alpha */ | ||
| 132 | # define DES_PTR | ||
| 133 | # define DES_RISC2 | ||
| 134 | #elif defined ( _AIX ) /* RS6000 */ | ||
| 135 | /* Unknown */ | ||
| 136 | #elif defined( __hpux ) /* HP-PA */ | ||
| 137 | /* Unknown */ | ||
| 138 | #elif defined( __aux ) /* 68K */ | ||
| 139 | /* Unknown */ | ||
| 140 | #elif defined( __dgux ) /* 88K (but P6 in latest boxes) */ | ||
| 141 | # define DES_UNROLL | ||
| 142 | #elif defined( __sgi ) /* Newer MIPS */ | ||
| 143 | # define DES_PTR | ||
| 144 | # define DES_RISC2 | ||
| 145 | # define DES_UNROLL | ||
| 146 | #elif defined(i386) || defined(__i386__) /* x86 boxes, should be gcc */ | ||
| 147 | # define DES_PTR | ||
| 148 | # define DES_RISC1 | ||
| 149 | # define DES_UNROLL | ||
| 150 | #endif /* Systems-specific speed defines */ | ||
| 151 | #endif | ||
| 152 | |||
| 153 | #endif /* DES_DEFAULT_OPTIONS */ | ||
| 154 | #endif /* HEADER_DES_LOCL_H */ | ||
diff --git a/include/compat/endian.h b/include/compat/endian.h index 5376c1a..af3664d 100644 --- a/include/compat/endian.h +++ b/include/compat/endian.h | |||
| @@ -62,7 +62,7 @@ | |||
| 62 | #endif | 62 | #endif |
| 63 | #endif | 63 | #endif |
| 64 | 64 | ||
| 65 | #if defined(__APPLE__) && !defined(HAVE_ENDIAN_H) | 65 | #if defined(__APPLE__) |
| 66 | #include <libkern/OSByteOrder.h> | 66 | #include <libkern/OSByteOrder.h> |
| 67 | #define be16toh(x) OSSwapBigToHostInt16((x)) | 67 | #define be16toh(x) OSSwapBigToHostInt16((x)) |
| 68 | #define htobe16(x) OSSwapHostToBigInt16((x)) | 68 | #define htobe16(x) OSSwapHostToBigInt16((x)) |
| @@ -74,7 +74,7 @@ | |||
| 74 | #define htobe64(x) OSSwapHostToBigInt64(x) | 74 | #define htobe64(x) OSSwapHostToBigInt64(x) |
| 75 | #define le64toh(x) OSSwapLittleToHostInt64(x) | 75 | #define le64toh(x) OSSwapLittleToHostInt64(x) |
| 76 | #define be64toh(x) OSSwapBigToHostInt64(x) | 76 | #define be64toh(x) OSSwapBigToHostInt64(x) |
| 77 | #endif /* __APPLE__ && !HAVE_ENDIAN_H */ | 77 | #endif /* __APPLE__ */ |
| 78 | 78 | ||
| 79 | #if defined(_WIN32) && !defined(HAVE_ENDIAN_H) | 79 | #if defined(_WIN32) && !defined(HAVE_ENDIAN_H) |
| 80 | #include <winsock2.h> | 80 | #include <winsock2.h> |
| @@ -101,6 +101,8 @@ | |||
| 101 | #endif | 101 | #endif |
| 102 | 102 | ||
| 103 | #define htobe64(x) ntohll((x)) | 103 | #define htobe64(x) ntohll((x)) |
| 104 | #define htole64(x) (x) | ||
| 105 | #define le64toh(x) (x) | ||
| 104 | #endif /* _WIN32 && !HAVE_ENDIAN_H */ | 106 | #endif /* _WIN32 && !HAVE_ENDIAN_H */ |
| 105 | 107 | ||
| 106 | #ifdef __linux__ | 108 | #ifdef __linux__ |
| @@ -151,6 +153,8 @@ | |||
| 151 | #define htole32(x) LE_32(x) | 153 | #define htole32(x) LE_32(x) |
| 152 | #define htobe32(x) BE_32(x) | 154 | #define htobe32(x) BE_32(x) |
| 153 | #define be64toh(x) BE_64(x) | 155 | #define be64toh(x) BE_64(x) |
| 156 | #define le64toh(x) LE_64(x) | ||
| 157 | #define htole64(x) LE_64(x) | ||
| 154 | #define htobe64(x) BE_64(x) | 158 | #define htobe64(x) BE_64(x) |
| 155 | #endif | 159 | #endif |
| 156 | 160 | ||
diff --git a/include/compat/netinet/ip.h b/include/compat/netinet/ip.h index 29f17f3..100e006 100644 --- a/include/compat/netinet/ip.h +++ b/include/compat/netinet/ip.h | |||
| @@ -44,6 +44,10 @@ | |||
| 44 | #define IPTOS_DSCP_AF43 0x98 | 44 | #define IPTOS_DSCP_AF43 0x98 |
| 45 | #endif | 45 | #endif |
| 46 | 46 | ||
| 47 | #ifndef IPTOS_DSCP_VA | ||
| 48 | #define IPTOS_DSCP_VA 0xb0 | ||
| 49 | #endif | ||
| 50 | |||
| 47 | #ifndef IPTOS_DSCP_EF | 51 | #ifndef IPTOS_DSCP_EF |
| 48 | #define IPTOS_DSCP_EF 0xb8 | 52 | #define IPTOS_DSCP_EF 0xb8 |
| 49 | #endif | 53 | #endif |
diff --git a/include/compat/stdio.h b/include/compat/stdio.h index 2af8f3e..2ccdeeb 100644 --- a/include/compat/stdio.h +++ b/include/compat/stdio.h | |||
| @@ -18,6 +18,18 @@ | |||
| 18 | #include_next <stdio.h> | 18 | #include_next <stdio.h> |
| 19 | #endif | 19 | #endif |
| 20 | 20 | ||
| 21 | #ifndef HAVE_GETDELIM | ||
| 22 | #include <sys/types.h> | ||
| 23 | #define getdelim libressl_getdelim | ||
| 24 | ssize_t getdelim(char **buf, size_t *bufsiz, int delimiter, FILE *fp); | ||
| 25 | #endif | ||
| 26 | |||
| 27 | #ifndef HAVE_GETLINE | ||
| 28 | #include <sys/types.h> | ||
| 29 | #define getline libressl_getline | ||
| 30 | ssize_t getline(char **buf, size_t *bufsiz, FILE *fp); | ||
| 31 | #endif | ||
| 32 | |||
| 21 | #ifndef HAVE_ASPRINTF | 33 | #ifndef HAVE_ASPRINTF |
| 22 | #include <stdarg.h> | 34 | #include <stdarg.h> |
| 23 | #define vasprintf libressl_vasprintf | 35 | #define vasprintf libressl_vasprintf |
diff --git a/include/compat/sys/stat.h b/include/compat/sys/stat.h index b88da1d..57aa521 100644 --- a/include/compat/sys/stat.h +++ b/include/compat/sys/stat.h | |||
| @@ -118,4 +118,12 @@ | |||
| 118 | 118 | ||
| 119 | #endif | 119 | #endif |
| 120 | 120 | ||
| 121 | #ifdef _WIN32 | ||
| 122 | int libressl_fstat(int fd, struct stat *statbuf); | ||
| 123 | |||
| 124 | #ifndef NO_REDEF_POSIX_FUNCTIONS | ||
| 125 | #define fstat(fd, statbuf) libressl_fstat(fd, statbuf) | ||
| 126 | #endif | ||
| 127 | #endif | ||
| 128 | |||
| 121 | #endif | 129 | #endif |
diff --git a/include/compat/sys/time.h b/include/compat/sys/time.h index 76428c1..2448969 100644 --- a/include/compat/sys/time.h +++ b/include/compat/sys/time.h | |||
| @@ -8,6 +8,15 @@ | |||
| 8 | 8 | ||
| 9 | #ifdef _MSC_VER | 9 | #ifdef _MSC_VER |
| 10 | #include <winsock2.h> | 10 | #include <winsock2.h> |
| 11 | |||
| 12 | #define timeval libressl_timeval | ||
| 13 | #define gettimeofday libressl_gettimeofday | ||
| 14 | |||
| 15 | struct timeval { | ||
| 16 | long long tv_sec; | ||
| 17 | long tv_usec; | ||
| 18 | }; | ||
| 19 | |||
| 11 | int gettimeofday(struct timeval *tp, void *tzp); | 20 | int gettimeofday(struct timeval *tp, void *tzp); |
| 12 | #else | 21 | #else |
| 13 | #include_next <sys/time.h> | 22 | #include_next <sys/time.h> |
diff --git a/include/compat/unistd.h b/include/compat/unistd.h index 63c07fc..544cb27 100644 --- a/include/compat/unistd.h +++ b/include/compat/unistd.h | |||
| @@ -45,6 +45,8 @@ static inline unsigned int sleep(unsigned int seconds) | |||
| 45 | Sleep(seconds * 1000); | 45 | Sleep(seconds * 1000); |
| 46 | return seconds; | 46 | return seconds; |
| 47 | } | 47 | } |
| 48 | |||
| 49 | int mkstemp(char *template); | ||
| 48 | #endif | 50 | #endif |
| 49 | 51 | ||
| 50 | int ftruncate(int fd, off_t length); | 52 | int ftruncate(int fd, off_t length); |
diff --git a/include/openssl/Makefile.am.tpl b/include/openssl/Makefile.am.tpl index 303d0b9..1bea34d 100644 --- a/include/openssl/Makefile.am.tpl +++ b/include/openssl/Makefile.am.tpl | |||
| @@ -3,40 +3,4 @@ include $(top_srcdir)/Makefile.am.common | |||
| 3 | if !ENABLE_LIBTLS_ONLY | 3 | if !ENABLE_LIBTLS_ONLY |
| 4 | opensslincludedir=$(includedir)/openssl | 4 | opensslincludedir=$(includedir)/openssl |
| 5 | 5 | ||
| 6 | BUILT_SOURCES = opensslconf.h | 6 | opensslinclude_HEADERS = |
| 7 | CLEANFILES = opensslconf.h | ||
| 8 | |||
| 9 | opensslconf.h: Makefile | ||
| 10 | -echo "generating opensslconf.h ..." | ||
| 11 | if HOST_AARCH64 | ||
| 12 | -cp $(top_srcdir)/include/arch/aarch64/opensslconf.h opensslconf.h | ||
| 13 | endif | ||
| 14 | if HOST_ARM | ||
| 15 | -cp $(top_srcdir)/include/arch/arm/opensslconf.h opensslconf.h | ||
| 16 | endif | ||
| 17 | if HOST_I386 | ||
| 18 | -cp $(top_srcdir)/include/arch/i386/opensslconf.h opensslconf.h | ||
| 19 | endif | ||
| 20 | if HOST_MIPS | ||
| 21 | -cp $(top_srcdir)/include/arch/mips/opensslconf.h opensslconf.h | ||
| 22 | endif | ||
| 23 | if HOST_MIPS64 | ||
| 24 | -cp $(top_srcdir)/include/arch/mips64/opensslconf.h opensslconf.h | ||
| 25 | endif | ||
| 26 | if HOST_POWERPC | ||
| 27 | -cp $(top_srcdir)/include/arch/powerpc/opensslconf.h opensslconf.h | ||
| 28 | endif | ||
| 29 | if HOST_POWERPC64 | ||
| 30 | -cp $(top_srcdir)/include/arch/powerpc64/opensslconf.h opensslconf.h | ||
| 31 | endif | ||
| 32 | if HOST_RISCV64 | ||
| 33 | -cp $(top_srcdir)/include/arch/riscv64/opensslconf.h opensslconf.h | ||
| 34 | endif | ||
| 35 | if HOST_SPARC64 | ||
| 36 | -cp $(top_srcdir)/include/arch/sparc64/opensslconf.h opensslconf.h | ||
| 37 | endif | ||
| 38 | if HOST_X86_64 | ||
| 39 | -cp $(top_srcdir)/include/arch/amd64/opensslconf.h opensslconf.h | ||
| 40 | endif | ||
| 41 | |||
| 42 | opensslinclude_HEADERS = opensslconf.h | ||
diff --git a/libcrypto.pc.in b/libcrypto.pc.in index 11d7ef0..c11fbd3 100644 --- a/libcrypto.pc.in +++ b/libcrypto.pc.in | |||
| @@ -1,3 +1,18 @@ | |||
| 1 | # | ||
| 2 | # Copyright (c) 2014 Brent Cook | ||
| 3 | # | ||
| 4 | # Permission to use, copy, modify, and distribute this software for any | ||
| 5 | # purpose with or without fee is hereby granted, provided that the above | ||
| 6 | # copyright notice and this permission notice appear in all copies. | ||
| 7 | # | ||
| 8 | # THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES | ||
| 9 | # WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF | ||
| 10 | # MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR | ||
| 11 | # ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES | ||
| 12 | # WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN | ||
| 13 | # ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF | ||
| 14 | # OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. | ||
| 15 | # | ||
| 1 | #libcrypto pkg-config source file | 16 | #libcrypto pkg-config source file |
| 2 | 17 | ||
| 3 | prefix=@prefix@ | 18 | prefix=@prefix@ |
diff --git a/libssl.pc.in b/libssl.pc.in index 512ec1c..9d0d641 100644 --- a/libssl.pc.in +++ b/libssl.pc.in | |||
| @@ -1,3 +1,18 @@ | |||
| 1 | # | ||
| 2 | # Copyright (c) 2014 Brent Cook | ||
| 3 | # | ||
| 4 | # Permission to use, copy, modify, and distribute this software for any | ||
| 5 | # purpose with or without fee is hereby granted, provided that the above | ||
| 6 | # copyright notice and this permission notice appear in all copies. | ||
| 7 | # | ||
| 8 | # THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES | ||
| 9 | # WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF | ||
| 10 | # MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR | ||
| 11 | # ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES | ||
| 12 | # WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN | ||
| 13 | # ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF | ||
| 14 | # OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. | ||
| 15 | # | ||
| 1 | #libssl pkg-config source file | 16 | #libssl pkg-config source file |
| 2 | 17 | ||
| 3 | prefix=@prefix@ | 18 | prefix=@prefix@ |
diff --git a/libtls.pc.in b/libtls.pc.in index 3c49391..19c8134 100644 --- a/libtls.pc.in +++ b/libtls.pc.in | |||
| @@ -1,3 +1,18 @@ | |||
| 1 | # | ||
| 2 | # Copyright (c) 2014 Brent Cook | ||
| 3 | # | ||
| 4 | # Permission to use, copy, modify, and distribute this software for any | ||
| 5 | # purpose with or without fee is hereby granted, provided that the above | ||
| 6 | # copyright notice and this permission notice appear in all copies. | ||
| 7 | # | ||
| 8 | # THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES | ||
| 9 | # WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF | ||
| 10 | # MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR | ||
| 11 | # ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES | ||
| 12 | # WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN | ||
| 13 | # ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF | ||
| 14 | # OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. | ||
| 15 | # | ||
| 1 | #libtls pkg-config source file | 16 | #libtls pkg-config source file |
| 2 | 17 | ||
| 3 | prefix=@prefix@ | 18 | prefix=@prefix@ |
diff --git a/m4/check-libc.m4 b/m4/check-libc.m4 index 40df15b..eec3cb3 100644 --- a/m4/check-libc.m4 +++ b/m4/check-libc.m4 | |||
| @@ -1,3 +1,18 @@ | |||
| 1 | # | ||
| 2 | # Copyright (c) 2014 Brent Cook | ||
| 3 | # | ||
| 4 | # Permission to use, copy, modify, and distribute this software for any | ||
| 5 | # purpose with or without fee is hereby granted, provided that the above | ||
| 6 | # copyright notice and this permission notice appear in all copies. | ||
| 7 | # | ||
| 8 | # THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES | ||
| 9 | # WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF | ||
| 10 | # MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR | ||
| 11 | # ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES | ||
| 12 | # WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN | ||
| 13 | # ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF | ||
| 14 | # OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. | ||
| 15 | |||
| 1 | AC_DEFUN([CHECK_LIBC_COMPAT], [ | 16 | AC_DEFUN([CHECK_LIBC_COMPAT], [ |
| 2 | # Check for libc headers | 17 | # Check for libc headers |
| 3 | AC_CHECK_HEADERS([endian.h machine/endian.h err.h readpassphrase.h]) | 18 | AC_CHECK_HEADERS([endian.h machine/endian.h err.h readpassphrase.h]) |
| @@ -7,7 +22,7 @@ AC_CHECK_HEADERS([netinet/ip.h], [], [], | |||
| 7 | ]) | 22 | ]) |
| 8 | AC_HEADER_RESOLV | 23 | AC_HEADER_RESOLV |
| 9 | # Check for general libc functions | 24 | # Check for general libc functions |
| 10 | AC_CHECK_FUNCS([asprintf freezero memmem]) | 25 | AC_CHECK_FUNCS([asprintf freezero ftruncate getdelim getline memmem]) |
| 11 | AC_CHECK_FUNCS([readpassphrase reallocarray recallocarray]) | 26 | AC_CHECK_FUNCS([readpassphrase reallocarray recallocarray]) |
| 12 | AC_CHECK_FUNCS([strcasecmp strlcat strlcpy strndup strnlen strsep strtonum]) | 27 | AC_CHECK_FUNCS([strcasecmp strlcat strlcpy strndup strnlen strsep strtonum]) |
| 13 | AC_CHECK_FUNCS([timegm _mkgmtime timespecsub]) | 28 | AC_CHECK_FUNCS([timegm _mkgmtime timespecsub]) |
| @@ -24,6 +39,9 @@ AC_CACHE_CHECK([for getpagesize], ac_cv_func_getpagesize, [ | |||
| 24 | ]) | 39 | ]) |
| 25 | AM_CONDITIONAL([HAVE_ASPRINTF], [test "x$ac_cv_func_asprintf" = xyes]) | 40 | AM_CONDITIONAL([HAVE_ASPRINTF], [test "x$ac_cv_func_asprintf" = xyes]) |
| 26 | AM_CONDITIONAL([HAVE_FREEZERO], [test "x$ac_cv_func_freezero" = xyes]) | 41 | AM_CONDITIONAL([HAVE_FREEZERO], [test "x$ac_cv_func_freezero" = xyes]) |
| 42 | AM_CONDITIONAL([HAVE_FTRUNCATE], [test "x$ac_cv_func_ftruncate" = xyes]) | ||
| 43 | AM_CONDITIONAL([HAVE_GETDELIM], [test "x$ac_cv_func_getdelim" = xyes]) | ||
| 44 | AM_CONDITIONAL([HAVE_GETLINE], [test "x$ac_cv_func_getline" = xyes]) | ||
| 27 | AM_CONDITIONAL([HAVE_GETPAGESIZE], [test "x$ac_cv_func_getpagesize" = xyes]) | 45 | AM_CONDITIONAL([HAVE_GETPAGESIZE], [test "x$ac_cv_func_getpagesize" = xyes]) |
| 28 | AM_CONDITIONAL([HAVE_GETOPT], [test "x$ac_cv_func_getopt" = xyes]) | 46 | AM_CONDITIONAL([HAVE_GETOPT], [test "x$ac_cv_func_getopt" = xyes]) |
| 29 | AM_CONDITIONAL([HAVE_MEMMEM], [test "x$ac_cv_func_memmem" = xyes]) | 47 | AM_CONDITIONAL([HAVE_MEMMEM], [test "x$ac_cv_func_memmem" = xyes]) |
diff --git a/m4/check-os-options.m4 b/m4/check-os-options.m4 index 91c3021..99f142e 100644 --- a/m4/check-os-options.m4 +++ b/m4/check-os-options.m4 | |||
| @@ -1,3 +1,18 @@ | |||
| 1 | # | ||
| 2 | # Copyright (c) 2014 Brent Cook | ||
| 3 | # | ||
| 4 | # Permission to use, copy, modify, and distribute this software for any | ||
| 5 | # purpose with or without fee is hereby granted, provided that the above | ||
| 6 | # copyright notice and this permission notice appear in all copies. | ||
| 7 | # | ||
| 8 | # THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES | ||
| 9 | # WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF | ||
| 10 | # MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR | ||
| 11 | # ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES | ||
| 12 | # WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN | ||
| 13 | # ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF | ||
| 14 | # OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. | ||
| 15 | |||
| 1 | AC_DEFUN([CHECK_OS_OPTIONS], [ | 16 | AC_DEFUN([CHECK_OS_OPTIONS], [ |
| 2 | 17 | ||
| 3 | CFLAGS="$CFLAGS -Wall -std=gnu99 -fno-strict-aliasing" | 18 | CFLAGS="$CFLAGS -Wall -std=gnu99 -fno-strict-aliasing" |
| @@ -133,6 +148,7 @@ char buf[1]; getentropy(buf, 1); | |||
| 133 | ;; | 148 | ;; |
| 134 | *) | 149 | *) |
| 135 | HOST_OS=unsupported | 150 | HOST_OS=unsupported |
| 151 | HOST_ABI=elf | ||
| 136 | ;; | 152 | ;; |
| 137 | esac | 153 | esac |
| 138 | 154 | ||
diff --git a/m4/disable-compiler-warnings.m4 b/m4/disable-compiler-warnings.m4 index 2792722..052e8ab 100644 --- a/m4/disable-compiler-warnings.m4 +++ b/m4/disable-compiler-warnings.m4 | |||
| @@ -1,3 +1,18 @@ | |||
| 1 | # | ||
| 2 | # Copyright (c) 2014 Brent Cook | ||
| 3 | # | ||
| 4 | # Permission to use, copy, modify, and distribute this software for any | ||
| 5 | # purpose with or without fee is hereby granted, provided that the above | ||
| 6 | # copyright notice and this permission notice appear in all copies. | ||
| 7 | # | ||
| 8 | # THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES | ||
| 9 | # WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF | ||
| 10 | # MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR | ||
| 11 | # ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES | ||
| 12 | # WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN | ||
| 13 | # ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF | ||
| 14 | # OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. | ||
| 15 | |||
| 1 | AC_DEFUN([DISABLE_COMPILER_WARNINGS], [ | 16 | AC_DEFUN([DISABLE_COMPILER_WARNINGS], [ |
| 2 | # Clang throws a lot of warnings when it does not understand a flag. Disable | 17 | # Clang throws a lot of warnings when it does not understand a flag. Disable |
| 3 | # this warning for now so other warnings are visible. | 18 | # this warning for now so other warnings are visible. |
diff --git a/man/CMakeLists.txt b/man/CMakeLists.txt index 462a831..8f1121e 100644 --- a/man/CMakeLists.txt +++ b/man/CMakeLists.txt | |||
| @@ -1,3 +1,18 @@ | |||
| 1 | # | ||
| 2 | # Copyright (c) 2015 Jeff Davey | ||
| 3 | # | ||
| 4 | # Permission to use, copy, modify, and distribute this software for any | ||
| 5 | # purpose with or without fee is hereby granted, provided that the above | ||
| 6 | # copyright notice and this permission notice appear in all copies. | ||
| 7 | # | ||
| 8 | # THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES | ||
| 9 | # WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF | ||
| 10 | # MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR | ||
| 11 | # ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES | ||
| 12 | # WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN | ||
| 13 | # ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF | ||
| 14 | # OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. | ||
| 15 | |||
| 1 | if(ENABLE_LIBRESSL_INSTALL) | 16 | if(ENABLE_LIBRESSL_INSTALL) |
| 2 | install(DIRECTORY . | 17 | install(DIRECTORY . |
| 3 | DESTINATION ${CMAKE_INSTALL_MANDIR}/man3 | 18 | DESTINATION ${CMAKE_INSTALL_MANDIR}/man3 |
| @@ -185,9 +185,7 @@ BIO_ctrl.3,BIO_set_info_callback.3 | |||
| 185 | BIO_ctrl.3,BIO_tell.3 | 185 | BIO_ctrl.3,BIO_tell.3 |
| 186 | BIO_ctrl.3,BIO_wpending.3 | 186 | BIO_ctrl.3,BIO_wpending.3 |
| 187 | BIO_ctrl.3,bio_info_cb.3 | 187 | BIO_ctrl.3,bio_info_cb.3 |
| 188 | BIO_dump.3,BIO_dump_fp.3 | ||
| 189 | BIO_dump.3,BIO_dump_indent.3 | 188 | BIO_dump.3,BIO_dump_indent.3 |
| 190 | BIO_dump.3,BIO_dump_indent_fp.3 | ||
| 191 | BIO_dup_chain.3,BIO_dup_state.3 | 189 | BIO_dup_chain.3,BIO_dup_state.3 |
| 192 | BIO_f_buffer.3,BIO_get_buffer_num_lines.3 | 190 | BIO_f_buffer.3,BIO_get_buffer_num_lines.3 |
| 193 | BIO_f_buffer.3,BIO_set_buffer_read_data.3 | 191 | BIO_f_buffer.3,BIO_set_buffer_read_data.3 |
| @@ -514,12 +512,6 @@ CONF_modules_free.3,CONF_modules_finish.3 | |||
| 514 | CONF_modules_free.3,CONF_modules_unload.3 | 512 | CONF_modules_free.3,CONF_modules_unload.3 |
| 515 | CONF_modules_load_file.3,CONF_modules_load.3 | 513 | CONF_modules_load_file.3,CONF_modules_load.3 |
| 516 | CONF_modules_load_file.3,X509_get_default_cert_area.3 | 514 | CONF_modules_load_file.3,X509_get_default_cert_area.3 |
| 517 | CRYPTO_get_mem_functions.3,CRYPTO_MEM_LEAK_CB.3 | ||
| 518 | CRYPTO_get_mem_functions.3,CRYPTO_mem_ctrl.3 | ||
| 519 | CRYPTO_get_mem_functions.3,CRYPTO_mem_leaks.3 | ||
| 520 | CRYPTO_get_mem_functions.3,CRYPTO_mem_leaks_cb.3 | ||
| 521 | CRYPTO_get_mem_functions.3,CRYPTO_mem_leaks_fp.3 | ||
| 522 | CRYPTO_get_mem_functions.3,CRYPTO_set_mem_functions.3 | ||
| 523 | CRYPTO_lock.3,CRYPTO_add.3 | 515 | CRYPTO_lock.3,CRYPTO_add.3 |
| 524 | CRYPTO_lock.3,CRYPTO_r_lock.3 | 516 | CRYPTO_lock.3,CRYPTO_r_lock.3 |
| 525 | CRYPTO_lock.3,CRYPTO_r_unlock.3 | 517 | CRYPTO_lock.3,CRYPTO_r_unlock.3 |
| @@ -532,6 +524,11 @@ CRYPTO_set_ex_data.3,CRYPTO_free_ex_data.3 | |||
| 532 | CRYPTO_set_ex_data.3,CRYPTO_get_ex_data.3 | 524 | CRYPTO_set_ex_data.3,CRYPTO_get_ex_data.3 |
| 533 | CRYPTO_set_ex_data.3,CRYPTO_get_ex_new_index.3 | 525 | CRYPTO_set_ex_data.3,CRYPTO_get_ex_new_index.3 |
| 534 | CRYPTO_set_ex_data.3,CRYPTO_new_ex_data.3 | 526 | CRYPTO_set_ex_data.3,CRYPTO_new_ex_data.3 |
| 527 | CRYPTO_set_mem_functions.3,CRYPTO_MEM_LEAK_CB.3 | ||
| 528 | CRYPTO_set_mem_functions.3,CRYPTO_mem_ctrl.3 | ||
| 529 | CRYPTO_set_mem_functions.3,CRYPTO_mem_leaks.3 | ||
| 530 | CRYPTO_set_mem_functions.3,CRYPTO_mem_leaks_cb.3 | ||
| 531 | CRYPTO_set_mem_functions.3,CRYPTO_mem_leaks_fp.3 | ||
| 535 | ChaCha.3,CRYPTO_chacha_20.3 | 532 | ChaCha.3,CRYPTO_chacha_20.3 |
| 536 | ChaCha.3,CRYPTO_hchacha_20.3 | 533 | ChaCha.3,CRYPTO_hchacha_20.3 |
| 537 | ChaCha.3,CRYPTO_xchacha_20.3 | 534 | ChaCha.3,CRYPTO_xchacha_20.3 |
| @@ -645,40 +642,33 @@ ECDSA_SIG_new.3,ECDSA_size.3 | |||
| 645 | ECDSA_SIG_new.3,ECDSA_verify.3 | 642 | ECDSA_SIG_new.3,ECDSA_verify.3 |
| 646 | ECDSA_SIG_new.3,d2i_ECDSA_SIG.3 | 643 | ECDSA_SIG_new.3,d2i_ECDSA_SIG.3 |
| 647 | ECDSA_SIG_new.3,i2d_ECDSA_SIG.3 | 644 | ECDSA_SIG_new.3,i2d_ECDSA_SIG.3 |
| 648 | EC_GFp_simple_method.3,EC_GFp_mont_method.3 | 645 | EC_GROUP_check.3,EC_GROUP_check_discriminant.3 |
| 649 | EC_GFp_simple_method.3,EC_METHOD_get_field_type.3 | 646 | EC_GROUP_get_curve_name.3,EC_GROUP_get0_seed.3 |
| 650 | EC_GROUP_copy.3,EC_GROUP_check.3 | 647 | EC_GROUP_get_curve_name.3,EC_GROUP_get_asn1_flag.3 |
| 651 | EC_GROUP_copy.3,EC_GROUP_check_discriminant.3 | 648 | EC_GROUP_get_curve_name.3,EC_GROUP_get_basis_type.3 |
| 652 | EC_GROUP_copy.3,EC_GROUP_cmp.3 | 649 | EC_GROUP_get_curve_name.3,EC_GROUP_get_point_conversion_form.3 |
| 653 | EC_GROUP_copy.3,EC_GROUP_dup.3 | 650 | EC_GROUP_get_curve_name.3,EC_GROUP_get_seed_len.3 |
| 654 | EC_GROUP_copy.3,EC_GROUP_get0_generator.3 | 651 | EC_GROUP_get_curve_name.3,EC_GROUP_set_asn1_flag.3 |
| 655 | EC_GROUP_copy.3,EC_GROUP_get0_seed.3 | 652 | EC_GROUP_get_curve_name.3,EC_GROUP_set_curve_name.3 |
| 656 | EC_GROUP_copy.3,EC_GROUP_get_asn1_flag.3 | 653 | EC_GROUP_get_curve_name.3,EC_GROUP_set_point_conversion_form.3 |
| 657 | EC_GROUP_copy.3,EC_GROUP_get_basis_type.3 | 654 | EC_GROUP_get_curve_name.3,EC_GROUP_set_seed.3 |
| 658 | EC_GROUP_copy.3,EC_GROUP_get_cofactor.3 | 655 | EC_GROUP_new_by_curve_name.3,EC_GROUP_cmp.3 |
| 659 | EC_GROUP_copy.3,EC_GROUP_get_curve_name.3 | 656 | EC_GROUP_new_by_curve_name.3,EC_GROUP_dup.3 |
| 660 | EC_GROUP_copy.3,EC_GROUP_get_degree.3 | 657 | EC_GROUP_new_by_curve_name.3,EC_GROUP_free.3 |
| 661 | EC_GROUP_copy.3,EC_GROUP_get_order.3 | 658 | EC_GROUP_new_by_curve_name.3,EC_curve_nid2nist.3 |
| 662 | EC_GROUP_copy.3,EC_GROUP_get_point_conversion_form.3 | 659 | EC_GROUP_new_by_curve_name.3,EC_curve_nist2nid.3 |
| 663 | EC_GROUP_copy.3,EC_GROUP_get_seed_len.3 | 660 | EC_GROUP_new_by_curve_name.3,EC_get_builtin_curves.3 |
| 664 | EC_GROUP_copy.3,EC_GROUP_method_of.3 | 661 | EC_GROUP_new_curve_GFp.3,EC_GROUP_clear_free.3 |
| 665 | EC_GROUP_copy.3,EC_GROUP_order_bits.3 | 662 | EC_GROUP_new_curve_GFp.3,EC_GROUP_get0_generator.3 |
| 666 | EC_GROUP_copy.3,EC_GROUP_set_asn1_flag.3 | 663 | EC_GROUP_new_curve_GFp.3,EC_GROUP_get_cofactor.3 |
| 667 | EC_GROUP_copy.3,EC_GROUP_set_curve_name.3 | 664 | EC_GROUP_new_curve_GFp.3,EC_GROUP_get_curve.3 |
| 668 | EC_GROUP_copy.3,EC_GROUP_set_generator.3 | 665 | EC_GROUP_new_curve_GFp.3,EC_GROUP_get_curve_GFp.3 |
| 669 | EC_GROUP_copy.3,EC_GROUP_set_point_conversion_form.3 | 666 | EC_GROUP_new_curve_GFp.3,EC_GROUP_get_degree.3 |
| 670 | EC_GROUP_copy.3,EC_GROUP_set_seed.3 | 667 | EC_GROUP_new_curve_GFp.3,EC_GROUP_get_order.3 |
| 671 | EC_GROUP_new.3,EC_GROUP_clear_free.3 | 668 | EC_GROUP_new_curve_GFp.3,EC_GROUP_order_bits.3 |
| 672 | EC_GROUP_new.3,EC_GROUP_free.3 | 669 | EC_GROUP_new_curve_GFp.3,EC_GROUP_set_curve.3 |
| 673 | EC_GROUP_new.3,EC_GROUP_get_curve.3 | 670 | EC_GROUP_new_curve_GFp.3,EC_GROUP_set_curve_GFp.3 |
| 674 | EC_GROUP_new.3,EC_GROUP_get_curve_GFp.3 | 671 | EC_GROUP_new_curve_GFp.3,EC_GROUP_set_generator.3 |
| 675 | EC_GROUP_new.3,EC_GROUP_new_by_curve_name.3 | ||
| 676 | EC_GROUP_new.3,EC_GROUP_new_curve_GFp.3 | ||
| 677 | EC_GROUP_new.3,EC_GROUP_set_curve.3 | ||
| 678 | EC_GROUP_new.3,EC_GROUP_set_curve_GFp.3 | ||
| 679 | EC_GROUP_new.3,EC_curve_nid2nist.3 | ||
| 680 | EC_GROUP_new.3,EC_curve_nist2nid.3 | ||
| 681 | EC_GROUP_new.3,EC_get_builtin_curves.3 | ||
| 682 | EC_KEY_METHOD_new.3,EC_KEY_METHOD_free.3 | 672 | EC_KEY_METHOD_new.3,EC_KEY_METHOD_free.3 |
| 683 | EC_KEY_METHOD_new.3,EC_KEY_METHOD_get_compute_key.3 | 673 | EC_KEY_METHOD_new.3,EC_KEY_METHOD_get_compute_key.3 |
| 684 | EC_KEY_METHOD_new.3,EC_KEY_METHOD_get_init.3 | 674 | EC_KEY_METHOD_new.3,EC_KEY_METHOD_get_init.3 |
| @@ -721,8 +711,6 @@ EC_KEY_new.3,EC_KEY_set_private_key.3 | |||
| 721 | EC_KEY_new.3,EC_KEY_set_public_key.3 | 711 | EC_KEY_new.3,EC_KEY_set_public_key.3 |
| 722 | EC_KEY_new.3,EC_KEY_set_public_key_affine_coordinates.3 | 712 | EC_KEY_new.3,EC_KEY_set_public_key_affine_coordinates.3 |
| 723 | EC_KEY_new.3,EC_KEY_up_ref.3 | 713 | EC_KEY_new.3,EC_KEY_up_ref.3 |
| 724 | EC_POINT_add.3,EC_GROUP_have_precompute_mult.3 | ||
| 725 | EC_POINT_add.3,EC_GROUP_precompute_mult.3 | ||
| 726 | EC_POINT_add.3,EC_POINT_cmp.3 | 714 | EC_POINT_add.3,EC_POINT_cmp.3 |
| 727 | EC_POINT_add.3,EC_POINT_dbl.3 | 715 | EC_POINT_add.3,EC_POINT_dbl.3 |
| 728 | EC_POINT_add.3,EC_POINT_invert.3 | 716 | EC_POINT_add.3,EC_POINT_invert.3 |
| @@ -730,28 +718,21 @@ EC_POINT_add.3,EC_POINT_is_at_infinity.3 | |||
| 730 | EC_POINT_add.3,EC_POINT_is_on_curve.3 | 718 | EC_POINT_add.3,EC_POINT_is_on_curve.3 |
| 731 | EC_POINT_add.3,EC_POINT_make_affine.3 | 719 | EC_POINT_add.3,EC_POINT_make_affine.3 |
| 732 | EC_POINT_add.3,EC_POINT_mul.3 | 720 | EC_POINT_add.3,EC_POINT_mul.3 |
| 733 | EC_POINT_add.3,EC_POINTs_make_affine.3 | 721 | EC_POINT_get_affine_coordinates.3,EC_POINT_get_affine_coordinates_GFp.3 |
| 734 | EC_POINT_add.3,EC_POINTs_mul.3 | 722 | EC_POINT_get_affine_coordinates.3,EC_POINT_set_affine_coordinates.3 |
| 735 | EC_POINT_new.3,EC_POINT_bn2point.3 | 723 | EC_POINT_get_affine_coordinates.3,EC_POINT_set_affine_coordinates_GFp.3 |
| 724 | EC_POINT_get_affine_coordinates.3,EC_POINT_set_compressed_coordinates.3 | ||
| 725 | EC_POINT_get_affine_coordinates.3,EC_POINT_set_compressed_coordinates_GFp.3 | ||
| 726 | EC_POINT_get_affine_coordinates.3,EC_POINT_set_to_infinity.3 | ||
| 736 | EC_POINT_new.3,EC_POINT_clear_free.3 | 727 | EC_POINT_new.3,EC_POINT_clear_free.3 |
| 737 | EC_POINT_new.3,EC_POINT_copy.3 | 728 | EC_POINT_new.3,EC_POINT_copy.3 |
| 738 | EC_POINT_new.3,EC_POINT_dup.3 | 729 | EC_POINT_new.3,EC_POINT_dup.3 |
| 739 | EC_POINT_new.3,EC_POINT_free.3 | 730 | EC_POINT_new.3,EC_POINT_free.3 |
| 740 | EC_POINT_new.3,EC_POINT_get_Jprojective_coordinates_GFp.3 | 731 | EC_POINT_point2oct.3,EC_POINT_bn2point.3 |
| 741 | EC_POINT_new.3,EC_POINT_get_affine_coordinates.3 | 732 | EC_POINT_point2oct.3,EC_POINT_hex2point.3 |
| 742 | EC_POINT_new.3,EC_POINT_get_affine_coordinates_GFp.3 | 733 | EC_POINT_point2oct.3,EC_POINT_oct2point.3 |
| 743 | EC_POINT_new.3,EC_POINT_hex2point.3 | 734 | EC_POINT_point2oct.3,EC_POINT_point2bn.3 |
| 744 | EC_POINT_new.3,EC_POINT_method_of.3 | 735 | EC_POINT_point2oct.3,EC_POINT_point2hex.3 |
| 745 | EC_POINT_new.3,EC_POINT_oct2point.3 | ||
| 746 | EC_POINT_new.3,EC_POINT_point2bn.3 | ||
| 747 | EC_POINT_new.3,EC_POINT_point2hex.3 | ||
| 748 | EC_POINT_new.3,EC_POINT_point2oct.3 | ||
| 749 | EC_POINT_new.3,EC_POINT_set_Jprojective_coordinates_GFp.3 | ||
| 750 | EC_POINT_new.3,EC_POINT_set_affine_coordinates.3 | ||
| 751 | EC_POINT_new.3,EC_POINT_set_affine_coordinates_GFp.3 | ||
| 752 | EC_POINT_new.3,EC_POINT_set_compressed_coordinates.3 | ||
| 753 | EC_POINT_new.3,EC_POINT_set_compressed_coordinates_GFp.3 | ||
| 754 | EC_POINT_new.3,EC_POINT_set_to_infinity.3 | ||
| 755 | ENGINE_new.3,ENGINE_by_id.3 | 736 | ENGINE_new.3,ENGINE_by_id.3 |
| 756 | ENGINE_new.3,ENGINE_cleanup.3 | 737 | ENGINE_new.3,ENGINE_cleanup.3 |
| 757 | ENGINE_new.3,ENGINE_ctrl_cmd.3 | 738 | ENGINE_new.3,ENGINE_ctrl_cmd.3 |
| @@ -791,8 +772,6 @@ ERR_load_strings.3,ERR_PACK.3 | |||
| 791 | ERR_load_strings.3,ERR_get_next_error_library.3 | 772 | ERR_load_strings.3,ERR_get_next_error_library.3 |
| 792 | ERR_print_errors.3,ERR_print_errors_cb.3 | 773 | ERR_print_errors.3,ERR_print_errors_cb.3 |
| 793 | ERR_print_errors.3,ERR_print_errors_fp.3 | 774 | ERR_print_errors.3,ERR_print_errors_fp.3 |
| 794 | ERR_put_error.3,ERR_add_error_data.3 | ||
| 795 | ERR_put_error.3,ERR_add_error_vdata.3 | ||
| 796 | ERR_remove_state.3,ERR_remove_thread_state.3 | 775 | ERR_remove_state.3,ERR_remove_thread_state.3 |
| 797 | ERR_set_mark.3,ERR_pop_to_mark.3 | 776 | ERR_set_mark.3,ERR_pop_to_mark.3 |
| 798 | ESS_SIGNING_CERT_new.3,ESS_CERT_ID_free.3 | 777 | ESS_SIGNING_CERT_new.3,ESS_CERT_ID_free.3 |
| @@ -938,13 +917,6 @@ EVP_EncryptInit.3,EVP_idea_cfb.3 | |||
| 938 | EVP_EncryptInit.3,EVP_idea_cfb64.3 | 917 | EVP_EncryptInit.3,EVP_idea_cfb64.3 |
| 939 | EVP_EncryptInit.3,EVP_idea_ecb.3 | 918 | EVP_EncryptInit.3,EVP_idea_ecb.3 |
| 940 | EVP_EncryptInit.3,EVP_idea_ofb.3 | 919 | EVP_EncryptInit.3,EVP_idea_ofb.3 |
| 941 | EVP_EncryptInit.3,EVP_rc2_40_cbc.3 | ||
| 942 | EVP_EncryptInit.3,EVP_rc2_64_cbc.3 | ||
| 943 | EVP_EncryptInit.3,EVP_rc2_cbc.3 | ||
| 944 | EVP_EncryptInit.3,EVP_rc2_cfb.3 | ||
| 945 | EVP_EncryptInit.3,EVP_rc2_cfb64.3 | ||
| 946 | EVP_EncryptInit.3,EVP_rc2_ecb.3 | ||
| 947 | EVP_EncryptInit.3,EVP_rc2_ofb.3 | ||
| 948 | EVP_MD_CTX_ctrl.3,EVP_MD_CTX_clear_flags.3 | 920 | EVP_MD_CTX_ctrl.3,EVP_MD_CTX_clear_flags.3 |
| 949 | EVP_MD_CTX_ctrl.3,EVP_MD_CTX_md_data.3 | 921 | EVP_MD_CTX_ctrl.3,EVP_MD_CTX_md_data.3 |
| 950 | EVP_MD_CTX_ctrl.3,EVP_MD_CTX_pkey_ctx.3 | 922 | EVP_MD_CTX_ctrl.3,EVP_MD_CTX_pkey_ctx.3 |
| @@ -992,32 +964,13 @@ EVP_PKEY_CTX_set_hkdf_md.3,EVP_PKEY_CTX_add1_hkdf_info.3 | |||
| 992 | EVP_PKEY_CTX_set_hkdf_md.3,EVP_PKEY_CTX_hkdf_mode.3 | 964 | EVP_PKEY_CTX_set_hkdf_md.3,EVP_PKEY_CTX_hkdf_mode.3 |
| 993 | EVP_PKEY_CTX_set_hkdf_md.3,EVP_PKEY_CTX_set1_hkdf_key.3 | 965 | EVP_PKEY_CTX_set_hkdf_md.3,EVP_PKEY_CTX_set1_hkdf_key.3 |
| 994 | EVP_PKEY_CTX_set_hkdf_md.3,EVP_PKEY_CTX_set1_hkdf_salt.3 | 966 | EVP_PKEY_CTX_set_hkdf_md.3,EVP_PKEY_CTX_set1_hkdf_salt.3 |
| 995 | EVP_PKEY_add1_attr.3,EVP_PKEY_add1_attr_by_NID.3 | 967 | EVP_PKEY_CTX_set_tls1_prf_md.3,EVP_PKEY_CTX_add1_tls1_prf_seed.3 |
| 996 | EVP_PKEY_add1_attr.3,EVP_PKEY_add1_attr_by_OBJ.3 | 968 | EVP_PKEY_CTX_set_tls1_prf_md.3,EVP_PKEY_CTX_set1_tls1_prf_secret.3 |
| 997 | EVP_PKEY_add1_attr.3,EVP_PKEY_add1_attr_by_txt.3 | ||
| 998 | EVP_PKEY_add1_attr.3,EVP_PKEY_delete_attr.3 | ||
| 999 | EVP_PKEY_add1_attr.3,EVP_PKEY_get_attr.3 | ||
| 1000 | EVP_PKEY_add1_attr.3,EVP_PKEY_get_attr_by_NID.3 | ||
| 1001 | EVP_PKEY_add1_attr.3,EVP_PKEY_get_attr_by_OBJ.3 | ||
| 1002 | EVP_PKEY_add1_attr.3,EVP_PKEY_get_attr_count.3 | ||
| 1003 | EVP_PKEY_asn1_get_count.3,EVP_PKEY_asn1_find.3 | 969 | EVP_PKEY_asn1_get_count.3,EVP_PKEY_asn1_find.3 |
| 1004 | EVP_PKEY_asn1_get_count.3,EVP_PKEY_asn1_find_str.3 | 970 | EVP_PKEY_asn1_get_count.3,EVP_PKEY_asn1_find_str.3 |
| 1005 | EVP_PKEY_asn1_get_count.3,EVP_PKEY_asn1_get0.3 | 971 | EVP_PKEY_asn1_get_count.3,EVP_PKEY_asn1_get0.3 |
| 1006 | EVP_PKEY_asn1_get_count.3,EVP_PKEY_asn1_get0_info.3 | 972 | EVP_PKEY_asn1_get_count.3,EVP_PKEY_asn1_get0_info.3 |
| 1007 | EVP_PKEY_asn1_get_count.3,EVP_PKEY_get0_asn1.3 | 973 | EVP_PKEY_asn1_get_count.3,EVP_PKEY_get0_asn1.3 |
| 1008 | EVP_PKEY_asn1_new.3,EVP_PKEY_asn1_copy.3 | ||
| 1009 | EVP_PKEY_asn1_new.3,EVP_PKEY_asn1_free.3 | ||
| 1010 | EVP_PKEY_asn1_new.3,EVP_PKEY_asn1_set_check.3 | ||
| 1011 | EVP_PKEY_asn1_new.3,EVP_PKEY_asn1_set_ctrl.3 | ||
| 1012 | EVP_PKEY_asn1_new.3,EVP_PKEY_asn1_set_free.3 | ||
| 1013 | EVP_PKEY_asn1_new.3,EVP_PKEY_asn1_set_param.3 | ||
| 1014 | EVP_PKEY_asn1_new.3,EVP_PKEY_asn1_set_param_check.3 | ||
| 1015 | EVP_PKEY_asn1_new.3,EVP_PKEY_asn1_set_private.3 | ||
| 1016 | EVP_PKEY_asn1_new.3,EVP_PKEY_asn1_set_public.3 | ||
| 1017 | EVP_PKEY_asn1_new.3,EVP_PKEY_asn1_set_public_check.3 | ||
| 1018 | EVP_PKEY_asn1_new.3,EVP_PKEY_asn1_set_security_bits.3 | ||
| 1019 | EVP_PKEY_check.3,EVP_PKEY_param_check.3 | ||
| 1020 | EVP_PKEY_check.3,EVP_PKEY_public_check.3 | ||
| 1021 | EVP_PKEY_cmp.3,EVP_PKEY_cmp_parameters.3 | 974 | EVP_PKEY_cmp.3,EVP_PKEY_cmp_parameters.3 |
| 1022 | EVP_PKEY_cmp.3,EVP_PKEY_copy_parameters.3 | 975 | EVP_PKEY_cmp.3,EVP_PKEY_copy_parameters.3 |
| 1023 | EVP_PKEY_cmp.3,EVP_PKEY_missing_parameters.3 | 976 | EVP_PKEY_cmp.3,EVP_PKEY_missing_parameters.3 |
| @@ -1028,41 +981,19 @@ EVP_PKEY_derive.3,EVP_PKEY_derive_set_peer.3 | |||
| 1028 | EVP_PKEY_encrypt.3,EVP_PKEY_encrypt_init.3 | 981 | EVP_PKEY_encrypt.3,EVP_PKEY_encrypt_init.3 |
| 1029 | EVP_PKEY_keygen.3,EVP_PKEY_CTX_get_app_data.3 | 982 | EVP_PKEY_keygen.3,EVP_PKEY_CTX_get_app_data.3 |
| 1030 | EVP_PKEY_keygen.3,EVP_PKEY_CTX_get_cb.3 | 983 | EVP_PKEY_keygen.3,EVP_PKEY_CTX_get_cb.3 |
| 984 | EVP_PKEY_keygen.3,EVP_PKEY_CTX_get_data.3 | ||
| 1031 | EVP_PKEY_keygen.3,EVP_PKEY_CTX_get_keygen_info.3 | 985 | EVP_PKEY_keygen.3,EVP_PKEY_CTX_get_keygen_info.3 |
| 1032 | EVP_PKEY_keygen.3,EVP_PKEY_CTX_set0_keygen_info.3 | 986 | EVP_PKEY_keygen.3,EVP_PKEY_CTX_set0_keygen_info.3 |
| 1033 | EVP_PKEY_keygen.3,EVP_PKEY_CTX_set_app_data.3 | 987 | EVP_PKEY_keygen.3,EVP_PKEY_CTX_set_app_data.3 |
| 1034 | EVP_PKEY_keygen.3,EVP_PKEY_CTX_set_cb.3 | 988 | EVP_PKEY_keygen.3,EVP_PKEY_CTX_set_cb.3 |
| 989 | EVP_PKEY_keygen.3,EVP_PKEY_CTX_set_data.3 | ||
| 1035 | EVP_PKEY_keygen.3,EVP_PKEY_gen_cb.3 | 990 | EVP_PKEY_keygen.3,EVP_PKEY_gen_cb.3 |
| 1036 | EVP_PKEY_keygen.3,EVP_PKEY_keygen_init.3 | 991 | EVP_PKEY_keygen.3,EVP_PKEY_keygen_init.3 |
| 1037 | EVP_PKEY_keygen.3,EVP_PKEY_paramgen.3 | 992 | EVP_PKEY_keygen.3,EVP_PKEY_paramgen.3 |
| 1038 | EVP_PKEY_keygen.3,EVP_PKEY_paramgen_init.3 | 993 | EVP_PKEY_keygen.3,EVP_PKEY_paramgen_init.3 |
| 1039 | EVP_PKEY_meth_new.3,EVP_PKEY_CTX_get_data.3 | ||
| 1040 | EVP_PKEY_meth_new.3,EVP_PKEY_CTX_set_data.3 | ||
| 1041 | EVP_PKEY_meth_new.3,EVP_PKEY_meth_add0.3 | ||
| 1042 | EVP_PKEY_meth_new.3,EVP_PKEY_meth_copy.3 | ||
| 1043 | EVP_PKEY_meth_new.3,EVP_PKEY_meth_find.3 | ||
| 1044 | EVP_PKEY_meth_new.3,EVP_PKEY_meth_free.3 | ||
| 1045 | EVP_PKEY_meth_new.3,EVP_PKEY_meth_set_check.3 | ||
| 1046 | EVP_PKEY_meth_new.3,EVP_PKEY_meth_set_cleanup.3 | ||
| 1047 | EVP_PKEY_meth_new.3,EVP_PKEY_meth_set_copy.3 | ||
| 1048 | EVP_PKEY_meth_new.3,EVP_PKEY_meth_set_ctrl.3 | ||
| 1049 | EVP_PKEY_meth_new.3,EVP_PKEY_meth_set_decrypt.3 | ||
| 1050 | EVP_PKEY_meth_new.3,EVP_PKEY_meth_set_derive.3 | ||
| 1051 | EVP_PKEY_meth_new.3,EVP_PKEY_meth_set_encrypt.3 | ||
| 1052 | EVP_PKEY_meth_new.3,EVP_PKEY_meth_set_init.3 | ||
| 1053 | EVP_PKEY_meth_new.3,EVP_PKEY_meth_set_keygen.3 | ||
| 1054 | EVP_PKEY_meth_new.3,EVP_PKEY_meth_set_param_check.3 | ||
| 1055 | EVP_PKEY_meth_new.3,EVP_PKEY_meth_set_paramgen.3 | ||
| 1056 | EVP_PKEY_meth_new.3,EVP_PKEY_meth_set_public_check.3 | ||
| 1057 | EVP_PKEY_meth_new.3,EVP_PKEY_meth_set_sign.3 | ||
| 1058 | EVP_PKEY_meth_new.3,EVP_PKEY_meth_set_signctx.3 | ||
| 1059 | EVP_PKEY_meth_new.3,EVP_PKEY_meth_set_verify.3 | ||
| 1060 | EVP_PKEY_meth_new.3,EVP_PKEY_meth_set_verify_recover.3 | ||
| 1061 | EVP_PKEY_meth_new.3,EVP_PKEY_meth_set_verifyctx.3 | ||
| 1062 | EVP_PKEY_new.3,EVP_PKEY_free.3 | 994 | EVP_PKEY_new.3,EVP_PKEY_free.3 |
| 1063 | EVP_PKEY_new.3,EVP_PKEY_get_raw_private_key.3 | 995 | EVP_PKEY_new.3,EVP_PKEY_get_raw_private_key.3 |
| 1064 | EVP_PKEY_new.3,EVP_PKEY_get_raw_public_key.3 | 996 | EVP_PKEY_new.3,EVP_PKEY_get_raw_public_key.3 |
| 1065 | EVP_PKEY_new.3,EVP_PKEY_new_CMAC_key.3 | ||
| 1066 | EVP_PKEY_new.3,EVP_PKEY_new_mac_key.3 | 997 | EVP_PKEY_new.3,EVP_PKEY_new_mac_key.3 |
| 1067 | EVP_PKEY_new.3,EVP_PKEY_new_raw_private_key.3 | 998 | EVP_PKEY_new.3,EVP_PKEY_new_raw_private_key.3 |
| 1068 | EVP_PKEY_new.3,EVP_PKEY_new_raw_public_key.3 | 999 | EVP_PKEY_new.3,EVP_PKEY_new_raw_public_key.3 |
| @@ -1106,41 +1037,39 @@ EVP_VerifyInit.3,EVP_VerifyFinal.3 | |||
| 1106 | EVP_VerifyInit.3,EVP_VerifyInit_ex.3 | 1037 | EVP_VerifyInit.3,EVP_VerifyInit_ex.3 |
| 1107 | EVP_VerifyInit.3,EVP_VerifyUpdate.3 | 1038 | EVP_VerifyInit.3,EVP_VerifyUpdate.3 |
| 1108 | EVP_aes_128_cbc.3,EVP_aes_128_cbc_hmac_sha1.3 | 1039 | EVP_aes_128_cbc.3,EVP_aes_128_cbc_hmac_sha1.3 |
| 1109 | EVP_aes_128_cbc.3,EVP_aes_128_ccm.3 | ||
| 1110 | EVP_aes_128_cbc.3,EVP_aes_128_cfb.3 | 1040 | EVP_aes_128_cbc.3,EVP_aes_128_cfb.3 |
| 1111 | EVP_aes_128_cbc.3,EVP_aes_128_cfb1.3 | 1041 | EVP_aes_128_cbc.3,EVP_aes_128_cfb1.3 |
| 1112 | EVP_aes_128_cbc.3,EVP_aes_128_cfb128.3 | 1042 | EVP_aes_128_cbc.3,EVP_aes_128_cfb128.3 |
| 1113 | EVP_aes_128_cbc.3,EVP_aes_128_cfb8.3 | 1043 | EVP_aes_128_cbc.3,EVP_aes_128_cfb8.3 |
| 1114 | EVP_aes_128_cbc.3,EVP_aes_128_ctr.3 | 1044 | EVP_aes_128_cbc.3,EVP_aes_128_ctr.3 |
| 1115 | EVP_aes_128_cbc.3,EVP_aes_128_ecb.3 | 1045 | EVP_aes_128_cbc.3,EVP_aes_128_ecb.3 |
| 1116 | EVP_aes_128_cbc.3,EVP_aes_128_gcm.3 | ||
| 1117 | EVP_aes_128_cbc.3,EVP_aes_128_ofb.3 | 1046 | EVP_aes_128_cbc.3,EVP_aes_128_ofb.3 |
| 1118 | EVP_aes_128_cbc.3,EVP_aes_128_wrap.3 | 1047 | EVP_aes_128_cbc.3,EVP_aes_128_wrap.3 |
| 1119 | EVP_aes_128_cbc.3,EVP_aes_128_xts.3 | 1048 | EVP_aes_128_cbc.3,EVP_aes_128_xts.3 |
| 1120 | EVP_aes_128_cbc.3,EVP_aes_192_cbc.3 | 1049 | EVP_aes_128_cbc.3,EVP_aes_192_cbc.3 |
| 1121 | EVP_aes_128_cbc.3,EVP_aes_192_ccm.3 | ||
| 1122 | EVP_aes_128_cbc.3,EVP_aes_192_cfb.3 | 1050 | EVP_aes_128_cbc.3,EVP_aes_192_cfb.3 |
| 1123 | EVP_aes_128_cbc.3,EVP_aes_192_cfb1.3 | 1051 | EVP_aes_128_cbc.3,EVP_aes_192_cfb1.3 |
| 1124 | EVP_aes_128_cbc.3,EVP_aes_192_cfb128.3 | 1052 | EVP_aes_128_cbc.3,EVP_aes_192_cfb128.3 |
| 1125 | EVP_aes_128_cbc.3,EVP_aes_192_cfb8.3 | 1053 | EVP_aes_128_cbc.3,EVP_aes_192_cfb8.3 |
| 1126 | EVP_aes_128_cbc.3,EVP_aes_192_ctr.3 | 1054 | EVP_aes_128_cbc.3,EVP_aes_192_ctr.3 |
| 1127 | EVP_aes_128_cbc.3,EVP_aes_192_ecb.3 | 1055 | EVP_aes_128_cbc.3,EVP_aes_192_ecb.3 |
| 1128 | EVP_aes_128_cbc.3,EVP_aes_192_gcm.3 | ||
| 1129 | EVP_aes_128_cbc.3,EVP_aes_192_ofb.3 | 1056 | EVP_aes_128_cbc.3,EVP_aes_192_ofb.3 |
| 1130 | EVP_aes_128_cbc.3,EVP_aes_192_wrap.3 | 1057 | EVP_aes_128_cbc.3,EVP_aes_192_wrap.3 |
| 1131 | EVP_aes_128_cbc.3,EVP_aes_256_cbc.3 | 1058 | EVP_aes_128_cbc.3,EVP_aes_256_cbc.3 |
| 1132 | EVP_aes_128_cbc.3,EVP_aes_256_cbc_hmac_sha1.3 | 1059 | EVP_aes_128_cbc.3,EVP_aes_256_cbc_hmac_sha1.3 |
| 1133 | EVP_aes_128_cbc.3,EVP_aes_256_ccm.3 | ||
| 1134 | EVP_aes_128_cbc.3,EVP_aes_256_cfb.3 | 1060 | EVP_aes_128_cbc.3,EVP_aes_256_cfb.3 |
| 1135 | EVP_aes_128_cbc.3,EVP_aes_256_cfb1.3 | 1061 | EVP_aes_128_cbc.3,EVP_aes_256_cfb1.3 |
| 1136 | EVP_aes_128_cbc.3,EVP_aes_256_cfb128.3 | 1062 | EVP_aes_128_cbc.3,EVP_aes_256_cfb128.3 |
| 1137 | EVP_aes_128_cbc.3,EVP_aes_256_cfb8.3 | 1063 | EVP_aes_128_cbc.3,EVP_aes_256_cfb8.3 |
| 1138 | EVP_aes_128_cbc.3,EVP_aes_256_ctr.3 | 1064 | EVP_aes_128_cbc.3,EVP_aes_256_ctr.3 |
| 1139 | EVP_aes_128_cbc.3,EVP_aes_256_ecb.3 | 1065 | EVP_aes_128_cbc.3,EVP_aes_256_ecb.3 |
| 1140 | EVP_aes_128_cbc.3,EVP_aes_256_gcm.3 | ||
| 1141 | EVP_aes_128_cbc.3,EVP_aes_256_ofb.3 | 1066 | EVP_aes_128_cbc.3,EVP_aes_256_ofb.3 |
| 1142 | EVP_aes_128_cbc.3,EVP_aes_256_wrap.3 | 1067 | EVP_aes_128_cbc.3,EVP_aes_256_wrap.3 |
| 1143 | EVP_aes_128_cbc.3,EVP_aes_256_xts.3 | 1068 | EVP_aes_128_cbc.3,EVP_aes_256_xts.3 |
| 1069 | EVP_aes_128_ccm.3,EVP_aes_192_ccm.3 | ||
| 1070 | EVP_aes_128_ccm.3,EVP_aes_256_ccm.3 | ||
| 1071 | EVP_aes_128_gcm.3,EVP_aes_192_gcm.3 | ||
| 1072 | EVP_aes_128_gcm.3,EVP_aes_256_gcm.3 | ||
| 1144 | EVP_camellia_128_cbc.3,EVP_camellia_128_cfb.3 | 1073 | EVP_camellia_128_cbc.3,EVP_camellia_128_cfb.3 |
| 1145 | EVP_camellia_128_cbc.3,EVP_camellia_128_cfb1.3 | 1074 | EVP_camellia_128_cbc.3,EVP_camellia_128_cfb1.3 |
| 1146 | EVP_camellia_128_cbc.3,EVP_camellia_128_cfb128.3 | 1075 | EVP_camellia_128_cbc.3,EVP_camellia_128_cfb128.3 |
| @@ -1183,6 +1112,12 @@ EVP_des_cbc.3,EVP_des_ede_ecb.3 | |||
| 1183 | EVP_des_cbc.3,EVP_des_ede_ofb.3 | 1112 | EVP_des_cbc.3,EVP_des_ede_ofb.3 |
| 1184 | EVP_des_cbc.3,EVP_des_ofb.3 | 1113 | EVP_des_cbc.3,EVP_des_ofb.3 |
| 1185 | EVP_des_cbc.3,EVP_desx_cbc.3 | 1114 | EVP_des_cbc.3,EVP_desx_cbc.3 |
| 1115 | EVP_rc2_cbc.3,EVP_rc2_40_cbc.3 | ||
| 1116 | EVP_rc2_cbc.3,EVP_rc2_64_cbc.3 | ||
| 1117 | EVP_rc2_cbc.3,EVP_rc2_cfb.3 | ||
| 1118 | EVP_rc2_cbc.3,EVP_rc2_cfb64.3 | ||
| 1119 | EVP_rc2_cbc.3,EVP_rc2_ecb.3 | ||
| 1120 | EVP_rc2_cbc.3,EVP_rc2_ofb.3 | ||
| 1186 | EVP_rc4.3,EVP_rc4_40.3 | 1121 | EVP_rc4.3,EVP_rc4_40.3 |
| 1187 | EVP_rc4.3,EVP_rc4_hmac_md5.3 | 1122 | EVP_rc4.3,EVP_rc4_hmac_md5.3 |
| 1188 | EVP_sha1.3,EVP_md4.3 | 1123 | EVP_sha1.3,EVP_md4.3 |
| @@ -1211,7 +1146,6 @@ HMAC.3,HMAC_CTX_new.3 | |||
| 1211 | HMAC.3,HMAC_CTX_reset.3 | 1146 | HMAC.3,HMAC_CTX_reset.3 |
| 1212 | HMAC.3,HMAC_CTX_set_flags.3 | 1147 | HMAC.3,HMAC_CTX_set_flags.3 |
| 1213 | HMAC.3,HMAC_Final.3 | 1148 | HMAC.3,HMAC_Final.3 |
| 1214 | HMAC.3,HMAC_Init.3 | ||
| 1215 | HMAC.3,HMAC_Init_ex.3 | 1149 | HMAC.3,HMAC_Init_ex.3 |
| 1216 | HMAC.3,HMAC_Update.3 | 1150 | HMAC.3,HMAC_Update.3 |
| 1217 | HMAC.3,HMAC_size.3 | 1151 | HMAC.3,HMAC_size.3 |
| @@ -1240,11 +1174,6 @@ MD5.3,MD5_Update.3 | |||
| 1240 | NAME_CONSTRAINTS_new.3,GENERAL_SUBTREE_free.3 | 1174 | NAME_CONSTRAINTS_new.3,GENERAL_SUBTREE_free.3 |
| 1241 | NAME_CONSTRAINTS_new.3,GENERAL_SUBTREE_new.3 | 1175 | NAME_CONSTRAINTS_new.3,GENERAL_SUBTREE_new.3 |
| 1242 | NAME_CONSTRAINTS_new.3,NAME_CONSTRAINTS_free.3 | 1176 | NAME_CONSTRAINTS_new.3,NAME_CONSTRAINTS_free.3 |
| 1243 | OBJ_NAME_add.3,OBJ_NAME_cleanup.3 | ||
| 1244 | OBJ_NAME_add.3,OBJ_NAME_get.3 | ||
| 1245 | OBJ_NAME_add.3,OBJ_NAME_init.3 | ||
| 1246 | OBJ_NAME_add.3,OBJ_NAME_new_index.3 | ||
| 1247 | OBJ_NAME_add.3,OBJ_NAME_remove.3 | ||
| 1248 | OBJ_create.3,OBJ_add_object.3 | 1177 | OBJ_create.3,OBJ_add_object.3 |
| 1249 | OBJ_create.3,OBJ_cleanup.3 | 1178 | OBJ_create.3,OBJ_cleanup.3 |
| 1250 | OBJ_create.3,OBJ_create_objects.3 | 1179 | OBJ_create.3,OBJ_create_objects.3 |
| @@ -1329,7 +1258,6 @@ OPENSSL_VERSION_NUMBER.3,SSLeay.3 | |||
| 1329 | OPENSSL_VERSION_NUMBER.3,SSLeay_version.3 | 1258 | OPENSSL_VERSION_NUMBER.3,SSLeay_version.3 |
| 1330 | OPENSSL_config.3,OPENSSL_no_config.3 | 1259 | OPENSSL_config.3,OPENSSL_no_config.3 |
| 1331 | OPENSSL_init_crypto.3,OPENSSL_init.3 | 1260 | OPENSSL_init_crypto.3,OPENSSL_init.3 |
| 1332 | OPENSSL_load_builtin_modules.3,ASN1_add_oid_module.3 | ||
| 1333 | OPENSSL_malloc.3,CRYPTO_free.3 | 1261 | OPENSSL_malloc.3,CRYPTO_free.3 |
| 1334 | OPENSSL_malloc.3,CRYPTO_malloc.3 | 1262 | OPENSSL_malloc.3,CRYPTO_malloc.3 |
| 1335 | OPENSSL_malloc.3,CRYPTO_strdup.3 | 1263 | OPENSSL_malloc.3,CRYPTO_strdup.3 |
| @@ -1361,7 +1289,6 @@ OpenSSL_add_all_algorithms.3,OpenSSL_add_all_digests.3 | |||
| 1361 | OpenSSL_add_all_algorithms.3,SSLeay_add_all_algorithms.3 | 1289 | OpenSSL_add_all_algorithms.3,SSLeay_add_all_algorithms.3 |
| 1362 | PEM_ASN1_read.3,PEM_ASN1_read_bio.3 | 1290 | PEM_ASN1_read.3,PEM_ASN1_read_bio.3 |
| 1363 | PEM_ASN1_read.3,d2i_of_void.3 | 1291 | PEM_ASN1_read.3,d2i_of_void.3 |
| 1364 | PEM_X509_INFO_read.3,PEM_X509_INFO_read_bio.3 | ||
| 1365 | PEM_read.3,PEM_def_callback.3 | 1292 | PEM_read.3,PEM_def_callback.3 |
| 1366 | PEM_read.3,PEM_do_header.3 | 1293 | PEM_read.3,PEM_do_header.3 |
| 1367 | PEM_read.3,PEM_get_EVP_CIPHER_INFO.3 | 1294 | PEM_read.3,PEM_get_EVP_CIPHER_INFO.3 |
| @@ -1522,6 +1449,12 @@ RAND_load_file.3,RAND_file_name.3 | |||
| 1522 | RAND_load_file.3,RAND_write_file.3 | 1449 | RAND_load_file.3,RAND_write_file.3 |
| 1523 | RAND_set_rand_method.3,RAND_SSLeay.3 | 1450 | RAND_set_rand_method.3,RAND_SSLeay.3 |
| 1524 | RAND_set_rand_method.3,RAND_get_rand_method.3 | 1451 | RAND_set_rand_method.3,RAND_get_rand_method.3 |
| 1452 | RC2_encrypt.3,RC2_cbc_encrypt.3 | ||
| 1453 | RC2_encrypt.3,RC2_cfb64_encrypt.3 | ||
| 1454 | RC2_encrypt.3,RC2_decrypt.3 | ||
| 1455 | RC2_encrypt.3,RC2_ecb_encrypt.3 | ||
| 1456 | RC2_encrypt.3,RC2_ofb64_encrypt.3 | ||
| 1457 | RC2_encrypt.3,RC2_set_key.3 | ||
| 1525 | RC4.3,RC4_set_key.3 | 1458 | RC4.3,RC4_set_key.3 |
| 1526 | RIPEMD160.3,RIPEMD160_Final.3 | 1459 | RIPEMD160.3,RIPEMD160_Final.3 |
| 1527 | RIPEMD160.3,RIPEMD160_Init.3 | 1460 | RIPEMD160.3,RIPEMD160_Init.3 |
| @@ -1651,6 +1584,7 @@ SSL_CIPHER_get_name.3,SSL_CIPHER_get_auth_nid.3 | |||
| 1651 | SSL_CIPHER_get_name.3,SSL_CIPHER_get_bits.3 | 1584 | SSL_CIPHER_get_name.3,SSL_CIPHER_get_bits.3 |
| 1652 | SSL_CIPHER_get_name.3,SSL_CIPHER_get_cipher_nid.3 | 1585 | SSL_CIPHER_get_name.3,SSL_CIPHER_get_cipher_nid.3 |
| 1653 | SSL_CIPHER_get_name.3,SSL_CIPHER_get_digest_nid.3 | 1586 | SSL_CIPHER_get_name.3,SSL_CIPHER_get_digest_nid.3 |
| 1587 | SSL_CIPHER_get_name.3,SSL_CIPHER_get_handshake_digest.3 | ||
| 1654 | SSL_CIPHER_get_name.3,SSL_CIPHER_get_id.3 | 1588 | SSL_CIPHER_get_name.3,SSL_CIPHER_get_id.3 |
| 1655 | SSL_CIPHER_get_name.3,SSL_CIPHER_get_kx_nid.3 | 1589 | SSL_CIPHER_get_name.3,SSL_CIPHER_get_kx_nid.3 |
| 1656 | SSL_CIPHER_get_name.3,SSL_CIPHER_get_version.3 | 1590 | SSL_CIPHER_get_name.3,SSL_CIPHER_get_version.3 |
| @@ -1739,6 +1673,7 @@ SSL_CTX_set_alpn_select_cb.3,SSL_get0_alpn_selected.3 | |||
| 1739 | SSL_CTX_set_alpn_select_cb.3,SSL_select_next_proto.3 | 1673 | SSL_CTX_set_alpn_select_cb.3,SSL_select_next_proto.3 |
| 1740 | SSL_CTX_set_alpn_select_cb.3,SSL_set_alpn_protos.3 | 1674 | SSL_CTX_set_alpn_select_cb.3,SSL_set_alpn_protos.3 |
| 1741 | SSL_CTX_set_cert_store.3,SSL_CTX_get_cert_store.3 | 1675 | SSL_CTX_set_cert_store.3,SSL_CTX_get_cert_store.3 |
| 1676 | SSL_CTX_set_cert_store.3,SSL_CTX_set1_cert_store.3 | ||
| 1742 | SSL_CTX_set_cipher_list.3,SSL_set_cipher_list.3 | 1677 | SSL_CTX_set_cipher_list.3,SSL_set_cipher_list.3 |
| 1743 | SSL_CTX_set_client_CA_list.3,SSL_CTX_add_client_CA.3 | 1678 | SSL_CTX_set_client_CA_list.3,SSL_CTX_add_client_CA.3 |
| 1744 | SSL_CTX_set_client_CA_list.3,SSL_add_client_CA.3 | 1679 | SSL_CTX_set_client_CA_list.3,SSL_add_client_CA.3 |
| @@ -1859,6 +1794,7 @@ SSL_SESSION_get_time.3,SSL_get_timeout.3 | |||
| 1859 | SSL_SESSION_get_time.3,SSL_set_time.3 | 1794 | SSL_SESSION_get_time.3,SSL_set_time.3 |
| 1860 | SSL_SESSION_get_time.3,SSL_set_timeout.3 | 1795 | SSL_SESSION_get_time.3,SSL_set_timeout.3 |
| 1861 | SSL_SESSION_has_ticket.3,SSL_SESSION_get_ticket_lifetime_hint.3 | 1796 | SSL_SESSION_has_ticket.3,SSL_SESSION_get_ticket_lifetime_hint.3 |
| 1797 | SSL_SESSION_new.3,SSL_SESSION_dup.3 | ||
| 1862 | SSL_SESSION_print.3,SSL_SESSION_print_fp.3 | 1798 | SSL_SESSION_print.3,SSL_SESSION_print_fp.3 |
| 1863 | SSL_SESSION_set1_id_context.3,SSL_SESSION_get0_id_context.3 | 1799 | SSL_SESSION_set1_id_context.3,SSL_SESSION_get0_id_context.3 |
| 1864 | SSL_alert_type_string.3,SSL_alert_desc_string.3 | 1800 | SSL_alert_type_string.3,SSL_alert_desc_string.3 |
| @@ -1947,7 +1883,6 @@ TS_REQ_new.3,TS_STATUS_INFO_free.3 | |||
| 1947 | TS_REQ_new.3,TS_STATUS_INFO_new.3 | 1883 | TS_REQ_new.3,TS_STATUS_INFO_new.3 |
| 1948 | TS_REQ_new.3,TS_TST_INFO_free.3 | 1884 | TS_REQ_new.3,TS_TST_INFO_free.3 |
| 1949 | TS_REQ_new.3,TS_TST_INFO_new.3 | 1885 | TS_REQ_new.3,TS_TST_INFO_new.3 |
| 1950 | UI_UTIL_read_pw.3,UI_UTIL_read_pw_string.3 | ||
| 1951 | UI_create_method.3,UI_destroy_method.3 | 1886 | UI_create_method.3,UI_destroy_method.3 |
| 1952 | UI_create_method.3,UI_method_get_closer.3 | 1887 | UI_create_method.3,UI_method_get_closer.3 |
| 1953 | UI_create_method.3,UI_method_get_flusher.3 | 1888 | UI_create_method.3,UI_method_get_flusher.3 |
| @@ -1998,6 +1933,7 @@ X25519.3,ED25519_sign.3 | |||
| 1998 | X25519.3,ED25519_verify.3 | 1933 | X25519.3,ED25519_verify.3 |
| 1999 | X25519.3,X25519_keypair.3 | 1934 | X25519.3,X25519_keypair.3 |
| 2000 | X509V3_EXT_get_nid.3,X509V3_EXT_get.3 | 1935 | X509V3_EXT_get_nid.3,X509V3_EXT_get.3 |
| 1936 | X509V3_EXT_print.3,X509V3_EXT_print_fp.3 | ||
| 2001 | X509V3_get_d2i.3,X509V3_EXT_d2i.3 | 1937 | X509V3_get_d2i.3,X509V3_EXT_d2i.3 |
| 2002 | X509V3_get_d2i.3,X509V3_EXT_i2d.3 | 1938 | X509V3_get_d2i.3,X509V3_EXT_i2d.3 |
| 2003 | X509V3_get_d2i.3,X509V3_add1_i2d.3 | 1939 | X509V3_get_d2i.3,X509V3_add1_i2d.3 |
| @@ -2011,6 +1947,7 @@ X509V3_get_d2i.3,X509_add1_ext_i2d.3 | |||
| 2011 | X509V3_get_d2i.3,X509_get0_extensions.3 | 1947 | X509V3_get_d2i.3,X509_get0_extensions.3 |
| 2012 | X509V3_get_d2i.3,X509_get0_uids.3 | 1948 | X509V3_get_d2i.3,X509_get0_uids.3 |
| 2013 | X509V3_get_d2i.3,X509_get_ext_d2i.3 | 1949 | X509V3_get_d2i.3,X509_get_ext_d2i.3 |
| 1950 | X509V3_parse_list.3,X509V3_conf_free.3 | ||
| 2014 | X509_ALGOR_dup.3,X509_ALGOR_cmp.3 | 1951 | X509_ALGOR_dup.3,X509_ALGOR_cmp.3 |
| 2015 | X509_ALGOR_dup.3,X509_ALGOR_free.3 | 1952 | X509_ALGOR_dup.3,X509_ALGOR_free.3 |
| 2016 | X509_ALGOR_dup.3,X509_ALGOR_get0.3 | 1953 | X509_ALGOR_dup.3,X509_ALGOR_get0.3 |
| @@ -2051,6 +1988,7 @@ X509_EXTENSION_set_object.3,X509_EXTENSION_get_object.3 | |||
| 2051 | X509_EXTENSION_set_object.3,X509_EXTENSION_new.3 | 1988 | X509_EXTENSION_set_object.3,X509_EXTENSION_new.3 |
| 2052 | X509_EXTENSION_set_object.3,X509_EXTENSION_set_critical.3 | 1989 | X509_EXTENSION_set_object.3,X509_EXTENSION_set_critical.3 |
| 2053 | X509_EXTENSION_set_object.3,X509_EXTENSION_set_data.3 | 1990 | X509_EXTENSION_set_object.3,X509_EXTENSION_set_data.3 |
| 1991 | X509_EXTENSION_set_object.3,X509_supported_extension.3 | ||
| 2054 | X509_INFO_new.3,X509_INFO_free.3 | 1992 | X509_INFO_new.3,X509_INFO_free.3 |
| 2055 | X509_LOOKUP_hash_dir.3,X509_LOOKUP_file.3 | 1993 | X509_LOOKUP_hash_dir.3,X509_LOOKUP_file.3 |
| 2056 | X509_LOOKUP_hash_dir.3,X509_LOOKUP_mem.3 | 1994 | X509_LOOKUP_hash_dir.3,X509_LOOKUP_mem.3 |
| @@ -2088,18 +2026,14 @@ X509_NAME_hash.3,X509_subject_name_hash.3 | |||
| 2088 | X509_NAME_hash.3,X509_subject_name_hash_old.3 | 2026 | X509_NAME_hash.3,X509_subject_name_hash_old.3 |
| 2089 | X509_NAME_new.3,X509_NAME_free.3 | 2027 | X509_NAME_new.3,X509_NAME_free.3 |
| 2090 | X509_NAME_print_ex.3,X509_NAME_oneline.3 | 2028 | X509_NAME_print_ex.3,X509_NAME_oneline.3 |
| 2091 | X509_NAME_print_ex.3,X509_NAME_print.3 | ||
| 2092 | X509_NAME_print_ex.3,X509_NAME_print_ex_fp.3 | 2029 | X509_NAME_print_ex.3,X509_NAME_print_ex_fp.3 |
| 2093 | X509_OBJECT_get0_X509.3,X509_OBJECT_free.3 | 2030 | X509_OBJECT_get0_X509.3,X509_OBJECT_free.3 |
| 2094 | X509_OBJECT_get0_X509.3,X509_OBJECT_free_contents.3 | ||
| 2095 | X509_OBJECT_get0_X509.3,X509_OBJECT_get0_X509_CRL.3 | 2031 | X509_OBJECT_get0_X509.3,X509_OBJECT_get0_X509_CRL.3 |
| 2096 | X509_OBJECT_get0_X509.3,X509_OBJECT_get_type.3 | 2032 | X509_OBJECT_get0_X509.3,X509_OBJECT_get_type.3 |
| 2097 | X509_OBJECT_get0_X509.3,X509_OBJECT_idx_by_subject.3 | 2033 | X509_OBJECT_get0_X509.3,X509_OBJECT_idx_by_subject.3 |
| 2098 | X509_OBJECT_get0_X509.3,X509_OBJECT_new.3 | 2034 | X509_OBJECT_get0_X509.3,X509_OBJECT_new.3 |
| 2099 | X509_OBJECT_get0_X509.3,X509_OBJECT_retrieve_by_subject.3 | 2035 | X509_OBJECT_get0_X509.3,X509_OBJECT_retrieve_by_subject.3 |
| 2100 | X509_OBJECT_get0_X509.3,X509_OBJECT_retrieve_match.3 | 2036 | X509_OBJECT_get0_X509.3,X509_OBJECT_retrieve_match.3 |
| 2101 | X509_OBJECT_get0_X509.3,X509_OBJECT_up_ref_count.3 | ||
| 2102 | X509_PKEY_new.3,X509_PKEY_free.3 | ||
| 2103 | X509_PUBKEY_new.3,X509_PUBKEY_free.3 | 2037 | X509_PUBKEY_new.3,X509_PUBKEY_free.3 |
| 2104 | X509_PUBKEY_new.3,X509_PUBKEY_get.3 | 2038 | X509_PUBKEY_new.3,X509_PUBKEY_get.3 |
| 2105 | X509_PUBKEY_new.3,X509_PUBKEY_get0.3 | 2039 | X509_PUBKEY_new.3,X509_PUBKEY_get0.3 |
| @@ -2134,9 +2068,7 @@ X509_REQ_add1_attr.3,X509_REQ_get_attr_by_OBJ.3 | |||
| 2134 | X509_REQ_add1_attr.3,X509_REQ_get_attr_count.3 | 2068 | X509_REQ_add1_attr.3,X509_REQ_get_attr_count.3 |
| 2135 | X509_REQ_add_extensions.3,X509_REQ_add_extensions_nid.3 | 2069 | X509_REQ_add_extensions.3,X509_REQ_add_extensions_nid.3 |
| 2136 | X509_REQ_add_extensions.3,X509_REQ_extension_nid.3 | 2070 | X509_REQ_add_extensions.3,X509_REQ_extension_nid.3 |
| 2137 | X509_REQ_add_extensions.3,X509_REQ_get_extension_nids.3 | ||
| 2138 | X509_REQ_add_extensions.3,X509_REQ_get_extensions.3 | 2071 | X509_REQ_add_extensions.3,X509_REQ_get_extensions.3 |
| 2139 | X509_REQ_add_extensions.3,X509_REQ_set_extension_nids.3 | ||
| 2140 | X509_REQ_new.3,X509_REQ_INFO_free.3 | 2072 | X509_REQ_new.3,X509_REQ_INFO_free.3 |
| 2141 | X509_REQ_new.3,X509_REQ_INFO_new.3 | 2073 | X509_REQ_new.3,X509_REQ_INFO_new.3 |
| 2142 | X509_REQ_new.3,X509_REQ_dup.3 | 2074 | X509_REQ_new.3,X509_REQ_dup.3 |
| @@ -2226,14 +2158,6 @@ X509_STORE_set1_param.3,X509_STORE_set_purpose.3 | |||
| 2226 | X509_STORE_set1_param.3,X509_STORE_set_trust.3 | 2158 | X509_STORE_set1_param.3,X509_STORE_set_trust.3 |
| 2227 | X509_STORE_set_verify_cb_func.3,X509_STORE_get_verify_cb.3 | 2159 | X509_STORE_set_verify_cb_func.3,X509_STORE_get_verify_cb.3 |
| 2228 | X509_STORE_set_verify_cb_func.3,X509_STORE_set_verify_cb.3 | 2160 | X509_STORE_set_verify_cb_func.3,X509_STORE_set_verify_cb.3 |
| 2229 | X509_TRUST_set.3,X509_TRUST_add.3 | ||
| 2230 | X509_TRUST_set.3,X509_TRUST_cleanup.3 | ||
| 2231 | X509_TRUST_set.3,X509_TRUST_get0.3 | ||
| 2232 | X509_TRUST_set.3,X509_TRUST_get0_name.3 | ||
| 2233 | X509_TRUST_set.3,X509_TRUST_get_by_id.3 | ||
| 2234 | X509_TRUST_set.3,X509_TRUST_get_count.3 | ||
| 2235 | X509_TRUST_set.3,X509_TRUST_get_flags.3 | ||
| 2236 | X509_TRUST_set.3,X509_TRUST_get_trust.3 | ||
| 2237 | X509_VERIFY_PARAM_new.3,X509_VERIFY_PARAM_add0_table.3 | 2161 | X509_VERIFY_PARAM_new.3,X509_VERIFY_PARAM_add0_table.3 |
| 2238 | X509_VERIFY_PARAM_new.3,X509_VERIFY_PARAM_free.3 | 2162 | X509_VERIFY_PARAM_new.3,X509_VERIFY_PARAM_free.3 |
| 2239 | X509_VERIFY_PARAM_new.3,X509_VERIFY_PARAM_get0.3 | 2163 | X509_VERIFY_PARAM_new.3,X509_VERIFY_PARAM_get0.3 |
| @@ -2249,6 +2173,7 @@ X509_VERIFY_PARAM_set_flags.3,X509_VERIFY_PARAM_get0_name.3 | |||
| 2249 | X509_VERIFY_PARAM_set_flags.3,X509_VERIFY_PARAM_get0_peername.3 | 2173 | X509_VERIFY_PARAM_set_flags.3,X509_VERIFY_PARAM_get0_peername.3 |
| 2250 | X509_VERIFY_PARAM_set_flags.3,X509_VERIFY_PARAM_get_depth.3 | 2174 | X509_VERIFY_PARAM_set_flags.3,X509_VERIFY_PARAM_get_depth.3 |
| 2251 | X509_VERIFY_PARAM_set_flags.3,X509_VERIFY_PARAM_get_flags.3 | 2175 | X509_VERIFY_PARAM_set_flags.3,X509_VERIFY_PARAM_get_flags.3 |
| 2176 | X509_VERIFY_PARAM_set_flags.3,X509_VERIFY_PARAM_get_hostflags.3 | ||
| 2252 | X509_VERIFY_PARAM_set_flags.3,X509_VERIFY_PARAM_get_time.3 | 2177 | X509_VERIFY_PARAM_set_flags.3,X509_VERIFY_PARAM_get_time.3 |
| 2253 | X509_VERIFY_PARAM_set_flags.3,X509_VERIFY_PARAM_set1_email.3 | 2178 | X509_VERIFY_PARAM_set_flags.3,X509_VERIFY_PARAM_set1_email.3 |
| 2254 | X509_VERIFY_PARAM_set_flags.3,X509_VERIFY_PARAM_set1_host.3 | 2179 | X509_VERIFY_PARAM_set_flags.3,X509_VERIFY_PARAM_set1_host.3 |
| @@ -2269,7 +2194,6 @@ X509_check_host.3,X509_check_email.3 | |||
| 2269 | X509_check_host.3,X509_check_ip.3 | 2194 | X509_check_host.3,X509_check_ip.3 |
| 2270 | X509_check_host.3,X509_check_ip_asc.3 | 2195 | X509_check_host.3,X509_check_ip_asc.3 |
| 2271 | X509_check_private_key.3,X509_REQ_check_private_key.3 | 2196 | X509_check_private_key.3,X509_REQ_check_private_key.3 |
| 2272 | X509_check_trust.3,X509_TRUST_set_default.3 | ||
| 2273 | X509_cmp.3,X509_CRL_cmp.3 | 2197 | X509_cmp.3,X509_CRL_cmp.3 |
| 2274 | X509_cmp.3,X509_CRL_match.3 | 2198 | X509_cmp.3,X509_CRL_match.3 |
| 2275 | X509_cmp.3,X509_NAME_cmp.3 | 2199 | X509_cmp.3,X509_NAME_cmp.3 |
| @@ -2309,6 +2233,7 @@ X509_get0_signature.3,X509_CRL_get_signature_nid.3 | |||
| 2309 | X509_get0_signature.3,X509_REQ_get0_signature.3 | 2233 | X509_get0_signature.3,X509_REQ_get0_signature.3 |
| 2310 | X509_get0_signature.3,X509_REQ_get_signature_nid.3 | 2234 | X509_get0_signature.3,X509_REQ_get_signature_nid.3 |
| 2311 | X509_get0_signature.3,X509_get0_tbs_sigalg.3 | 2235 | X509_get0_signature.3,X509_get0_tbs_sigalg.3 |
| 2236 | X509_get0_signature.3,X509_get_signature_info.3 | ||
| 2312 | X509_get0_signature.3,X509_get_signature_nid.3 | 2237 | X509_get0_signature.3,X509_get_signature_nid.3 |
| 2313 | X509_get0_signature.3,X509_get_signature_type.3 | 2238 | X509_get0_signature.3,X509_get_signature_type.3 |
| 2314 | X509_get1_email.3,X509_email_free.3 | 2239 | X509_get1_email.3,X509_email_free.3 |
| @@ -2361,14 +2286,6 @@ X509_sign.3,X509_REQ_verify.3 | |||
| 2361 | X509_sign.3,X509_sign_ctx.3 | 2286 | X509_sign.3,X509_sign_ctx.3 |
| 2362 | X509_sign.3,X509_verify.3 | 2287 | X509_sign.3,X509_verify.3 |
| 2363 | X509_signature_dump.3,X509_signature_print.3 | 2288 | X509_signature_dump.3,X509_signature_print.3 |
| 2364 | X509at_add1_attr.3,X509at_add1_attr_by_NID.3 | ||
| 2365 | X509at_add1_attr.3,X509at_add1_attr_by_OBJ.3 | ||
| 2366 | X509at_add1_attr.3,X509at_add1_attr_by_txt.3 | ||
| 2367 | X509at_add1_attr.3,X509at_delete_attr.3 | ||
| 2368 | X509at_get_attr.3,X509at_get0_data_by_OBJ.3 | ||
| 2369 | X509at_get_attr.3,X509at_get_attr_by_NID.3 | ||
| 2370 | X509at_get_attr.3,X509at_get_attr_by_OBJ.3 | ||
| 2371 | X509at_get_attr.3,X509at_get_attr_count.3 | ||
| 2372 | X509v3_addr_add_inherit.3,X509v3_addr_add_prefix.3 | 2289 | X509v3_addr_add_inherit.3,X509v3_addr_add_prefix.3 |
| 2373 | X509v3_addr_add_inherit.3,X509v3_addr_add_range.3 | 2290 | X509v3_addr_add_inherit.3,X509v3_addr_add_range.3 |
| 2374 | X509v3_addr_add_inherit.3,X509v3_addr_canonize.3 | 2291 | X509v3_addr_add_inherit.3,X509v3_addr_canonize.3 |
| @@ -2409,19 +2326,8 @@ X509v3_get_ext_by_NID.3,X509v3_get_ext.3 | |||
| 2409 | X509v3_get_ext_by_NID.3,X509v3_get_ext_by_OBJ.3 | 2326 | X509v3_get_ext_by_NID.3,X509v3_get_ext_by_OBJ.3 |
| 2410 | X509v3_get_ext_by_NID.3,X509v3_get_ext_by_critical.3 | 2327 | X509v3_get_ext_by_NID.3,X509v3_get_ext_by_critical.3 |
| 2411 | X509v3_get_ext_by_NID.3,X509v3_get_ext_count.3 | 2328 | X509v3_get_ext_by_NID.3,X509v3_get_ext_count.3 |
| 2412 | bn_dump.3,bn_add_words.3 | 2329 | a2i_ipadd.3,a2i_IPADDRESS.3 |
| 2413 | bn_dump.3,bn_div_words.3 | 2330 | a2i_ipadd.3,a2i_IPADDRESS_NC.3 |
| 2414 | bn_dump.3,bn_expand.3 | ||
| 2415 | bn_dump.3,bn_mul_add_words.3 | ||
| 2416 | bn_dump.3,bn_mul_comba4.3 | ||
| 2417 | bn_dump.3,bn_mul_comba8.3 | ||
| 2418 | bn_dump.3,bn_mul_normal.3 | ||
| 2419 | bn_dump.3,bn_mul_words.3 | ||
| 2420 | bn_dump.3,bn_sqr_comba4.3 | ||
| 2421 | bn_dump.3,bn_sqr_comba8.3 | ||
| 2422 | bn_dump.3,bn_sqr_words.3 | ||
| 2423 | bn_dump.3,bn_sub_words.3 | ||
| 2424 | bn_dump.3,bn_wexpand.3 | ||
| 2425 | d2i_ASN1_NULL.3,i2d_ASN1_NULL.3 | 2331 | d2i_ASN1_NULL.3,i2d_ASN1_NULL.3 |
| 2426 | d2i_ASN1_OBJECT.3,OBJ_get0_data.3 | 2332 | d2i_ASN1_OBJECT.3,OBJ_get0_data.3 |
| 2427 | d2i_ASN1_OBJECT.3,OBJ_length.3 | 2333 | d2i_ASN1_OBJECT.3,OBJ_length.3 |
| @@ -2790,6 +2696,7 @@ tls_conn_version.3,tls_conn_cipher_strength.3 | |||
| 2790 | tls_conn_version.3,tls_conn_servername.3 | 2696 | tls_conn_version.3,tls_conn_servername.3 |
| 2791 | tls_conn_version.3,tls_conn_session_resumed.3 | 2697 | tls_conn_version.3,tls_conn_session_resumed.3 |
| 2792 | tls_conn_version.3,tls_peer_cert_chain_pem.3 | 2698 | tls_conn_version.3,tls_peer_cert_chain_pem.3 |
| 2699 | tls_conn_version.3,tls_peer_cert_common_name.3 | ||
| 2793 | tls_conn_version.3,tls_peer_cert_contains_name.3 | 2700 | tls_conn_version.3,tls_peer_cert_contains_name.3 |
| 2794 | tls_conn_version.3,tls_peer_cert_hash.3 | 2701 | tls_conn_version.3,tls_peer_cert_hash.3 |
| 2795 | tls_conn_version.3,tls_peer_cert_issuer.3 | 2702 | tls_conn_version.3,tls_peer_cert_issuer.3 |
| @@ -2841,6 +2748,7 @@ tls_read.3,tls_close.3 | |||
| 2841 | tls_read.3,tls_error.3 | 2748 | tls_read.3,tls_error.3 |
| 2842 | tls_read.3,tls_handshake.3 | 2749 | tls_read.3,tls_handshake.3 |
| 2843 | tls_read.3,tls_write.3 | 2750 | tls_read.3,tls_write.3 |
| 2751 | v2i_ASN1_BIT_STRING.3,i2v_ASN1_BIT_STRING.3 | ||
| 2844 | x509_verify.3,x509_verify_ctx_chain.3 | 2752 | x509_verify.3,x509_verify_ctx_chain.3 |
| 2845 | x509_verify.3,x509_verify_ctx_error_depth.3 | 2753 | x509_verify.3,x509_verify_ctx_error_depth.3 |
| 2846 | x509_verify.3,x509_verify_ctx_error_string.3 | 2754 | x509_verify.3,x509_verify_ctx_error_string.3 |
diff --git a/patches/crypto_namespace.h.patch b/patches/crypto_namespace.h.patch deleted file mode 100644 index c18f0da..0000000 --- a/patches/crypto_namespace.h.patch +++ /dev/null | |||
| @@ -1,22 +0,0 @@ | |||
| 1 | --- crypto/hidden/crypto_namespace.h.orig 2024-04-09 10:12:22.320737957 +0200 | ||
| 2 | +++ crypto/hidden/crypto_namespace.h 2024-04-11 09:09:31.163350515 +0200 | ||
| 3 | @@ -24,6 +24,12 @@ | ||
| 4 | * external calls use the latter name. | ||
| 5 | */ | ||
| 6 | |||
| 7 | +#ifdef _MSC_VER | ||
| 8 | +# define LCRYPTO_UNUSED(x) | ||
| 9 | +# define LCRYPTO_USED(x) | ||
| 10 | +# define LCRYPTO_ALIAS1(pre, x) | ||
| 11 | +# define LCRYPTO_ALIAS(x) | ||
| 12 | +#else | ||
| 13 | #ifdef LIBRESSL_NAMESPACE | ||
| 14 | #ifdef LIBRESSL_CRYPTO_NAMESPACE | ||
| 15 | # define LCRYPTO_UNUSED(x) __attribute__((deprecated)) \ | ||
| 16 | @@ -43,5 +49,6 @@ | ||
| 17 | # define LCRYPTO_ALIAS1(pre,x) | ||
| 18 | # define LCRYPTO_ALIAS(x) asm("") | ||
| 19 | #endif | ||
| 20 | +#endif /* _MSC_VER */ | ||
| 21 | |||
| 22 | #endif /* _LIBCRYPTO_CRYPTO_NAMESPACE_H_ */ | ||
diff --git a/patches/mlkem_internal.h.patch b/patches/mlkem_internal.h.patch new file mode 100644 index 0000000..ee25521 --- /dev/null +++ b/patches/mlkem_internal.h.patch | |||
| @@ -0,0 +1,11 @@ | |||
| 1 | --- crypto/mlkem/mlkem_internal.h.orig Fri Oct 24 07:06:10 2025 | ||
| 2 | +++ crypto/mlkem/mlkem_internal.h Fri Oct 24 07:06:22 2025 | ||
| 3 | @@ -20,7 +20,7 @@ | ||
| 4 | #define OPENSSL_HEADER_CRYPTO_MLKEM_INTERNAL_H | ||
| 5 | |||
| 6 | #include "bytestring.h" | ||
| 7 | -#include "mlkem.h" | ||
| 8 | +#include <openssl/mlkem.h> | ||
| 9 | |||
| 10 | #if defined(__cplusplus) | ||
| 11 | extern "C" { | ||
diff --git a/patches/modes_local.h.patch b/patches/modes_local.h.patch deleted file mode 100644 index 1ff799b..0000000 --- a/patches/modes_local.h.patch +++ /dev/null | |||
| @@ -1,18 +0,0 @@ | |||
| 1 | --- crypto/modes/modes_local.h.orig Sat Jul 8 14:03:53 2023 | ||
| 2 | +++ crypto/modes/modes_local.h Sat Jul 8 14:10:56 2023 | ||
| 3 | @@ -45,6 +45,7 @@ | ||
| 4 | asm ("bswapl %0" \ | ||
| 5 | : "+r"(ret)); ret; }) | ||
| 6 | # elif (defined(__arm__) || defined(__arm)) && !defined(__STRICT_ALIGNMENT) | ||
| 7 | +# if (__ARM_ARCH >= 6) | ||
| 8 | # define BSWAP8(x) ({ u32 lo=(u64)(x)>>32,hi=(x); \ | ||
| 9 | asm ("rev %0,%0; rev %1,%1" \ | ||
| 10 | : "+r"(hi),"+r"(lo)); \ | ||
| 11 | @@ -53,6 +54,7 @@ | ||
| 12 | asm ("rev %0,%1" \ | ||
| 13 | : "=r"(ret) : "r"((u32)(x))); \ | ||
| 14 | ret; }) | ||
| 15 | +# endif | ||
| 16 | # endif | ||
| 17 | #endif | ||
| 18 | #endif | ||
diff --git a/patches/netcat.c.patch b/patches/netcat.c.patch index 9c3a450..c6b9f68 100644 --- a/patches/netcat.c.patch +++ b/patches/netcat.c.patch | |||
| @@ -1,5 +1,5 @@ | |||
| 1 | --- apps/nc/netcat.c.orig Tue Aug 15 15:17:28 2023 | 1 | --- apps/nc/netcat.c.orig Fri Oct 24 07:06:13 2025 |
| 2 | +++ apps/nc/netcat.c Tue Aug 15 15:17:54 2023 | 2 | +++ apps/nc/netcat.c Fri Oct 24 07:06:22 2025 |
| 3 | @@ -93,9 +93,13 @@ int zflag; /* Port Scan Flag */ | 3 | @@ -93,9 +93,13 @@ int zflag; /* Port Scan Flag */ |
| 4 | int Dflag; /* sodebug */ | 4 | int Dflag; /* sodebug */ |
| 5 | int Iflag; /* TCP receive buffer size */ | 5 | int Iflag; /* TCP receive buffer size */ |
| @@ -14,7 +14,7 @@ | |||
| 14 | 14 | ||
| 15 | int usetls; /* use TLS */ | 15 | int usetls; /* use TLS */ |
| 16 | const char *Cflag; /* Public cert file */ | 16 | const char *Cflag; /* Public cert file */ |
| 17 | @@ -268,12 +272,14 @@ main(int argc, char *argv[]) | 17 | @@ -271,12 +275,14 @@ main(int argc, char *argv[]) |
| 18 | case 'u': | 18 | case 'u': |
| 19 | uflag = 1; | 19 | uflag = 1; |
| 20 | break; | 20 | break; |
| @@ -29,7 +29,7 @@ | |||
| 29 | case 'v': | 29 | case 'v': |
| 30 | vflag = 1; | 30 | vflag = 1; |
| 31 | break; | 31 | break; |
| 32 | @@ -320,9 +326,11 @@ main(int argc, char *argv[]) | 32 | @@ -323,9 +329,11 @@ main(int argc, char *argv[]) |
| 33 | case 'o': | 33 | case 'o': |
| 34 | oflag = optarg; | 34 | oflag = optarg; |
| 35 | break; | 35 | break; |
| @@ -41,7 +41,7 @@ | |||
| 41 | case 'T': | 41 | case 'T': |
| 42 | errstr = NULL; | 42 | errstr = NULL; |
| 43 | errno = 0; | 43 | errno = 0; |
| 44 | @@ -346,9 +354,11 @@ main(int argc, char *argv[]) | 44 | @@ -349,9 +357,11 @@ main(int argc, char *argv[]) |
| 45 | argc -= optind; | 45 | argc -= optind; |
| 46 | argv += optind; | 46 | argv += optind; |
| 47 | 47 | ||
| @@ -53,7 +53,7 @@ | |||
| 53 | 53 | ||
| 54 | /* Cruft to make sure options are clean, and used properly. */ | 54 | /* Cruft to make sure options are clean, and used properly. */ |
| 55 | if (argc == 1 && family == AF_UNIX) { | 55 | if (argc == 1 && family == AF_UNIX) { |
| 56 | @@ -927,7 +937,10 @@ remote_connect(const char *host, const char *port, str | 56 | @@ -928,7 +938,10 @@ remote_connect(const char *host, const char *port, str |
| 57 | char *ipaddr) | 57 | char *ipaddr) |
| 58 | { | 58 | { |
| 59 | struct addrinfo *res, *res0; | 59 | struct addrinfo *res, *res0; |
| @@ -65,7 +65,7 @@ | |||
| 65 | 65 | ||
| 66 | if ((error = getaddrinfo(host, port, &hints, &res0))) | 66 | if ((error = getaddrinfo(host, port, &hints, &res0))) |
| 67 | errx(1, "getaddrinfo for host \"%s\" port %s: %s", host, | 67 | errx(1, "getaddrinfo for host \"%s\" port %s: %s", host, |
| 68 | @@ -942,8 +955,10 @@ remote_connect(const char *host, const char *port, str | 68 | @@ -943,8 +956,10 @@ remote_connect(const char *host, const char *port, str |
| 69 | if (sflag || pflag) { | 69 | if (sflag || pflag) { |
| 70 | struct addrinfo ahints, *ares; | 70 | struct addrinfo ahints, *ares; |
| 71 | 71 | ||
| @@ -76,7 +76,7 @@ | |||
| 76 | memset(&ahints, 0, sizeof(struct addrinfo)); | 76 | memset(&ahints, 0, sizeof(struct addrinfo)); |
| 77 | ahints.ai_family = res->ai_family; | 77 | ahints.ai_family = res->ai_family; |
| 78 | ahints.ai_socktype = uflag ? SOCK_DGRAM : SOCK_STREAM; | 78 | ahints.ai_socktype = uflag ? SOCK_DGRAM : SOCK_STREAM; |
| 79 | @@ -1035,7 +1050,10 @@ int | 79 | @@ -1036,7 +1051,10 @@ int |
| 80 | local_listen(const char *host, const char *port, struct addrinfo hints) | 80 | local_listen(const char *host, const char *port, struct addrinfo hints) |
| 81 | { | 81 | { |
| 82 | struct addrinfo *res, *res0; | 82 | struct addrinfo *res, *res0; |
| @@ -88,7 +88,7 @@ | |||
| 88 | int error; | 88 | int error; |
| 89 | 89 | ||
| 90 | /* Allow nodename to be null. */ | 90 | /* Allow nodename to be null. */ |
| 91 | @@ -1056,9 +1074,11 @@ local_listen(const char *host, const char *port, struc | 91 | @@ -1057,9 +1075,11 @@ local_listen(const char *host, const char *port, struc |
| 92 | res->ai_protocol)) == -1) | 92 | res->ai_protocol)) == -1) |
| 93 | continue; | 93 | continue; |
| 94 | 94 | ||
| @@ -100,7 +100,7 @@ | |||
| 100 | 100 | ||
| 101 | set_common_sockopts(s, res->ai_family); | 101 | set_common_sockopts(s, res->ai_family); |
| 102 | 102 | ||
| 103 | @@ -1563,11 +1583,13 @@ set_common_sockopts(int s, int af) | 103 | @@ -1569,11 +1589,13 @@ set_common_sockopts(int s, int af) |
| 104 | { | 104 | { |
| 105 | int x = 1; | 105 | int x = 1; |
| 106 | 106 | ||
| @@ -114,7 +114,7 @@ | |||
| 114 | if (Dflag) { | 114 | if (Dflag) { |
| 115 | if (setsockopt(s, SOL_SOCKET, SO_DEBUG, | 115 | if (setsockopt(s, SOL_SOCKET, SO_DEBUG, |
| 116 | &x, sizeof(x)) == -1) | 116 | &x, sizeof(x)) == -1) |
| 117 | @@ -1578,9 +1600,16 @@ set_common_sockopts(int s, int af) | 117 | @@ -1584,9 +1606,16 @@ set_common_sockopts(int s, int af) |
| 118 | IP_TOS, &Tflag, sizeof(Tflag)) == -1) | 118 | IP_TOS, &Tflag, sizeof(Tflag)) == -1) |
| 119 | err(1, "set IP ToS"); | 119 | err(1, "set IP ToS"); |
| 120 | 120 | ||
| @@ -131,7 +131,7 @@ | |||
| 131 | } | 131 | } |
| 132 | if (Iflag) { | 132 | if (Iflag) { |
| 133 | if (setsockopt(s, SOL_SOCKET, SO_RCVBUF, | 133 | if (setsockopt(s, SOL_SOCKET, SO_RCVBUF, |
| 134 | @@ -1604,13 +1633,17 @@ set_common_sockopts(int s, int af) | 134 | @@ -1610,13 +1639,17 @@ set_common_sockopts(int s, int af) |
| 135 | } | 135 | } |
| 136 | 136 | ||
| 137 | if (minttl != -1) { | 137 | if (minttl != -1) { |
| @@ -150,7 +150,7 @@ | |||
| 150 | } | 150 | } |
| 151 | } | 151 | } |
| 152 | 152 | ||
| 153 | @@ -1835,15 +1868,19 @@ help(void) | 153 | @@ -1846,15 +1879,19 @@ help(void) |
| 154 | \t-P proxyuser\tUsername for proxy authentication\n\ | 154 | \t-P proxyuser\tUsername for proxy authentication\n\ |
| 155 | \t-p port\t Specify local port for remote connects\n\ | 155 | \t-p port\t Specify local port for remote connects\n\ |
| 156 | \t-R CAfile CA bundle\n\ | 156 | \t-R CAfile CA bundle\n\ |
| @@ -175,4 +175,4 @@ | |||
| 175 | + "\t-v Verbose\n\ | 175 | + "\t-v Verbose\n\ |
| 176 | \t-W recvlimit Terminate after receiving a number of packets\n\ | 176 | \t-W recvlimit Terminate after receiving a number of packets\n\ |
| 177 | \t-w timeout Timeout for connects and final net reads\n\ | 177 | \t-w timeout Timeout for connects and final net reads\n\ |
| 178 | \t-X proto Proxy protocol: \"4\", \"5\" (SOCKS) or \"connect\"\n\ | 178 | \t-X proto Proxy protocol: \"4\", \"4A\", \"5\" (SOCKS) or \"connect\"\n\ |
diff --git a/patches/openssl.c.patch b/patches/openssl.c.patch index 15afb78..60ea9a7 100644 --- a/patches/openssl.c.patch +++ b/patches/openssl.c.patch | |||
| @@ -1,6 +1,6 @@ | |||
| 1 | --- apps/openssl/openssl.c.orig Mon Mar 4 13:39:56 2024 | 1 | --- apps/openssl/openssl.c.orig Sat May 31 03:18:05 2025 |
| 2 | +++ apps/openssl/openssl.c Mon Mar 4 13:40:15 2024 | 2 | +++ apps/openssl/openssl.c Sat May 31 03:18:17 2025 |
| 3 | @@ -348,7 +348,9 @@ | 3 | @@ -341,7 +341,9 @@ BIO *bio_err = NULL; |
| 4 | static void | 4 | static void |
| 5 | openssl_startup(void) | 5 | openssl_startup(void) |
| 6 | { | 6 | { |
diff --git a/patches/opensslfeatures.h.patch b/patches/opensslfeatures.h.patch index 618de73..d370b32 100644 --- a/patches/opensslfeatures.h.patch +++ b/patches/opensslfeatures.h.patch | |||
| @@ -14,3 +14,36 @@ | |||
| 14 | #define OPENSSL_THREADS | 14 | #define OPENSSL_THREADS |
| 15 | 15 | ||
| 16 | #define OPENSSL_NO_BUF_FREELISTS | 16 | #define OPENSSL_NO_BUF_FREELISTS |
| 17 | --- crypto/crypto_internal.h.orig Sat Dec 14 14:15:39 2024 | ||
| 18 | +++ crypto/crypto_internal.h Sat Dec 14 14:15:52 2024 | ||
| 19 | @@ -15,6 +15,8 @@ | ||
| 20 | * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. | ||
| 21 | */ | ||
| 22 | |||
| 23 | +#include <openssl/opensslfeatures.h> | ||
| 24 | + | ||
| 25 | #include <endian.h> | ||
| 26 | #include <stddef.h> | ||
| 27 | #include <stdint.h> | ||
| 28 | --- tests/parse_test_file.h.orig Thu Dec 26 01:13:00 2024 | ||
| 29 | +++ tests/parse_test_file.h Thu Dec 26 01:13:27 2024 | ||
| 30 | @@ -22,6 +22,8 @@ | ||
| 31 | #include <stdint.h> | ||
| 32 | #include <stdio.h> | ||
| 33 | |||
| 34 | +#include <openssl/opensslfeatures.h> | ||
| 35 | + | ||
| 36 | #include "bytestring.h" | ||
| 37 | |||
| 38 | #if defined(__cplusplus) | ||
| 39 | --- tests/test.h.orig Sat May 31 04:48:09 2025 | ||
| 40 | +++ tests/test.h Sat May 31 04:48:31 2025 | ||
| 41 | @@ -18,6 +18,8 @@ | ||
| 42 | #ifndef HEADER_TEST_H | ||
| 43 | #define HEADER_TEST_H | ||
| 44 | |||
| 45 | +#include <openssl/opensslfeatures.h> | ||
| 46 | + | ||
| 47 | #include <stddef.h> | ||
| 48 | #include <stdint.h> | ||
| 49 | |||
diff --git a/patches/patch-amd64-crypto-cpu-caps.c.patch b/patches/patch-amd64-crypto-cpu-caps.c.patch new file mode 100644 index 0000000..5fd7524 --- /dev/null +++ b/patches/patch-amd64-crypto-cpu-caps.c.patch | |||
| @@ -0,0 +1,20 @@ | |||
| 1 | --- crypto/arch/amd64/crypto_cpu_caps.c.orig Sat Dec 14 13:45:16 2024 | ||
| 2 | +++ crypto/arch/amd64/crypto_cpu_caps.c Sat Dec 14 13:54:06 2024 | ||
| 3 | @@ -37,7 +37,7 @@ cpuid(uint32_t eax, uint32_t *out_eax, uint32_t *out_e | ||
| 4 | { | ||
| 5 | uint32_t ebx = 0, ecx = 0, edx = 0; | ||
| 6 | |||
| 7 | -#ifndef OPENSSL_NO_ASM | ||
| 8 | +#if defined(__GNUC__) && !defined(OPENSSL_NO_ASM) | ||
| 9 | __asm__ ("cpuid": "+a"(eax), "+b"(ebx), "+c"(ecx), "+d"(edx)); | ||
| 10 | #else | ||
| 11 | eax = 0; | ||
| 12 | @@ -58,7 +58,7 @@ xgetbv(uint32_t ecx, uint32_t *out_eax, uint32_t *out_ | ||
| 13 | { | ||
| 14 | uint32_t eax = 0, edx = 0; | ||
| 15 | |||
| 16 | -#ifndef OPENSSL_NO_ASM | ||
| 17 | +#if defined(__GNUC__) && !defined(OPENSSL_NO_ASM) | ||
| 18 | __asm__ ("xgetbv": "+a"(eax), "+c"(ecx), "+d"(edx)); | ||
| 19 | #endif | ||
| 20 | |||
diff --git a/patches/patch-i386-crypto-cpu-caps.c.patch b/patches/patch-i386-crypto-cpu-caps.c.patch new file mode 100644 index 0000000..0642582 --- /dev/null +++ b/patches/patch-i386-crypto-cpu-caps.c.patch | |||
| @@ -0,0 +1,20 @@ | |||
| 1 | --- crypto/arch/i386/crypto_cpu_caps.c.orig Mon Jun 16 10:38:27 2025 | ||
| 2 | +++ crypto/arch/i386/crypto_cpu_caps.c Mon Jun 16 10:38:39 2025 | ||
| 3 | @@ -37,7 +37,7 @@ cpuid(uint32_t eax, uint32_t *out_eax, uint32_t *out_e | ||
| 4 | { | ||
| 5 | uint32_t ebx = 0, ecx = 0, edx = 0; | ||
| 6 | |||
| 7 | -#ifndef OPENSSL_NO_ASM | ||
| 8 | +#if defined(__GNUC__) && !defined(OPENSSL_NO_ASM) | ||
| 9 | __asm__ ("cpuid": "+a"(eax), "+b"(ebx), "+c"(ecx), "+d"(edx)); | ||
| 10 | #else | ||
| 11 | eax = 0; | ||
| 12 | @@ -58,7 +58,7 @@ xgetbv(uint32_t ecx, uint32_t *out_eax, uint32_t *out_ | ||
| 13 | { | ||
| 14 | uint32_t eax = 0, edx = 0; | ||
| 15 | |||
| 16 | -#ifndef OPENSSL_NO_ASM | ||
| 17 | +#if defined(__GNUC__) && !defined(OPENSSL_NO_ASM) | ||
| 18 | __asm__ ("xgetbv": "+a"(eax), "+c"(ecx), "+d"(edx)); | ||
| 19 | #endif | ||
| 20 | |||
diff --git a/patches/speed.c.patch b/patches/speed.c.patch index c29ef4d..0f29358 100644 --- a/patches/speed.c.patch +++ b/patches/speed.c.patch | |||
| @@ -1,8 +1,8 @@ | |||
| 1 | --- apps/openssl/speed.c.orig Sat Jul 13 11:02:51 2024 | 1 | --- apps/openssl/speed.c.orig Thu Dec 18 07:45:00 2025 |
| 2 | +++ apps/openssl/speed.c Sat Jul 13 10:27:25 2024 | 2 | +++ apps/openssl/speed.c Thu Dec 18 07:45:12 2025 |
| 3 | @@ -161,7 +161,16 @@ | 3 | @@ -154,7 +154,16 @@ static void |
| 4 | pkey_print_message(const char *str, const char *str2, | 4 | pkey_print_message(const char *str, const char *str2, |
| 5 | long num, int bits, int sec); | 5 | int bits, int sec); |
| 6 | static void print_result(int alg, int run_no, int count, double time_used); | 6 | static void print_result(int alg, int run_no, int count, double time_used); |
| 7 | +#ifndef _WIN32 | 7 | +#ifndef _WIN32 |
| 8 | static int do_multi(int multi); | 8 | static int do_multi(int multi); |
| @@ -15,9 +15,9 @@ | |||
| 15 | +#define alarm(seconds) speed_alarm((seconds)) | 15 | +#define alarm(seconds) speed_alarm((seconds)) |
| 16 | +#endif | 16 | +#endif |
| 17 | 17 | ||
| 18 | #define ALGOR_NUM 32 | ||
| 19 | #define SIZE_NUM 5 | 18 | #define SIZE_NUM 5 |
| 20 | @@ -430,8 +439,10 @@ | 19 | #define MAX_ECDH_SIZE 256 |
| 20 | @@ -1089,8 +1098,10 @@ speed_main(int argc, char **argv) | ||
| 21 | const EVP_CIPHER *evp_cipher = NULL; | 21 | const EVP_CIPHER *evp_cipher = NULL; |
| 22 | const EVP_MD *evp_md = NULL; | 22 | const EVP_MD *evp_md = NULL; |
| 23 | int decrypt = 0; | 23 | int decrypt = 0; |
| @@ -28,7 +28,7 @@ | |||
| 28 | const char *errstr = NULL; | 28 | const char *errstr = NULL; |
| 29 | 29 | ||
| 30 | if (pledge("stdio proc", NULL) == -1) { | 30 | if (pledge("stdio proc", NULL) == -1) { |
| 31 | @@ -506,6 +517,7 @@ | 31 | @@ -1164,6 +1175,7 @@ speed_main(int argc, char **argv) |
| 32 | decrypt = 1; | 32 | decrypt = 1; |
| 33 | j--; /* Otherwise, -decrypt gets confused with an | 33 | j--; /* Otherwise, -decrypt gets confused with an |
| 34 | * algorithm. */ | 34 | * algorithm. */ |
| @@ -36,7 +36,7 @@ | |||
| 36 | } else if (argc > 0 && strcmp(*argv, "-multi") == 0) { | 36 | } else if (argc > 0 && strcmp(*argv, "-multi") == 0) { |
| 37 | argc--; | 37 | argc--; |
| 38 | argv++; | 38 | argv++; |
| 39 | @@ -520,6 +532,7 @@ | 39 | @@ -1178,6 +1190,7 @@ speed_main(int argc, char **argv) |
| 40 | } | 40 | } |
| 41 | j--; /* Otherwise, -multi gets confused with an | 41 | j--; /* Otherwise, -multi gets confused with an |
| 42 | * algorithm. */ | 42 | * algorithm. */ |
| @@ -44,7 +44,7 @@ | |||
| 44 | } else if (argc > 0 && strcmp(*argv, "-unaligned") == 0) { | 44 | } else if (argc > 0 && strcmp(*argv, "-unaligned") == 0) { |
| 45 | argc--; | 45 | argc--; |
| 46 | argv++; | 46 | argv++; |
| 47 | @@ -851,7 +864,9 @@ | 47 | @@ -1492,7 +1505,9 @@ speed_main(int argc, char **argv) |
| 48 | BIO_printf(bio_err, "-evp e use EVP e.\n"); | 48 | BIO_printf(bio_err, "-evp e use EVP e.\n"); |
| 49 | BIO_printf(bio_err, "-decrypt time decryption instead of encryption (only EVP).\n"); | 49 | BIO_printf(bio_err, "-decrypt time decryption instead of encryption (only EVP).\n"); |
| 50 | BIO_printf(bio_err, "-mr produce machine readable output.\n"); | 50 | BIO_printf(bio_err, "-mr produce machine readable output.\n"); |
| @@ -54,7 +54,7 @@ | |||
| 54 | BIO_printf(bio_err, "-unaligned n use buffers with offset n from proper alignment.\n"); | 54 | BIO_printf(bio_err, "-unaligned n use buffers with offset n from proper alignment.\n"); |
| 55 | goto end; | 55 | goto end; |
| 56 | } | 56 | } |
| 57 | @@ -860,8 +875,10 @@ | 57 | @@ -1501,8 +1516,10 @@ speed_main(int argc, char **argv) |
| 58 | j++; | 58 | j++; |
| 59 | } | 59 | } |
| 60 | 60 | ||
| @@ -65,8 +65,8 @@ | |||
| 65 | 65 | ||
| 66 | if (j == 0) { | 66 | if (j == 0) { |
| 67 | for (i = 0; i < ALGOR_NUM; i++) { | 67 | for (i = 0; i < ALGOR_NUM; i++) { |
| 68 | @@ -933,11 +950,13 @@ | 68 | @@ -1573,11 +1590,13 @@ speed_main(int argc, char **argv) |
| 69 | #define COND(c) (run && count<0x7fffffff) | 69 | #define COND (run && count<0x7fffffff) |
| 70 | #define COUNT(d) (count) | 70 | #define COUNT(d) (count) |
| 71 | 71 | ||
| 72 | +#ifndef _WIN32 | 72 | +#ifndef _WIN32 |
| @@ -79,7 +79,7 @@ | |||
| 79 | 79 | ||
| 80 | #ifndef OPENSSL_NO_MD4 | 80 | #ifndef OPENSSL_NO_MD4 |
| 81 | if (doit[D_MD4]) { | 81 | if (doit[D_MD4]) { |
| 82 | @@ -1743,7 +1762,9 @@ | 82 | @@ -2362,7 +2381,9 @@ speed_main(int argc, char **argv) |
| 83 | ecdh_doit[j] = 0; | 83 | ecdh_doit[j] = 0; |
| 84 | } | 84 | } |
| 85 | } | 85 | } |
| @@ -89,7 +89,7 @@ | |||
| 89 | if (!mr) { | 89 | if (!mr) { |
| 90 | fprintf(stdout, "%s\n", SSLeay_version(SSLEAY_VERSION)); | 90 | fprintf(stdout, "%s\n", SSLeay_version(SSLEAY_VERSION)); |
| 91 | fprintf(stdout, "%s\n", SSLeay_version(SSLEAY_BUILT_ON)); | 91 | fprintf(stdout, "%s\n", SSLeay_version(SSLEAY_BUILT_ON)); |
| 92 | @@ -1899,11 +1920,15 @@ | 92 | @@ -2518,11 +2539,15 @@ pkey_print_message(const char *str, const char *str2, |
| 93 | static void | 93 | static void |
| 94 | print_result(int alg, int run_no, int count, double time_used) | 94 | print_result(int alg, int run_no, int count, double time_used) |
| 95 | { | 95 | { |
| @@ -105,9 +105,10 @@ | |||
| 105 | static char * | 105 | static char * |
| 106 | sstrsep(char **string, const char *delim) | 106 | sstrsep(char **string, const char *delim) |
| 107 | { | 107 | { |
| 108 | @@ -2104,4 +2129,5 @@ | 108 | @@ -2723,5 +2748,6 @@ do_multi(int multi) |
| 109 | free(fds); | 109 | free(fds); |
| 110 | return 1; | 110 | return 1; |
| 111 | } | 111 | } |
| 112 | +#endif | 112 | +#endif |
| 113 | #endif | 113 | |
| 114 | #endif /* OPENSSL_NO_SPEED */ | ||
diff --git a/patches/ssl_namespace.h.patch b/patches/ssl_namespace.h.patch deleted file mode 100644 index 758f8dc..0000000 --- a/patches/ssl_namespace.h.patch +++ /dev/null | |||
| @@ -1,21 +0,0 @@ | |||
| 1 | --- openbsd/src/lib/libssl/hidden/ssl_namespace.h 2023-03-15 11:41:52.481641800 -0600 | ||
| 2 | +++ ssl/hidden/ssl_namespace.h 2023-03-15 17:28:04.685309300 -0600 | ||
| 3 | @@ -23,6 +23,11 @@ | ||
| 4 | * and we alias that to the normal name. | ||
| 5 | */ | ||
| 6 | |||
| 7 | +#ifdef _MSC_VER | ||
| 8 | +#define LSSL_UNUSED(x) | ||
| 9 | +#define LSSL_USED(x) | ||
| 10 | +#define LSSL_ALIAS(x) | ||
| 11 | +#else | ||
| 12 | #ifdef LIBRESSL_NAMESPACE | ||
| 13 | #define LSSL_UNUSED(x) typeof(x) x __attribute__((deprecated)) | ||
| 14 | #define LSSL_USED(x) __attribute__((visibility("hidden"))) \ | ||
| 15 | @@ -33,5 +38,6 @@ | ||
| 16 | #define LSSL_USED(x) | ||
| 17 | #define LSSL_ALIAS(x) asm("") | ||
| 18 | #endif | ||
| 19 | +#endif /* _MSC_VER */ | ||
| 20 | |||
| 21 | #endif /* _LIBSSL_SSL_NAMESPACE_H_ */ | ||
diff --git a/patches/test.c.patch b/patches/test.c.patch new file mode 100644 index 0000000..7e80e1f --- /dev/null +++ b/patches/test.c.patch | |||
| @@ -0,0 +1,11 @@ | |||
| 1 | --- tests/test.c.orig 2025-10-07 09:57:42.853015505 -0500 | ||
| 2 | +++ tests/test.c 2025-10-07 09:58:08.872499852 -0500 | ||
| 3 | @@ -67,7 +67,7 @@ | ||
| 4 | return t; | ||
| 5 | |||
| 6 | /* Create a temporary file for logging in non-verbose mode */ | ||
| 7 | - if ((tmp_file = strdup("/tmp/libressl-test.XXXXXXXX")) == NULL) | ||
| 8 | + if ((tmp_file = strdup("libressl-test.XXXXXXXX")) == NULL) | ||
| 9 | err(1, "strdup"); | ||
| 10 | if ((out_fd = mkstemp(tmp_file)) == -1) | ||
| 11 | err(1, "mkstemp"); | ||
diff --git a/patches/tls_config.c.patch b/patches/tls_config.c.patch new file mode 100644 index 0000000..1342a60 --- /dev/null +++ b/patches/tls_config.c.patch | |||
| @@ -0,0 +1,15 @@ | |||
| 1 | uid_t can be 64-bit | ||
| 2 | |||
| 3 | --- tls/tls_config.c.orig 2024-11-02 21:19:47.090322191 +0100 | ||
| 4 | +++ tls/tls_config.c 2024-11-02 21:38:22.527071689 +0100 | ||
| 5 | @@ -742,8 +742,8 @@ | ||
| 6 | |||
| 7 | if (sb.st_uid != getuid()) { | ||
| 8 | tls_config_set_errorx(config, TLS_ERROR_UNKNOWN, | ||
| 9 | - "session file has incorrect owner (uid %u != %u)", | ||
| 10 | - sb.st_uid, getuid()); | ||
| 11 | + "session file has incorrect owner (uid %llu != %llu)", | ||
| 12 | + (unsigned long long)sb.st_uid, (unsigned long long)getuid()); | ||
| 13 | return (-1); | ||
| 14 | } | ||
| 15 | mugo = sb.st_mode & (S_IRWXU|S_IRWXG|S_IRWXO); | ||
diff --git a/patches/win32_amd64_bn_arch.h.patch b/patches/win32_amd64_bn_arch.h.patch index b7926e3..a6a5ee9 100644 --- a/patches/win32_amd64_bn_arch.h.patch +++ b/patches/win32_amd64_bn_arch.h.patch | |||
| @@ -1,8 +1,8 @@ | |||
| 1 | We should consider a OPENSSL_NO_BN_ASM if we can't figure | 1 | We should consider a OPENSSL_NO_BN_ASM if we can't figure |
| 2 | out how to fix BIGNUM on this OS | 2 | out how to fix BIGNUM on this OS |
| 3 | 3 | ||
| 4 | --- crypto/bn/arch/amd64/bn_arch.h.orig Wed Mar 27 22:17:03 2024 | 4 | --- crypto/bn/arch/amd64/bn_arch.h.orig Fri Oct 24 07:06:10 2025 |
| 5 | +++ crypto/bn/arch/amd64/bn_arch.h Wed Mar 27 22:17:31 2024 | 5 | +++ crypto/bn/arch/amd64/bn_arch.h Fri Oct 24 07:06:22 2025 |
| 6 | @@ -20,8 +20,14 @@ | 6 | @@ -20,8 +20,14 @@ |
| 7 | #ifndef HEADER_BN_ARCH_H | 7 | #ifndef HEADER_BN_ARCH_H |
| 8 | #define HEADER_BN_ARCH_H | 8 | #define HEADER_BN_ARCH_H |
| @@ -18,7 +18,7 @@ out how to fix BIGNUM on this OS | |||
| 18 | #define HAVE_BN_ADD | 18 | #define HAVE_BN_ADD |
| 19 | #define HAVE_BN_ADD_WORDS | 19 | #define HAVE_BN_ADD_WORDS |
| 20 | 20 | ||
| 21 | @@ -104,6 +110,7 @@ bn_subw(BN_ULONG a, BN_ULONG b, BN_ULONG *out_borrow, | 21 | @@ -110,6 +116,7 @@ bn_subw(BN_ULONG a, BN_ULONG b, BN_ULONG *out_borrow, |
| 22 | } | 22 | } |
| 23 | 23 | ||
| 24 | #endif /* __GNUC__ */ | 24 | #endif /* __GNUC__ */ |
diff --git a/scripts/test b/scripts/test index e389728..2148d52 100755 --- a/scripts/test +++ b/scripts/test | |||
| @@ -2,9 +2,45 @@ | |||
| 2 | set -e | 2 | set -e |
| 3 | set -x | 3 | set -x |
| 4 | 4 | ||
| 5 | unset CC | 5 | if [ "$ARCH" = "" ]; then |
| 6 | ARCH=`uname -m` | ||
| 7 | fi | ||
| 8 | |||
| 9 | if [ "$ARCH" = "mingw32" -o "$ARCH" = "mingw64" -o "$ARCH" = "arm32" ]; then | ||
| 10 | unset CC | ||
| 11 | fi | ||
| 12 | |||
| 6 | ENABLE_ASM="${ENABLE_ASM:=ON}" | 13 | ENABLE_ASM="${ENABLE_ASM:=ON}" |
| 7 | 14 | ||
| 15 | # setup_cross_compiler sets up environment variables for cross-compilation with the given prefix. | ||
| 16 | setup_cross_compiler() { | ||
| 17 | cross_prefix=$1 | ||
| 18 | |||
| 19 | CC=${cross_prefix}-gcc | ||
| 20 | CXX=${cross_prefix}-g++ | ||
| 21 | AR=${cross_prefix}-ar | ||
| 22 | STRIP=${cross_prefix}-strip | ||
| 23 | RANLIB=${cross_prefix}-ranlib | ||
| 24 | |||
| 25 | # If the unversioned symlink for gcc doesn't exist, find versioned binary. | ||
| 26 | if ! command -v "$CC" >/dev/null 2>&1; then | ||
| 27 | gcc_ver=$(find /usr/bin -name "${CC}-[0-9]*" -prune 2>/dev/null \ | ||
| 28 | | sed "s/.*${CC}-//" | sort -n | tail -n 1) | ||
| 29 | CC=${CC}-${gcc_ver} | ||
| 30 | CXX=${CXX}-${gcc_ver} | ||
| 31 | fi | ||
| 32 | |||
| 33 | # Check all binaries actually exist. | ||
| 34 | for c in "$CC" "$CXX" "$AR" "$STRIP" "$RANLIB"; do | ||
| 35 | if ! command -v "$c" >/dev/null 2>&1; then | ||
| 36 | echo "##### Error: $c not found" | ||
| 37 | exit 1 | ||
| 38 | fi | ||
| 39 | done | ||
| 40 | |||
| 41 | echo "##### Using $($CC --version | head -n 1)" | ||
| 42 | } | ||
| 43 | |||
| 8 | if type apt-get >/dev/null 2>&1; then | 44 | if type apt-get >/dev/null 2>&1; then |
| 9 | sudo apt-get update | 45 | sudo apt-get update |
| 10 | sudo apt-get install -y cmake ninja-build | 46 | sudo apt-get install -y cmake ninja-build |
| @@ -15,10 +51,6 @@ fi | |||
| 15 | 51 | ||
| 16 | VERSION=`cat VERSION` | 52 | VERSION=`cat VERSION` |
| 17 | 53 | ||
| 18 | if [ "$ARCH" = "" ]; then | ||
| 19 | ARCH=`uname -m` | ||
| 20 | fi | ||
| 21 | |||
| 22 | # test macOS | 54 | # test macOS |
| 23 | if [ `uname` = "Darwin" ]; then | 55 | if [ `uname` = "Darwin" ]; then |
| 24 | # test autotools | 56 | # test autotools |
| @@ -84,7 +116,7 @@ elif [ "$ARCH" = "native" ]; then | |||
| 84 | ninja test | 116 | ninja test |
| 85 | ) | 117 | ) |
| 86 | 118 | ||
| 87 | elif [ "$ARCH" = "mingw32" -o "$ARCH" = "mingw64" ]; then | 119 | elif [ "$ARCH" = "mingw32" ] || [ "$ARCH" = "mingw64" ]; then |
| 88 | CPU=i686 | 120 | CPU=i686 |
| 89 | if [ "$ARCH" = "mingw64" ]; then | 121 | if [ "$ARCH" = "mingw64" ]; then |
| 90 | CPU=x86_64 | 122 | CPU=x86_64 |
| @@ -112,39 +144,57 @@ elif [ "$ARCH" = "mingw32" -o "$ARCH" = "mingw64" ]; then | |||
| 112 | ninja -j 4 | 144 | ninja -j 4 |
| 113 | ) | 145 | ) |
| 114 | 146 | ||
| 115 | elif [ "$ARCH" = "arm32" -o "$ARCH" = "arm64" ]; then | 147 | elif [ "$ARCH" = "arm32" ] || [ "$ARCH" = "arm64" ]; then |
| 116 | sudo apt-get install -y qemu-user-static binfmt-support | 148 | sudo apt-get install -y qemu-user-static binfmt-support |
| 117 | 149 | ||
| 118 | if [ "$ARCH" = "arm32" ]; then | 150 | if [ "$ARCH" = "arm32" ]; then |
| 119 | sudo apt-get install -y g++-arm-linux-gnueabihf | 151 | sudo apt-get install -y g++-arm-linux-gnueabihf |
| 120 | sudo ln -sf /usr/arm-linux-gnueabihf/lib/ld-linux-armhf.so.3 /lib/ | 152 | sudo ln -sf /usr/arm-linux-gnueabihf/lib/ld-linux-armhf.so.3 /lib/ |
| 153 | setup_cross_compiler arm-linux-gnueabihf | ||
| 154 | |||
| 121 | ./configure --host=arm-linux-gnueabihf | 155 | ./configure --host=arm-linux-gnueabihf |
| 122 | LD_LIBRARY_PATH=/usr/arm-linux-gnueabihf/lib make -j 4 check | 156 | LD_LIBRARY_PATH=/usr/arm-linux-gnueabihf/lib make -j 4 check |
| 123 | else | 157 | else |
| 124 | sudo apt-get install -y g++-aarch64-linux-gnu | 158 | sudo apt-get install -y g++-aarch64-linux-gnu |
| 125 | sudo ln -sf /usr/aarch64-linux-gnu/lib/ld-linux-aarch64.so.1 /lib/ | 159 | sudo ln -sf /usr/aarch64-linux-gnu/lib/ld-linux-aarch64.so.1 /lib/ |
| 160 | setup_cross_compiler aarch64-linux-gnu | ||
| 161 | |||
| 126 | ./configure --host=aarch64-linux-gnu | 162 | ./configure --host=aarch64-linux-gnu |
| 127 | LD_LIBRARY_PATH=/usr/aarch64-linux-gnu/lib make -j 4 check | 163 | LD_LIBRARY_PATH=/usr/aarch64-linux-gnu/lib make -j 4 check |
| 128 | fi | 164 | fi |
| 129 | 165 | ||
| 130 | file apps/openssl/.libs/openssl | 166 | file apps/openssl/openssl |
| 131 | 167 | ||
| 132 | elif [ "$ARCH" = "mips32" -o "$ARCH" = "mips64" ]; then | 168 | elif [ "$ARCH" = "loong64" ]; then |
| 169 | sudo apt install -y qemu-user-static binfmt-support g++-14-loongarch64-linux-gnu | ||
| 170 | sudo ln -sf /usr/loongarch64-linux-gnu/lib64/ld-linux-loongarch-lp64d.so.1 /lib64 | ||
| 171 | setup_cross_compiler loongarch64-linux-gnu | ||
| 172 | |||
| 173 | ./configure --host=loongarch64-linux-gnu | ||
| 174 | LD_LIBRARY_PATH=/usr/loongarch64-linux-gnu/lib make -j 4 check | ||
| 175 | |||
| 176 | file apps/openssl/openssl | ||
| 177 | |||
| 178 | elif [ "$ARCH" = "mips32" ] || [ "$ARCH" = "mips64" ]; then | ||
| 133 | sudo apt-get install -y qemu-user-static binfmt-support | 179 | sudo apt-get install -y qemu-user-static binfmt-support |
| 134 | 180 | ||
| 135 | if [ "$ARCH" = "mips32" ]; then | 181 | if [ "$ARCH" = "mips32" ]; then |
| 136 | sudo apt-get install -y g++-mips-linux-gnu | 182 | sudo apt-get install -y g++-mips-linux-gnu |
| 137 | sudo ln -sf /usr/mipsel-linux-gnu/lib/ld.so.1 /lib/ | 183 | sudo ln -sf /usr/mips-linux-gnu/lib/ld.so.1 /lib/ |
| 138 | ./configure --host=mipsel-linux-gnu | 184 | setup_cross_compiler mips-linux-gnu |
| 139 | LD_LIBRARY_PATH=/usr/mipsel-linux-gnu/lib make -j 4 check | 185 | |
| 186 | ./configure --host=mips-linux-gnu | ||
| 187 | LD_LIBRARY_PATH=/usr/mips-linux-gnu/lib make -j 4 check | ||
| 140 | else | 188 | else |
| 141 | sudo apt-get install -y g++-mips64el-linux-gnuabi64 | 189 | sudo apt-get install -y g++-mips64el-linux-gnuabi64 |
| 142 | sudo ln -sf /usr/mips64el-linux-gnuabi64/lib64/ld.so.1 /lib64 | 190 | sudo ln -sf /usr/mips64el-linux-gnuabi64/lib64/ld.so.1 /lib64 |
| 191 | setup_cross_compiler mips64el-linux-gnuabi64 | ||
| 192 | |||
| 143 | ./configure --host=mips64el-linux-gnuabi64 | 193 | ./configure --host=mips64el-linux-gnuabi64 |
| 144 | LD_LIBRARY_PATH=/usr/mips64el-linux-gnuabi64/lib make -j 4 check | 194 | LD_LIBRARY_PATH=/usr/mips64el-linux-gnuabi64/lib make -j 4 check |
| 145 | fi | 195 | fi |
| 146 | 196 | ||
| 147 | file apps/openssl/.libs/openssl | 197 | file apps/openssl/openssl |
| 148 | 198 | ||
| 149 | elif [ "$ARCH" = "android" ]; then | 199 | elif [ "$ARCH" = "android" ]; then |
| 150 | export TC_FILE=$ANDROID_NDK_HOME/build/cmake/android.toolchain.cmake | 200 | export TC_FILE=$ANDROID_NDK_HOME/build/cmake/android.toolchain.cmake |
| @@ -173,7 +223,7 @@ elif [ "$ARCH" = "android" ]; then | |||
| 173 | 223 | ||
| 174 | ( | 224 | ( |
| 175 | build_dir=build-$NAL_$ABI | 225 | build_dir=build-$NAL_$ABI |
| 176 | rm -fr $build_dir include/openssl/opensslconf.h | 226 | rm -fr $build_dir |
| 177 | mkdir $build_dir | 227 | mkdir $build_dir |
| 178 | cd $build_dir | 228 | cd $build_dir |
| 179 | echo "##### cmake -GNinja -DCMAKE_MAKE_PROGRAM=ninja -DANDROID_NDK=$ANDROID_NDK_HOME -DCMAKE_TOOLCHAIN_FILE=$TC_FILE -DANDROID_ABI=$ABI -DANDROID_NATIVE_API_LEVEL=$NAL .." | 229 | echo "##### cmake -GNinja -DCMAKE_MAKE_PROGRAM=ninja -DANDROID_NDK=$ANDROID_NDK_HOME -DCMAKE_TOOLCHAIN_FILE=$TC_FILE -DANDROID_ABI=$ABI -DANDROID_NATIVE_API_LEVEL=$NAL .." |
diff --git a/ssl/CMakeLists.txt b/ssl/CMakeLists.txt index e2eeab5..637e0f0 100644 --- a/ssl/CMakeLists.txt +++ b/ssl/CMakeLists.txt | |||
| @@ -1,3 +1,18 @@ | |||
| 1 | # | ||
| 2 | # Copyright (c) 2014 Brent Cook | ||
| 3 | # | ||
| 4 | # Permission to use, copy, modify, and distribute this software for any | ||
| 5 | # purpose with or without fee is hereby granted, provided that the above | ||
| 6 | # copyright notice and this permission notice appear in all copies. | ||
| 7 | # | ||
| 8 | # THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES | ||
| 9 | # WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF | ||
| 10 | # MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR | ||
| 11 | # ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES | ||
| 12 | # WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN | ||
| 13 | # ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF | ||
| 14 | # OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. | ||
| 15 | |||
| 1 | set( | 16 | set( |
| 2 | SSL_SRC | 17 | SSL_SRC |
| 3 | bio_ssl.c | 18 | bio_ssl.c |
| @@ -72,6 +87,13 @@ target_include_directories(ssl_obj | |||
| 72 | ../include | 87 | ../include |
| 73 | ${CMAKE_BINARY_DIR}/include) | 88 | ${CMAKE_BINARY_DIR}/include) |
| 74 | 89 | ||
| 90 | if(MSVC) | ||
| 91 | # "C4702" - unreachable code | ||
| 92 | set_source_files_properties(d1_pkt.c s3_cbc.c PROPERTIES | ||
| 93 | COMPILE_OPTIONS /wd4702 | ||
| 94 | ) | ||
| 95 | endif() | ||
| 96 | |||
| 75 | add_library(bs_obj OBJECT ${BS_SRC}) | 97 | add_library(bs_obj OBJECT ${BS_SRC}) |
| 76 | target_include_directories(bs_obj | 98 | target_include_directories(bs_obj |
| 77 | PRIVATE | 99 | PRIVATE |
| @@ -86,16 +108,16 @@ endif() | |||
| 86 | 108 | ||
| 87 | export_symbol(ssl ${CMAKE_CURRENT_SOURCE_DIR}/ssl.sym) | 109 | export_symbol(ssl ${CMAKE_CURRENT_SOURCE_DIR}/ssl.sym) |
| 88 | target_link_libraries(ssl crypto ${PLATFORM_LIBS}) | 110 | target_link_libraries(ssl crypto ${PLATFORM_LIBS}) |
| 89 | if (WIN32) | ||
| 90 | set(SSL_POSTFIX -${SSL_MAJOR_VERSION} PARENT_SCOPE) | ||
| 91 | endif() | ||
| 92 | set_target_properties(ssl PROPERTIES | 111 | set_target_properties(ssl PROPERTIES |
| 93 | OUTPUT_NAME ssl${SSL_POSTFIX} | 112 | OUTPUT_NAME ssl |
| 94 | ARCHIVE_OUTPUT_NAME ssl${SSL_POSTFIX} | 113 | ARCHIVE_OUTPUT_NAME ssl |
| 95 | EXPORT_NAME SSL | 114 | EXPORT_NAME SSL |
| 96 | VERSION ${SSL_VERSION} | 115 | VERSION ${SSL_VERSION} |
| 97 | SOVERSION ${SSL_MAJOR_VERSION} | 116 | SOVERSION ${SSL_MAJOR_VERSION} |
| 98 | ) | 117 | ) |
| 118 | if(NOT CMAKE_VERSION VERSION_LESS 3.27.0) | ||
| 119 | set_target_properties(ssl PROPERTIES DLL_NAME_WITH_SOVERSION TRUE) | ||
| 120 | endif() | ||
| 99 | 121 | ||
| 100 | target_include_directories( | 122 | target_include_directories( |
| 101 | ssl | 123 | ssl |
| @@ -104,6 +126,30 @@ target_include_directories( | |||
| 104 | $<INSTALL_INTERFACE:${CMAKE_INSTALL_INCLUDEDIR}> | 126 | $<INSTALL_INTERFACE:${CMAKE_INSTALL_INCLUDEDIR}> |
| 105 | ) | 127 | ) |
| 106 | 128 | ||
| 129 | if(HOST_AARCH64) | ||
| 130 | target_include_directories(ssl_obj PRIVATE ../crypto/arch/aarch64/) | ||
| 131 | elseif(HOST_ARM) | ||
| 132 | target_include_directories(ssl_obj PRIVATE ../crypto/arch/arm/) | ||
| 133 | elseif(HOST_I386) | ||
| 134 | target_include_directories(ssl_obj PRIVATE ../crypto/arch/i386/) | ||
| 135 | elseif(HOST_LOONGARCH64) | ||
| 136 | target_include_directories(ssl_obj PRIVATE ../crypto/arch/loongarch64) | ||
| 137 | elseif(HOST_MIPS64) | ||
| 138 | target_include_directories(ssl_obj PRIVATE ../crypto/arch/mips64) | ||
| 139 | elseif(HOST_MIPS) | ||
| 140 | target_include_directories(ssl_obj PRIVATE ../crypto/arch/mips) | ||
| 141 | elseif(HOST_POWERPC) | ||
| 142 | target_include_directories(ssl_obj PRIVATE ../crypto/arch/powerpc) | ||
| 143 | elseif(HOST_POWERPC64) | ||
| 144 | target_include_directories(ssl_obj PRIVATE ../crypto/arch/powerpc64) | ||
| 145 | elseif(HOST_RISCV64) | ||
| 146 | target_include_directories(ssl_obj PRIVATE ../crypto/arch/riscv64) | ||
| 147 | elseif(HOST_SPARC64) | ||
| 148 | target_include_directories(ssl_obj PRIVATE ../crypto/arch/sparc64) | ||
| 149 | elseif(HOST_X86_64) | ||
| 150 | target_include_directories(ssl_obj PRIVATE ../crypto/arch/amd64) | ||
| 151 | endif() | ||
| 152 | |||
| 107 | install( | 153 | install( |
| 108 | TARGETS ssl | 154 | TARGETS ssl |
| 109 | EXPORT SSL-target | 155 | EXPORT SSL-target |
| @@ -135,4 +181,3 @@ if(BUILD_SHARED_LIBS) | |||
| 135 | add_library(ssl-static STATIC $<TARGET_OBJECTS:ssl_obj>) | 181 | add_library(ssl-static STATIC $<TARGET_OBJECTS:ssl_obj>) |
| 136 | target_link_libraries(ssl-static crypto-static ${PLATFORM_LIBS}) | 182 | target_link_libraries(ssl-static crypto-static ${PLATFORM_LIBS}) |
| 137 | endif() | 183 | endif() |
| 138 | |||
diff --git a/ssl/Makefile.am b/ssl/Makefile.am index a7a7d72..3096749 100644 --- a/ssl/Makefile.am +++ b/ssl/Makefile.am | |||
| @@ -1,3 +1,18 @@ | |||
| 1 | # | ||
| 2 | # Copyright (c) 2014 Brent Cook | ||
| 3 | # | ||
| 4 | # Permission to use, copy, modify, and distribute this software for any | ||
| 5 | # purpose with or without fee is hereby granted, provided that the above | ||
| 6 | # copyright notice and this permission notice appear in all copies. | ||
| 7 | # | ||
| 8 | # THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES | ||
| 9 | # WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF | ||
| 10 | # MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR | ||
| 11 | # ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES | ||
| 12 | # WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN | ||
| 13 | # ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF | ||
| 14 | # OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. | ||
| 15 | |||
| 1 | include $(top_srcdir)/Makefile.am.common | 16 | include $(top_srcdir)/Makefile.am.common |
| 2 | 17 | ||
| 3 | -include $(abs_top_builddir)/crypto/libcrypto_la_objects.mk | 18 | -include $(abs_top_builddir)/crypto/libcrypto_la_objects.mk |
| @@ -26,7 +41,7 @@ EXTRA_libssl_la_DEPENDENCIES = libssl_la_objects.mk | |||
| 26 | 41 | ||
| 27 | libssl_la_objects.mk: Makefile | 42 | libssl_la_objects.mk: Makefile |
| 28 | @echo "libssl_la_objects= $(libssl_la_OBJECTS)" \ | 43 | @echo "libssl_la_objects= $(libssl_la_OBJECTS)" \ |
| 29 | | sed 's/ */ $$\(abs_top_builddir\)\/ssl\//g' \ | 44 | | sed 's/ */ $$\(top_builddir\)\/ssl\//g' \ |
| 30 | > libssl_la_objects.mk | 45 | > libssl_la_objects.mk |
| 31 | 46 | ||
| 32 | .PHONY: remove_bs_objects | 47 | .PHONY: remove_bs_objects |
| @@ -114,3 +129,59 @@ noinst_HEADERS += tls12_internal.h | |||
| 114 | noinst_HEADERS += tls13_internal.h | 129 | noinst_HEADERS += tls13_internal.h |
| 115 | noinst_HEADERS += tls13_handshake.h | 130 | noinst_HEADERS += tls13_handshake.h |
| 116 | noinst_HEADERS += tls13_record.h | 131 | noinst_HEADERS += tls13_record.h |
| 132 | |||
| 133 | # arch | ||
| 134 | if HOST_AARCH64 | ||
| 135 | libssl_la_CPPFLAGS += -I$(top_srcdir)/crypto/arch/aarch64/ | ||
| 136 | endif | ||
| 137 | noinst_HEADERS += $(top_srcdir)/crypto/arch/aarch64/crypto_arch.h | ||
| 138 | |||
| 139 | if HOST_ARM | ||
| 140 | libssl_la_CPPFLAGS += -I$(top_srcdir)/crypto/arch/arm/ | ||
| 141 | endif | ||
| 142 | noinst_HEADERS += $(top_srcdir)/crypto/arch/arm/crypto_arch.h | ||
| 143 | |||
| 144 | if HOST_I386 | ||
| 145 | libssl_la_CPPFLAGS += -I$(top_srcdir)/crypto/arch/i386/ | ||
| 146 | endif | ||
| 147 | noinst_HEADERS += $(top_srcdir)/crypto/arch/i386/crypto_arch.h | ||
| 148 | |||
| 149 | if HOST_LOONGARCH64 | ||
| 150 | libssl_la_CPPFLAGS += -I$(top_srcdir)/crypto/arch/loongarch64/ | ||
| 151 | endif | ||
| 152 | noinst_HEADERS += $(top_srcdir)/crypto/arch/loongarch64/crypto_arch.h | ||
| 153 | |||
| 154 | if HOST_MIPS | ||
| 155 | libssl_la_CPPFLAGS += -I$(top_srcdir)/crypto/arch/mips/ | ||
| 156 | endif | ||
| 157 | noinst_HEADERS += $(top_srcdir)/crypto/arch/mips/crypto_arch.h | ||
| 158 | |||
| 159 | if HOST_MIPS64 | ||
| 160 | libssl_la_CPPFLAGS += -I$(top_srcdir)/crypto/arch/mips64/ | ||
| 161 | endif | ||
| 162 | noinst_HEADERS += $(top_srcdir)/crypto/arch/mips64/crypto_arch.h | ||
| 163 | |||
| 164 | if HOST_POWERPC | ||
| 165 | libssl_la_CPPFLAGS += -I$(top_srcdir)/crypto/arch/powerpc/ | ||
| 166 | endif | ||
| 167 | noinst_HEADERS += $(top_srcdir)/crypto/arch/powerpc/crypto_arch.h | ||
| 168 | |||
| 169 | if HOST_POWERPC64 | ||
| 170 | libssl_la_CPPFLAGS += -I$(top_srcdir)/crypto/arch/powerpc64/ | ||
| 171 | endif | ||
| 172 | noinst_HEADERS += $(top_srcdir)/crypto/arch/powerpc64/crypto_arch.h | ||
| 173 | |||
| 174 | if HOST_RISCV64 | ||
| 175 | libssl_la_CPPFLAGS += -I$(top_srcdir)/crypto/arch/riscv64/ | ||
| 176 | endif | ||
| 177 | noinst_HEADERS += $(top_srcdir)/crypto/arch/riscv64/crypto_arch.h | ||
| 178 | |||
| 179 | if HOST_SPARC64 | ||
| 180 | libssl_la_CPPFLAGS += -I$(top_srcdir)/crypto/arch/sparc64/ | ||
| 181 | endif | ||
| 182 | noinst_HEADERS += $(top_srcdir)/crypto/arch/sparc64/crypto_arch.h | ||
| 183 | |||
| 184 | if HOST_X86_64 | ||
| 185 | libssl_la_CPPFLAGS += -I$(top_srcdir)/crypto/arch/amd64/ | ||
| 186 | endif | ||
| 187 | noinst_HEADERS += $(top_srcdir)/crypto/arch/amd64/crypto_arch.h | ||
diff --git a/tests/CMakeLists.txt b/tests/CMakeLists.txt index 480d893..eaf4ed1 100644 --- a/tests/CMakeLists.txt +++ b/tests/CMakeLists.txt | |||
| @@ -1,3 +1,18 @@ | |||
| 1 | # | ||
| 2 | # Copyright (c) 2015 Brent Cook | ||
| 3 | # | ||
| 4 | # Permission to use, copy, modify, and distribute this software for any | ||
| 5 | # purpose with or without fee is hereby granted, provided that the above | ||
| 6 | # copyright notice and this permission notice appear in all copies. | ||
| 7 | # | ||
| 8 | # THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES | ||
| 9 | # WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF | ||
| 10 | # MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR | ||
| 11 | # ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES | ||
| 12 | # WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN | ||
| 13 | # ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF | ||
| 14 | # OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. | ||
| 15 | |||
| 1 | add_definitions(-DLIBRESSL_CRYPTO_INTERNAL) | 16 | add_definitions(-DLIBRESSL_CRYPTO_INTERNAL) |
| 2 | 17 | ||
| 3 | include_directories( | 18 | include_directories( |
| @@ -6,9 +21,13 @@ include_directories( | |||
| 6 | ../crypto/asn1 | 21 | ../crypto/asn1 |
| 7 | ../crypto/bio | 22 | ../crypto/bio |
| 8 | ../crypto/bn | 23 | ../crypto/bn |
| 24 | ../crypto/bytestring | ||
| 9 | ../crypto/curve25519 | 25 | ../crypto/curve25519 |
| 26 | ../crypto/ec | ||
| 10 | ../crypto/evp | 27 | ../crypto/evp |
| 28 | ../crypto/mlkem | ||
| 11 | ../crypto/modes | 29 | ../crypto/modes |
| 30 | ../crypto/sha | ||
| 12 | ../crypto/x509 | 31 | ../crypto/x509 |
| 13 | ../ssl | 32 | ../ssl |
| 14 | ../apps/openssl | 33 | ../apps/openssl |
| @@ -18,6 +37,30 @@ include_directories( | |||
| 18 | ../include/compat | 37 | ../include/compat |
| 19 | ) | 38 | ) |
| 20 | 39 | ||
| 40 | if(HOST_AARCH64) | ||
| 41 | include_directories(../crypto/arch/aarch64/) | ||
| 42 | elseif(HOST_ARM) | ||
| 43 | include_directories(../crypto/arch/arm/) | ||
| 44 | elseif(HOST_I386) | ||
| 45 | include_directories(../crypto/arch/i386/) | ||
| 46 | elseif(HOST_LOONGARCH64) | ||
| 47 | include_directories(../crypto/arch/loongarch64) | ||
| 48 | elseif(HOST_MIPS64) | ||
| 49 | include_directories(../crypto/arch/mips64) | ||
| 50 | elseif(HOST_MIPS) | ||
| 51 | include_directories(../crypto/arch/mips) | ||
| 52 | elseif(HOST_POWERPC) | ||
| 53 | include_directories(../crypto/arch/powerpc) | ||
| 54 | elseif(HOST_POWERPC64) | ||
| 55 | include_directories(../crypto/arch/powerpc64) | ||
| 56 | elseif(HOST_RISCV64) | ||
| 57 | include_directories(../crypto/arch/riscv64) | ||
| 58 | elseif(HOST_SPARC64) | ||
| 59 | include_directories(../crypto/arch/sparc64) | ||
| 60 | elseif(HOST_X86_64) | ||
| 61 | include_directories(../crypto/arch/amd64) | ||
| 62 | endif() | ||
| 63 | |||
| 21 | add_definitions(-D_PATH_SSL_CA_FILE=\"${CMAKE_CURRENT_SOURCE_DIR}/../cert.pem\") | 64 | add_definitions(-D_PATH_SSL_CA_FILE=\"${CMAKE_CURRENT_SOURCE_DIR}/../cert.pem\") |
| 22 | 65 | ||
| 23 | file(TO_NATIVE_PATH ${CMAKE_CURRENT_SOURCE_DIR} TEST_SOURCE_DIR) | 66 | file(TO_NATIVE_PATH ${CMAKE_CURRENT_SOURCE_DIR} TEST_SOURCE_DIR) |
| @@ -37,6 +80,12 @@ function(add_platform_test TEST_NAME) | |||
| 37 | endif() | 80 | endif() |
| 38 | endfunction() | 81 | endfunction() |
| 39 | 82 | ||
| 83 | # XXX - should probably be in their own static lib | ||
| 84 | set(TEST_HELPER_SRC test.c test_util.c) | ||
| 85 | if(WIN32) | ||
| 86 | set(TEST_HELPER_SRC ${TEST_HELPER_SRC} compat/mkstemp.c) | ||
| 87 | endif() | ||
| 88 | |||
| 40 | # aeadtest | 89 | # aeadtest |
| 41 | add_executable(aeadtest aeadtest.c) | 90 | add_executable(aeadtest aeadtest.c) |
| 42 | target_link_libraries(aeadtest ${OPENSSL_TEST_LIBS}) | 91 | target_link_libraries(aeadtest ${OPENSSL_TEST_LIBS}) |
| @@ -194,8 +243,13 @@ add_executable(bn_convert bn_convert.c) | |||
| 194 | target_link_libraries(bn_convert ${OPENSSL_TEST_LIBS}) | 243 | target_link_libraries(bn_convert ${OPENSSL_TEST_LIBS}) |
| 195 | add_platform_test(bn_convert bn_convert) | 244 | add_platform_test(bn_convert bn_convert) |
| 196 | 245 | ||
| 246 | # bn_ffdh | ||
| 247 | add_executable(bn_ffdh bn_ffdh.c) | ||
| 248 | target_link_libraries(bn_ffdh ${OPENSSL_TEST_LIBS}) | ||
| 249 | add_platform_test(bn_ffdh bn_ffdh) | ||
| 250 | |||
| 197 | # bn_gcd | 251 | # bn_gcd |
| 198 | add_executable(bn_gcd bn_cmp.c) | 252 | add_executable(bn_gcd bn_gcd.c) |
| 199 | target_link_libraries(bn_gcd ${OPENSSL_TEST_LIBS}) | 253 | target_link_libraries(bn_gcd ${OPENSSL_TEST_LIBS}) |
| 200 | add_platform_test(bn_gcd bn_gcd) | 254 | add_platform_test(bn_gcd bn_gcd) |
| 201 | 255 | ||
| @@ -303,9 +357,10 @@ target_link_libraries(cipherstest ${OPENSSL_TEST_LIBS}) | |||
| 303 | add_platform_test(cipherstest cipherstest) | 357 | add_platform_test(cipherstest cipherstest) |
| 304 | 358 | ||
| 305 | ## clienttest | 359 | ## clienttest |
| 306 | #add_executable(clienttest clienttest.c) | 360 | add_executable(clienttest clienttest.c) |
| 307 | #target_link_libraries(clienttest ${OPENSSL_TEST_LIBS}) | 361 | target_link_libraries(clienttest ${OPENSSL_TEST_LIBS}) |
| 308 | #add_platform_test(clienttest clienttest) | 362 | prepare_emscripten_test_target(clienttest) |
| 363 | add_platform_test(clienttest clienttest) | ||
| 309 | 364 | ||
| 310 | # cmstest | 365 | # cmstest |
| 311 | add_executable(cmstest cmstest.c) | 366 | add_executable(cmstest cmstest.c) |
| @@ -368,6 +423,7 @@ add_platform_test(ecc_cdh ecc_cdh) | |||
| 368 | # ec_asn1_test | 423 | # ec_asn1_test |
| 369 | add_executable(ec_asn1_test ec_asn1_test.c) | 424 | add_executable(ec_asn1_test ec_asn1_test.c) |
| 370 | target_link_libraries(ec_asn1_test ${OPENSSL_TEST_LIBS}) | 425 | target_link_libraries(ec_asn1_test ${OPENSSL_TEST_LIBS}) |
| 426 | prepare_emscripten_test_target(ec_asn1_test) | ||
| 371 | add_platform_test(ec_asn1_test ec_asn1_test) | 427 | add_platform_test(ec_asn1_test ec_asn1_test) |
| 372 | 428 | ||
| 373 | # ec_point_conversion | 429 | # ec_point_conversion |
| @@ -396,16 +452,16 @@ add_executable(ed25519test ed25519test.c) | |||
| 396 | target_link_libraries(ed25519test ${OPENSSL_TEST_LIBS}) | 452 | target_link_libraries(ed25519test ${OPENSSL_TEST_LIBS}) |
| 397 | add_platform_test(ed25519test ed25519test) | 453 | add_platform_test(ed25519test ed25519test) |
| 398 | 454 | ||
| 455 | # err_test | ||
| 456 | add_executable(err_test err_test.c) | ||
| 457 | target_link_libraries(err_test ${OPENSSL_TEST_LIBS}) | ||
| 458 | add_platform_test(err_test err_test) | ||
| 459 | |||
| 399 | # evp_ecx_test | 460 | # evp_ecx_test |
| 400 | add_executable(evp_ecx_test evp_ecx_test.c) | 461 | add_executable(evp_ecx_test evp_ecx_test.c) |
| 401 | target_link_libraries(evp_ecx_test ${OPENSSL_TEST_LIBS}) | 462 | target_link_libraries(evp_ecx_test ${OPENSSL_TEST_LIBS}) |
| 402 | add_platform_test(evp_ecx_test evp_ecx_test) | 463 | add_platform_test(evp_ecx_test evp_ecx_test) |
| 403 | 464 | ||
| 404 | # evp_pkey_check | ||
| 405 | add_executable(evp_pkey_check evp_pkey_check.c) | ||
| 406 | target_link_libraries(evp_pkey_check ${OPENSSL_TEST_LIBS}) | ||
| 407 | add_platform_test(evp_pkey_check evp_pkey_check) | ||
| 408 | |||
| 409 | # evp_pkey_cleanup | 465 | # evp_pkey_cleanup |
| 410 | add_executable(evp_pkey_cleanup evp_pkey_cleanup.c) | 466 | add_executable(evp_pkey_cleanup evp_pkey_cleanup.c) |
| 411 | target_link_libraries(evp_pkey_cleanup ${OPENSSL_TEST_LIBS}) | 467 | target_link_libraries(evp_pkey_cleanup ${OPENSSL_TEST_LIBS}) |
| @@ -420,6 +476,7 @@ add_platform_test(evptest evptest ${CMAKE_CURRENT_SOURCE_DIR}/evptests.txt) | |||
| 420 | # evp_test | 476 | # evp_test |
| 421 | add_executable(evp_test evp_test.c) | 477 | add_executable(evp_test evp_test.c) |
| 422 | target_link_libraries(evp_test ${OPENSSL_TEST_LIBS}) | 478 | target_link_libraries(evp_test ${OPENSSL_TEST_LIBS}) |
| 479 | prepare_emscripten_test_target(evp_test) | ||
| 423 | add_platform_test(evp_test evp_test) | 480 | add_platform_test(evp_test evp_test) |
| 424 | 481 | ||
| 425 | # exdata_test | 482 | # exdata_test |
| @@ -507,10 +564,34 @@ prepare_emscripten_test_target(lhash_test) | |||
| 507 | add_platform_test(lhash_test lhash_test) | 564 | add_platform_test(lhash_test lhash_test) |
| 508 | 565 | ||
| 509 | # md_test | 566 | # md_test |
| 510 | add_executable(md_test md_test.c) | 567 | add_executable(md_test md_test.c ${TEST_HELPER_SRC}) |
| 511 | target_link_libraries(md_test ${OPENSSL_TEST_LIBS}) | 568 | target_link_libraries(md_test ${OPENSSL_TEST_LIBS}) |
| 512 | add_platform_test(md_test md_test) | 569 | add_platform_test(md_test md_test) |
| 513 | 570 | ||
| 571 | # mlkem_tests | ||
| 572 | add_executable(mlkem_tests mlkem_tests.c parse_test_file.c) | ||
| 573 | target_link_libraries(mlkem_tests ${OPENSSL_TEST_LIBS}) | ||
| 574 | prepare_emscripten_test_target(mlkem_tests) | ||
| 575 | if(NOT MSVC) | ||
| 576 | add_test(NAME mlkem_tests COMMAND ${CMAKE_CURRENT_SOURCE_DIR}/mlkem_tests.sh) | ||
| 577 | set_tests_properties(mlkem_tests PROPERTIES ENVIRONMENT "srcdir=${TEST_SOURCE_DIR}") | ||
| 578 | else() | ||
| 579 | add_test(NAME mlkem_tests COMMAND ${CMAKE_CURRENT_SOURCE_DIR}/mlkem_tests.bat $<TARGET_FILE:mlkem_tests>) | ||
| 580 | endif() | ||
| 581 | set_tests_properties(mlkem_tests PROPERTIES ENVIRONMENT "srcdir=${TEST_SOURCE_DIR}") | ||
| 582 | |||
| 583 | # mlkem_iteration_tests | ||
| 584 | add_executable(mlkem_iteration_tests mlkem_iteration_tests.c mlkem_tests_util.c) | ||
| 585 | target_link_libraries(mlkem_iteration_tests ${OPENSSL_TEST_LIBS}) | ||
| 586 | prepare_emscripten_test_target(mlkem_iteration_tests) | ||
| 587 | add_platform_test(mlkem_iteration_tests mlkem_iteration_tests) | ||
| 588 | |||
| 589 | # mlkem_unittest | ||
| 590 | add_executable(mlkem_unittest mlkem_unittest.c mlkem_tests_util.c) | ||
| 591 | target_link_libraries(mlkem_unittest ${OPENSSL_TEST_LIBS}) | ||
| 592 | prepare_emscripten_test_target(mlkem_unittest) | ||
| 593 | add_platform_test(mlkem_unittest mlkem_unittest) | ||
| 594 | |||
| 514 | # objectstest | 595 | # objectstest |
| 515 | add_executable(objectstest objectstest.c) | 596 | add_executable(objectstest objectstest.c) |
| 516 | target_link_libraries(objectstest ${OPENSSL_TEST_LIBS}) | 597 | target_link_libraries(objectstest ${OPENSSL_TEST_LIBS}) |
| @@ -520,7 +601,7 @@ add_platform_test(objectstest objectstest) | |||
| 520 | if(ENABLE_EXTRATESTS) | 601 | if(ENABLE_EXTRATESTS) |
| 521 | add_executable(ocsp_test ocsp_test.c) | 602 | add_executable(ocsp_test ocsp_test.c) |
| 522 | target_link_libraries(ocsp_test ${OPENSSL_TEST_LIBS}) | 603 | target_link_libraries(ocsp_test ${OPENSSL_TEST_LIBS}) |
| 523 | if(NOT MSVC) | 604 | if(NOT WIN32) |
| 524 | add_test(NAME ocsptest COMMAND ${CMAKE_CURRENT_SOURCE_DIR}/ocsptest.sh) | 605 | add_test(NAME ocsptest COMMAND ${CMAKE_CURRENT_SOURCE_DIR}/ocsptest.sh) |
| 525 | else() | 606 | else() |
| 526 | add_test(NAME ocsptest COMMAND ${CMAKE_CURRENT_SOURCE_DIR}/ocsptest.bat $<TARGET_FILE:ocsp_test>) | 607 | add_test(NAME ocsptest COMMAND ${CMAKE_CURRENT_SOURCE_DIR}/ocsptest.bat $<TARGET_FILE:ocsp_test>) |
| @@ -569,20 +650,14 @@ add_platform_test(policy policy) | |||
| 569 | # pq_test | 650 | # pq_test |
| 570 | add_executable(pq_test pq_test.c) | 651 | add_executable(pq_test pq_test.c) |
| 571 | target_link_libraries(pq_test ${OPENSSL_TEST_LIBS}) | 652 | target_link_libraries(pq_test ${OPENSSL_TEST_LIBS}) |
| 572 | if(NOT MSVC) | 653 | add_platform_test(pq_test pq_test) |
| 573 | add_test(NAME pq_test COMMAND ${CMAKE_CURRENT_SOURCE_DIR}/pq_test.sh) | ||
| 574 | else() | ||
| 575 | add_test(NAME pq_test COMMAND ${CMAKE_CURRENT_SOURCE_DIR}/pq_test.bat | ||
| 576 | $<TARGET_FILE:pq_test>) | ||
| 577 | endif() | ||
| 578 | set_tests_properties(pq_test PROPERTIES ENVIRONMENT "srcdir=${TEST_SOURCE_DIR}") | ||
| 579 | 654 | ||
| 580 | # quictest | 655 | # quictest |
| 581 | set(QUICTEST_SRC quictest.c) | 656 | set(QUICTEST_SRC quictest.c) |
| 582 | add_executable(quictest ${QUICTEST_SRC}) | 657 | add_executable(quictest ${QUICTEST_SRC}) |
| 583 | target_link_libraries(quictest ${OPENSSL_TEST_LIBS}) | 658 | target_link_libraries(quictest ${OPENSSL_TEST_LIBS}) |
| 584 | prepare_emscripten_test_target(quictest) | 659 | prepare_emscripten_test_target(quictest) |
| 585 | if(NOT MSVC) | 660 | if(NOT WIN32) |
| 586 | add_test(NAME quictest COMMAND ${CMAKE_CURRENT_SOURCE_DIR}/quictest.sh) | 661 | add_test(NAME quictest COMMAND ${CMAKE_CURRENT_SOURCE_DIR}/quictest.sh) |
| 587 | else() | 662 | else() |
| 588 | add_test(NAME quictest COMMAND ${CMAKE_CURRENT_SOURCE_DIR}/quictest.bat $<TARGET_FILE:quictest>) | 663 | add_test(NAME quictest COMMAND ${CMAKE_CURRENT_SOURCE_DIR}/quictest.bat $<TARGET_FILE:quictest>) |
| @@ -614,6 +689,18 @@ add_executable(record_layer_test record_layer_test.c) | |||
| 614 | target_link_libraries(record_layer_test ${OPENSSL_TEST_LIBS}) | 689 | target_link_libraries(record_layer_test ${OPENSSL_TEST_LIBS}) |
| 615 | add_platform_test(record_layer_test record_layer_test) | 690 | add_platform_test(record_layer_test record_layer_test) |
| 616 | 691 | ||
| 692 | # renegotiation_test | ||
| 693 | set(RENEGOTIATION_TEST_SRC renegotiation_test.c) | ||
| 694 | add_executable(renegotiation_test ${RENEGOTIATION_TEST_SRC}) | ||
| 695 | target_link_libraries(renegotiation_test ${OPENSSL_TEST_LIBS}) | ||
| 696 | prepare_emscripten_test_target(renegotiation_test) | ||
| 697 | if(NOT MSVC) | ||
| 698 | add_test(NAME renegotiation_test COMMAND ${CMAKE_CURRENT_SOURCE_DIR}/renegotiation_test.sh) | ||
| 699 | else() | ||
| 700 | add_test(NAME renegotiation_test COMMAND ${CMAKE_CURRENT_SOURCE_DIR}/renegotiation_test.bat $<TARGET_FILE:renegotiation_test>) | ||
| 701 | endif() | ||
| 702 | set_tests_properties(renegotiation_test PROPERTIES ENVIRONMENT "srcdir=${TEST_SOURCE_DIR}") | ||
| 703 | |||
| 617 | # rfc3779 | 704 | # rfc3779 |
| 618 | add_executable(rfc3779 rfc3779.c) | 705 | add_executable(rfc3779 rfc3779.c) |
| 619 | target_link_libraries(rfc3779 ${OPENSSL_TEST_LIBS}) | 706 | target_link_libraries(rfc3779 ${OPENSSL_TEST_LIBS}) |
| @@ -632,6 +719,11 @@ add_executable(rmd_test rmd_test.c) | |||
| 632 | target_link_libraries(rmd_test ${OPENSSL_TEST_LIBS}) | 719 | target_link_libraries(rmd_test ${OPENSSL_TEST_LIBS}) |
| 633 | add_platform_test(rmd_test rmd_test) | 720 | add_platform_test(rmd_test rmd_test) |
| 634 | 721 | ||
| 722 | # rsa_method_test | ||
| 723 | add_executable(rsa_method_test rsa_method_test.c) | ||
| 724 | target_link_libraries(rsa_method_test ${OPENSSL_TEST_LIBS}) | ||
| 725 | add_platform_test(rsa_method_test rsa_method_test) | ||
| 726 | |||
| 635 | # rsa_padding_test | 727 | # rsa_padding_test |
| 636 | add_executable(rsa_padding_test rsa_padding_test.c) | 728 | add_executable(rsa_padding_test rsa_padding_test.c) |
| 637 | target_link_libraries(rsa_padding_test ${OPENSSL_TEST_LIBS}) | 729 | target_link_libraries(rsa_padding_test ${OPENSSL_TEST_LIBS}) |
| @@ -648,7 +740,7 @@ add_platform_test(rsa_test rsa_test) | |||
| 648 | add_executable(servertest servertest.c) | 740 | add_executable(servertest servertest.c) |
| 649 | target_link_libraries(servertest ${OPENSSL_TEST_LIBS}) | 741 | target_link_libraries(servertest ${OPENSSL_TEST_LIBS}) |
| 650 | prepare_emscripten_test_target(servertest) | 742 | prepare_emscripten_test_target(servertest) |
| 651 | if(NOT MSVC) | 743 | if(NOT WIN32) |
| 652 | add_test(NAME servertest COMMAND ${CMAKE_CURRENT_SOURCE_DIR}/servertest.sh) | 744 | add_test(NAME servertest COMMAND ${CMAKE_CURRENT_SOURCE_DIR}/servertest.sh) |
| 653 | else() | 745 | else() |
| 654 | add_test(NAME servertest COMMAND ${CMAKE_CURRENT_SOURCE_DIR}/servertest.bat $<TARGET_FILE:servertest>) | 746 | add_test(NAME servertest COMMAND ${CMAKE_CURRENT_SOURCE_DIR}/servertest.bat $<TARGET_FILE:servertest>) |
| @@ -656,7 +748,7 @@ endif() | |||
| 656 | set_tests_properties(servertest PROPERTIES ENVIRONMENT "srcdir=${TEST_SOURCE_DIR}") | 748 | set_tests_properties(servertest PROPERTIES ENVIRONMENT "srcdir=${TEST_SOURCE_DIR}") |
| 657 | 749 | ||
| 658 | # sha_test | 750 | # sha_test |
| 659 | add_executable(sha_test sha_test.c) | 751 | add_executable(sha_test sha_test.c ${TEST_HELPER_SRC}) |
| 660 | target_link_libraries(sha_test ${OPENSSL_TEST_LIBS}) | 752 | target_link_libraries(sha_test ${OPENSSL_TEST_LIBS}) |
| 661 | add_platform_test(sha_test sha_test) | 753 | add_platform_test(sha_test sha_test) |
| 662 | 754 | ||
| @@ -665,7 +757,7 @@ set(SHUTDOWNTEST_SRC shutdowntest.c) | |||
| 665 | add_executable(shutdowntest ${SHUTDOWNTEST_SRC}) | 757 | add_executable(shutdowntest ${SHUTDOWNTEST_SRC}) |
| 666 | target_link_libraries(shutdowntest ${OPENSSL_TEST_LIBS}) | 758 | target_link_libraries(shutdowntest ${OPENSSL_TEST_LIBS}) |
| 667 | prepare_emscripten_test_target(shutdowntest) | 759 | prepare_emscripten_test_target(shutdowntest) |
| 668 | if(NOT MSVC) | 760 | if(NOT WIN32) |
| 669 | add_test(NAME shutdowntest COMMAND ${CMAKE_CURRENT_SOURCE_DIR}/shutdowntest.sh) | 761 | add_test(NAME shutdowntest COMMAND ${CMAKE_CURRENT_SOURCE_DIR}/shutdowntest.sh) |
| 670 | else() | 762 | else() |
| 671 | add_test(NAME shutdowntest COMMAND ${CMAKE_CURRENT_SOURCE_DIR}/shutdowntest.bat $<TARGET_FILE:shutdowntest>) | 763 | add_test(NAME shutdowntest COMMAND ${CMAKE_CURRENT_SOURCE_DIR}/shutdowntest.bat $<TARGET_FILE:shutdowntest>) |
| @@ -676,7 +768,7 @@ set_tests_properties(shutdowntest PROPERTIES ENVIRONMENT "srcdir=${TEST_SOURCE_D | |||
| 676 | # Emscripten does not support socketpair syscall. | 768 | # Emscripten does not support socketpair syscall. |
| 677 | if(NOT (CMAKE_SYSTEM_NAME MATCHES "WindowsStore" OR EMSCRIPTEN)) | 769 | if(NOT (CMAKE_SYSTEM_NAME MATCHES "WindowsStore" OR EMSCRIPTEN)) |
| 678 | set(SIGNERTEST_SRC signertest.c) | 770 | set(SIGNERTEST_SRC signertest.c) |
| 679 | check_function_exists(pipe2 HAVE_PIPE2) | 771 | check_symbol_exists(pipe2 "fcntl.h;unistd.h" HAVE_PIPE2) |
| 680 | if(HAVE_PIPE2) | 772 | if(HAVE_PIPE2) |
| 681 | add_definitions(-DHAVE_PIPE2) | 773 | add_definitions(-DHAVE_PIPE2) |
| 682 | else() | 774 | else() |
| @@ -737,7 +829,7 @@ add_platform_test(ssl_versions ssl_versions) | |||
| 737 | add_executable(ssltest ssltest.c) | 829 | add_executable(ssltest ssltest.c) |
| 738 | target_link_libraries(ssltest ${OPENSSL_TEST_LIBS}) | 830 | target_link_libraries(ssltest ${OPENSSL_TEST_LIBS}) |
| 739 | prepare_emscripten_test_target(ssltest) | 831 | prepare_emscripten_test_target(ssltest) |
| 740 | if(NOT MSVC) | 832 | if(NOT WIN32) |
| 741 | add_test(NAME ssltest COMMAND ${CMAKE_CURRENT_SOURCE_DIR}/ssltest.sh) | 833 | add_test(NAME ssltest COMMAND ${CMAKE_CURRENT_SOURCE_DIR}/ssltest.sh) |
| 742 | else() | 834 | else() |
| 743 | add_test(NAME ssltest COMMAND ${CMAKE_CURRENT_SOURCE_DIR}/ssltest.bat $<TARGET_FILE:ssltest> $<TARGET_FILE:openssl>) | 835 | add_test(NAME ssltest COMMAND ${CMAKE_CURRENT_SOURCE_DIR}/ssltest.bat $<TARGET_FILE:ssltest> $<TARGET_FILE:openssl>) |
| @@ -748,7 +840,7 @@ set_tests_properties(ssltest PROPERTIES ENVIRONMENT "srcdir=${TEST_SOURCE_DIR}") | |||
| 748 | # access various files for IO. Adding such files to --preload-file is infeasible. | 840 | # access various files for IO. Adding such files to --preload-file is infeasible. |
| 749 | if(NOT EMSCRIPTEN) | 841 | if(NOT EMSCRIPTEN) |
| 750 | # testdsa | 842 | # testdsa |
| 751 | if(NOT MSVC) | 843 | if(NOT WIN32) |
| 752 | add_test(NAME testdsa COMMAND ${CMAKE_CURRENT_SOURCE_DIR}/testdsa.sh) | 844 | add_test(NAME testdsa COMMAND ${CMAKE_CURRENT_SOURCE_DIR}/testdsa.sh) |
| 753 | else() | 845 | else() |
| 754 | add_test(NAME testdsa COMMAND ${CMAKE_CURRENT_SOURCE_DIR}/testdsa.bat $<TARGET_FILE:openssl>) | 846 | add_test(NAME testdsa COMMAND ${CMAKE_CURRENT_SOURCE_DIR}/testdsa.bat $<TARGET_FILE:openssl>) |
| @@ -756,7 +848,7 @@ if(NOT EMSCRIPTEN) | |||
| 756 | set_tests_properties(testdsa PROPERTIES ENVIRONMENT "srcdir=${TEST_SOURCE_DIR}") | 848 | set_tests_properties(testdsa PROPERTIES ENVIRONMENT "srcdir=${TEST_SOURCE_DIR}") |
| 757 | 849 | ||
| 758 | # testenc | 850 | # testenc |
| 759 | if(NOT MSVC) | 851 | if(NOT WIN32) |
| 760 | add_test(NAME testenc COMMAND ${CMAKE_CURRENT_SOURCE_DIR}/testenc.sh) | 852 | add_test(NAME testenc COMMAND ${CMAKE_CURRENT_SOURCE_DIR}/testenc.sh) |
| 761 | else() | 853 | else() |
| 762 | add_test(NAME testenc COMMAND ${CMAKE_CURRENT_SOURCE_DIR}/testenc.bat $<TARGET_FILE:openssl>) | 854 | add_test(NAME testenc COMMAND ${CMAKE_CURRENT_SOURCE_DIR}/testenc.bat $<TARGET_FILE:openssl>) |
| @@ -764,7 +856,7 @@ if(NOT EMSCRIPTEN) | |||
| 764 | set_tests_properties(testenc PROPERTIES ENVIRONMENT "srcdir=${TEST_SOURCE_DIR}") | 856 | set_tests_properties(testenc PROPERTIES ENVIRONMENT "srcdir=${TEST_SOURCE_DIR}") |
| 765 | 857 | ||
| 766 | # testrsa | 858 | # testrsa |
| 767 | if(NOT MSVC) | 859 | if(NOT WIN32) |
| 768 | add_test(NAME testrsa COMMAND ${CMAKE_CURRENT_SOURCE_DIR}/testrsa.sh) | 860 | add_test(NAME testrsa COMMAND ${CMAKE_CURRENT_SOURCE_DIR}/testrsa.sh) |
| 769 | else() | 861 | else() |
| 770 | add_test(NAME testrsa COMMAND ${CMAKE_CURRENT_SOURCE_DIR}/testrsa.bat $<TARGET_FILE:openssl>) | 862 | add_test(NAME testrsa COMMAND ${CMAKE_CURRENT_SOURCE_DIR}/testrsa.bat $<TARGET_FILE:openssl>) |
| @@ -792,7 +884,7 @@ add_platform_test(tlslegacytest tlslegacytest) | |||
| 792 | # Emscripten does not support socketpair syscall. | 884 | # Emscripten does not support socketpair syscall. |
| 793 | if(NOT (CMAKE_SYSTEM_NAME MATCHES "WindowsStore" OR EMSCRIPTEN)) | 885 | if(NOT (CMAKE_SYSTEM_NAME MATCHES "WindowsStore" OR EMSCRIPTEN)) |
| 794 | set(TLSTEST_SRC tlstest.c) | 886 | set(TLSTEST_SRC tlstest.c) |
| 795 | check_function_exists(pipe2 HAVE_PIPE2) | 887 | check_symbol_exists(pipe2 "fcntl.h;unistd.h" HAVE_PIPE2) |
| 796 | if(HAVE_PIPE2) | 888 | if(HAVE_PIPE2) |
| 797 | add_definitions(-DHAVE_PIPE2) | 889 | add_definitions(-DHAVE_PIPE2) |
| 798 | else() | 890 | else() |
| @@ -801,7 +893,7 @@ if(NOT (CMAKE_SYSTEM_NAME MATCHES "WindowsStore" OR EMSCRIPTEN)) | |||
| 801 | 893 | ||
| 802 | add_executable(tlstest ${TLSTEST_SRC}) | 894 | add_executable(tlstest ${TLSTEST_SRC}) |
| 803 | target_link_libraries(tlstest ${LIBTLS_TEST_LIBS}) | 895 | target_link_libraries(tlstest ${LIBTLS_TEST_LIBS}) |
| 804 | if(NOT MSVC) | 896 | if(NOT WIN32) |
| 805 | add_test(NAME tlstest COMMAND ${CMAKE_CURRENT_SOURCE_DIR}/tlstest.sh) | 897 | add_test(NAME tlstest COMMAND ${CMAKE_CURRENT_SOURCE_DIR}/tlstest.sh) |
| 806 | else() | 898 | else() |
| 807 | add_test(NAME tlstest COMMAND ${CMAKE_CURRENT_SOURCE_DIR}/tlstest.bat $<TARGET_FILE:tlstest>) | 899 | add_test(NAME tlstest COMMAND ${CMAKE_CURRENT_SOURCE_DIR}/tlstest.bat $<TARGET_FILE:tlstest>) |
| @@ -834,11 +926,6 @@ add_executable(verifytest verifytest.c) | |||
| 834 | target_link_libraries(verifytest ${LIBTLS_TEST_LIBS}) | 926 | target_link_libraries(verifytest ${LIBTLS_TEST_LIBS}) |
| 835 | add_platform_test(verifytest verifytest) | 927 | add_platform_test(verifytest verifytest) |
| 836 | 928 | ||
| 837 | # whirlpool_test | ||
| 838 | add_executable(whirlpool_test whirlpool_test.c) | ||
| 839 | target_link_libraries(whirlpool_test ${OPENSSL_TEST_LIBS}) | ||
| 840 | add_platform_test(whirlpool_test whirlpool_test) | ||
| 841 | |||
| 842 | # x25519test | 929 | # x25519test |
| 843 | add_executable(x25519test x25519test.c) | 930 | add_executable(x25519test x25519test.c) |
| 844 | target_link_libraries(x25519test ${OPENSSL_TEST_LIBS}) | 931 | target_link_libraries(x25519test ${OPENSSL_TEST_LIBS}) |
| @@ -870,10 +957,10 @@ add_executable(x509_info x509_info.c) | |||
| 870 | target_link_libraries(x509_info ${OPENSSL_TEST_LIBS}) | 957 | target_link_libraries(x509_info ${OPENSSL_TEST_LIBS}) |
| 871 | add_platform_test(x509_info x509_info) | 958 | add_platform_test(x509_info x509_info) |
| 872 | 959 | ||
| 873 | # x509name | 960 | # x509_name_test |
| 874 | add_executable(x509name x509name.c) | 961 | add_executable(x509_name_test x509_name_test.c) |
| 875 | target_link_libraries(x509name ${OPENSSL_TEST_LIBS}) | 962 | target_link_libraries(x509_name_test ${OPENSSL_TEST_LIBS}) |
| 876 | add_platform_test(x509name x509name) | 963 | add_platform_test(x509_name_test x509_name_test) |
| 877 | 964 | ||
| 878 | # x509req_ext | 965 | # x509req_ext |
| 879 | add_executable(x509req_ext x509req_ext.c) | 966 | add_executable(x509req_ext x509req_ext.c) |
diff --git a/tests/Makefile.am b/tests/Makefile.am index 76ed83a..22e3dee 100644 --- a/tests/Makefile.am +++ b/tests/Makefile.am | |||
| @@ -1,3 +1,18 @@ | |||
| 1 | # | ||
| 2 | # Copyright (c) 2015 Brent Cook | ||
| 3 | # | ||
| 4 | # Permission to use, copy, modify, and distribute this software for any | ||
| 5 | # purpose with or without fee is hereby granted, provided that the above | ||
| 6 | # copyright notice and this permission notice appear in all copies. | ||
| 7 | # | ||
| 8 | # THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES | ||
| 9 | # WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF | ||
| 10 | # MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR | ||
| 11 | # ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES | ||
| 12 | # WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN | ||
| 13 | # ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF | ||
| 14 | # OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. | ||
| 15 | |||
| 1 | include $(top_srcdir)/Makefile.am.common | 16 | include $(top_srcdir)/Makefile.am.common |
| 2 | 17 | ||
| 3 | -include $(abs_top_builddir)/crypto/libcrypto_la_objects.mk | 18 | -include $(abs_top_builddir)/crypto/libcrypto_la_objects.mk |
| @@ -10,15 +25,65 @@ AM_CPPFLAGS += -I $(top_srcdir)/crypto/ | |||
| 10 | AM_CPPFLAGS += -I $(top_srcdir)/crypto/asn1 | 25 | AM_CPPFLAGS += -I $(top_srcdir)/crypto/asn1 |
| 11 | AM_CPPFLAGS += -I $(top_srcdir)/crypto/bio | 26 | AM_CPPFLAGS += -I $(top_srcdir)/crypto/bio |
| 12 | AM_CPPFLAGS += -I $(top_srcdir)/crypto/bn | 27 | AM_CPPFLAGS += -I $(top_srcdir)/crypto/bn |
| 28 | AM_CPPFLAGS += -I $(top_srcdir)/crypto/bytestring | ||
| 13 | AM_CPPFLAGS += -I $(top_srcdir)/crypto/curve25519 | 29 | AM_CPPFLAGS += -I $(top_srcdir)/crypto/curve25519 |
| 30 | AM_CPPFLAGS += -I $(top_srcdir)/crypto/ec | ||
| 14 | AM_CPPFLAGS += -I $(top_srcdir)/crypto/evp | 31 | AM_CPPFLAGS += -I $(top_srcdir)/crypto/evp |
| 32 | AM_CPPFLAGS += -I $(top_srcdir)/crypto/mlkem | ||
| 15 | AM_CPPFLAGS += -I $(top_srcdir)/crypto/modes | 33 | AM_CPPFLAGS += -I $(top_srcdir)/crypto/modes |
| 34 | AM_CPPFLAGS += -I $(top_srcdir)/crypto/sha | ||
| 16 | AM_CPPFLAGS += -I $(top_srcdir)/crypto/x509 | 35 | AM_CPPFLAGS += -I $(top_srcdir)/crypto/x509 |
| 17 | AM_CPPFLAGS += -I $(top_srcdir)/ssl | 36 | AM_CPPFLAGS += -I $(top_srcdir)/ssl |
| 37 | AM_CPPFLAGS += -I $(top_srcdir)/tests | ||
| 18 | AM_CPPFLAGS += -I $(top_srcdir)/apps/openssl | 38 | AM_CPPFLAGS += -I $(top_srcdir)/apps/openssl |
| 19 | AM_CPPFLAGS += -I $(top_srcdir)/apps/openssl/compat | 39 | AM_CPPFLAGS += -I $(top_srcdir)/apps/openssl/compat |
| 20 | AM_CPPFLAGS += -D_PATH_SSL_CA_FILE=\"$(top_srcdir)/cert.pem\" | 40 | AM_CPPFLAGS += -D_PATH_SSL_CA_FILE=\"$(top_srcdir)/cert.pem\" |
| 21 | 41 | ||
| 42 | # arch | ||
| 43 | if HOST_AARCH64 | ||
| 44 | AM_CPPFLAGS += -I$(top_srcdir)/crypto/arch/aarch64/ | ||
| 45 | endif | ||
| 46 | |||
| 47 | if HOST_ARM | ||
| 48 | AM_CPPFLAGS += -I$(top_srcdir)/crypto/arch/arm/ | ||
| 49 | endif | ||
| 50 | |||
| 51 | if HOST_I386 | ||
| 52 | AM_CPPFLAGS += -I$(top_srcdir)/crypto/arch/i386/ | ||
| 53 | endif | ||
| 54 | |||
| 55 | if HOST_LOONGARCH64 | ||
| 56 | AM_CPPFLAGS += -I$(top_srcdir)/crypto/arch/loongarch64/ | ||
| 57 | endif | ||
| 58 | |||
| 59 | if HOST_MIPS | ||
| 60 | AM_CPPFLAGS += -I$(top_srcdir)/crypto/arch/mips/ | ||
| 61 | endif | ||
| 62 | |||
| 63 | if HOST_MIPS64 | ||
| 64 | AM_CPPFLAGS += -I$(top_srcdir)/crypto/arch/mips64/ | ||
| 65 | endif | ||
| 66 | |||
| 67 | if HOST_POWERPC | ||
| 68 | AM_CPPFLAGS += -I$(top_srcdir)/crypto/arch/powerpc/ | ||
| 69 | endif | ||
| 70 | |||
| 71 | if HOST_POWERPC64 | ||
| 72 | AM_CPPFLAGS += -I$(top_srcdir)/crypto/arch/powerpc64/ | ||
| 73 | endif | ||
| 74 | |||
| 75 | if HOST_RISCV64 | ||
| 76 | AM_CPPFLAGS += -I$(top_srcdir)/crypto/arch/riscv64/ | ||
| 77 | endif | ||
| 78 | |||
| 79 | if HOST_SPARC64 | ||
| 80 | AM_CPPFLAGS += -I$(top_srcdir)/crypto/arch/sparc64/ | ||
| 81 | endif | ||
| 82 | |||
| 83 | if HOST_X86_64 | ||
| 84 | AM_CPPFLAGS += -I$(top_srcdir)/crypto/arch/amd64/ | ||
| 85 | endif | ||
| 86 | |||
| 22 | noinst_LTLIBRARIES = libtest.la | 87 | noinst_LTLIBRARIES = libtest.la |
| 23 | libtest_la_LIBADD = $(libcrypto_la_objects) | 88 | libtest_la_LIBADD = $(libcrypto_la_objects) |
| 24 | libtest_la_LIBADD += $(libcompat_la_objects) | 89 | libtest_la_LIBADD += $(libcompat_la_objects) |
| @@ -37,6 +102,13 @@ check_PROGRAMS = | |||
| 37 | EXTRA_DIST = CMakeLists.txt | 102 | EXTRA_DIST = CMakeLists.txt |
| 38 | DISTCLEANFILES = pidwraptest.txt | 103 | DISTCLEANFILES = pidwraptest.txt |
| 39 | 104 | ||
| 105 | # XXX - should probably be in their own static lib | ||
| 106 | TEST_HELPER_SRC = test.c test_util.c | ||
| 107 | noinst_HEADERS = test.h | ||
| 108 | EXTRA_DIST += $(TEST_HELPER_SRC) | ||
| 109 | # Needed by test helper on MSVC | ||
| 110 | EXTRA_DIST += compat/mkstemp.c | ||
| 111 | |||
| 40 | # aeadtest | 112 | # aeadtest |
| 41 | TESTS += aeadtest.sh | 113 | TESTS += aeadtest.sh |
| 42 | check_PROGRAMS += aeadtest | 114 | check_PROGRAMS += aeadtest |
| @@ -193,6 +265,11 @@ TESTS += bn_convert | |||
| 193 | check_PROGRAMS += bn_convert | 265 | check_PROGRAMS += bn_convert |
| 194 | bn_convert_SOURCES = bn_convert.c | 266 | bn_convert_SOURCES = bn_convert.c |
| 195 | 267 | ||
| 268 | # bn_ffdh | ||
| 269 | TESTS += bn_ffdh | ||
| 270 | check_PROGRAMS += bn_ffdh | ||
| 271 | bn_ffdh_SOURCES = bn_ffdh.c | ||
| 272 | |||
| 196 | # bn_gcd | 273 | # bn_gcd |
| 197 | TESTS += bn_gcd | 274 | TESTS += bn_gcd |
| 198 | check_PROGRAMS += bn_gcd | 275 | check_PROGRAMS += bn_gcd |
| @@ -289,7 +366,7 @@ chachatest_SOURCES = chachatest.c | |||
| 289 | TESTS += cipher_list | 366 | TESTS += cipher_list |
| 290 | check_PROGRAMS += cipher_list | 367 | check_PROGRAMS += cipher_list |
| 291 | cipher_list_SOURCES = cipher_list.c | 368 | cipher_list_SOURCES = cipher_list.c |
| 292 | noinst_HEADERS = tests.h | 369 | noinst_HEADERS += tests.h |
| 293 | 370 | ||
| 294 | # cipherstest | 371 | # cipherstest |
| 295 | TESTS += cipherstest | 372 | TESTS += cipherstest |
| @@ -297,9 +374,9 @@ check_PROGRAMS += cipherstest | |||
| 297 | cipherstest_SOURCES = cipherstest.c | 374 | cipherstest_SOURCES = cipherstest.c |
| 298 | 375 | ||
| 299 | ## clienttest | 376 | ## clienttest |
| 300 | #TESTS += clienttest | 377 | TESTS += clienttest |
| 301 | #check_PROGRAMS += clienttest | 378 | check_PROGRAMS += clienttest |
| 302 | #clienttest_SOURCES = clienttest.c | 379 | clienttest_SOURCES = clienttest.c |
| 303 | 380 | ||
| 304 | # cmstest | 381 | # cmstest |
| 305 | TESTS += cmstest | 382 | TESTS += cmstest |
| @@ -389,16 +466,16 @@ TESTS += ed25519test | |||
| 389 | check_PROGRAMS += ed25519test | 466 | check_PROGRAMS += ed25519test |
| 390 | ed25519test_SOURCES = ed25519test.c | 467 | ed25519test_SOURCES = ed25519test.c |
| 391 | 468 | ||
| 469 | # err_test | ||
| 470 | TESTS += err_test | ||
| 471 | check_PROGRAMS += err_test | ||
| 472 | err_test_SOURCES = err_test.c | ||
| 473 | |||
| 392 | # evp_ecx_test | 474 | # evp_ecx_test |
| 393 | TESTS += evp_ecx_test | 475 | TESTS += evp_ecx_test |
| 394 | check_PROGRAMS += evp_ecx_test | 476 | check_PROGRAMS += evp_ecx_test |
| 395 | evp_ecx_test_SOURCES = evp_ecx_test.c | 477 | evp_ecx_test_SOURCES = evp_ecx_test.c |
| 396 | 478 | ||
| 397 | # evp_pkey_check | ||
| 398 | TESTS += evp_pkey_check | ||
| 399 | check_PROGRAMS += evp_pkey_check | ||
| 400 | evp_pkey_check_SOURCES = evp_pkey_check.c | ||
| 401 | |||
| 402 | # evp_pkey_cleanup | 479 | # evp_pkey_cleanup |
| 403 | TESTS += evp_pkey_cleanup | 480 | TESTS += evp_pkey_cleanup |
| 404 | check_PROGRAMS += evp_pkey_cleanup | 481 | check_PROGRAMS += evp_pkey_cleanup |
| @@ -499,7 +576,36 @@ lhash_test_SOURCES = lhash_test.c | |||
| 499 | # md_test | 576 | # md_test |
| 500 | TESTS += md_test | 577 | TESTS += md_test |
| 501 | check_PROGRAMS += md_test | 578 | check_PROGRAMS += md_test |
| 502 | md_test_SOURCES = md_test.c | 579 | md_test_SOURCES = md_test.c $(TEST_HELPER_SRC) |
| 580 | |||
| 581 | noinst_HEADERS += mlkem_tests_util.h | ||
| 582 | noinst_HEADERS += parse_test_file.h | ||
| 583 | |||
| 584 | # mlkem_tests | ||
| 585 | TESTS += mlkem_tests.sh | ||
| 586 | check_PROGRAMS += mlkem_tests | ||
| 587 | mlkem_tests_SOURCES = mlkem_tests.c parse_test_file.c | ||
| 588 | EXTRA_DIST += mlkem_tests.sh mlkem_tests.bat | ||
| 589 | EXTRA_DIST += mlkem768_decap_tests.txt | ||
| 590 | EXTRA_DIST += mlkem768_encap_tests.txt | ||
| 591 | EXTRA_DIST += mlkem768_keygen_tests.txt | ||
| 592 | EXTRA_DIST += mlkem768_nist_decap_tests.txt | ||
| 593 | EXTRA_DIST += mlkem768_nist_keygen_tests.txt | ||
| 594 | EXTRA_DIST += mlkem1024_decap_tests.txt | ||
| 595 | EXTRA_DIST += mlkem1024_encap_tests.txt | ||
| 596 | EXTRA_DIST += mlkem1024_keygen_tests.txt | ||
| 597 | EXTRA_DIST += mlkem1024_nist_decap_tests.txt | ||
| 598 | EXTRA_DIST += mlkem1024_nist_keygen_tests.txt | ||
| 599 | |||
| 600 | # mlkem_iteration_tests | ||
| 601 | TESTS += mlkem_iteration_tests | ||
| 602 | check_PROGRAMS += mlkem_iteration_tests | ||
| 603 | mlkem_iteration_tests_SOURCES = mlkem_iteration_tests.c mlkem_tests_util.c | ||
| 604 | |||
| 605 | # mlkem_unittest | ||
| 606 | TESTS += mlkem_unittest | ||
| 607 | check_PROGRAMS += mlkem_unittest | ||
| 608 | mlkem_unittest_SOURCES = mlkem_unittest.c mlkem_tests_util.c | ||
| 503 | 609 | ||
| 504 | # objectstest | 610 | # objectstest |
| 505 | TESTS += objectstest | 611 | TESTS += objectstest |
| @@ -578,11 +684,9 @@ EXTRA_DIST += policy_root2.pem | |||
| 578 | EXTRA_DIST += policy_root_cross_inhibit_mapping.pem | 684 | EXTRA_DIST += policy_root_cross_inhibit_mapping.pem |
| 579 | 685 | ||
| 580 | # pq_test | 686 | # pq_test |
| 581 | TESTS += pq_test.sh | 687 | TESTS += pq_test |
| 582 | check_PROGRAMS += pq_test | 688 | check_PROGRAMS += pq_test |
| 583 | pq_test_SOURCES = pq_test.c | 689 | pq_test_SOURCES = pq_test.c |
| 584 | EXTRA_DIST += pq_test.sh pq_test.bat | ||
| 585 | EXTRA_DIST += pq_expected.txt | ||
| 586 | 690 | ||
| 587 | # quictest | 691 | # quictest |
| 588 | TESTS += quictest.sh | 692 | TESTS += quictest.sh |
| @@ -615,6 +719,12 @@ TESTS += record_layer_test | |||
| 615 | check_PROGRAMS += record_layer_test | 719 | check_PROGRAMS += record_layer_test |
| 616 | record_layer_test_SOURCES = record_layer_test.c | 720 | record_layer_test_SOURCES = record_layer_test.c |
| 617 | 721 | ||
| 722 | # renegotiation_test | ||
| 723 | TESTS += renegotiation_test.sh | ||
| 724 | check_PROGRAMS += renegotiation_test | ||
| 725 | renegotiation_test_SOURCES = renegotiation_test.c | ||
| 726 | EXTRA_DIST += renegotiation_test.sh renegotiation_test.bat | ||
| 727 | |||
| 618 | # rfc3779 | 728 | # rfc3779 |
| 619 | TESTS += rfc3779 | 729 | TESTS += rfc3779 |
| 620 | rfc3779_CPPFLAGS = $(AM_CPPFLAGS) | 730 | rfc3779_CPPFLAGS = $(AM_CPPFLAGS) |
| @@ -637,6 +747,11 @@ TESTS += rmd_test | |||
| 637 | check_PROGRAMS += rmd_test | 747 | check_PROGRAMS += rmd_test |
| 638 | rmd_test_SOURCES = rmd_test.c | 748 | rmd_test_SOURCES = rmd_test.c |
| 639 | 749 | ||
| 750 | # rsa_method_test | ||
| 751 | TESTS += rsa_method_test | ||
| 752 | check_PROGRAMS += rsa_method_test | ||
| 753 | rsa_method_test_SOURCES = rsa_method_test.c | ||
| 754 | |||
| 640 | # rsa_padding_test | 755 | # rsa_padding_test |
| 641 | TESTS += rsa_padding_test | 756 | TESTS += rsa_padding_test |
| 642 | check_PROGRAMS += rsa_padding_test | 757 | check_PROGRAMS += rsa_padding_test |
| @@ -658,7 +773,7 @@ EXTRA_DIST += servertest.sh servertest.bat | |||
| 658 | # sha_test | 773 | # sha_test |
| 659 | TESTS += sha_test | 774 | TESTS += sha_test |
| 660 | check_PROGRAMS += sha_test | 775 | check_PROGRAMS += sha_test |
| 661 | sha_test_SOURCES = sha_test.c | 776 | sha_test_SOURCES = sha_test.c $(TEST_HELPER_SRC) |
| 662 | 777 | ||
| 663 | # shutdowntest | 778 | # shutdowntest |
| 664 | TESTS += shutdowntest.sh | 779 | TESTS += shutdowntest.sh |
| @@ -795,11 +910,6 @@ TESTS += verifytest | |||
| 795 | check_PROGRAMS += verifytest | 910 | check_PROGRAMS += verifytest |
| 796 | verifytest_SOURCES = verifytest.c | 911 | verifytest_SOURCES = verifytest.c |
| 797 | 912 | ||
| 798 | # whirlpool | ||
| 799 | TESTS += whirlpool_test | ||
| 800 | check_PROGRAMS += whirlpool_test | ||
| 801 | whirlpool_test_SOURCES = whirlpool_test.c | ||
| 802 | |||
| 803 | # x25519test | 913 | # x25519test |
| 804 | TESTS += x25519test | 914 | TESTS += x25519test |
| 805 | check_PROGRAMS += x25519test | 915 | check_PROGRAMS += x25519test |
| @@ -830,10 +940,10 @@ TESTS += x509_info | |||
| 830 | check_PROGRAMS += x509_info | 940 | check_PROGRAMS += x509_info |
| 831 | x509_info_SOURCES = x509_info.c | 941 | x509_info_SOURCES = x509_info.c |
| 832 | 942 | ||
| 833 | # x509name | 943 | # x509_name_test |
| 834 | TESTS += x509name | 944 | TESTS += x509_name_test |
| 835 | check_PROGRAMS += x509name | 945 | check_PROGRAMS += x509_name_test |
| 836 | x509name_SOURCES = x509name.c | 946 | x509_name_test_SOURCES = x509_name_test.c |
| 837 | 947 | ||
| 838 | # x509req_ext | 948 | # x509req_ext |
| 839 | TESTS += x509req_ext | 949 | TESTS += x509req_ext |
diff --git a/tests/aeadtest.sh b/tests/aeadtest.sh index 212e354..bb09df2 100755 --- a/tests/aeadtest.sh +++ b/tests/aeadtest.sh | |||
| @@ -1,4 +1,19 @@ | |||
| 1 | #!/bin/sh | 1 | #!/bin/sh |
| 2 | # | ||
| 3 | # Copyright (c) 2014 Brent Cook | ||
| 4 | # | ||
| 5 | # Permission to use, copy, modify, and distribute this software for any | ||
| 6 | # purpose with or without fee is hereby granted, provided that the above | ||
| 7 | # copyright notice and this permission notice appear in all copies. | ||
| 8 | # | ||
| 9 | # THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES | ||
| 10 | # WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF | ||
| 11 | # MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR | ||
| 12 | # ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES | ||
| 13 | # WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN | ||
| 14 | # ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF | ||
| 15 | # OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. | ||
| 16 | |||
| 2 | set -e | 17 | set -e |
| 3 | TEST=./aeadtest | 18 | TEST=./aeadtest |
| 4 | if [ -e ./aeadtest.exe ]; then | 19 | if [ -e ./aeadtest.exe ]; then |
diff --git a/tests/arc4randomforktest.sh b/tests/arc4randomforktest.sh index fe03068..bbe7641 100755 --- a/tests/arc4randomforktest.sh +++ b/tests/arc4randomforktest.sh | |||
| @@ -1,4 +1,19 @@ | |||
| 1 | #!/bin/sh | 1 | #!/bin/sh |
| 2 | # | ||
| 3 | # Copyright (c) 2014 Brent Cook | ||
| 4 | # | ||
| 5 | # Permission to use, copy, modify, and distribute this software for any | ||
| 6 | # purpose with or without fee is hereby granted, provided that the above | ||
| 7 | # copyright notice and this permission notice appear in all copies. | ||
| 8 | # | ||
| 9 | # THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES | ||
| 10 | # WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF | ||
| 11 | # MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR | ||
| 12 | # ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES | ||
| 13 | # WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN | ||
| 14 | # ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF | ||
| 15 | # OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. | ||
| 16 | |||
| 2 | set -e | 17 | set -e |
| 3 | ./arc4randomforktest | 18 | ./arc4randomforktest |
| 4 | ./arc4randomforktest -b | 19 | ./arc4randomforktest -b |
diff --git a/tests/cmake/CMakeLists.txt b/tests/cmake/CMakeLists.txt index 956fbfd..c3b7c4f 100644 --- a/tests/cmake/CMakeLists.txt +++ b/tests/cmake/CMakeLists.txt | |||
| @@ -1,3 +1,18 @@ | |||
| 1 | # | ||
| 2 | # Copyright (c) 2023 Pierre Wendling | ||
| 3 | # | ||
| 4 | # Permission to use, copy, modify, and distribute this software for any | ||
| 5 | # purpose with or without fee is hereby granted, provided that the above | ||
| 6 | # copyright notice and this permission notice appear in all copies. | ||
| 7 | # | ||
| 8 | # THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES | ||
| 9 | # WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF | ||
| 10 | # MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR | ||
| 11 | # ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES | ||
| 12 | # WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN | ||
| 13 | # ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF | ||
| 14 | # OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. | ||
| 15 | |||
| 1 | cmake_minimum_required(VERSION 3.5) | 16 | cmake_minimum_required(VERSION 3.5) |
| 2 | 17 | ||
| 3 | project(LibreSSL_Consumer LANGUAGES C) | 18 | project(LibreSSL_Consumer LANGUAGES C) |
diff --git a/tests/compat/mkstemp.c b/tests/compat/mkstemp.c new file mode 100644 index 0000000..fe3d15a --- /dev/null +++ b/tests/compat/mkstemp.c | |||
| @@ -0,0 +1,52 @@ | |||
| 1 | /* | ||
| 2 | musl as a whole is licensed under the following standard MIT license: | ||
| 3 | |||
| 4 | ---------------------------------------------------------------------- | ||
| 5 | Copyright © 2005-2020 Rich Felker, et al. | ||
| 6 | |||
| 7 | Permission is hereby granted, free of charge, to any person obtaining | ||
| 8 | a copy of this software and associated documentation files (the | ||
| 9 | "Software"), to deal in the Software without restriction, including | ||
| 10 | without limitation the rights to use, copy, modify, merge, publish, | ||
| 11 | distribute, sublicense, and/or sell copies of the Software, and to | ||
| 12 | permit persons to whom the Software is furnished to do so, subject to | ||
| 13 | the following conditions: | ||
| 14 | |||
| 15 | The above copyright notice and this permission notice shall be | ||
| 16 | included in all copies or substantial portions of the Software. | ||
| 17 | |||
| 18 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, | ||
| 19 | EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF | ||
| 20 | MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. | ||
| 21 | IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY | ||
| 22 | CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, | ||
| 23 | TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE | ||
| 24 | SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. | ||
| 25 | ---------------------------------------------------------------------- | ||
| 26 | */ | ||
| 27 | |||
| 28 | #include <string.h> | ||
| 29 | #include <stdio.h> | ||
| 30 | #include <stdlib.h> | ||
| 31 | #include <fcntl.h> | ||
| 32 | #include <unistd.h> | ||
| 33 | #include <limits.h> | ||
| 34 | #include <errno.h> | ||
| 35 | |||
| 36 | #include <io.h> | ||
| 37 | |||
| 38 | int mkstemp(char *template) | ||
| 39 | { | ||
| 40 | int fd; | ||
| 41 | retry: | ||
| 42 | if (!_mktemp(template)) return -1; | ||
| 43 | fd = open(template, O_RDWR | O_CREAT | O_EXCL, 0600); | ||
| 44 | if (fd >= 0) return fd; | ||
| 45 | if (errno == EEXIST) { | ||
| 46 | /* this is safe because mktemp verified | ||
| 47 | * that we have a valid template string */ | ||
| 48 | strcpy(template+strlen(template)-6, "XXXXXX"); | ||
| 49 | goto retry; | ||
| 50 | } | ||
| 51 | return -1; | ||
| 52 | } | ||
diff --git a/tests/compat/pipe2.c b/tests/compat/pipe2.c index c27a858..d7b4062 100644 --- a/tests/compat/pipe2.c +++ b/tests/compat/pipe2.c | |||
| @@ -42,7 +42,7 @@ static int setfl(int fd, int flag) | |||
| 42 | static void create_issue_1069_sentinels(int socket_vector[2]) | 42 | static void create_issue_1069_sentinels(int socket_vector[2]) |
| 43 | { | 43 | { |
| 44 | int fd = open("CONIN$", O_RDONLY); | 44 | int fd = open("CONIN$", O_RDONLY); |
| 45 | if (fd == -1 || fd > socket_vector[0] && fd > socket_vector[1]) { | 45 | if (fd == -1 || (fd > socket_vector[0] && fd > socket_vector[1])) { |
| 46 | return; | 46 | return; |
| 47 | } | 47 | } |
| 48 | create_issue_1069_sentinels(socket_vector); | 48 | create_issue_1069_sentinels(socket_vector); |
diff --git a/tests/dtlstest.sh b/tests/dtlstest.sh index 8f9b229..f0b7161 100755 --- a/tests/dtlstest.sh +++ b/tests/dtlstest.sh | |||
| @@ -1,4 +1,19 @@ | |||
| 1 | #!/bin/sh | 1 | #!/bin/sh |
| 2 | # | ||
| 3 | # Copyright (c) 2021 Kinichiro Inoguchi | ||
| 4 | # | ||
| 5 | # Permission to use, copy, modify, and distribute this software for any | ||
| 6 | # purpose with or without fee is hereby granted, provided that the above | ||
| 7 | # copyright notice and this permission notice appear in all copies. | ||
| 8 | # | ||
| 9 | # THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES | ||
| 10 | # WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF | ||
| 11 | # MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR | ||
| 12 | # ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES | ||
| 13 | # WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN | ||
| 14 | # ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF | ||
| 15 | # OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. | ||
| 16 | |||
| 2 | set -e | 17 | set -e |
| 3 | 18 | ||
| 4 | dtlstest_bin=./dtlstest | 19 | dtlstest_bin=./dtlstest |
diff --git a/tests/evptest.sh b/tests/evptest.sh index ba44d75..ddd7445 100755 --- a/tests/evptest.sh +++ b/tests/evptest.sh | |||
| @@ -1,4 +1,19 @@ | |||
| 1 | #!/bin/sh | 1 | #!/bin/sh |
| 2 | # | ||
| 3 | # Copyright (c) 2014 Brent Cook | ||
| 4 | # | ||
| 5 | # Permission to use, copy, modify, and distribute this software for any | ||
| 6 | # purpose with or without fee is hereby granted, provided that the above | ||
| 7 | # copyright notice and this permission notice appear in all copies. | ||
| 8 | # | ||
| 9 | # THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES | ||
| 10 | # WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF | ||
| 11 | # MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR | ||
| 12 | # ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES | ||
| 13 | # WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN | ||
| 14 | # ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF | ||
| 15 | # OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. | ||
| 16 | |||
| 2 | set -e | 17 | set -e |
| 3 | TEST=./evptest | 18 | TEST=./evptest |
| 4 | if [ -e ./evptest.exe ]; then | 19 | if [ -e ./evptest.exe ]; then |
diff --git a/tests/keypairtest.sh b/tests/keypairtest.sh index 8bb7d9f..f2c20c4 100755 --- a/tests/keypairtest.sh +++ b/tests/keypairtest.sh | |||
| @@ -1,4 +1,19 @@ | |||
| 1 | #!/bin/sh | 1 | #!/bin/sh |
| 2 | # | ||
| 3 | # Copyright (c) 2018 Kinichiro Inoguchi | ||
| 4 | # | ||
| 5 | # Permission to use, copy, modify, and distribute this software for any | ||
| 6 | # purpose with or without fee is hereby granted, provided that the above | ||
| 7 | # copyright notice and this permission notice appear in all copies. | ||
| 8 | # | ||
| 9 | # THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES | ||
| 10 | # WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF | ||
| 11 | # MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR | ||
| 12 | # ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES | ||
| 13 | # WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN | ||
| 14 | # ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF | ||
| 15 | # OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. | ||
| 16 | |||
| 2 | set -e | 17 | set -e |
| 3 | TEST=./keypairtest | 18 | TEST=./keypairtest |
| 4 | if [ -e ./keypairtest.exe ]; then | 19 | if [ -e ./keypairtest.exe ]; then |
diff --git a/tests/mlkem_tests.bat b/tests/mlkem_tests.bat new file mode 100644 index 0000000..618c9e0 --- /dev/null +++ b/tests/mlkem_tests.bat | |||
| @@ -0,0 +1,63 @@ | |||
| 1 | @echo off | ||
| 2 | setlocal enabledelayedexpansion | ||
| 3 | |||
| 4 | :: Copyright (c) 2025 Theo Beuhler | ||
| 5 | :: | ||
| 6 | :: Permission to use, copy, modify, and distribute this software for any | ||
| 7 | :: purpose with or without fee is hereby granted, provided that the above | ||
| 8 | :: copyright notice and this permission notice appear in all copies. | ||
| 9 | :: | ||
| 10 | :: THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES | ||
| 11 | :: WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF | ||
| 12 | :: MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR | ||
| 13 | :: ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES | ||
| 14 | :: WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN | ||
| 15 | :: ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF | ||
| 16 | :: OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. | ||
| 17 | |||
| 18 | set mlkem_tests_bin=%1 | ||
| 19 | set mlkem_tests_bin=%mlkem_tests_bin:/=\% | ||
| 20 | if not exist %mlkem_tests_bin% exit /b 1 | ||
| 21 | |||
| 22 | %mlkem_tests_bin% mlkem768_decap_tests %srcdir%\mlkem768_decap_tests.txt | ||
| 23 | if !errorlevel! neq 0 ( | ||
| 24 | exit /b 1 | ||
| 25 | ) | ||
| 26 | %mlkem_tests_bin% mlkem768_encap_tests %srcdir%\mlkem768_encap_tests.txt | ||
| 27 | if !errorlevel! neq 0 ( | ||
| 28 | exit /b 1 | ||
| 29 | ) | ||
| 30 | %mlkem_tests_bin% mlkem768_keygen_tests %srcdir%\mlkem768_keygen_tests.txt | ||
| 31 | if !errorlevel! neq 0 ( | ||
| 32 | exit /b 1 | ||
| 33 | ) | ||
| 34 | %mlkem_tests_bin% mlkem768_nist_decap_tests %srcdir%\mlkem768_nist_decap_tests.txt | ||
| 35 | if !errorlevel! neq 0 ( | ||
| 36 | exit /b 1 | ||
| 37 | ) | ||
| 38 | %mlkem_tests_bin% mlkem768_nist_keygen_tests %srcdir%\mlkem768_nist_keygen_tests.txt | ||
| 39 | if !errorlevel! neq 0 ( | ||
| 40 | exit /b 1 | ||
| 41 | ) | ||
| 42 | %mlkem_tests_bin% mlkem1024_decap_tests %srcdir%\mlkem1024_decap_tests.txt | ||
| 43 | if !errorlevel! neq 0 ( | ||
| 44 | exit /b 1 | ||
| 45 | ) | ||
| 46 | %mlkem_tests_bin% mlkem1024_encap_tests %srcdir%\mlkem1024_encap_tests.txt | ||
| 47 | if !errorlevel! neq 0 ( | ||
| 48 | exit /b 1 | ||
| 49 | ) | ||
| 50 | %mlkem_tests_bin% mlkem1024_keygen_tests %srcdir%\mlkem1024_keygen_tests.txt | ||
| 51 | if !errorlevel! neq 0 ( | ||
| 52 | exit /b 1 | ||
| 53 | ) | ||
| 54 | %mlkem_tests_bin% mlkem1024_nist_decap_tests %srcdir%\mlkem1024_nist_decap_tests.txt | ||
| 55 | if !errorlevel! neq 0 ( | ||
| 56 | exit /b 1 | ||
| 57 | ) | ||
| 58 | %mlkem_tests_bin% mlkem1024_nist_keygen_tests %srcdir%\mlkem1024_nist_keygen_tests.txt | ||
| 59 | if !errorlevel! neq 0 ( | ||
| 60 | exit /b 1 | ||
| 61 | ) | ||
| 62 | |||
| 63 | endlocal | ||
diff --git a/tests/mlkem_tests.sh b/tests/mlkem_tests.sh new file mode 100755 index 0000000..cbc0f0b --- /dev/null +++ b/tests/mlkem_tests.sh | |||
| @@ -0,0 +1,39 @@ | |||
| 1 | #!/bin/sh | ||
| 2 | # | ||
| 3 | # Copyright (c) 2024 Theo Buehler | ||
| 4 | # | ||
| 5 | # Permission to use, copy, modify, and distribute this software for any | ||
| 6 | # purpose with or without fee is hereby granted, provided that the above | ||
| 7 | # copyright notice and this permission notice appear in all copies. | ||
| 8 | # | ||
| 9 | # THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES | ||
| 10 | # WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF | ||
| 11 | # MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR | ||
| 12 | # ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES | ||
| 13 | # WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN | ||
| 14 | # ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF | ||
| 15 | # OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. | ||
| 16 | |||
| 17 | set -e | ||
| 18 | |||
| 19 | TEST=./mlkem_tests | ||
| 20 | if [ -e ./mlkem_tests.exe ]; then | ||
| 21 | TEST=./mlkem_tests.exe | ||
| 22 | elif [ -e ./mlkem_tests.js ]; then | ||
| 23 | TEST="node ./mlkem_tests.js" | ||
| 24 | fi | ||
| 25 | |||
| 26 | if [ -z $srcdir ]; then | ||
| 27 | srcdir=. | ||
| 28 | fi | ||
| 29 | |||
| 30 | $TEST mlkem768_decap_tests $srcdir/mlkem768_decap_tests.txt | ||
| 31 | $TEST mlkem768_encap_tests $srcdir/mlkem768_encap_tests.txt | ||
| 32 | $TEST mlkem768_keygen_tests $srcdir/mlkem768_keygen_tests.txt | ||
| 33 | $TEST mlkem768_nist_decap_tests $srcdir/mlkem768_nist_decap_tests.txt | ||
| 34 | $TEST mlkem768_nist_keygen_tests $srcdir/mlkem768_nist_keygen_tests.txt | ||
| 35 | $TEST mlkem1024_decap_tests $srcdir/mlkem1024_decap_tests.txt | ||
| 36 | $TEST mlkem1024_encap_tests $srcdir/mlkem1024_encap_tests.txt | ||
| 37 | $TEST mlkem1024_keygen_tests $srcdir/mlkem1024_keygen_tests.txt | ||
| 38 | $TEST mlkem1024_nist_decap_tests $srcdir/mlkem1024_nist_decap_tests.txt | ||
| 39 | $TEST mlkem1024_nist_keygen_tests $srcdir/mlkem1024_nist_keygen_tests.txt | ||
diff --git a/tests/ocsptest.bat b/tests/ocsptest.bat index 2b6b66b..8d44ee0 100644 --- a/tests/ocsptest.bat +++ b/tests/ocsptest.bat | |||
| @@ -1,6 +1,19 @@ | |||
| 1 | @echo off | 1 | @echo off |
| 2 | setlocal enabledelayedexpansion | 2 | setlocal enabledelayedexpansion |
| 3 | REM ocspocsp_test_bin.bat | 3 | |
| 4 | :: Copyright (c) 2016 Kinichiro Inoguchi | ||
| 5 | :: | ||
| 6 | :: Permission to use, copy, modify, and distribute this software for any | ||
| 7 | :: purpose with or without fee is hereby granted, provided that the above | ||
| 8 | :: copyright notice and this permission notice appear in all copies. | ||
| 9 | :: | ||
| 10 | :: THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES | ||
| 11 | :: WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF | ||
| 12 | :: MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR | ||
| 13 | :: ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES | ||
| 14 | :: WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN | ||
| 15 | :: ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF | ||
| 16 | :: OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. | ||
| 4 | 17 | ||
| 5 | set ocsp_test_bin=%1 | 18 | set ocsp_test_bin=%1 |
| 6 | set ocsp_test_bin=%ocsp_test_bin:/=\% | 19 | set ocsp_test_bin=%ocsp_test_bin:/=\% |
diff --git a/tests/ocsptest.sh b/tests/ocsptest.sh index a1c266d..71c975e 100755 --- a/tests/ocsptest.sh +++ b/tests/ocsptest.sh | |||
| @@ -1,4 +1,19 @@ | |||
| 1 | #!/bin/sh | 1 | #!/bin/sh |
| 2 | # | ||
| 3 | # Copyright (c) 2016 Brent Cook | ||
| 4 | # | ||
| 5 | # Permission to use, copy, modify, and distribute this software for any | ||
| 6 | # purpose with or without fee is hereby granted, provided that the above | ||
| 7 | # copyright notice and this permission notice appear in all copies. | ||
| 8 | # | ||
| 9 | # THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES | ||
| 10 | # WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF | ||
| 11 | # MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR | ||
| 12 | # ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES | ||
| 13 | # WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN | ||
| 14 | # ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF | ||
| 15 | # OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. | ||
| 16 | |||
| 2 | set -e | 17 | set -e |
| 3 | TEST=./ocsp_test | 18 | TEST=./ocsp_test |
| 4 | if [ -e ./ocsp_test.exe ]; then | 19 | if [ -e ./ocsp_test.exe ]; then |
diff --git a/tests/pidwraptest.sh b/tests/pidwraptest.sh index 04fb5c4..d5a2f71 100755 --- a/tests/pidwraptest.sh +++ b/tests/pidwraptest.sh | |||
| @@ -1,4 +1,19 @@ | |||
| 1 | #!/bin/sh | 1 | #!/bin/sh |
| 2 | # | ||
| 3 | # Copyright (c) 2014 Brent Cook | ||
| 4 | # | ||
| 5 | # Permission to use, copy, modify, and distribute this software for any | ||
| 6 | # purpose with or without fee is hereby granted, provided that the above | ||
| 7 | # copyright notice and this permission notice appear in all copies. | ||
| 8 | # | ||
| 9 | # THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES | ||
| 10 | # WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF | ||
| 11 | # MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR | ||
| 12 | # ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES | ||
| 13 | # WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN | ||
| 14 | # ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF | ||
| 15 | # OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. | ||
| 16 | |||
| 2 | ./pidwraptest > pidwraptest.txt | 17 | ./pidwraptest > pidwraptest.txt |
| 3 | while read a b; | 18 | while read a b; |
| 4 | do | 19 | do |
diff --git a/tests/pq_test.bat b/tests/pq_test.bat deleted file mode 100644 index 084f06d..0000000 --- a/tests/pq_test.bat +++ /dev/null | |||
| @@ -1,15 +0,0 @@ | |||
| 1 | @echo off | ||
| 2 | setlocal enabledelayedexpansion | ||
| 3 | REM pq_test.bat | ||
| 4 | |||
| 5 | set pq_test_bin=%1 | ||
| 6 | set pq_test_bin=%pq_test_bin:/=\% | ||
| 7 | if not exist %pq_test_bin% exit /b 1 | ||
| 8 | |||
| 9 | set pq_output=pq_output.txt | ||
| 10 | if exist %pq_output% del %pq_output% | ||
| 11 | |||
| 12 | %pq_test_bin% > %pq_output% | ||
| 13 | fc /b %pq_output% %srcdir%\pq_expected.txt | ||
| 14 | |||
| 15 | endlocal | ||
diff --git a/tests/pq_test.sh b/tests/pq_test.sh deleted file mode 100755 index eab6f3c..0000000 --- a/tests/pq_test.sh +++ /dev/null | |||
| @@ -1,9 +0,0 @@ | |||
| 1 | #!/bin/sh | ||
| 2 | set -e | ||
| 3 | TEST=./pq_test | ||
| 4 | if [ -e ./pq_test.exe ]; then | ||
| 5 | TEST=./pq_test.exe | ||
| 6 | elif [ -e ./pq_test.js ]; then | ||
| 7 | TEST="node ./pq_test.js" | ||
| 8 | fi | ||
| 9 | $TEST | diff -b $srcdir/pq_expected.txt - | ||
diff --git a/tests/quictest.bat b/tests/quictest.bat index 645fc2f..be731c8 100644 --- a/tests/quictest.bat +++ b/tests/quictest.bat | |||
| @@ -1,6 +1,19 @@ | |||
| 1 | @echo off | 1 | @echo off |
| 2 | setlocal enabledelayedexpansion | 2 | setlocal enabledelayedexpansion |
| 3 | REM quictest.bat | 3 | |
| 4 | :: Copyright (c) 2022 Brent Cook | ||
| 5 | :: | ||
| 6 | :: Permission to use, copy, modify, and distribute this software for any | ||
| 7 | :: purpose with or without fee is hereby granted, provided that the above | ||
| 8 | :: copyright notice and this permission notice appear in all copies. | ||
| 9 | :: | ||
| 10 | :: THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES | ||
| 11 | :: WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF | ||
| 12 | :: MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR | ||
| 13 | :: ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES | ||
| 14 | :: WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN | ||
| 15 | :: ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF | ||
| 16 | :: OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. | ||
| 4 | 17 | ||
| 5 | set quictest_bin=%1 | 18 | set quictest_bin=%1 |
| 6 | set quictest_bin=%quictest_bin:/=\% | 19 | set quictest_bin=%quictest_bin:/=\% |
diff --git a/tests/quictest.sh b/tests/quictest.sh index 23561ad..407a66b 100755 --- a/tests/quictest.sh +++ b/tests/quictest.sh | |||
| @@ -1,4 +1,19 @@ | |||
| 1 | #!/bin/sh | 1 | #!/bin/sh |
| 2 | # | ||
| 3 | # Copyright (c) 2022 Brent Cook | ||
| 4 | # | ||
| 5 | # Permission to use, copy, modify, and distribute this software for any | ||
| 6 | # purpose with or without fee is hereby granted, provided that the above | ||
| 7 | # copyright notice and this permission notice appear in all copies. | ||
| 8 | # | ||
| 9 | # THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES | ||
| 10 | # WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF | ||
| 11 | # MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR | ||
| 12 | # ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES | ||
| 13 | # WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN | ||
| 14 | # ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF | ||
| 15 | # OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. | ||
| 16 | |||
| 2 | set -e | 17 | set -e |
| 3 | 18 | ||
| 4 | quictest_bin=./quictest | 19 | quictest_bin=./quictest |
diff --git a/tests/renegotiation_test.bat b/tests/renegotiation_test.bat new file mode 100644 index 0000000..6691a39 --- /dev/null +++ b/tests/renegotiation_test.bat | |||
| @@ -0,0 +1,27 @@ | |||
| 1 | @echo off | ||
| 2 | setlocal enabledelayedexpansion | ||
| 3 | |||
| 4 | :: Copyright (c) 2025 Theo Beuhler | ||
| 5 | :: | ||
| 6 | :: Permission to use, copy, modify, and distribute this software for any | ||
| 7 | :: purpose with or without fee is hereby granted, provided that the above | ||
| 8 | :: copyright notice and this permission notice appear in all copies. | ||
| 9 | :: | ||
| 10 | :: THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES | ||
| 11 | :: WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF | ||
| 12 | :: MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR | ||
| 13 | :: ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES | ||
| 14 | :: WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN | ||
| 15 | :: ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF | ||
| 16 | :: OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. | ||
| 17 | |||
| 18 | set renegotiation_test_bin=%1 | ||
| 19 | set renegotiation_test_bin=%renegotiation_test_bin:/=\% | ||
| 20 | if not exist %renegotiation_test_bin% exit /b 1 | ||
| 21 | |||
| 22 | %renegotiation_test_bin% %srcdir%\server1-rsa.pem %srcdir%\server1-rsa-chain.pem %srcdir%\ca-root-rsa.pem | ||
| 23 | if !errorlevel! neq 0 ( | ||
| 24 | exit /b 1 | ||
| 25 | ) | ||
| 26 | |||
| 27 | endlocal | ||
diff --git a/tests/renegotiation_test.sh b/tests/renegotiation_test.sh new file mode 100755 index 0000000..8d963a2 --- /dev/null +++ b/tests/renegotiation_test.sh | |||
| @@ -0,0 +1,30 @@ | |||
| 1 | #!/bin/sh | ||
| 2 | # | ||
| 3 | # Copyright (c) 2025 Theo Buehler | ||
| 4 | # | ||
| 5 | # Permission to use, copy, modify, and distribute this software for any | ||
| 6 | # purpose with or without fee is hereby granted, provided that the above | ||
| 7 | # copyright notice and this permission notice appear in all copies. | ||
| 8 | # | ||
| 9 | # THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES | ||
| 10 | # WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF | ||
| 11 | # MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR | ||
| 12 | # ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES | ||
| 13 | # WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN | ||
| 14 | # ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF | ||
| 15 | # OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. | ||
| 16 | |||
| 17 | set -e | ||
| 18 | |||
| 19 | renegotiation_test_bin=./renegotiation_test | ||
| 20 | if [ -e ./renegotiation_test.exe ]; then | ||
| 21 | renegotiation_test_bin=./renegotiation_test.exe | ||
| 22 | elif [ -e ./renegotiation_test.js ]; then | ||
| 23 | renegotiation_test_bin="node ./renegotiation_test.js" | ||
| 24 | fi | ||
| 25 | |||
| 26 | if [ -z $srcdir ]; then | ||
| 27 | srcdir=. | ||
| 28 | fi | ||
| 29 | |||
| 30 | $renegotiation_test_bin $srcdir/server1-rsa.pem $srcdir/server1-rsa-chain.pem $srcdir/ca-root-rsa.pem | ||
diff --git a/tests/servertest.bat b/tests/servertest.bat index c0bfaa4..d72d8de 100644 --- a/tests/servertest.bat +++ b/tests/servertest.bat | |||
| @@ -1,6 +1,19 @@ | |||
| 1 | @echo off | 1 | @echo off |
| 2 | setlocal enabledelayedexpansion | 2 | setlocal enabledelayedexpansion |
| 3 | REM servertest.bat | 3 | |
| 4 | :: Copyright (c) 2017 Kinichiro Inoguchi | ||
| 5 | :: | ||
| 6 | :: Permission to use, copy, modify, and distribute this software for any | ||
| 7 | :: purpose with or without fee is hereby granted, provided that the above | ||
| 8 | :: copyright notice and this permission notice appear in all copies. | ||
| 9 | :: | ||
| 10 | :: THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES | ||
| 11 | :: WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF | ||
| 12 | :: MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR | ||
| 13 | :: ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES | ||
| 14 | :: WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN | ||
| 15 | :: ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF | ||
| 16 | :: OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. | ||
| 4 | 17 | ||
| 5 | set servertest_bin=%1 | 18 | set servertest_bin=%1 |
| 6 | set servertest_bin=%servertest_bin:/=\% | 19 | set servertest_bin=%servertest_bin:/=\% |
diff --git a/tests/servertest.sh b/tests/servertest.sh index 1662332..4770e4b 100755 --- a/tests/servertest.sh +++ b/tests/servertest.sh | |||
| @@ -1,4 +1,19 @@ | |||
| 1 | #!/bin/sh | 1 | #!/bin/sh |
| 2 | # | ||
| 3 | # Copyright (c) 2017 Kinichiro Inoguchi | ||
| 4 | # | ||
| 5 | # Permission to use, copy, modify, and distribute this software for any | ||
| 6 | # purpose with or without fee is hereby granted, provided that the above | ||
| 7 | # copyright notice and this permission notice appear in all copies. | ||
| 8 | # | ||
| 9 | # THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES | ||
| 10 | # WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF | ||
| 11 | # MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR | ||
| 12 | # ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES | ||
| 13 | # WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN | ||
| 14 | # ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF | ||
| 15 | # OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. | ||
| 16 | |||
| 2 | set -e | 17 | set -e |
| 3 | 18 | ||
| 4 | servertest_bin=./servertest | 19 | servertest_bin=./servertest |
diff --git a/tests/shutdowntest.bat b/tests/shutdowntest.bat index f087dbb..d722fa0 100644 --- a/tests/shutdowntest.bat +++ b/tests/shutdowntest.bat | |||
| @@ -1,6 +1,19 @@ | |||
| 1 | @echo off | 1 | @echo off |
| 2 | setlocal enabledelayedexpansion | 2 | setlocal enabledelayedexpansion |
| 3 | REM shutdowntest.bat | 3 | |
| 4 | :: Copyright (c) 2024 Theo Beuhler | ||
| 5 | :: | ||
| 6 | :: Permission to use, copy, modify, and distribute this software for any | ||
| 7 | :: purpose with or without fee is hereby granted, provided that the above | ||
| 8 | :: copyright notice and this permission notice appear in all copies. | ||
| 9 | :: | ||
| 10 | :: THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES | ||
| 11 | :: WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF | ||
| 12 | :: MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR | ||
| 13 | :: ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES | ||
| 14 | :: WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN | ||
| 15 | :: ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF | ||
| 16 | :: OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. | ||
| 4 | 17 | ||
| 5 | set shutdowntest_bin=%1 | 18 | set shutdowntest_bin=%1 |
| 6 | set shutdowntest_bin=%shutdowntest_bin:/=\% | 19 | set shutdowntest_bin=%shutdowntest_bin:/=\% |
diff --git a/tests/shutdowntest.sh b/tests/shutdowntest.sh index d3ae472..b3c98da 100755 --- a/tests/shutdowntest.sh +++ b/tests/shutdowntest.sh | |||
| @@ -1,4 +1,19 @@ | |||
| 1 | #!/bin/sh | 1 | #!/bin/sh |
| 2 | # | ||
| 3 | # Copyright (c) 2024 Theo Buehler | ||
| 4 | # | ||
| 5 | # Permission to use, copy, modify, and distribute this software for any | ||
| 6 | # purpose with or without fee is hereby granted, provided that the above | ||
| 7 | # copyright notice and this permission notice appear in all copies. | ||
| 8 | # | ||
| 9 | # THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES | ||
| 10 | # WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF | ||
| 11 | # MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR | ||
| 12 | # ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES | ||
| 13 | # WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN | ||
| 14 | # ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF | ||
| 15 | # OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. | ||
| 16 | |||
| 2 | set -e | 17 | set -e |
| 3 | 18 | ||
| 4 | shutdowntest_bin=./shutdowntest | 19 | shutdowntest_bin=./shutdowntest |
diff --git a/tests/ssltest.bat b/tests/ssltest.bat index 5dda6bc..17f912f 100644 --- a/tests/ssltest.bat +++ b/tests/ssltest.bat | |||
| @@ -1,6 +1,19 @@ | |||
| 1 | @echo off | 1 | @echo off |
| 2 | setlocal enabledelayedexpansion | 2 | setlocal enabledelayedexpansion |
| 3 | REM ssltest.bat | 3 | |
| 4 | :: Copyright (c) 2016 Kinichiro Inoguchi | ||
| 5 | :: | ||
| 6 | :: Permission to use, copy, modify, and distribute this software for any | ||
| 7 | :: purpose with or without fee is hereby granted, provided that the above | ||
| 8 | :: copyright notice and this permission notice appear in all copies. | ||
| 9 | :: | ||
| 10 | :: THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES | ||
| 11 | :: WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF | ||
| 12 | :: MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR | ||
| 13 | :: ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES | ||
| 14 | :: WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN | ||
| 15 | :: ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF | ||
| 16 | :: OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. | ||
| 4 | 17 | ||
| 5 | set ssltest_bin=%1 | 18 | set ssltest_bin=%1 |
| 6 | set ssltest_bin=%ssltest_bin:/=\% | 19 | set ssltest_bin=%ssltest_bin:/=\% |
diff --git a/tests/ssltest.sh b/tests/ssltest.sh index 29ea0b0..4ec4884 100755 --- a/tests/ssltest.sh +++ b/tests/ssltest.sh | |||
| @@ -1,4 +1,19 @@ | |||
| 1 | #!/bin/sh | 1 | #!/bin/sh |
| 2 | # | ||
| 3 | # Copyright (c) 2014 Brent Cook | ||
| 4 | # | ||
| 5 | # Permission to use, copy, modify, and distribute this software for any | ||
| 6 | # purpose with or without fee is hereby granted, provided that the above | ||
| 7 | # copyright notice and this permission notice appear in all copies. | ||
| 8 | # | ||
| 9 | # THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES | ||
| 10 | # WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF | ||
| 11 | # MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR | ||
| 12 | # ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES | ||
| 13 | # WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN | ||
| 14 | # ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF | ||
| 15 | # OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. | ||
| 16 | |||
| 2 | set -e | 17 | set -e |
| 3 | 18 | ||
| 4 | ssltest_bin=./ssltest | 19 | ssltest_bin=./ssltest |
diff --git a/tests/testdsa.bat b/tests/testdsa.bat index 898ded8..df53305 100644 --- a/tests/testdsa.bat +++ b/tests/testdsa.bat | |||
| @@ -1,9 +1,21 @@ | |||
| 1 | @echo off | 1 | @echo off |
| 2 | setlocal enabledelayedexpansion | 2 | setlocal enabledelayedexpansion |
| 3 | REM testdsa.bat | ||
| 4 | 3 | ||
| 5 | 4 | :: Copyright (c) 2016 Kinichiro Inoguchi | |
| 6 | REM # Test DSA certificate generation of openssl | 5 | :: |
| 6 | :: Permission to use, copy, modify, and distribute this software for any | ||
| 7 | :: purpose with or without fee is hereby granted, provided that the above | ||
| 8 | :: copyright notice and this permission notice appear in all copies. | ||
| 9 | :: | ||
| 10 | :: THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES | ||
| 11 | :: WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF | ||
| 12 | :: MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR | ||
| 13 | :: ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES | ||
| 14 | :: WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN | ||
| 15 | :: ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF | ||
| 16 | :: OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. | ||
| 17 | |||
| 18 | :: Test DSA certificate generation of openssl | ||
| 7 | 19 | ||
| 8 | set openssl_bin=%1 | 20 | set openssl_bin=%1 |
| 9 | set openssl_bin=%openssl_bin:/=\% | 21 | set openssl_bin=%openssl_bin:/=\% |
diff --git a/tests/testdsa.sh b/tests/testdsa.sh index 7ecb8ef..230a1f8 100755 --- a/tests/testdsa.sh +++ b/tests/testdsa.sh | |||
| @@ -1,6 +1,18 @@ | |||
| 1 | #!/bin/sh | 1 | #!/bin/sh |
| 2 | # $OpenBSD: testdsa.sh,v 1.1 2014/08/26 17:50:07 jsing Exp $ | 2 | # |
| 3 | 3 | # Copyright (c) 2015 Brent Cook | |
| 4 | # | ||
| 5 | # Permission to use, copy, modify, and distribute this software for any | ||
| 6 | # purpose with or without fee is hereby granted, provided that the above | ||
| 7 | # copyright notice and this permission notice appear in all copies. | ||
| 8 | # | ||
| 9 | # THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES | ||
| 10 | # WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF | ||
| 11 | # MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR | ||
| 12 | # ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES | ||
| 13 | # WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN | ||
| 14 | # ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF | ||
| 15 | # OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. | ||
| 4 | 16 | ||
| 5 | #Test DSA certificate generation of openssl | 17 | #Test DSA certificate generation of openssl |
| 6 | 18 | ||
diff --git a/tests/testenc.bat b/tests/testenc.bat index 84f48f2..fa14620 100644 --- a/tests/testenc.bat +++ b/tests/testenc.bat | |||
| @@ -1,6 +1,19 @@ | |||
| 1 | @echo off | 1 | @echo off |
| 2 | setlocal enabledelayedexpansion | 2 | setlocal enabledelayedexpansion |
| 3 | REM testenc.bat | 3 | |
| 4 | :: Copyright (c) 2016 Kinichiro Inoguchi | ||
| 5 | :: | ||
| 6 | :: Permission to use, copy, modify, and distribute this software for any | ||
| 7 | :: purpose with or without fee is hereby granted, provided that the above | ||
| 8 | :: copyright notice and this permission notice appear in all copies. | ||
| 9 | :: | ||
| 10 | :: THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES | ||
| 11 | :: WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF | ||
| 12 | :: MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR | ||
| 13 | :: ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES | ||
| 14 | :: WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN | ||
| 15 | :: ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF | ||
| 16 | :: OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. | ||
| 4 | 17 | ||
| 5 | set test=P | 18 | set test=P |
| 6 | 19 | ||
diff --git a/tests/testenc.sh b/tests/testenc.sh index 63bce34..418e48d 100755 --- a/tests/testenc.sh +++ b/tests/testenc.sh | |||
| @@ -1,5 +1,18 @@ | |||
| 1 | #!/bin/sh | 1 | #!/bin/sh |
| 2 | # $OpenBSD: testenc.sh,v 1.1 2014/08/26 17:50:07 jsing Exp $ | 2 | # |
| 3 | # Copyright (c) 2015 Brent Cook | ||
| 4 | # | ||
| 5 | # Permission to use, copy, modify, and distribute this software for any | ||
| 6 | # purpose with or without fee is hereby granted, provided that the above | ||
| 7 | # copyright notice and this permission notice appear in all copies. | ||
| 8 | # | ||
| 9 | # THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES | ||
| 10 | # WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF | ||
| 11 | # MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR | ||
| 12 | # ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES | ||
| 13 | # WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN | ||
| 14 | # ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF | ||
| 15 | # OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. | ||
| 3 | 16 | ||
| 4 | test=p | 17 | test=p |
| 5 | if [ -d ../apps/openssl ]; then | 18 | if [ -d ../apps/openssl ]; then |
diff --git a/tests/testrsa.bat b/tests/testrsa.bat index 59c3b5d..af59aad 100644 --- a/tests/testrsa.bat +++ b/tests/testrsa.bat | |||
| @@ -1,9 +1,21 @@ | |||
| 1 | @echo off | 1 | @echo off |
| 2 | setlocal enabledelayedexpansion | 2 | setlocal enabledelayedexpansion |
| 3 | REM testrsa.bat | ||
| 4 | 3 | ||
| 5 | 4 | :: Copyright (c) 2016 Kinichiro Inoguchi | |
| 6 | REM # Test RSA certificate generation of openssl | 5 | :: |
| 6 | :: Permission to use, copy, modify, and distribute this software for any | ||
| 7 | :: purpose with or without fee is hereby granted, provided that the above | ||
| 8 | :: copyright notice and this permission notice appear in all copies. | ||
| 9 | :: | ||
| 10 | :: THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES | ||
| 11 | :: WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF | ||
| 12 | :: MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR | ||
| 13 | :: ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES | ||
| 14 | :: WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN | ||
| 15 | :: ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF | ||
| 16 | :: OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. | ||
| 17 | |||
| 18 | :: Test RSA certificate generation of openssl | ||
| 7 | 19 | ||
| 8 | set openssl_bin=%1 | 20 | set openssl_bin=%1 |
| 9 | set openssl_bin=%openssl_bin:/=\% | 21 | set openssl_bin=%openssl_bin:/=\% |
diff --git a/tests/testrsa.sh b/tests/testrsa.sh index e644999..afbc610 100755 --- a/tests/testrsa.sh +++ b/tests/testrsa.sh | |||
| @@ -1,6 +1,18 @@ | |||
| 1 | #!/bin/sh | 1 | #!/bin/sh |
| 2 | # $OpenBSD: testrsa.sh,v 1.1 2014/08/26 17:50:07 jsing Exp $ | 2 | # |
| 3 | 3 | # Copyright (c) 2015 Brent Cook | |
| 4 | # | ||
| 5 | # Permission to use, copy, modify, and distribute this software for any | ||
| 6 | # purpose with or without fee is hereby granted, provided that the above | ||
| 7 | # copyright notice and this permission notice appear in all copies. | ||
| 8 | # | ||
| 9 | # THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES | ||
| 10 | # WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF | ||
| 11 | # MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR | ||
| 12 | # ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES | ||
| 13 | # WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN | ||
| 14 | # ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF | ||
| 15 | # OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. | ||
| 4 | 16 | ||
| 5 | #Test RSA certificate generation of openssl | 17 | #Test RSA certificate generation of openssl |
| 6 | 18 | ||
diff --git a/tests/testssl.bat b/tests/testssl.bat index c4e6286..35a789a 100644 --- a/tests/testssl.bat +++ b/tests/testssl.bat | |||
| @@ -1,6 +1,19 @@ | |||
| 1 | @echo on | 1 | @echo on |
| 2 | setlocal enabledelayedexpansion | 2 | setlocal enabledelayedexpansion |
| 3 | REM testssl.bat | 3 | |
| 4 | :: Copyright (c) 2016 Kinichiro Inoguchi | ||
| 5 | :: | ||
| 6 | :: Permission to use, copy, modify, and distribute this software for any | ||
| 7 | :: purpose with or without fee is hereby granted, provided that the above | ||
| 8 | :: copyright notice and this permission notice appear in all copies. | ||
| 9 | :: | ||
| 10 | :: THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES | ||
| 11 | :: WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF | ||
| 12 | :: MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR | ||
| 13 | :: ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES | ||
| 14 | :: WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN | ||
| 15 | :: ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF | ||
| 16 | :: OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. | ||
| 4 | 17 | ||
| 5 | set key=%1 | 18 | set key=%1 |
| 6 | set cert=%2 | 19 | set cert=%2 |
diff --git a/tests/tlstest.bat b/tests/tlstest.bat index 5f5f6a6..204201b 100644 --- a/tests/tlstest.bat +++ b/tests/tlstest.bat | |||
| @@ -1,6 +1,19 @@ | |||
| 1 | @echo off | 1 | @echo off |
| 2 | setlocal enabledelayedexpansion | 2 | setlocal enabledelayedexpansion |
| 3 | REM tlstest.bat | 3 | |
| 4 | :: Copyright (c) 2017 Brent Cook | ||
| 5 | :: | ||
| 6 | :: Permission to use, copy, modify, and distribute this software for any | ||
| 7 | :: purpose with or without fee is hereby granted, provided that the above | ||
| 8 | :: copyright notice and this permission notice appear in all copies. | ||
| 9 | :: | ||
| 10 | :: THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES | ||
| 11 | :: WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF | ||
| 12 | :: MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR | ||
| 13 | :: ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES | ||
| 14 | :: WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN | ||
| 15 | :: ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF | ||
| 16 | :: OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. | ||
| 4 | 17 | ||
| 5 | set tlstest_bin=%1 | 18 | set tlstest_bin=%1 |
| 6 | set tlstest_bin=%tlstest_bin:/=\% | 19 | set tlstest_bin=%tlstest_bin:/=\% |
diff --git a/tests/tlstest.sh b/tests/tlstest.sh index 4024007..4a5aff6 100755 --- a/tests/tlstest.sh +++ b/tests/tlstest.sh | |||
| @@ -1,4 +1,19 @@ | |||
| 1 | #!/bin/sh | 1 | #!/bin/sh |
| 2 | # | ||
| 3 | # Copyright (c) 2015 Brent Cook | ||
| 4 | # | ||
| 5 | # Permission to use, copy, modify, and distribute this software for any | ||
| 6 | # purpose with or without fee is hereby granted, provided that the above | ||
| 7 | # copyright notice and this permission notice appear in all copies. | ||
| 8 | # | ||
| 9 | # THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES | ||
| 10 | # WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF | ||
| 11 | # MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR | ||
| 12 | # ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES | ||
| 13 | # WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN | ||
| 14 | # ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF | ||
| 15 | # OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. | ||
| 16 | |||
| 2 | set -e | 17 | set -e |
| 3 | 18 | ||
| 4 | tlstest_bin=./tlstest | 19 | tlstest_bin=./tlstest |
diff --git a/tls/CMakeLists.txt b/tls/CMakeLists.txt index 919b1fa..a1b244a 100644 --- a/tls/CMakeLists.txt +++ b/tls/CMakeLists.txt | |||
| @@ -1,3 +1,18 @@ | |||
| 1 | # | ||
| 2 | # Copyright (c) 2014 Brent Cook | ||
| 3 | # | ||
| 4 | # Permission to use, copy, modify, and distribute this software for any | ||
| 5 | # purpose with or without fee is hereby granted, provided that the above | ||
| 6 | # copyright notice and this permission notice appear in all copies. | ||
| 7 | # | ||
| 8 | # THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES | ||
| 9 | # WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF | ||
| 10 | # MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR | ||
| 11 | # ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES | ||
| 12 | # WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN | ||
| 13 | # ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF | ||
| 14 | # OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. | ||
| 15 | |||
| 1 | set( | 16 | set( |
| 2 | TLS_SRC | 17 | TLS_SRC |
| 3 | tls.c | 18 | tls.c |
| @@ -22,7 +37,6 @@ if(WIN32) | |||
| 22 | ${TLS_SRC} | 37 | ${TLS_SRC} |
| 23 | ) | 38 | ) |
| 24 | 39 | ||
| 25 | set(TLS_COMPAT_SRC ${TLS_COMPAT_SRC} compat/ftruncate.c) | ||
| 26 | set(TLS_COMPAT_SRC ${TLS_COMPAT_SRC} compat/pread.c) | 40 | set(TLS_COMPAT_SRC ${TLS_COMPAT_SRC} compat/pread.c) |
| 27 | set(TLS_COMPAT_SRC ${TLS_COMPAT_SRC} compat/pwrite.c) | 41 | set(TLS_COMPAT_SRC ${TLS_COMPAT_SRC} compat/pwrite.c) |
| 28 | endif() | 42 | endif() |
| @@ -58,16 +72,16 @@ endif() | |||
| 58 | 72 | ||
| 59 | export_symbol(tls ${CMAKE_CURRENT_BINARY_DIR}/tls.sym) | 73 | export_symbol(tls ${CMAKE_CURRENT_BINARY_DIR}/tls.sym) |
| 60 | target_link_libraries(tls ${OPENSSL_LIBS}) | 74 | target_link_libraries(tls ${OPENSSL_LIBS}) |
| 61 | if (WIN32) | ||
| 62 | set(TLS_POSTFIX -${TLS_MAJOR_VERSION} PARENT_SCOPE) | ||
| 63 | endif() | ||
| 64 | set_target_properties(tls PROPERTIES | 75 | set_target_properties(tls PROPERTIES |
| 65 | OUTPUT_NAME tls${TLS_POSTFIX} | 76 | OUTPUT_NAME tls |
| 66 | ARCHIVE_OUTPUT_NAME tls${TLS_POSTFIX} | 77 | ARCHIVE_OUTPUT_NAME tls |
| 67 | EXPORT_NAME TLS | 78 | EXPORT_NAME TLS |
| 68 | VERSION ${TLS_VERSION} | 79 | VERSION ${TLS_VERSION} |
| 69 | SOVERSION ${TLS_MAJOR_VERSION} | 80 | SOVERSION ${TLS_MAJOR_VERSION} |
| 70 | ) | 81 | ) |
| 82 | if(NOT CMAKE_VERSION VERSION_LESS 3.27.0) | ||
| 83 | set_target_properties(tls PROPERTIES DLL_NAME_WITH_SOVERSION TRUE) | ||
| 84 | endif() | ||
| 71 | 85 | ||
| 72 | target_include_directories( | 86 | target_include_directories( |
| 73 | tls | 87 | tls |
diff --git a/tls/Makefile.am b/tls/Makefile.am index 22f3222..03824b4 100644 --- a/tls/Makefile.am +++ b/tls/Makefile.am | |||
| @@ -1,3 +1,18 @@ | |||
| 1 | # | ||
| 2 | # Copyright (c) 2014 Brent Cook | ||
| 3 | # | ||
| 4 | # Permission to use, copy, modify, and distribute this software for any | ||
| 5 | # purpose with or without fee is hereby granted, provided that the above | ||
| 6 | # copyright notice and this permission notice appear in all copies. | ||
| 7 | # | ||
| 8 | # THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES | ||
| 9 | # WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF | ||
| 10 | # MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR | ||
| 11 | # ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES | ||
| 12 | # WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN | ||
| 13 | # ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF | ||
| 14 | # OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. | ||
| 15 | |||
| 1 | include $(top_srcdir)/Makefile.am.common | 16 | include $(top_srcdir)/Makefile.am.common |
| 2 | 17 | ||
| 3 | -include $(abs_top_builddir)/crypto/libcrypto_la_objects.mk | 18 | -include $(abs_top_builddir)/crypto/libcrypto_la_objects.mk |
| @@ -16,7 +31,7 @@ EXTRA_libtls_la_DEPENDENCIES = libtls_la_objects.mk | |||
| 16 | 31 | ||
| 17 | libtls_la_objects.mk: Makefile | 32 | libtls_la_objects.mk: Makefile |
| 18 | @echo "libtls_la_objects= $(libtls_la_OBJECTS)" \ | 33 | @echo "libtls_la_objects= $(libtls_la_OBJECTS)" \ |
| 19 | | sed -e 's/ *$$//' -e 's/ */ $$\(abs_top_builddir\)\/tls\//g' \ | 34 | | sed -e 's/ *$$//' -e 's/ */ $$\(top_builddir\)\/tls\//g' \ |
| 20 | > libtls_la_objects.mk | 35 | > libtls_la_objects.mk |
| 21 | 36 | ||
| 22 | libtls_la_LDFLAGS = -version-info @LIBTLS_VERSION@ -no-undefined -export-symbols $(top_srcdir)/tls/tls.sym | 37 | libtls_la_LDFLAGS = -version-info @LIBTLS_VERSION@ -no-undefined -export-symbols $(top_srcdir)/tls/tls.sym |
| @@ -55,7 +70,6 @@ libtls_la_SOURCES += tls_verify.c | |||
| 55 | noinst_HEADERS = tls_internal.h | 70 | noinst_HEADERS = tls_internal.h |
| 56 | 71 | ||
| 57 | if HOST_WIN | 72 | if HOST_WIN |
| 58 | libtls_la_SOURCES += compat/ftruncate.c | ||
| 59 | libtls_la_SOURCES += compat/pread.c | 73 | libtls_la_SOURCES += compat/pread.c |
| 60 | libtls_la_SOURCES += compat/pwrite.c | 74 | libtls_la_SOURCES += compat/pwrite.c |
| 61 | endif | 75 | endif |
| @@ -1,4 +1,19 @@ | |||
| 1 | #!/bin/sh | 1 | #!/bin/sh |
| 2 | # | ||
| 3 | # Copyright (c) 2014 Brent Cook | ||
| 4 | # | ||
| 5 | # Permission to use, copy, modify, and distribute this software for any | ||
| 6 | # purpose with or without fee is hereby granted, provided that the above | ||
| 7 | # copyright notice and this permission notice appear in all copies. | ||
| 8 | # | ||
| 9 | # THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES | ||
| 10 | # WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF | ||
| 11 | # MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR | ||
| 12 | # ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES | ||
| 13 | # WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN | ||
| 14 | # ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF | ||
| 15 | # OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. | ||
| 16 | |||
| 2 | set -e | 17 | set -e |
| 3 | 18 | ||
| 4 | openbsd_branch=`cat OPENBSD_BRANCH` | 19 | openbsd_branch=`cat OPENBSD_BRANCH` |
| @@ -83,8 +98,7 @@ if [ -x /opt/csw/bin/ggrep ]; then | |||
| 83 | GREP='/opt/csw/bin/ggrep' | 98 | GREP='/opt/csw/bin/ggrep' |
| 84 | fi | 99 | fi |
| 85 | 100 | ||
| 86 | $CP $libssl_src/LICENSE COPYING | 101 | $CP $libcrypto_src/opensslconf.h include/openssl |
| 87 | |||
| 88 | $CP $libcrypto_src/opensslfeatures.h include/openssl | 102 | $CP $libcrypto_src/opensslfeatures.h include/openssl |
| 89 | $CP $libssl_src/pqueue.h include | 103 | $CP $libssl_src/pqueue.h include |
| 90 | 104 | ||
| @@ -129,13 +143,13 @@ copy_hdrs $libcrypto_src "stack/stack.h lhash/lhash.h stack/safestack.h | |||
| 129 | ossl_typ.h err/err.h crypto.h comp/comp.h x509/x509.h buffer/buffer.h | 143 | ossl_typ.h err/err.h crypto.h comp/comp.h x509/x509.h buffer/buffer.h |
| 130 | objects/objects.h asn1/asn1.h asn1/posix_time.h bn/bn.h ec/ec.h ecdsa/ecdsa.h | 144 | objects/objects.h asn1/asn1.h asn1/posix_time.h bn/bn.h ec/ec.h ecdsa/ecdsa.h |
| 131 | ecdh/ecdh.h rsa/rsa.h sha/sha.h x509/x509_vfy.h pkcs7/pkcs7.h pem/pem.h | 145 | ecdh/ecdh.h rsa/rsa.h sha/sha.h x509/x509_vfy.h pkcs7/pkcs7.h pem/pem.h |
| 132 | hkdf/hkdf.h hmac/hmac.h rand/rand.h md5/md5.h | 146 | hkdf/hkdf.h hmac/hmac.h rand/rand.h md5/md5.h mlkem/mlkem.h |
| 133 | x509/x509v3.h conf/conf.h ocsp/ocsp.h | 147 | x509/x509v3.h conf/conf.h ocsp/ocsp.h |
| 134 | aes/aes.h modes/modes.h asn1/asn1t.h bf/blowfish.h | 148 | aes/aes.h modes/modes.h asn1/asn1t.h bf/blowfish.h |
| 135 | bio/bio.h cast/cast.h cmac/cmac.h cms/cms.h conf/conf_api.h des/des.h dh/dh.h | 149 | bio/bio.h cast/cast.h cmac/cmac.h cms/cms.h des/des.h dh/dh.h |
| 136 | dsa/dsa.h engine/engine.h ui/ui.h pkcs12/pkcs12.h ts/ts.h | 150 | dsa/dsa.h engine/engine.h ui/ui.h pkcs12/pkcs12.h ts/ts.h |
| 137 | md4/md4.h ripemd/ripemd.h whrlpool/whrlpool.h idea/idea.h | 151 | md4/md4.h ripemd/ripemd.h idea/idea.h |
| 138 | rc2/rc2.h rc4/rc4.h ui/ui_compat.h txt_db/txt_db.h | 152 | rc2/rc2.h rc4/rc4.h txt_db/txt_db.h |
| 139 | sm3/sm3.h sm4/sm4.h chacha/chacha.h evp/evp.h poly1305/poly1305.h | 153 | sm3/sm3.h sm4/sm4.h chacha/chacha.h evp/evp.h poly1305/poly1305.h |
| 140 | camellia/camellia.h curve25519/curve25519.h | 154 | camellia/camellia.h curve25519/curve25519.h |
| 141 | ct/ct.h kdf/kdf.h" | 155 | ct/ct.h kdf/kdf.h" |
| @@ -156,32 +170,21 @@ echo "LibreSSL version `cat VERSION`" | |||
| 156 | echo copying libcrypto source | 170 | echo copying libcrypto source |
| 157 | rm -f crypto/*.c crypto/*.h | 171 | rm -f crypto/*.c crypto/*.h |
| 158 | touch crypto/empty.c | 172 | touch crypto/empty.c |
| 159 | for i in `awk '/SOURCES|HEADERS/ { print $3 }' crypto/Makefile.am` ; do | 173 | crypto_files=`awk '/^ASM|SOURCES|HEADERS/ { print $3 }' crypto/Makefile.am* | grep -v '^\$(' | sort | uniq` |
| 174 | for i in $crypto_files; do | ||
| 160 | dir=`dirname $i` | 175 | dir=`dirname $i` |
| 161 | mkdir -p crypto/$dir | 176 | mkdir -p crypto/$dir |
| 162 | if [ $dir != "compat" ]; then | 177 | if [ $dir != "compat" ]; then |
| 163 | if [ -e $libcrypto_src/$i ]; then | 178 | if [ -f $libcrypto_src/$i ]; then |
| 164 | $CP $libcrypto_src/$i crypto/$i | 179 | $CP $libcrypto_src/$i crypto/$i |
| 165 | fi | 180 | fi |
| 166 | fi | 181 | fi |
| 167 | done | 182 | done |
| 168 | 183 | ||
| 169 | for i in $libcrypto_src/arch/*; do | ||
| 170 | arch=`basename $i` | ||
| 171 | mkdir -p include/arch/$arch | ||
| 172 | $CP $libcrypto_src/arch/$arch/opensslconf.h include/arch/$arch/ | ||
| 173 | done | ||
| 174 | |||
| 175 | for i in $libcrypto_src/bn/arch/*; do | ||
| 176 | arch=`basename $i` | ||
| 177 | mkdir -p crypto/bn/arch/$arch | ||
| 178 | $CP $libcrypto_src/bn/arch/$arch/* crypto/bn/arch/$arch/ | ||
| 179 | done | ||
| 180 | |||
| 181 | $CP crypto/compat/b_win.c crypto/bio | 184 | $CP crypto/compat/b_win.c crypto/bio |
| 182 | $CP crypto/compat/ui_openssl_win.c crypto/ui | 185 | $CP crypto/compat/ui_openssl_win.c crypto/ui |
| 183 | # add the libcrypto symbol export list | 186 | # add the libcrypto symbol export list |
| 184 | $GREP -v OPENSSL_ia32cap_P $libcrypto_src/Symbols.list | $GREP '^[A-Za-z0-9_]' > crypto/crypto.sym | 187 | $GREP '^[A-Za-z0-9_]' $libcrypto_src/Symbols.list > crypto/crypto.sym |
| 185 | 188 | ||
| 186 | fixup_masm() { | 189 | fixup_masm() { |
| 187 | cpp -I./crypto -I./include/compat -D_MSC_VER -U__CET__ $1 \ | 190 | cpp -I./crypto -I./include/compat -D_MSC_VER -U__CET__ $1 \ |
| @@ -204,6 +207,7 @@ gen_asm_stdout() { | |||
| 204 | EOF | 207 | EOF |
| 205 | if [ $1 = "masm" ]; then | 208 | if [ $1 = "masm" ]; then |
| 206 | fixup_masm crypto/$3.tmp crypto/$3 | 209 | fixup_masm crypto/$3.tmp crypto/$3 |
| 210 | rm crypto/$3.tmp | ||
| 207 | else | 211 | else |
| 208 | $MV crypto/$3.tmp crypto/$3 | 212 | $MV crypto/$3.tmp crypto/$3 |
| 209 | fi | 213 | fi |
| @@ -232,6 +236,7 @@ gen_asm() { | |||
| 232 | EOF | 236 | EOF |
| 233 | if [ $1 = "masm" ]; then | 237 | if [ $1 = "masm" ]; then |
| 234 | fixup_masm crypto/$3.tmp crypto/$3 | 238 | fixup_masm crypto/$3.tmp crypto/$3 |
| 239 | rm crypto/$3.tmp | ||
| 235 | else | 240 | else |
| 236 | $MV crypto/$3.tmp crypto/$3 | 241 | $MV crypto/$3.tmp crypto/$3 |
| 237 | fi | 242 | fi |
| @@ -253,34 +258,16 @@ gen_asm_mips 64 sha sha1-mips sha1-mips64 | |||
| 253 | gen_asm_mips 64 sha sha512-mips sha256-mips64 | 258 | gen_asm_mips 64 sha sha512-mips sha256-mips64 |
| 254 | gen_asm_mips 64 sha sha512-mips sha512-mips64 | 259 | gen_asm_mips 64 sha sha512-mips sha512-mips64 |
| 255 | 260 | ||
| 256 | echo generating arm ASM source for elf | ||
| 257 | gen_asm_stdout elf aes/asm/aes-armv4.pl aes/aes-elf-armv4.S | ||
| 258 | gen_asm_stdout elf bn/asm/armv4-mont.pl bn/mont-elf-armv4.S | ||
| 259 | gen_asm_stdout elf sha/asm/sha1-armv4-large.pl sha/sha1-elf-armv4.S | ||
| 260 | gen_asm_stdout elf sha/asm/sha256-armv4.pl sha/sha256-elf-armv4.S | ||
| 261 | gen_asm_stdout elf sha/asm/sha512-armv4.pl sha/sha512-elf-armv4.S | ||
| 262 | gen_asm_stdout elf modes/asm/ghash-armv4.pl modes/ghash-elf-armv4.S | ||
| 263 | $CP $libcrypto_src/arch/arm/armv4cpuid.S crypto | ||
| 264 | $CP $libcrypto_src/arch/arm/armcap.c crypto | ||
| 265 | $CP $libcrypto_src/arch/arm/arm_arch.h crypto | ||
| 266 | |||
| 267 | for abi in elf macosx masm mingw64; do | 261 | for abi in elf macosx masm mingw64; do |
| 268 | echo generating x86_64 ASM source for $abi | 262 | echo generating x86_64 ASM source for $abi |
| 269 | 263 | ||
| 270 | gen_asm_stdout $abi aes/asm/aes-x86_64.pl aes/aes-$abi-x86_64.S | 264 | gen_asm_stdout $abi aes/asm/aes-x86_64.pl aes/aes-$abi-x86_64.S |
| 271 | gen_asm_stdout $abi aes/asm/vpaes-x86_64.pl aes/vpaes-$abi-x86_64.S | ||
| 272 | gen_asm_stdout $abi aes/asm/bsaes-x86_64.pl aes/bsaes-$abi-x86_64.S | ||
| 273 | gen_asm_stdout $abi aes/asm/aesni-x86_64.pl aes/aesni-$abi-x86_64.S | 265 | gen_asm_stdout $abi aes/asm/aesni-x86_64.pl aes/aesni-$abi-x86_64.S |
| 274 | gen_asm_stdout $abi bn/asm/modexp512-x86_64.pl bn/modexp512-$abi-x86_64.S | 266 | gen_asm_stdout $abi bn/asm/modexp512-x86_64.pl bn/modexp512-$abi-x86_64.S |
| 275 | gen_asm_stdout $abi bn/asm/x86_64-mont.pl bn/mont-$abi-x86_64.S | 267 | gen_asm_stdout $abi bn/asm/x86_64-mont.pl bn/mont-$abi-x86_64.S |
| 276 | gen_asm_stdout $abi bn/asm/x86_64-mont5.pl bn/mont5-$abi-x86_64.S | 268 | gen_asm_stdout $abi bn/asm/x86_64-mont5.pl bn/mont5-$abi-x86_64.S |
| 277 | gen_asm_stdout $abi md5/asm/md5-x86_64.pl md5/md5-$abi-x86_64.S | ||
| 278 | gen_asm_stdout $abi modes/asm/ghash-x86_64.pl modes/ghash-$abi-x86_64.S | 269 | gen_asm_stdout $abi modes/asm/ghash-x86_64.pl modes/ghash-$abi-x86_64.S |
| 279 | gen_asm_stdout $abi rc4/asm/rc4-x86_64.pl rc4/rc4-$abi-x86_64.S | 270 | gen_asm_stdout $abi rc4/asm/rc4-x86_64.pl rc4/rc4-$abi-x86_64.S |
| 280 | gen_asm_stdout $abi sha/asm/sha1-x86_64.pl sha/sha1-$abi-x86_64.S | ||
| 281 | gen_asm $abi sha/asm/sha512-x86_64.pl sha/sha256-$abi-x86_64.S | ||
| 282 | gen_asm $abi sha/asm/sha512-x86_64.pl sha/sha512-$abi-x86_64.S | ||
| 283 | gen_asm $abi x86_64cpuid.pl cpuid-$abi-x86_64.S | ||
| 284 | done | 271 | done |
| 285 | 272 | ||
| 286 | # copy libtls source | 273 | # copy libtls source |
| @@ -333,7 +320,7 @@ done | |||
| 333 | echo "copying libssl source" | 320 | echo "copying libssl source" |
| 334 | rm -f ssl/*.c ssl/*.h | 321 | rm -f ssl/*.c ssl/*.h |
| 335 | touch ssl/empty.c | 322 | touch ssl/empty.c |
| 336 | for i in `awk '/SOURCES|HEADERS/ { print $3 }' ssl/Makefile.am` ; do | 323 | for i in `awk '/SOURCES|HEADERS/ { if ($3 !~ /.*crypto_arch.*/) print $3 }' ssl/Makefile.am` ; do |
| 337 | dir=`dirname $i` | 324 | dir=`dirname $i` |
| 338 | mkdir -p ssl/$dir | 325 | mkdir -p ssl/$dir |
| 339 | $CP $libssl_src/$i ssl/$i | 326 | $CP $libssl_src/$i ssl/$i |
| @@ -344,7 +331,7 @@ $GREP '^[A-Za-z0-9_]' < $libssl_src/Symbols.list > ssl/ssl.sym | |||
| 344 | # copy libcrypto tests | 331 | # copy libcrypto tests |
| 345 | echo "copying tests" | 332 | echo "copying tests" |
| 346 | touch tests/empty.c | 333 | touch tests/empty.c |
| 347 | for i in `find $libcrypto_regress -name '*.c'`; do | 334 | for i in `find $libcrypto_regress -name '*.[ch]'`; do |
| 348 | $CP "$i" tests | 335 | $CP "$i" tests |
| 349 | done | 336 | done |
| 350 | $CP $libcrypto_regress/evp/evptests.txt tests | 337 | $CP $libcrypto_regress/evp/evptests.txt tests |
| @@ -352,6 +339,7 @@ $CP $libcrypto_regress/aead/*.txt tests | |||
| 352 | $CP $libcrypto_regress/ct/ctlog.conf tests | 339 | $CP $libcrypto_regress/ct/ctlog.conf tests |
| 353 | $CP $libcrypto_regress/ct/*.crt tests | 340 | $CP $libcrypto_regress/ct/*.crt tests |
| 354 | $CP $libcrypto_regress/x509/policy/*.pem tests | 341 | $CP $libcrypto_regress/x509/policy/*.pem tests |
| 342 | $CP $libcrypto_regress/mlkem/*.txt tests | ||
| 355 | 343 | ||
| 356 | # generate libcrypto freenull.c | 344 | # generate libcrypto freenull.c |
| 357 | awk -f $libcrypto_regress/free/freenull.awk \ | 345 | awk -f $libcrypto_regress/free/freenull.awk \ |
| @@ -374,7 +362,6 @@ done | |||
| 374 | $CP $libssl_regress/unit/tests.h tests | 362 | $CP $libssl_regress/unit/tests.h tests |
| 375 | $CP $libssl_regress/certs/*.pem tests | 363 | $CP $libssl_regress/certs/*.pem tests |
| 376 | $CP $libssl_regress/certs/*.crl tests | 364 | $CP $libssl_regress/certs/*.crl tests |
| 377 | $CP $libssl_regress/pqueue/expected.txt tests/pq_expected.txt | ||
| 378 | 365 | ||
| 379 | # copy libtls tests | 366 | # copy libtls tests |
| 380 | for i in `find $libtls_regress -name '*.c'`; do | 367 | for i in `find $libtls_regress -name '*.c'`; do |
