1
0
mirror of https://github.com/SoftEtherVPN/SoftEtherVPN.git synced 2025-09-20 10:19:20 +03:00

4 Commits

Author SHA1 Message Date
5d1ce1a2cd Merge pull request #2051 from chipitsine/master
bump version for upcoming 5187 release
2024-09-09 21:57:51 +02:00
d8569ad31a bump version for upcoming 5187 release 2024-09-09 21:12:38 +02:00
e3e0c33e3b Merge pull request #2044 from Evengard/fix2043
Incorrect variable used while iterating through sessions which makes the loop stuck
2024-09-09 21:06:40 +02:00
8f0deb576c Incorrect variable used while iterating through sessions which makes the loop stuck 2024-08-25 15:36:50 +03:00
12 changed files with 58 additions and 93 deletions

View File

@ -8,16 +8,15 @@ on:
jobs: jobs:
build: build:
name: Build name: build
runs-on: ubuntu-latest runs-on: ubuntu-latest
steps: steps:
- name: Checkout - uses: actions/checkout@v1
uses: actions/checkout@v4
with: with:
submodules: true submodules: true
- name: Archive - name: archive
id: archive id: archive
run: | run: |
VERSION=${{ github.event.release.tag_name }} VERSION=${{ github.event.release.tag_name }}
@ -29,8 +28,12 @@ jobs:
tar cJf $TARBALL $PKGNAME tar cJf $TARBALL $PKGNAME
echo "tarball=$TARBALL" >> $GITHUB_OUTPUT echo "tarball=$TARBALL" >> $GITHUB_OUTPUT
- name: Upload tarball - name: upload tarball
uses: softprops/action-gh-release@v2 uses: actions/upload-release-asset@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with: with:
files: ./${{ steps.archive.outputs.tarball }} upload_url: ${{ github.event.release.upload_url }}
name: ${{ steps.archive.outputs.tarball }} asset_path: ./${{ steps.archive.outputs.tarball }}
asset_name: ${{ steps.archive.outputs.tarball }}
asset_content_type: application/gzip

View File

@ -1,3 +1,4 @@
name: Coverity name: Coverity
on: on:
@ -9,36 +10,28 @@ permissions:
jobs: jobs:
scan: scan:
name: Scan
runs-on: ubuntu-latest runs-on: ubuntu-latest
if: github.repository_owner == 'SoftEtherVPN' if: ${{ github.repository_owner == 'SoftEtherVPN' }}
steps: steps:
- uses: actions/checkout@v2
- name: Checkout
uses: actions/checkout@v4
with: with:
submodules: true submodules: true
- name: Install apt dependencies - name: Install apt dependencies
run: | run: |
sudo apt-get update sudo apt-get update
sudo apt-get install -y cmake gcc g++ libncurses5-dev libreadline-dev libssl-dev make zlib1g-dev libsodium-dev sudo apt-get install -y cmake gcc g++ libncurses5-dev libreadline-dev libssl-dev make zlib1g-dev libsodium-dev
- name: Download Coverity build tool - name: Download Coverity build tool
run: | run: |
wget -c -N https://scan.coverity.com/download/linux64 --post-data "token=${{ secrets.COVERITY_SCAN_TOKEN }}&project=SoftEtherVPN%2FSoftEtherVPN" -O coverity_tool.tar.gz wget -c -N https://scan.coverity.com/download/linux64 --post-data "token=${{ secrets.COVERITY_SCAN_TOKEN }}&project=SoftEtherVPN%2FSoftEtherVPN" -O coverity_tool.tar.gz
mkdir coverity_tool mkdir coverity_tool
tar xzf coverity_tool.tar.gz --strip 1 -C coverity_tool tar xzf coverity_tool.tar.gz --strip 1 -C coverity_tool
- name: Configure - name: Configure
run: | run: |
./configure ./configure
- name: Build with Coverity build tool - name: Build with Coverity build tool
run: | run: |
export PATH=`pwd`/coverity_tool/bin:$PATH export PATH=`pwd`/coverity_tool/bin:$PATH
cov-build --dir cov-int make -C build cov-build --dir cov-int make -C build
- name: Submit build result to Coverity Scan - name: Submit build result to Coverity Scan
run: | run: |
tar czvf cov.tar.gz cov-int tar czvf cov.tar.gz cov-int

View File

@ -20,18 +20,15 @@ jobs:
container: container:
image: fedora:rawhide image: fedora:rawhide
steps: steps:
- uses: actions/checkout@v1
with:
submodules: true
- name: Install dependencies - name: Install dependencies
run: | run: |
dnf -y install git cmake ncurses-devel openssl-devel-engine libsodium-devel readline-devel zlib-devel gcc-c++ clang dnf -y install git cmake ncurses-devel openssl-devel-engine libsodium-devel readline-devel zlib-devel gcc-c++ clang
- name: Checkout
uses: actions/checkout@v4
with:
submodules: true
- name: Compile with ${{ matrix.cc }} - name: Compile with ${{ matrix.cc }}
run: | run: |
export CC=${{ matrix.cc }} export CC=${{ matrix.cc }}
./configure ./configure
make -C build make -C build

View File

@ -1,4 +1,3 @@
name: Linux
on: [push, pull_request] on: [push, pull_request]
permissions: permissions:
@ -6,16 +5,14 @@ permissions:
jobs: jobs:
build_and_test: build_and_test:
name: Build
runs-on: ubuntu-latest runs-on: ubuntu-latest
steps: steps:
- uses: actions/checkout@v4 - uses: actions/checkout@v4
with: with:
submodules: true submodules: true
- name: Install dependencies - name: Install dependencies
run: sudo apt-get update && sudo apt-get -y install cmake gcc g++ ninja-build libncurses5-dev libreadline-dev libsodium-dev libssl-dev make zlib1g-dev liblz4-dev libnl-genl-3-dev run: sudo apt update && sudo apt-get -y install cmake gcc g++ ninja-build libncurses5-dev libreadline-dev libsodium-dev libssl-dev make zlib1g-dev liblz4-dev libnl-genl-3-dev
- name: Build - name: Build
run: | run: |

View File

@ -1,4 +1,3 @@
name: macOS
on: [push, pull_request, workflow_dispatch] on: [push, pull_request, workflow_dispatch]
permissions: permissions:
@ -12,22 +11,18 @@ jobs:
name: ${{ matrix.os }} name: ${{ matrix.os }}
runs-on: ${{ matrix.os }} runs-on: ${{ matrix.os }}
steps: steps:
- uses: actions/checkout@v1
- name: Checkout
uses: actions/checkout@v4
with: with:
submodules: true submodules: true
- name: Install dependencies - name: Install dependencies
run: | run: |
brew install libsodium brew install libsodium
- name: Compile - name: Compile
run: | run: |
./configure ./configure
make -C build make -C build
- name: Test - name: Test
run: | run: |
otool -L build/vpnserver otool -L build/vpnserver
.ci/memory-leak-test.sh .ci/memory-leak-test.sh

View File

@ -1,4 +1,4 @@
name: Alpine/musl name: alpine/musl
on: [push, pull_request] on: [push, pull_request]
@ -12,17 +12,12 @@ jobs:
container: container:
image: alpine:latest image: alpine:latest
steps: steps:
- uses: actions/checkout@v1
- name: Install dependencies
run: apk add binutils --no-cache build-base readline-dev openssl-dev ncurses-dev git cmake zlib-dev libsodium-dev gnu-libiconv
- name: Checkout
uses: actions/checkout@v4
with: with:
submodules: true submodules: true
- name: Install dependencies
run: apk add binutils --no-cache build-base readline-dev openssl-dev ncurses-dev git cmake zlib-dev libsodium-dev gnu-libiconv
- name: Configure - name: Configure
run: ./configure run: ./configure
- name: make - name: make
run: make -C build run: make -C build

View File

@ -1,4 +1,3 @@
name: STB Check
on: [push, pull_request] on: [push, pull_request]
permissions: permissions:
@ -6,15 +5,11 @@ permissions:
jobs: jobs:
check: check:
name: Check
runs-on: ubuntu-latest runs-on: ubuntu-latest
steps: steps:
- uses: actions/checkout@v1
- name: Checkout
uses: actions/checkout@v4
with: with:
submodules: true submodules: true
- name: Check - name: Check
run: | run: |
cd developer_tools/stbchecker cd developer_tools/stbchecker

View File

@ -1,4 +1,3 @@
name: Windows
on: [push, pull_request] on: [push, pull_request]
permissions: permissions:
@ -15,24 +14,19 @@ jobs:
runs-on: windows-latest runs-on: windows-latest
name: ${{ matrix.platform.ARCHITECTURE }} name: ${{ matrix.platform.ARCHITECTURE }}
steps: steps:
- uses: actions/checkout@v4
- name: Checkout
uses: actions/checkout@v4
with: with:
submodules: true submodules: true
- name: Cache vcpkg - name: Cache vcpkg
uses: actions/cache@v4 uses: actions/cache@v4
with: with:
path: 'build/vcpkg_installed/' path: 'build/vcpkg_installed/'
key: vcpkg-${{ matrix.platform.VCPKG_TRIPLET }} key: vcpkg-${{ matrix.platform.VCPKG_TRIPLET }}
- name: Set version variables - name: Set version variables
run: | run: |
$v = python version.py $v = python version.py
echo "VERSION=$v" | Out-File -FilePath $Env:GITHUB_ENV -Encoding utf8 -Append echo "VERSION=$v" | Out-File -FilePath $Env:GITHUB_ENV -Encoding utf8 -Append
shell: pwsh shell: pwsh
- name: Build - name: Build
env: env:
ARCHITECTURE: ${{ matrix.platform.ARCHITECTURE }} ARCHITECTURE: ${{ matrix.platform.ARCHITECTURE }}
@ -50,14 +44,11 @@ jobs:
vpnsetup /SFXMODE:vpnclient /SFXOUT:"installers\softether-vpnclient-%VERSION%.%BUILD_NUMBER%.%ARCHITECTURE%.exe" vpnsetup /SFXMODE:vpnclient /SFXOUT:"installers\softether-vpnclient-%VERSION%.%BUILD_NUMBER%.%ARCHITECTURE%.exe"
vpnsetup /SFXMODE:vpnserver_vpnbridge /SFXOUT:"installers\softether-vpnserver_vpnbridge-%VERSION%.%BUILD_NUMBER%.%ARCHITECTURE%.exe" vpnsetup /SFXMODE:vpnserver_vpnbridge /SFXOUT:"installers\softether-vpnserver_vpnbridge-%VERSION%.%BUILD_NUMBER%.%ARCHITECTURE%.exe"
shell: cmd shell: cmd
- name: Test - name: Test
shell: powershell shell: powershell
run: | run: |
. .ci/appveyor-vpntest.ps1 . .ci/appveyor-vpntest.ps1
- uses: actions/upload-artifact@v4
- name: Upload built binaries
uses: actions/upload-artifact@v4
with: with:
if-no-files-found: error if-no-files-found: error
name: Binaries-${{ matrix.platform.ARCHITECTURE }} name: Binaries-${{ matrix.platform.ARCHITECTURE }}
@ -65,9 +56,7 @@ jobs:
build/*.exe build/*.exe
build/*.pdb build/*.pdb
build/*.se2 build/*.se2
- uses: actions/upload-artifact@v4
- name: Upload installers
uses: actions/upload-artifact@v4
with: with:
if-no-files-found: error if-no-files-found: error
name: Installers-${{ matrix.platform.ARCHITECTURE }} name: Installers-${{ matrix.platform.ARCHITECTURE }}

View File

@ -14,19 +14,16 @@ permissions:
jobs: jobs:
release: release:
name: Release
runs-on: windows-latest runs-on: windows-latest
outputs: outputs:
upload_url: "${{ steps.create_release.outputs.upload_url }}" upload_url: "${{ steps.create_release.outputs.upload_url }}"
steps: steps:
- name: "Checkout repository" - name: "Checkout repository"
uses: actions/checkout@v4 uses: actions/checkout@v4
- name: "Create GitHub release" - name: "Create GitHub release"
id: create_release id: create_release
uses: softprops/action-gh-release@v2 uses: softprops/action-gh-release@v1
build-windows: build-windows:
name: ${{ matrix.platform.ARCHITECTURE }} name: ${{ matrix.platform.ARCHITECTURE }}
runs-on: windows-latest runs-on: windows-latest
@ -38,18 +35,15 @@ jobs:
{ ARCHITECTURE: x64, COMPILER_PATH: "C:/Program Files/Microsoft Visual Studio/2022/Enterprise/VC/Tools/Llvm/x64/bin/clang-cl.exe", VCPKG_TRIPLET: "x64-windows-static", VCVARS_PATH: "C:/Program Files/Microsoft Visual Studio/2022/Enterprise/VC/Auxiliary/Build/vcvars64.bat"} { ARCHITECTURE: x64, COMPILER_PATH: "C:/Program Files/Microsoft Visual Studio/2022/Enterprise/VC/Tools/Llvm/x64/bin/clang-cl.exe", VCPKG_TRIPLET: "x64-windows-static", VCVARS_PATH: "C:/Program Files/Microsoft Visual Studio/2022/Enterprise/VC/Auxiliary/Build/vcvars64.bat"}
] ]
steps: steps:
- name: "Checkout repository" - name: "Checkout repository"
uses: actions/checkout@v4 uses: actions/checkout@v4
with: with:
submodules: true submodules: true
- name: Cache vcpkg - name: Cache vcpkg
uses: actions/cache@v4 uses: actions/cache@v4
with: with:
path: 'build/vcpkg_installed/' path: 'build/vcpkg_installed/'
key: vcpkg-release-${{ matrix.platform.VCPKG_TRIPLET }} key: vcpkg-release-${{ matrix.platform.VCPKG_TRIPLET }}
- name: Set version variables - name: Set version variables
run: | run: |
$b=(Get-Content CMakeSettings.json | Out-String | ConvertFrom-Json).environments.BuildNumber $b=(Get-Content CMakeSettings.json | Out-String | ConvertFrom-Json).environments.BuildNumber
@ -57,7 +51,6 @@ jobs:
$v = python version.py $v = python version.py
echo "VERSION=$v" | Out-File -FilePath $Env:GITHUB_ENV -Encoding utf8 -Append echo "VERSION=$v" | Out-File -FilePath $Env:GITHUB_ENV -Encoding utf8 -Append
shell: pwsh shell: pwsh
- name: Build - name: Build
env: env:
ARCHITECTURE: ${{ matrix.platform.ARCHITECTURE }} ARCHITECTURE: ${{ matrix.platform.ARCHITECTURE }}
@ -75,19 +68,27 @@ jobs:
vpnsetup /SFXMODE:vpnserver_vpnbridge /SFXOUT:"installers\softether-vpnserver_vpnbridge-%VERSION%.%BUILD_NUMBER%.%ARCHITECTURE%.exe" vpnsetup /SFXMODE:vpnserver_vpnbridge /SFXOUT:"installers\softether-vpnserver_vpnbridge-%VERSION%.%BUILD_NUMBER%.%ARCHITECTURE%.exe"
shell: cmd shell: cmd
- name: Show directory items - name: dir
run: | run: |
Get-ChildItem -Recurse build/installers Get-ChildItem -Recurse build/installers
shell: pwsh shell: pwsh
- name: "Upload softether-vpnclient" - name: "Upload softether-vpnclient"
uses: softprops/action-gh-release@v2 uses: actions/upload-release-asset@v1
env:
GITHUB_TOKEN: "${{ github.token }}"
with: with:
files: "build/installers/softether-vpnclient-${{ env.VERSION }}.${{ env.BUILD_NUMBER }}.${{ matrix.platform.ARCHITECTURE }}.exe" upload_url: "${{ needs.release.outputs.upload_url }}"
name: "softether-vpnclient-${{ env.VERSION }}.${{ env.BUILD_NUMBER }}.${{ matrix.platform.ARCHITECTURE }}.exe" asset_path: "build/installers/softether-vpnclient-${{ env.VERSION }}.${{ env.BUILD_NUMBER }}.${{ matrix.platform.ARCHITECTURE }}.exe"
asset_name: "softether-vpnclient-${{ env.VERSION }}.${{ env.BUILD_NUMBER }}.${{ matrix.platform.ARCHITECTURE }}.exe"
asset_content_type: "application/octet-stream"
- name: "Upload softether-vpnserver_vpnbridge" - name: "Upload softether-vpnserver_vpnbridge"
uses: softprops/action-gh-release@v2 uses: actions/upload-release-asset@v1
env:
GITHUB_TOKEN: "${{ github.token }}"
with: with:
files: "build/installers/softether-vpnserver_vpnbridge-${{ env.VERSION }}.${{ env.BUILD_NUMBER }}.${{ matrix.platform.ARCHITECTURE }}.exe" upload_url: "${{ needs.release.outputs.upload_url }}"
name: "softether-vpnserver_vpnbridge-${{ env.VERSION }}.${{ env.BUILD_NUMBER }}.${{ matrix.platform.ARCHITECTURE }}.exe" asset_path: "build/installers/softether-vpnserver_vpnbridge-${{ env.VERSION }}.${{ env.BUILD_NUMBER }}.${{ matrix.platform.ARCHITECTURE }}.exe"
asset_name: "softether-vpnserver_vpnbridge-${{ env.VERSION }}.${{ env.BUILD_NUMBER }}.${{ matrix.platform.ARCHITECTURE }}.exe"
asset_content_type: "application/octet-stream"

View File

@ -3,7 +3,7 @@ cmake_minimum_required(VERSION 3.15)
set(BUILD_NUMBER CACHE STRING "The number of the current build.") set(BUILD_NUMBER CACHE STRING "The number of the current build.")
if ("${BUILD_NUMBER}" STREQUAL "") if ("${BUILD_NUMBER}" STREQUAL "")
set(BUILD_NUMBER "5186") set(BUILD_NUMBER "5187")
endif() endif()
if (BUILD_NUMBER LESS 5180) if (BUILD_NUMBER LESS 5180)

View File

@ -1,5 +1,5 @@
{ {
"environments": [ { "BuildNumber": "5186" } ], "environments": [ { "BuildNumber": "5187" } ],
"configurations": [ "configurations": [
{ {
"name": "x64-native", "name": "x64-native",

View File

@ -2138,9 +2138,9 @@ void L2TPProcessInterrupts(L2TP_SERVER *l2tp)
UINT64 l2tpTimeout = L2TP_TUNNEL_TIMEOUT; UINT64 l2tpTimeout = L2TP_TUNNEL_TIMEOUT;
// If we got on ANY session a higher timeout than the default L2TP tunnel timeout, increase it // If we got on ANY session a higher timeout than the default L2TP tunnel timeout, increase it
for (i = 0; i < LIST_NUM(t->SessionList); i++) for (j = 0; j < LIST_NUM(t->SessionList); j++)
{ {
L2TP_SESSION* s = LIST_DATA(t->SessionList, i); L2TP_SESSION* s = LIST_DATA(t->SessionList, j);
if (s->TubeRecv != NULL && s->TubeRecv->DataTimeout > l2tpTimeout) if (s->TubeRecv != NULL && s->TubeRecv->DataTimeout > l2tpTimeout)
{ {