mirror of
https://github.com/SoftEtherVPN/SoftEtherVPN.git
synced 2026-04-21 14:29:27 +03:00
Compare commits
98 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| 019261e47f | |||
| bd1512f15b | |||
| 33d682beee | |||
| 476638b7d9 | |||
| bc2d951000 | |||
| e0c86ab4a6 | |||
| 5130f1a4da | |||
| 13f15384f2 | |||
| bbda0c298d | |||
| e42aa6bf78 | |||
| ef05c4f0c4 | |||
| 7f6e527b47 | |||
| a0afd98744 | |||
| ae448abdad | |||
| cfe854b339 | |||
| c075bd85a8 | |||
| 6f749ab71c | |||
| 0e36e095f0 | |||
| 34e4d4a54b | |||
| df3ea19f0e | |||
| 9da4aabda5 | |||
| 3cb3dd20fc | |||
| b551b77e25 | |||
| 609b8f4a5e | |||
| 0a87ff8fbd | |||
| 6016f84315 | |||
| 9d27b935b7 | |||
| 1e1104d3ba | |||
| 074efb5479 | |||
| fe460de5a6 | |||
| 6ef941db21 | |||
| d7d3ec8cac | |||
| 68e9f0b593 | |||
| f1012da5fb | |||
| 1411d4ceb4 | |||
| a3176175f9 | |||
| 88af7986b4 | |||
| 38f102e2e7 | |||
| e722f78608 | |||
| 969812e0f2 | |||
| 14526cf3ea | |||
| 875c4fa344 | |||
| d8be1e4ddc | |||
| eaef60a582 | |||
| 06c93414f2 | |||
| e065752618 | |||
| d75aba9866 | |||
| 1b9ac396ba | |||
| 041581ce30 | |||
| ca745bd234 | |||
| 051da3a48f | |||
| 669f58036e | |||
| ce95ef93a2 | |||
| 355609b339 | |||
| 85c814a0fb | |||
| 90a77cfddf | |||
| 65e5e28549 | |||
| 770aef2866 | |||
| b92294fc52 | |||
| a4681818c4 | |||
| 0a44e995de | |||
| d85fc71a3a | |||
| e884c4ef76 | |||
| 859ff5ca5e | |||
| 85561f3584 | |||
| 6880886e5a | |||
| c32184495b | |||
| 304364719c | |||
| d5c2e33175 | |||
| 1ec05c0cb6 | |||
| 873ba87029 | |||
| 2e83cd5726 | |||
| 3bf7361dc1 | |||
| c26f89e441 | |||
| 3526387d5b | |||
| 9ad703731a | |||
| 204ab85e51 | |||
| 2628c562be | |||
| e9f7089c8b | |||
| 9be944a9b2 | |||
| 137d7f551f | |||
| d90e89bbbd | |||
| 173df872b8 | |||
| 4a4c1c79de | |||
| acbc514b87 | |||
| d9d78a0b2c | |||
| 1373ed4c6c | |||
| ffe9ade675 | |||
| ab245552b1 | |||
| fdcb0a207b | |||
| 564d2f84b4 | |||
| 4bb366572d | |||
| 6c04825b46 | |||
| 0ec8a1ed54 | |||
| 2acefef41e | |||
| efb04daa34 | |||
| c399ce6bbe | |||
| 2746e8dd19 |
+2
-2
@@ -4,14 +4,14 @@ FreeBSD_task:
|
|||||||
SSL: openssl
|
SSL: openssl
|
||||||
OPENSSL_ROOT_DIR: /usr/local
|
OPENSSL_ROOT_DIR: /usr/local
|
||||||
env:
|
env:
|
||||||
SSL: openssl32
|
SSL: openssl36
|
||||||
OPENSSL_ROOT_DIR: /usr/local
|
OPENSSL_ROOT_DIR: /usr/local
|
||||||
env:
|
env:
|
||||||
# base openssl
|
# base openssl
|
||||||
SSL:
|
SSL:
|
||||||
matrix:
|
matrix:
|
||||||
freebsd_instance:
|
freebsd_instance:
|
||||||
image_family: freebsd-14-2
|
image_family: freebsd-14-3
|
||||||
prepare_script:
|
prepare_script:
|
||||||
- pkg install -y pkgconf cmake git libsodium cpu_features $SSL
|
- pkg install -y pkgconf cmake git libsodium cpu_features $SSL
|
||||||
- git submodule update --init --recursive
|
- git submodule update --init --recursive
|
||||||
|
|||||||
@@ -8,6 +8,8 @@ body:
|
|||||||
Thanks for taking the time to fill out this bug report!
|
Thanks for taking the time to fill out this bug report!
|
||||||
We provide a template which is specifically made for bug reports, to be sure that the report includes enough details to be helpful.
|
We provide a template which is specifically made for bug reports, to be sure that the report includes enough details to be helpful.
|
||||||
|
|
||||||
|
**⚠️ Antivirus False Positive?** If you're reporting an antivirus detection issue, please see [ANTIVIRUS.md](https://github.com/SoftEtherVPN/SoftEtherVPN/blob/master/ANTIVIRUS.md) first. Antivirus false positives should be reported to the antivirus vendor, not as bugs in SoftEther VPN.
|
||||||
|
|
||||||
- type: checkboxes
|
- type: checkboxes
|
||||||
attributes:
|
attributes:
|
||||||
label: Are you using SoftEther VPN 5.x?
|
label: Are you using SoftEther VPN 5.x?
|
||||||
|
|||||||
@@ -1,4 +1,8 @@
|
|||||||
contact_links:
|
contact_links:
|
||||||
|
- name: Antivirus False Positive Detection
|
||||||
|
about: If antivirus software is flagging SoftEther VPN as malicious, this is a false positive. See our documentation for solutions and how to report to antivirus vendors.
|
||||||
|
url: https://github.com/SoftEtherVPN/SoftEtherVPN/blob/master/ANTIVIRUS.md
|
||||||
|
|
||||||
- name: Are you using SoftEther VPN 4.x?
|
- name: Are you using SoftEther VPN 4.x?
|
||||||
about: This repository is for SoftEther VPN 5.x Developer Edition, developed independently from SoftEther VPN 4.x. Visit vpnusers.com if you would like to report issues or ask questions about version 4.x!
|
about: This repository is for SoftEther VPN 5.x Developer Edition, developed independently from SoftEther VPN 4.x. Visit vpnusers.com if you would like to report issues or ask questions about version 4.x!
|
||||||
url: https://www.vpnusers.com/
|
url: https://www.vpnusers.com/
|
||||||
|
|||||||
@@ -4,6 +4,7 @@ name: Coverity
|
|||||||
on:
|
on:
|
||||||
schedule:
|
schedule:
|
||||||
- cron: "0 0 * * *"
|
- cron: "0 0 * * *"
|
||||||
|
workflow_dispatch:
|
||||||
|
|
||||||
permissions:
|
permissions:
|
||||||
contents: read
|
contents: read
|
||||||
@@ -11,7 +12,7 @@ permissions:
|
|||||||
jobs:
|
jobs:
|
||||||
scan:
|
scan:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
if: ${{ github.repository_owner == 'SoftEtherVPN' }}
|
if: ${{ github.repository_owner == 'SoftEtherVPN' || github.event_name == 'workflow_dispatch' }}
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v2
|
- uses: actions/checkout@v2
|
||||||
with:
|
with:
|
||||||
|
|||||||
@@ -7,7 +7,7 @@ jobs:
|
|||||||
build_and_test:
|
build_and_test:
|
||||||
strategy:
|
strategy:
|
||||||
matrix:
|
matrix:
|
||||||
os: [macos-15, macos-14, macos-13]
|
os: [macos-26, macos-15, macos-14]
|
||||||
name: ${{ matrix.os }}
|
name: ${{ matrix.os }}
|
||||||
runs-on: ${{ matrix.os }}
|
runs-on: ${{ matrix.os }}
|
||||||
steps:
|
steps:
|
||||||
|
|||||||
@@ -8,10 +8,11 @@ jobs:
|
|||||||
strategy:
|
strategy:
|
||||||
matrix:
|
matrix:
|
||||||
platform: [
|
platform: [
|
||||||
{ ARCHITECTURE: x86, COMPILER_PATH: "C:/Program Files/Microsoft Visual Studio/2022/Enterprise/VC/Tools/Llvm/bin/clang-cl.exe", VCPKG_TRIPLET: "x86-windows-static", VCVARS_PATH: "C:/Program Files/Microsoft Visual Studio/2022/Enterprise/VC/Auxiliary/Build/vcvars32.bat"},
|
{ ARCHITECTURE: x86, COMPILER_PATH: "C:/Program Files/Microsoft Visual Studio/2022/Enterprise/VC/Tools/Llvm/bin/clang-cl.exe", VCPKG_TRIPLET: "x86-windows-static", VCVARS_PATH: "C:/Program Files/Microsoft Visual Studio/2022/Enterprise/VC/Auxiliary/Build/vcvars32.bat", RUNNER: "windows-latest", CMAKE_EXTRA_FLAGS: ""},
|
||||||
{ 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", RUNNER: "windows-latest", CMAKE_EXTRA_FLAGS: ""},
|
||||||
|
{ ARCHITECTURE: arm64, COMPILER_PATH: "C:/Program Files/Microsoft Visual Studio/2022/Enterprise/VC/Tools/Llvm/ARM64/bin/clang-cl.exe", VCPKG_TRIPLET: "arm64-windows-static", VCVARS_PATH: "C:/Program Files/Microsoft Visual Studio/2022/Enterprise/VC/Auxiliary/Build/vcvarsarm64.bat", RUNNER: "windows-11-arm", CMAKE_EXTRA_FLAGS: "-DOQS_PERMIT_UNSUPPORTED_ARCHITECTURE=ON"}
|
||||||
]
|
]
|
||||||
runs-on: windows-latest
|
runs-on: ${{ matrix.platform.RUNNER }}
|
||||||
name: ${{ matrix.platform.ARCHITECTURE }}
|
name: ${{ matrix.platform.ARCHITECTURE }}
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v4
|
- uses: actions/checkout@v4
|
||||||
@@ -33,12 +34,13 @@ jobs:
|
|||||||
COMPILER_PATH: ${{ matrix.platform.COMPILER_PATH }}
|
COMPILER_PATH: ${{ matrix.platform.COMPILER_PATH }}
|
||||||
VCPKG_TRIPLET: ${{ matrix.platform.VCPKG_TRIPLET }}
|
VCPKG_TRIPLET: ${{ matrix.platform.VCPKG_TRIPLET }}
|
||||||
VCVARS_PATH: ${{ matrix.platform.VCVARS_PATH }}
|
VCVARS_PATH: ${{ matrix.platform.VCVARS_PATH }}
|
||||||
|
CMAKE_EXTRA_FLAGS: ${{ matrix.platform.CMAKE_EXTRA_FLAGS }}
|
||||||
run: |
|
run: |
|
||||||
set BUILD_NUMBER=0
|
set BUILD_NUMBER=0
|
||||||
mkdir build
|
mkdir build
|
||||||
cd build
|
cd build
|
||||||
call "%VCVARS_PATH%"
|
call "%VCVARS_PATH%"
|
||||||
cmake -G "Ninja" -DCMAKE_TOOLCHAIN_FILE="C:\vcpkg\scripts\buildsystems\vcpkg.cmake" -DVCPKG_TARGET_TRIPLET=%VCPKG_TRIPLET% -DCMAKE_BUILD_TYPE=RelWithDebInfo -DCMAKE_C_COMPILER="%COMPILER_PATH%" -DCMAKE_CXX_COMPILER="%COMPILER_PATH%" -DBUILD_NUMBER=%BUILD_NUMBER% ..
|
cmake -G "Ninja" -DCMAKE_TOOLCHAIN_FILE="C:\vcpkg\scripts\buildsystems\vcpkg.cmake" -DVCPKG_TARGET_TRIPLET=%VCPKG_TRIPLET% -DCMAKE_BUILD_TYPE=RelWithDebInfo -DCMAKE_C_COMPILER="%COMPILER_PATH%" -DCMAKE_CXX_COMPILER="%COMPILER_PATH%" -DBUILD_NUMBER=%BUILD_NUMBER% %CMAKE_EXTRA_FLAGS% ..
|
||||||
cmake --build .
|
cmake --build .
|
||||||
mkdir installers
|
mkdir installers
|
||||||
vpnsetup /SFXMODE:vpnclient /SFXOUT:"installers\softether-vpnclient-%VERSION%.%BUILD_NUMBER%.%ARCHITECTURE%.exe"
|
vpnsetup /SFXMODE:vpnclient /SFXOUT:"installers\softether-vpnclient-%VERSION%.%BUILD_NUMBER%.%ARCHITECTURE%.exe"
|
||||||
|
|||||||
@@ -26,13 +26,14 @@ jobs:
|
|||||||
uses: softprops/action-gh-release@v1
|
uses: softprops/action-gh-release@v1
|
||||||
build-windows:
|
build-windows:
|
||||||
name: ${{ matrix.platform.ARCHITECTURE }}
|
name: ${{ matrix.platform.ARCHITECTURE }}
|
||||||
runs-on: windows-latest
|
runs-on: ${{ matrix.platform.RUNNER }}
|
||||||
needs: ["release"]
|
needs: ["release"]
|
||||||
strategy:
|
strategy:
|
||||||
matrix:
|
matrix:
|
||||||
platform: [
|
platform: [
|
||||||
{ ARCHITECTURE: x86, COMPILER_PATH: "C:/Program Files/Microsoft Visual Studio/2022/Enterprise/VC/Tools/Llvm/bin/clang-cl.exe", VCPKG_TRIPLET: "x86-windows-static", VCVARS_PATH: "C:/Program Files/Microsoft Visual Studio/2022/Enterprise/VC/Auxiliary/Build/vcvars32.bat"},
|
{ ARCHITECTURE: x86, COMPILER_PATH: "C:/Program Files/Microsoft Visual Studio/2022/Enterprise/VC/Tools/Llvm/bin/clang-cl.exe", VCPKG_TRIPLET: "x86-windows-static", VCVARS_PATH: "C:/Program Files/Microsoft Visual Studio/2022/Enterprise/VC/Auxiliary/Build/vcvars32.bat", RUNNER: "windows-latest", CMAKE_EXTRA_FLAGS: ""},
|
||||||
{ 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", RUNNER: "windows-latest", CMAKE_EXTRA_FLAGS: ""},
|
||||||
|
{ ARCHITECTURE: arm64, COMPILER_PATH: "C:/Program Files/Microsoft Visual Studio/2022/Enterprise/VC/Tools/Llvm/ARM64/bin/clang-cl.exe", VCPKG_TRIPLET: "arm64-windows-static", VCVARS_PATH: "C:/Program Files/Microsoft Visual Studio/2022/Enterprise/VC/Auxiliary/Build/vcvarsarm64.bat", RUNNER: "windows-11-arm", CMAKE_EXTRA_FLAGS: "-DOQS_PERMIT_UNSUPPORTED_ARCHITECTURE=ON"}
|
||||||
]
|
]
|
||||||
steps:
|
steps:
|
||||||
- name: "Checkout repository"
|
- name: "Checkout repository"
|
||||||
@@ -57,11 +58,12 @@ jobs:
|
|||||||
COMPILER_PATH: ${{ matrix.platform.COMPILER_PATH }}
|
COMPILER_PATH: ${{ matrix.platform.COMPILER_PATH }}
|
||||||
VCPKG_TRIPLET: ${{ matrix.platform.VCPKG_TRIPLET }}
|
VCPKG_TRIPLET: ${{ matrix.platform.VCPKG_TRIPLET }}
|
||||||
VCVARS_PATH: ${{ matrix.platform.VCVARS_PATH }}
|
VCVARS_PATH: ${{ matrix.platform.VCVARS_PATH }}
|
||||||
|
CMAKE_EXTRA_FLAGS: ${{ matrix.platform.CMAKE_EXTRA_FLAGS }}
|
||||||
run: |
|
run: |
|
||||||
mkdir build
|
mkdir build
|
||||||
cd build
|
cd build
|
||||||
call "%VCVARS_PATH%"
|
call "%VCVARS_PATH%"
|
||||||
cmake -G "Ninja" -DCMAKE_TOOLCHAIN_FILE="C:\vcpkg\scripts\buildsystems\vcpkg.cmake" -DVCPKG_TARGET_TRIPLET=%VCPKG_TRIPLET% -DCMAKE_BUILD_TYPE=RelWithDebInfo -DCMAKE_C_COMPILER="%COMPILER_PATH%" -DCMAKE_CXX_COMPILER="%COMPILER_PATH%" -DBUILD_NUMBER=%BUILD_NUMBER% ..
|
cmake -G "Ninja" -DCMAKE_TOOLCHAIN_FILE="C:\vcpkg\scripts\buildsystems\vcpkg.cmake" -DVCPKG_TARGET_TRIPLET=%VCPKG_TRIPLET% -DCMAKE_BUILD_TYPE=RelWithDebInfo -DCMAKE_C_COMPILER="%COMPILER_PATH%" -DCMAKE_CXX_COMPILER="%COMPILER_PATH%" -DBUILD_NUMBER=%BUILD_NUMBER% %CMAKE_EXTRA_FLAGS% ..
|
||||||
cmake --build .
|
cmake --build .
|
||||||
mkdir installers
|
mkdir installers
|
||||||
vpnsetup /SFXMODE:vpnclient /SFXOUT:"installers\softether-vpnclient-%VERSION%.%BUILD_NUMBER%.%ARCHITECTURE%.exe"
|
vpnsetup /SFXMODE:vpnclient /SFXOUT:"installers\softether-vpnclient-%VERSION%.%BUILD_NUMBER%.%ARCHITECTURE%.exe"
|
||||||
|
|||||||
@@ -210,3 +210,9 @@ developer_tools/stbchecker/**/*.binlog
|
|||||||
developer_tools/stbchecker/**/*.nvuser
|
developer_tools/stbchecker/**/*.nvuser
|
||||||
developer_tools/stbchecker/**/.mfractor/
|
developer_tools/stbchecker/**/.mfractor/
|
||||||
/vcpkg_installed
|
/vcpkg_installed
|
||||||
|
|
||||||
|
# Build directories
|
||||||
|
/_codeql_build_dir/
|
||||||
|
/_codeql_detected_source_root
|
||||||
|
/build/
|
||||||
|
/build_test/
|
||||||
|
|||||||
+338
@@ -0,0 +1,338 @@
|
|||||||
|
# Antivirus False Positive Detection
|
||||||
|
|
||||||
|
## Overview
|
||||||
|
|
||||||
|
Some antivirus software, including Microsoft Defender, may incorrectly flag SoftEther VPN executables as malicious software. This is a **false positive** detection. SoftEther VPN is legitimate, open-source software that has been developed and maintained since 2013 by researchers at the University of Tsukuba, Japan.
|
||||||
|
|
||||||
|
## Why Does This Happen?
|
||||||
|
|
||||||
|
Antivirus software uses heuristic analysis to detect potentially malicious behavior. VPN software like SoftEther VPN performs operations that can appear suspicious to antivirus programs, including:
|
||||||
|
|
||||||
|
- **Network tunneling and traffic interception**: VPN software creates virtual network adapters and intercepts network traffic to secure it
|
||||||
|
- **Low-level network operations**: Packet filtering, protocol handling, and kernel-mode operations
|
||||||
|
- **Service installation**: VPN clients install system services that run with elevated privileges
|
||||||
|
- **Registry modifications**: Required for Windows integration and auto-start functionality
|
||||||
|
- **Dynamic code execution**: Network protocol implementations may use techniques that appear similar to malicious software
|
||||||
|
|
||||||
|
These are **normal and necessary operations** for any VPN software, but they can trigger heuristic-based detection algorithms.
|
||||||
|
|
||||||
|
## Microsoft Defender Specific Issue
|
||||||
|
|
||||||
|
### Affected Components
|
||||||
|
|
||||||
|
Microsoft Defender may flag the following SoftEther VPN 5.x components as `Trojan:Win32/KepavII!rfn`:
|
||||||
|
|
||||||
|
- `vpnclient.exe` - VPN Client executable
|
||||||
|
- `vpnserver.exe` - VPN Server executable
|
||||||
|
- `vpnbridge.exe` - VPN Bridge executable
|
||||||
|
- `vpncmd.exe` - VPN Command-line utility
|
||||||
|
- Start menu shortcuts
|
||||||
|
- Registry entries
|
||||||
|
- Windows services (`SEVPNCLIENTDEV`, `SEVPNSERVERDEV`, etc.)
|
||||||
|
|
||||||
|
### Detection Details
|
||||||
|
|
||||||
|
```
|
||||||
|
Detected: Trojan:Win32/KepavII!rfn
|
||||||
|
Status: Quarantined
|
||||||
|
Description: "This program is dangerous and executes commands from an attacker."
|
||||||
|
```
|
||||||
|
|
||||||
|
**This is a false positive.** The detection is based on behavioral heuristics, not actual malicious code.
|
||||||
|
|
||||||
|
## Solutions and Workarounds
|
||||||
|
|
||||||
|
### Option 1: Add Exclusions (Recommended for Users)
|
||||||
|
|
||||||
|
The recommended approach is to add SoftEther VPN directories to Microsoft Defender's exclusion list:
|
||||||
|
|
||||||
|
#### Step-by-Step Instructions:
|
||||||
|
|
||||||
|
1. **Open Windows Security**
|
||||||
|
- Press `Windows Key + I` to open Settings
|
||||||
|
- Navigate to **Privacy & Security** → **Windows Security**
|
||||||
|
- Click **Virus & threat protection**
|
||||||
|
|
||||||
|
2. **Access Exclusion Settings**
|
||||||
|
- Scroll down to **Virus & threat protection settings**
|
||||||
|
- Click **Manage settings**
|
||||||
|
- Scroll down to **Exclusions**
|
||||||
|
- Click **Add or remove exclusions**
|
||||||
|
|
||||||
|
3. **Add SoftEther VPN Directories**
|
||||||
|
|
||||||
|
Click **Add an exclusion** → **Folder** and add these paths:
|
||||||
|
|
||||||
|
- `C:\Program Files\SoftEther VPN Client`
|
||||||
|
- `C:\Program Files\SoftEther VPN Client Developer Edition`
|
||||||
|
- `C:\Program Files\SoftEther VPN Server`
|
||||||
|
- `C:\Program Files\SoftEther VPN Server Manager`
|
||||||
|
- `C:\Program Files\SoftEther VPN Server Manager Developer Edition`
|
||||||
|
- `C:\Program Files\SoftEther VPN Server Developer Edition`
|
||||||
|
- `C:\ProgramData\SoftEther VPN Client`
|
||||||
|
- `C:\ProgramData\SoftEther VPN Server`
|
||||||
|
|
||||||
|
**Note**: Add only the directories that correspond to the SoftEther VPN components you have installed.
|
||||||
|
|
||||||
|
4. **Restore Quarantined Files** (if needed)
|
||||||
|
- Go back to **Virus & threat protection**
|
||||||
|
- Click **Protection history**
|
||||||
|
- Find the quarantined SoftEther VPN files
|
||||||
|
- Click **Actions** → **Restore**
|
||||||
|
|
||||||
|
5. **Reinstall if Necessary**
|
||||||
|
- If files were deleted, you may need to reinstall SoftEther VPN
|
||||||
|
- The exclusions will prevent future detections
|
||||||
|
|
||||||
|
### Option 2: Report False Positive to Microsoft
|
||||||
|
|
||||||
|
Help improve Microsoft Defender by reporting the false positive:
|
||||||
|
|
||||||
|
1. **Submit to Microsoft Defender Security Intelligence**
|
||||||
|
- Visit: https://www.microsoft.com/en-us/wdsi/filesubmission
|
||||||
|
- Select **File** submission type
|
||||||
|
- Choose **Software developer** as your role
|
||||||
|
- Submit the falsely detected SoftEther VPN executable files
|
||||||
|
- Provide details: "False positive detection of SoftEther VPN, open-source VPN software"
|
||||||
|
|
||||||
|
2. **Include Information**
|
||||||
|
- Product Name: SoftEther VPN
|
||||||
|
- Vendor: SoftEther Project at University of Tsukuba
|
||||||
|
- Official Website: https://www.softether.org/
|
||||||
|
- GitHub Repository: https://github.com/SoftEtherVPN/SoftEtherVPN
|
||||||
|
- License: Apache License 2.0
|
||||||
|
|
||||||
|
Microsoft typically reviews submissions within a few days and updates their definitions if confirmed as a false positive.
|
||||||
|
|
||||||
|
### Option 3: Use Alternative Antivirus Software
|
||||||
|
|
||||||
|
If Microsoft Defender continues to cause issues:
|
||||||
|
|
||||||
|
1. Consider using alternative antivirus software that doesn't flag SoftEther VPN
|
||||||
|
2. Some users report fewer false positives with third-party antivirus solutions
|
||||||
|
3. Ensure any alternative antivirus is from a reputable vendor
|
||||||
|
|
||||||
|
## For IT Administrators
|
||||||
|
|
||||||
|
### Group Policy Configuration
|
||||||
|
|
||||||
|
To deploy exclusions across an organization using Group Policy:
|
||||||
|
|
||||||
|
1. **Open Group Policy Management Console**
|
||||||
|
```
|
||||||
|
gpmc.msc
|
||||||
|
```
|
||||||
|
|
||||||
|
2. **Navigate to Windows Defender Antivirus Settings**
|
||||||
|
```
|
||||||
|
Computer Configuration → Policies → Administrative Templates
|
||||||
|
→ Windows Components → Microsoft Defender Antivirus → Exclusions
|
||||||
|
```
|
||||||
|
|
||||||
|
3. **Configure Path Exclusions**
|
||||||
|
- Enable **Path Exclusions**
|
||||||
|
- Add the SoftEther VPN installation directories
|
||||||
|
|
||||||
|
4. **Update Group Policy**
|
||||||
|
```powershell
|
||||||
|
gpupdate /force
|
||||||
|
```
|
||||||
|
|
||||||
|
### PowerShell Exclusion Script
|
||||||
|
|
||||||
|
For automated deployment, use this PowerShell script (requires Administrator privileges):
|
||||||
|
|
||||||
|
```powershell
|
||||||
|
# Add Windows Defender exclusions for SoftEther VPN
|
||||||
|
# Requires Administrator privileges
|
||||||
|
|
||||||
|
$exclusionPaths = @(
|
||||||
|
"C:\Program Files\SoftEther VPN Client",
|
||||||
|
"C:\Program Files\SoftEther VPN Client Developer Edition",
|
||||||
|
"C:\Program Files\SoftEther VPN Server",
|
||||||
|
"C:\Program Files\SoftEther VPN Server Manager",
|
||||||
|
"C:\Program Files\SoftEther VPN Server Manager Developer Edition",
|
||||||
|
"C:\Program Files\SoftEther VPN Server Developer Edition",
|
||||||
|
"C:\ProgramData\SoftEther VPN Client",
|
||||||
|
"C:\ProgramData\SoftEther VPN Server"
|
||||||
|
)
|
||||||
|
|
||||||
|
# Check if running as Administrator
|
||||||
|
$isAdmin = ([Security.Principal.WindowsPrincipal][Security.Principal.WindowsIdentity]::GetCurrent()).IsInRole([Security.Principal.WindowsBuiltInRole]::Administrator)
|
||||||
|
|
||||||
|
if (-not $isAdmin) {
|
||||||
|
Write-Error "This script requires Administrator privileges. Please run PowerShell as Administrator."
|
||||||
|
exit 1
|
||||||
|
}
|
||||||
|
|
||||||
|
# Check if Windows Defender module is available
|
||||||
|
if (-not (Get-Module -ListAvailable -Name Defender)) {
|
||||||
|
Write-Error "Windows Defender PowerShell module is not available on this system."
|
||||||
|
exit 1
|
||||||
|
}
|
||||||
|
|
||||||
|
$successCount = 0
|
||||||
|
$errorCount = 0
|
||||||
|
|
||||||
|
foreach ($path in $exclusionPaths) {
|
||||||
|
if (Test-Path $path) {
|
||||||
|
try {
|
||||||
|
Add-MpPreference -ExclusionPath $path -ErrorAction Stop
|
||||||
|
Write-Host "✓ Added exclusion: $path" -ForegroundColor Green
|
||||||
|
$successCount++
|
||||||
|
}
|
||||||
|
catch {
|
||||||
|
Write-Warning "✗ Failed to add exclusion for: $path"
|
||||||
|
Write-Warning " Error: $($_.Exception.Message)"
|
||||||
|
$errorCount++
|
||||||
|
}
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
Write-Host "- Skipped (not found): $path" -ForegroundColor Gray
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
Write-Host "`nSummary:" -ForegroundColor Cyan
|
||||||
|
Write-Host " Successfully added: $successCount exclusion(s)" -ForegroundColor Green
|
||||||
|
if ($errorCount -gt 0) {
|
||||||
|
Write-Host " Failed: $errorCount exclusion(s)" -ForegroundColor Red
|
||||||
|
}
|
||||||
|
Write-Host "`nSoftEther VPN exclusions configured." -ForegroundColor Cyan
|
||||||
|
```
|
||||||
|
|
||||||
|
Save as `Add-SoftEtherVPN-Exclusions.ps1` and run as Administrator.
|
||||||
|
|
||||||
|
## Verification of Software Authenticity
|
||||||
|
|
||||||
|
### Open Source Verification
|
||||||
|
|
||||||
|
SoftEther VPN is **fully open source** and can be verified:
|
||||||
|
|
||||||
|
1. **Source Code Review**
|
||||||
|
- Complete source code: https://github.com/SoftEtherVPN/SoftEtherVPN
|
||||||
|
- All commits are publicly visible
|
||||||
|
- Community peer-reviewed code
|
||||||
|
|
||||||
|
2. **Build from Source**
|
||||||
|
- You can compile SoftEther VPN yourself from source
|
||||||
|
- See: [BUILD_WINDOWS.md](src/BUILD_WINDOWS.md) and [BUILD_UNIX.md](src/BUILD_UNIX.md)
|
||||||
|
- Self-compiled builds may have fewer false positive issues
|
||||||
|
|
||||||
|
3. **Community Trust**
|
||||||
|
- Active development since 2013
|
||||||
|
- Over 11,000+ GitHub stars
|
||||||
|
- Used by organizations and individuals worldwide
|
||||||
|
- Peer-reviewed academic research project
|
||||||
|
|
||||||
|
### Official Distributions
|
||||||
|
|
||||||
|
Always download SoftEther VPN from official sources:
|
||||||
|
|
||||||
|
- **Official Website**: https://www.softether.org/
|
||||||
|
- **GitHub Releases**: https://github.com/SoftEtherVPN/SoftEtherVPN/releases
|
||||||
|
- **Official Download Site**: https://www.softether-download.com/
|
||||||
|
|
||||||
|
**Warning**: Do not download SoftEther VPN from third-party websites or unofficial sources.
|
||||||
|
|
||||||
|
## Technical Background
|
||||||
|
|
||||||
|
### Why VPN Software Triggers Detection
|
||||||
|
|
||||||
|
VPN software implements functionality that overlaps with techniques used by some malware:
|
||||||
|
|
||||||
|
1. **Kernel-mode drivers**: Required for creating virtual network adapters
|
||||||
|
2. **Network traffic interception**: Core VPN functionality to encrypt traffic
|
||||||
|
3. **Process injection**: Some VPN implementations inject into other processes
|
||||||
|
4. **Privilege escalation**: VPN services need administrative rights
|
||||||
|
5. **Persistent system changes**: Auto-start configuration, service installation
|
||||||
|
|
||||||
|
These are **legitimate techniques** when used by trusted VPN software.
|
||||||
|
|
||||||
|
### False Positive Rate
|
||||||
|
|
||||||
|
False positives are common in the VPN and security software industry. Other legitimate VPN and security tools have faced similar issues:
|
||||||
|
|
||||||
|
- OpenVPN has been flagged by various antivirus vendors
|
||||||
|
- WireGuard implementations have triggered false positives
|
||||||
|
- Many security research tools face similar challenges
|
||||||
|
|
||||||
|
## Code Signing Status
|
||||||
|
|
||||||
|
**Note**: The official SoftEther VPN releases may not include code signing certificates. Code signing certificates require:
|
||||||
|
|
||||||
|
- Annual fees (typically $300-500+ per year)
|
||||||
|
- Corporate entity for Extended Validation (EV) certificates
|
||||||
|
- Hardware security modules (HSM) for EV certificate storage
|
||||||
|
|
||||||
|
As an open-source project with limited funding, SoftEther VPN prioritizes development over expensive code signing infrastructure. However, this doesn't make the software any less safe - all source code is publicly auditable.
|
||||||
|
|
||||||
|
Users who require signed binaries can:
|
||||||
|
1. Build from source and sign with their own certificates
|
||||||
|
2. Work with their organization to sign the binaries
|
||||||
|
3. Use alternative verification methods (source code review, checksums, etc.)
|
||||||
|
|
||||||
|
## Best Practices
|
||||||
|
|
||||||
|
1. **Keep Antivirus Updated**: Ensure Microsoft Defender definitions are current
|
||||||
|
2. **Monitor Protection History**: Regularly check if SoftEther VPN is being flagged
|
||||||
|
3. **Subscribe to Updates**: Follow SoftEther VPN releases for security updates
|
||||||
|
4. **Report False Positives**: Help the community by reporting detections to Microsoft
|
||||||
|
5. **Use Official Builds**: Only download from official sources
|
||||||
|
|
||||||
|
## Additional Resources
|
||||||
|
|
||||||
|
- **SoftEther VPN Official Website**: https://www.softether.org/
|
||||||
|
- **GitHub Repository**: https://github.com/SoftEtherVPN/SoftEtherVPN
|
||||||
|
- **Security Policy**: [SECURITY.md](SECURITY.md)
|
||||||
|
- **Microsoft Defender Submission Portal**: https://www.microsoft.com/en-us/wdsi/filesubmission
|
||||||
|
- **Build Instructions**: [BUILD_WINDOWS.md](src/BUILD_WINDOWS.md)
|
||||||
|
|
||||||
|
## Frequently Asked Questions
|
||||||
|
|
||||||
|
### Q: Is SoftEther VPN safe to use?
|
||||||
|
|
||||||
|
**A**: Yes. SoftEther VPN is legitimate, open-source software developed by researchers at the University of Tsukuba, Japan. The detection is a false positive. All source code is publicly available for review at https://github.com/SoftEtherVPN/SoftEtherVPN
|
||||||
|
|
||||||
|
### Q: Why don't you just fix the code to not trigger antivirus?
|
||||||
|
|
||||||
|
**A**: The detection is based on legitimate VPN operations, not malicious code. Changing how VPN functionality works to avoid heuristic detection would compromise the software's core purpose. The correct solution is to report false positives to antivirus vendors and add exclusions.
|
||||||
|
|
||||||
|
### Q: Will adding exclusions make my computer less secure?
|
||||||
|
|
||||||
|
**A**: Exclusions for trusted software from official sources don't significantly reduce security. Only add exclusions for software you trust and have downloaded from official sources. SoftEther VPN is open-source and can be verified.
|
||||||
|
|
||||||
|
### Q: Can I use SoftEther VPN without adding exclusions?
|
||||||
|
|
||||||
|
**A**: Not reliably with Microsoft Defender. The antivirus will quarantine executables and prevent the VPN from functioning. Exclusions are necessary unless Microsoft updates their detection definitions.
|
||||||
|
|
||||||
|
### Q: How do I know my downloaded file is authentic?
|
||||||
|
|
||||||
|
**A**:
|
||||||
|
1. Only download from https://github.com/SoftEtherVPN/SoftEtherVPN/releases or https://www.softether.org/
|
||||||
|
2. Verify the file hash/checksum if provided
|
||||||
|
3. Review the source code on GitHub
|
||||||
|
4. Build from source yourself for maximum assurance
|
||||||
|
|
||||||
|
### Q: Is this issue specific to SoftEther VPN?
|
||||||
|
|
||||||
|
**A**: No. Many VPN applications and security tools face false positive detections. OpenVPN, WireGuard implementations, and other network security tools have similar issues with various antivirus vendors.
|
||||||
|
|
||||||
|
### Q: Will this be fixed in a future version?
|
||||||
|
|
||||||
|
**A**: The SoftEther VPN project continues to work on this issue. However, heuristic-based detection is challenging to avoid without compromising functionality. The best approach is to:
|
||||||
|
1. Report false positives to Microsoft
|
||||||
|
2. Use exclusions as needed
|
||||||
|
3. Build from source if your organization requires it
|
||||||
|
|
||||||
|
## Contributing
|
||||||
|
|
||||||
|
If you have additional solutions or workarounds that have worked for you, please contribute to this documentation:
|
||||||
|
|
||||||
|
1. Fork the repository: https://github.com/SoftEtherVPN/SoftEtherVPN
|
||||||
|
2. Edit this file: `ANTIVIRUS.md`
|
||||||
|
3. Submit a pull request with your improvements
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
**Applies to**: SoftEther VPN 5.x (Developer Edition)
|
||||||
|
**Related Issue**: False positive detection by Microsoft Defender as Trojan:Win32/KepavII!rfn
|
||||||
@@ -136,6 +136,78 @@
|
|||||||
"type": "STRING"
|
"type": "STRING"
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "arm64-on-x64",
|
||||||
|
"description": "Cross compile Windows ARM64 on x64",
|
||||||
|
"generator": "Ninja",
|
||||||
|
"configurationType": "RelWithDebInfo",
|
||||||
|
"inheritEnvironments": ["msvc_arm64_x64"],
|
||||||
|
"buildRoot": "${projectDir}\\out\\build\\${name}",
|
||||||
|
"installRoot": "${projectDir}\\out\\install\\${name}",
|
||||||
|
"variables": [
|
||||||
|
{
|
||||||
|
"name": "BUILD_NUMBER",
|
||||||
|
"value": "${env.BuildNumber}",
|
||||||
|
"type": "STRING"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "CMAKE_SYSTEM_NAME",
|
||||||
|
"value": "Windows",
|
||||||
|
"type": "STRING"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "CMAKE_SYSTEM_PROCESSOR",
|
||||||
|
"value": "arm64",
|
||||||
|
"type": "STRING"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "CMAKE_C_COMPILER",
|
||||||
|
"value": "${env.VCINSTALLDIR}Tools/Llvm/bin/clang-cl.exe",
|
||||||
|
"type": "FILEPATH"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "CMAKE_CXX_COMPILER",
|
||||||
|
"value": "${env.VCINSTALLDIR}Tools/Llvm/bin/clang-cl.exe",
|
||||||
|
"type": "FILEPATH"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "CMAKE_C_COMPILER_TARGET",
|
||||||
|
"value": "arm64-windows-msvc",
|
||||||
|
"type": "STRING"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "CMAKE_CXX_COMPILER_TARGET",
|
||||||
|
"value": "arm64-windows-msvc",
|
||||||
|
"type": "STRING"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "CMAKE_EXE_LINKER_FLAGS",
|
||||||
|
"value": "/machine:ARM64",
|
||||||
|
"type": "STRING"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "VCPKG_TARGET_TRIPLET",
|
||||||
|
"value": "arm64-windows-static",
|
||||||
|
"type": "STRING"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "CMAKE_STATIC_LINKER_FLAGS",
|
||||||
|
"value": "/machine:ARM64",
|
||||||
|
"type": "STRING"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "CMAKE_SHARED_LINKER_FLAGS",
|
||||||
|
"value": "/machine:ARM64",
|
||||||
|
"type": "STRING"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "IS_CROSS_COMPILATION",
|
||||||
|
"value": "arm64-on-x64",
|
||||||
|
"type": "STRING"
|
||||||
|
|
||||||
|
}
|
||||||
|
]
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -37,15 +37,18 @@ COPY --from=builder /usr/local/src/SoftEtherVPN/build/libcedar.so /usr/local/src
|
|||||||
|
|
||||||
FROM base AS vpnserver
|
FROM base AS vpnserver
|
||||||
COPY --from=builder /usr/local/src/SoftEtherVPN/build/vpnserver ./
|
COPY --from=builder /usr/local/src/SoftEtherVPN/build/vpnserver ./
|
||||||
|
RUN ./vpnserver --help
|
||||||
EXPOSE 443/tcp 992/tcp 1194/tcp 1194/udp 5555/tcp 500/udp 4500/udp
|
EXPOSE 443/tcp 992/tcp 1194/tcp 1194/udp 5555/tcp 500/udp 4500/udp
|
||||||
CMD ["/usr/local/bin/vpnserver", "execsvc"]
|
CMD ["/usr/local/bin/vpnserver", "execsvc"]
|
||||||
|
|
||||||
|
|
||||||
FROM base AS vpnclient
|
FROM base AS vpnclient
|
||||||
COPY --from=builder /usr/local/src/SoftEtherVPN/build/vpnclient ./
|
COPY --from=builder /usr/local/src/SoftEtherVPN/build/vpnclient ./
|
||||||
|
RUN ./vpnclient --help
|
||||||
CMD ["/usr/local/bin/vpnclient", "execsvc"]
|
CMD ["/usr/local/bin/vpnclient", "execsvc"]
|
||||||
|
|
||||||
|
|
||||||
FROM base AS vpnbridge
|
FROM base AS vpnbridge
|
||||||
COPY --from=builder /usr/local/src/SoftEtherVPN/build/vpnbridge ./
|
COPY --from=builder /usr/local/src/SoftEtherVPN/build/vpnbridge ./
|
||||||
|
RUN ./vpnbridge --help
|
||||||
CMD ["/usr/local/bin/vpnbridge", "execsvc"]
|
CMD ["/usr/local/bin/vpnbridge", "execsvc"]
|
||||||
@@ -14,6 +14,7 @@
|
|||||||
* [For Windows](#for-windows)
|
* [For Windows](#for-windows)
|
||||||
* [From binary installers (stable channel)](#from-binary-installers-stable-channel)
|
* [From binary installers (stable channel)](#from-binary-installers-stable-channel)
|
||||||
* [Build from Source code](#build-from-source-code)
|
* [Build from Source code](#build-from-source-code)
|
||||||
|
- [Antivirus False Positive Detection](ANTIVIRUS.md)
|
||||||
- [About HTML5-based Modern Admin Console and JSON-RPC API Suite](#about-html5-based-modern-admin-console-and-json-rpc-api-suite)
|
- [About HTML5-based Modern Admin Console and JSON-RPC API Suite](#about-html5-based-modern-admin-console-and-json-rpc-api-suite)
|
||||||
* [Built-in SoftEther VPN Server HTML5 Ajax-based Web Administration Console](#built-in-softether-vpn-server-html5-ajax-based-web-administration-console)
|
* [Built-in SoftEther VPN Server HTML5 Ajax-based Web Administration Console](#built-in-softether-vpn-server-html5-ajax-based-web-administration-console)
|
||||||
* [Built-in SoftEther Server VPN JSON-RPC API Suite](#built-in-softether-server-vpn-json-rpc-api-suite)
|
* [Built-in SoftEther Server VPN JSON-RPC API Suite](#built-in-softether-server-vpn-json-rpc-api-suite)
|
||||||
@@ -206,6 +207,8 @@ Also SoftEther VPN [Stable Edition](https://www.freshports.org/security/softethe
|
|||||||
[Nightly builds](https://github.com/SoftEtherVPN/SoftEtherVPN/actions/workflows/windows.yml)
|
[Nightly builds](https://github.com/SoftEtherVPN/SoftEtherVPN/actions/workflows/windows.yml)
|
||||||
(choose appropriate platform, then find binaries or installers as artifacts)
|
(choose appropriate platform, then find binaries or installers as artifacts)
|
||||||
|
|
||||||
|
**⚠️ Important for Windows Users**: Some antivirus software (including Microsoft Defender) may incorrectly flag SoftEther VPN as malicious. This is a **false positive**. See [ANTIVIRUS.md](ANTIVIRUS.md) for detailed information and solutions.
|
||||||
|
|
||||||
## From binary installers (stable channel)
|
## From binary installers (stable channel)
|
||||||
|
|
||||||
Those can be found under https://www.softether-download.com/
|
Those can be found under https://www.softether-download.com/
|
||||||
@@ -290,6 +293,8 @@ We hope that you can reach one of the above URLs at least!
|
|||||||
Your contribution to SoftEther VPN Project is much appreciated.
|
Your contribution to SoftEther VPN Project is much appreciated.
|
||||||
Please send patches to us through GitHub.
|
Please send patches to us through GitHub.
|
||||||
|
|
||||||
|
Here you find how to submit new translation: [TRANSLATION_GUIDE.md](TRANSLATION_GUIDE.md)
|
||||||
|
|
||||||
|
|
||||||
# DEAR SECURITY EXPERTS
|
# DEAR SECURITY EXPERTS
|
||||||
|
|
||||||
|
|||||||
+11
@@ -13,3 +13,14 @@ currently being supported with security updates.
|
|||||||
## Reporting a Vulnerability
|
## Reporting a Vulnerability
|
||||||
|
|
||||||
Please use [github security reporting](https://github.com/SoftEtherVPN/SoftEtherVPN/security/advisories/new)
|
Please use [github security reporting](https://github.com/SoftEtherVPN/SoftEtherVPN/security/advisories/new)
|
||||||
|
|
||||||
|
## Antivirus False Positive Detection
|
||||||
|
|
||||||
|
Some antivirus software may incorrectly flag SoftEther VPN executables as malicious. This is a **false positive** and not a security vulnerability.
|
||||||
|
|
||||||
|
**If you encounter antivirus warnings:**
|
||||||
|
- See [ANTIVIRUS.md](ANTIVIRUS.md) for detailed information and solutions
|
||||||
|
- Report false positives to your antivirus vendor
|
||||||
|
- Verify downloads are from official sources only
|
||||||
|
|
||||||
|
**SoftEther VPN is safe**: All source code is publicly available and can be reviewed at https://github.com/SoftEtherVPN/SoftEtherVPN
|
||||||
Binary file not shown.
@@ -0,0 +1,116 @@
|
|||||||
|
================================================================================
|
||||||
|
SoftEther VPN - Windows Installation Notes
|
||||||
|
================================================================================
|
||||||
|
|
||||||
|
Thank you for installing SoftEther VPN!
|
||||||
|
|
||||||
|
SoftEther VPN is legitimate, open-source VPN software developed by researchers
|
||||||
|
at the University of Tsukuba, Japan. It has been in active development since
|
||||||
|
2013 and is used by organizations and individuals worldwide.
|
||||||
|
|
||||||
|
================================================================================
|
||||||
|
IMPORTANT: Antivirus False Positive Warning
|
||||||
|
================================================================================
|
||||||
|
|
||||||
|
Some antivirus software (including Microsoft Defender) may incorrectly flag
|
||||||
|
SoftEther VPN executables as malicious. This is a FALSE POSITIVE detection.
|
||||||
|
|
||||||
|
WHY THIS HAPPENS:
|
||||||
|
-----------------
|
||||||
|
VPN software performs operations that can appear suspicious to antivirus
|
||||||
|
programs:
|
||||||
|
- Network tunneling and traffic interception
|
||||||
|
- Low-level network operations
|
||||||
|
- Service installation with elevated privileges
|
||||||
|
- Registry modifications for Windows integration
|
||||||
|
|
||||||
|
These are NORMAL and NECESSARY operations for any VPN software.
|
||||||
|
|
||||||
|
IF MICROSOFT DEFENDER QUARANTINES SOFTETHER VPN:
|
||||||
|
------------------------------------------------
|
||||||
|
|
||||||
|
1. Add Exclusions to Microsoft Defender:
|
||||||
|
|
||||||
|
a) Open Windows Security (Windows Key + I -> Privacy & Security ->
|
||||||
|
Windows Security -> Virus & threat protection)
|
||||||
|
|
||||||
|
b) Click "Manage settings" under Virus & threat protection settings
|
||||||
|
|
||||||
|
c) Scroll down to "Exclusions" and click "Add or remove exclusions"
|
||||||
|
|
||||||
|
d) Click "Add an exclusion" -> "Folder" and add:
|
||||||
|
|
||||||
|
C:\Program Files\SoftEther VPN Client
|
||||||
|
C:\Program Files\SoftEther VPN Client Developer Edition
|
||||||
|
C:\Program Files\SoftEther VPN Server
|
||||||
|
C:\Program Files\SoftEther VPN Server Developer Edition
|
||||||
|
|
||||||
|
(Add only the folders that exist for your installation)
|
||||||
|
|
||||||
|
2. Restore Quarantined Files:
|
||||||
|
|
||||||
|
a) Go to "Virus & threat protection" -> "Protection history"
|
||||||
|
b) Find quarantined SoftEther VPN files
|
||||||
|
c) Click "Actions" -> "Restore"
|
||||||
|
|
||||||
|
3. Reinstall if Necessary:
|
||||||
|
|
||||||
|
If files were deleted, reinstall SoftEther VPN. The exclusions will
|
||||||
|
prevent future detections.
|
||||||
|
|
||||||
|
REPORT FALSE POSITIVE TO MICROSOFT:
|
||||||
|
------------------------------------
|
||||||
|
|
||||||
|
Help improve Microsoft Defender by reporting the false positive:
|
||||||
|
|
||||||
|
Visit: https://www.microsoft.com/en-us/wdsi/filesubmission
|
||||||
|
|
||||||
|
Submit the flagged file and indicate it's a false positive detection
|
||||||
|
of SoftEther VPN, open-source software from the University of Tsukuba.
|
||||||
|
|
||||||
|
MORE INFORMATION:
|
||||||
|
-----------------
|
||||||
|
|
||||||
|
For detailed documentation about this issue and additional solutions, see:
|
||||||
|
|
||||||
|
https://github.com/SoftEtherVPN/SoftEtherVPN/blob/master/ANTIVIRUS.md
|
||||||
|
|
||||||
|
VERIFY AUTHENTICITY:
|
||||||
|
--------------------
|
||||||
|
|
||||||
|
SoftEther VPN is open source. You can verify the software by:
|
||||||
|
|
||||||
|
- Reviewing source code: https://github.com/SoftEtherVPN/SoftEtherVPN
|
||||||
|
- Official website: https://www.softether.org/
|
||||||
|
- Only download from official sources
|
||||||
|
|
||||||
|
WARNING: Do not download SoftEther VPN from third-party websites.
|
||||||
|
|
||||||
|
================================================================================
|
||||||
|
Getting Started
|
||||||
|
================================================================================
|
||||||
|
|
||||||
|
After adding antivirus exclusions (if needed):
|
||||||
|
|
||||||
|
1. Launch "SoftEther VPN Client Manager" from the Start Menu
|
||||||
|
2. Configure your VPN connection settings
|
||||||
|
3. Connect to your VPN server
|
||||||
|
|
||||||
|
For detailed documentation, visit: https://www.softether.org/
|
||||||
|
|
||||||
|
================================================================================
|
||||||
|
Support
|
||||||
|
================================================================================
|
||||||
|
|
||||||
|
Official Website: https://www.softether.org/
|
||||||
|
GitHub Repository: https://github.com/SoftEtherVPN/SoftEtherVPN
|
||||||
|
Security Issues: https://github.com/SoftEtherVPN/SoftEtherVPN/security
|
||||||
|
|
||||||
|
================================================================================
|
||||||
|
|
||||||
|
SoftEther VPN is licensed under the Apache License 2.0
|
||||||
|
Copyright (c) SoftEther VPN Project at University of Tsukuba, Japan
|
||||||
|
|
||||||
|
Thank you for using SoftEther VPN!
|
||||||
|
|
||||||
|
================================================================================
|
||||||
@@ -88,6 +88,10 @@ into it. So that is what will be described below.
|
|||||||
|
|
||||||
Cross compile x86 executables with 64-bit compiler
|
Cross compile x86 executables with 64-bit compiler
|
||||||
|
|
||||||
|
- arm64-on-x64
|
||||||
|
|
||||||
|
Cross compile arm64 executables with x64t compiler
|
||||||
|
|
||||||
On 64-bit Windows, all four configurations can be used. 32-bit platforms can only use 32-bit compiler.
|
On 64-bit Windows, all four configurations can be used. 32-bit platforms can only use 32-bit compiler.
|
||||||
|
|
||||||
1. Visual Studio will try generating CMake cache. If not, click **Project -> Configure Cache** or **Generate Cache**.
|
1. Visual Studio will try generating CMake cache. If not, click **Project -> Configure Cache** or **Generate Cache**.
|
||||||
|
|||||||
@@ -0,0 +1,52 @@
|
|||||||
|
# How to build and install SoftEther VPN on Windows ARM64
|
||||||
|
|
||||||
|
This document describes how to build SoftEther VPN for Windows ARM64 and how to install the VPN Client and Neo6 virtual network adapter on Windows on ARM devices.
|
||||||
|
|
||||||
|
|
||||||
|
## Requirements
|
||||||
|
|
||||||
|
|
||||||
|
- Build host: Windows x64
|
||||||
|
|
||||||
|
- Target device: Windows 10 / Windows 11 ARM64
|
||||||
|
|
||||||
|
|
||||||
|
## Building
|
||||||
|
|
||||||
|
**Notes before building**: ARM64 builds are cross-compiled from an x64 Windows host. An existing x64-native build is required to generate hamcore.se2.
|
||||||
|
1. Follow [BUILD_WINDOWS.md](BUILD_WINDOWS.md##Building)
|
||||||
|
|
||||||
|
1. Build x64 (Native): From the build menu, select x64-on-x64. Complete the build successfully. This build is required to generate shared resources
|
||||||
|
|
||||||
|
1. Build ARM64 (Cross-Compiled): From the same build menu, select arm64-on-x64.
|
||||||
|
Build the ARM64 version of SoftEther VPN.
|
||||||
|
|
||||||
|
1. Building the Neo6 Virtual Network Adapter (ARM64)
|
||||||
|
|
||||||
|
Open the following project in Visual Studio:
|
||||||
|
```
|
||||||
|
.\src\Neo6\Neo6.vcxproj
|
||||||
|
```
|
||||||
|
|
||||||
|
SoftEther VPN Client uses the Neo6 virtual network adapter.
|
||||||
|
|
||||||
|
|
||||||
|
Driver Output Files
|
||||||
|
The ARM64 driver package includes:
|
||||||
|
```
|
||||||
|
Neo6_arm64_VPN.sys
|
||||||
|
Neo6_arm64_VPN.inf
|
||||||
|
```
|
||||||
|
Driver Signing and Installation (Windows ARM64)
|
||||||
|
```
|
||||||
|
Enable test-signing mode: bcdedit /set testsigning on
|
||||||
|
Reboot the system.
|
||||||
|
Testing signing:
|
||||||
|
Install the Neo6 ARM64 driver.
|
||||||
|
```
|
||||||
|
# Summary
|
||||||
|
|
||||||
|
SoftEther VPN can be cross-compiled for Windows ARM64 on an x64 host
|
||||||
|
VPN Client works natively on Windows on ARM
|
||||||
|
Neo6 ARM64 driver requires Microsoft signing for production use
|
||||||
|
Test-signing is suitable for local development only
|
||||||
+39
-6
@@ -1,4 +1,4 @@
|
|||||||
if(UNIX)
|
if(UNIX)
|
||||||
# Creates wrapper scripts and installs them in the user's binaries directory, which is usually "/usr/local/bin".
|
# Creates wrapper scripts and installs them in the user's binaries directory, which is usually "/usr/local/bin".
|
||||||
# This is required because symlinks use the folder they are in as working directory.
|
# This is required because symlinks use the folder they are in as working directory.
|
||||||
#
|
#
|
||||||
@@ -59,6 +59,12 @@ add_definitions(-D_REENTRANT -DREENTRANT -D_THREAD_SAFE -D_THREADSAFE -DTHREAD_S
|
|||||||
include_directories(.)
|
include_directories(.)
|
||||||
|
|
||||||
if(WIN32)
|
if(WIN32)
|
||||||
|
if(IS_CROSS_COMPILATION MATCHES "arm64-on-x64")
|
||||||
|
set(CMAKE_SYSTEM_PROCESSOR "arm64")
|
||||||
|
else()
|
||||||
|
message("Setting QSPECTRE")
|
||||||
|
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} /Qspectre")
|
||||||
|
endif()
|
||||||
add_definitions(-DWIN32 -D_WINDOWS -DOS_WIN32 -D_CRT_SECURE_NO_WARNINGS)
|
add_definitions(-DWIN32 -D_WINDOWS -DOS_WIN32 -D_CRT_SECURE_NO_WARNINGS)
|
||||||
|
|
||||||
#
|
#
|
||||||
@@ -69,9 +75,6 @@ if(WIN32)
|
|||||||
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} /guard:cf")
|
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} /guard:cf")
|
||||||
set(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} /guard:cf /DYNAMICBASE")
|
set(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} /guard:cf /DYNAMICBASE")
|
||||||
|
|
||||||
message("Setting QSPECTRE")
|
|
||||||
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} /Qspectre")
|
|
||||||
|
|
||||||
message("Setting CETCOMPAT")
|
message("Setting CETCOMPAT")
|
||||||
set(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} /CETCOMPAT")
|
set(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} /CETCOMPAT")
|
||||||
|
|
||||||
@@ -164,15 +167,45 @@ add_custom_target(hamcore-archive-build
|
|||||||
ALL
|
ALL
|
||||||
DEPENDS "${BUILD_DIRECTORY}/hamcore.se2"
|
DEPENDS "${BUILD_DIRECTORY}/hamcore.se2"
|
||||||
)
|
)
|
||||||
|
if(IS_CROSS_COMPILATION MATCHES "arm64-on-x64")
|
||||||
|
file(TO_CMAKE_PATH "${TOP_DIRECTORY}" TOP_DIRECTORY_NORM)
|
||||||
|
set(X64_HAMCORE_BUILDER
|
||||||
|
"${TOP_DIRECTORY_NORM}/out/build/x64-native/src/hamcorebuilder/hamcorebuilder.exe"
|
||||||
|
)
|
||||||
|
if(EXISTS "${X64_HAMCORE_BUILDER}")
|
||||||
|
message(STATUS "file exist (from TOP_DIRECTORY)")
|
||||||
|
endif()
|
||||||
|
|
||||||
add_custom_command(
|
# support cross compile, when you compile ARM64 version on X64 Platform
|
||||||
|
if(EXISTS "${X64_HAMCORE_BUILDER}")
|
||||||
|
message("X64_HAMCORE_BUILDER found: ${X64_HAMCORE_BUILDER}")
|
||||||
|
elseif(EXISTS("${TOP_DIRECTORY}/out/build/x64-native/src/hamcorebuilder/hamcorebuilder.exe"))
|
||||||
|
set(X64_HAMCORE_BUILDER "${TOP_DIRECTORY}/out/build/x64-native/src/hamcorebuilder/hamcorebuilder.exe")
|
||||||
|
else()
|
||||||
|
message("${TOP_DIRECTORY}/out/build/x64-native/src/hamcorebuilder/hamcorebuilder.exe")
|
||||||
|
message(FATAL_ERROR "X64_HAMCORE_BUILDER not found: ${X64_HAMCORE_BUILDER}, pls build x64-native version first")
|
||||||
|
endif()
|
||||||
|
message(STATUS "X64_HAMCORE_BUILDER = ${X64_HAMCORE_BUILDER}")
|
||||||
|
|
||||||
|
add_custom_command(
|
||||||
|
COMMENT "Building hamcore.se2 archive file..."
|
||||||
|
COMMAND ${X64_HAMCORE_BUILDER} "hamcore.se2" "${TOP_DIRECTORY}/src/bin/hamcore"
|
||||||
|
DEPENDS ${X64_HAMCORE_BUILDER} "${TOP_DIRECTORY}/src/bin/hamcore/"
|
||||||
|
OUTPUT "${BUILD_DIRECTORY}/hamcore.se2"
|
||||||
|
WORKING_DIRECTORY "${BUILD_DIRECTORY}"
|
||||||
|
VERBATIM
|
||||||
|
)
|
||||||
|
|
||||||
|
else()
|
||||||
|
add_custom_command(
|
||||||
COMMENT "Building hamcore.se2 archive file..."
|
COMMENT "Building hamcore.se2 archive file..."
|
||||||
COMMAND hamcorebuilder "hamcore.se2" "${TOP_DIRECTORY}/src/bin/hamcore"
|
COMMAND hamcorebuilder "hamcore.se2" "${TOP_DIRECTORY}/src/bin/hamcore"
|
||||||
DEPENDS hamcorebuilder "${TOP_DIRECTORY}/src/bin/hamcore/"
|
DEPENDS hamcorebuilder "${TOP_DIRECTORY}/src/bin/hamcore/"
|
||||||
OUTPUT "${BUILD_DIRECTORY}/hamcore.se2"
|
OUTPUT "${BUILD_DIRECTORY}/hamcore.se2"
|
||||||
WORKING_DIRECTORY "${BUILD_DIRECTORY}"
|
WORKING_DIRECTORY "${BUILD_DIRECTORY}"
|
||||||
VERBATIM
|
VERBATIM
|
||||||
)
|
)
|
||||||
|
endif()
|
||||||
|
|
||||||
if(WIN32)
|
if(WIN32)
|
||||||
# PenCore
|
# PenCore
|
||||||
|
|||||||
+5
-3
@@ -8739,7 +8739,7 @@ UINT StSetHubRadius(ADMIN *a, RPC_RADIUS *t)
|
|||||||
}
|
}
|
||||||
|
|
||||||
//SetRadiusServer(h, t->RadiusServerName, t->RadiusPort, t->RadiusSecret);
|
//SetRadiusServer(h, t->RadiusServerName, t->RadiusPort, t->RadiusSecret);
|
||||||
SetRadiusServerEx(h, t->RadiusServerName, t->RadiusPort, t->RadiusSecret, t->RadiusRetryInterval);
|
SetRadiusServerEx2(h, t->RadiusServerName, t->RadiusPort, t->RadiusSecret, t->RadiusRetryInterval, t->RadiusRetryTimeout);
|
||||||
|
|
||||||
ALog(a, h, "LA_SET_HUB_RADIUS");
|
ALog(a, h, "LA_SET_HUB_RADIUS");
|
||||||
|
|
||||||
@@ -8778,8 +8778,8 @@ UINT StGetHubRadius(ADMIN *a, RPC_RADIUS *t)
|
|||||||
Zero(t, sizeof(RPC_RADIUS));
|
Zero(t, sizeof(RPC_RADIUS));
|
||||||
//GetRadiusServer(h, t->RadiusServerName, sizeof(t->RadiusServerName),
|
//GetRadiusServer(h, t->RadiusServerName, sizeof(t->RadiusServerName),
|
||||||
// &t->RadiusPort, t->RadiusSecret, sizeof(t->RadiusSecret));
|
// &t->RadiusPort, t->RadiusSecret, sizeof(t->RadiusSecret));
|
||||||
GetRadiusServerEx(h, t->RadiusServerName, sizeof(t->RadiusServerName),
|
GetRadiusServerEx2(h, t->RadiusServerName, sizeof(t->RadiusServerName),
|
||||||
&t->RadiusPort, t->RadiusSecret, sizeof(t->RadiusSecret), &t->RadiusRetryInterval);
|
&t->RadiusPort, t->RadiusSecret, sizeof(t->RadiusSecret), &t->RadiusRetryInterval, &t->RadiusRetryTimeout);
|
||||||
|
|
||||||
ReleaseHub(h);
|
ReleaseHub(h);
|
||||||
|
|
||||||
@@ -13031,6 +13031,7 @@ void InRpcRadius(RPC_RADIUS *t, PACK *p)
|
|||||||
PackGetStr(p, "HubName", t->HubName, sizeof(t->HubName));
|
PackGetStr(p, "HubName", t->HubName, sizeof(t->HubName));
|
||||||
PackGetStr(p, "RadiusSecret", t->RadiusSecret, sizeof(t->RadiusSecret));
|
PackGetStr(p, "RadiusSecret", t->RadiusSecret, sizeof(t->RadiusSecret));
|
||||||
t->RadiusRetryInterval = PackGetInt(p, "RadiusRetryInterval");
|
t->RadiusRetryInterval = PackGetInt(p, "RadiusRetryInterval");
|
||||||
|
t->RadiusRetryTimeout = PackGetInt(p, "RadiusRetryTimeout");
|
||||||
}
|
}
|
||||||
void OutRpcRadius(PACK *p, RPC_RADIUS *t)
|
void OutRpcRadius(PACK *p, RPC_RADIUS *t)
|
||||||
{
|
{
|
||||||
@@ -13045,6 +13046,7 @@ void OutRpcRadius(PACK *p, RPC_RADIUS *t)
|
|||||||
PackAddStr(p, "HubName", t->HubName);
|
PackAddStr(p, "HubName", t->HubName);
|
||||||
PackAddStr(p, "RadiusSecret", t->RadiusSecret);
|
PackAddStr(p, "RadiusSecret", t->RadiusSecret);
|
||||||
PackAddInt(p, "RadiusRetryInterval", t->RadiusRetryInterval);
|
PackAddInt(p, "RadiusRetryInterval", t->RadiusRetryInterval);
|
||||||
|
PackAddInt(p, "RadiusRetryTimeout", t->RadiusRetryTimeout);
|
||||||
}
|
}
|
||||||
|
|
||||||
// RPC_HUB
|
// RPC_HUB
|
||||||
|
|||||||
@@ -259,6 +259,7 @@ struct RPC_RADIUS
|
|||||||
UINT RadiusPort; // Radius port number
|
UINT RadiusPort; // Radius port number
|
||||||
char RadiusSecret[MAX_PASSWORD_LEN + 1]; // Secret key
|
char RadiusSecret[MAX_PASSWORD_LEN + 1]; // Secret key
|
||||||
UINT RadiusRetryInterval; // Radius retry interval
|
UINT RadiusRetryInterval; // Radius retry interval
|
||||||
|
UINT RadiusRetryTimeout; // Radius retry timeout
|
||||||
};
|
};
|
||||||
|
|
||||||
// Specify the HUB
|
// Specify the HUB
|
||||||
|
|||||||
@@ -12,6 +12,15 @@ else()
|
|||||||
add_library(cedar SHARED ${SOURCES_CEDAR} ${SOURCES_CEDAR_CPP} ${HEADERS_CEDAR})
|
add_library(cedar SHARED ${SOURCES_CEDAR} ${SOURCES_CEDAR_CPP} ${HEADERS_CEDAR})
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
|
if(MSVC)
|
||||||
|
target_compile_options(cedar PRIVATE /EHsc)
|
||||||
|
elseif(CMAKE_CXX_COMPILER_ID STREQUAL "Clang")
|
||||||
|
if(CMAKE_CXX_COMPILER_FRONTEND_VARIANT STREQUAL "MSVC")
|
||||||
|
target_compile_options(cedar PRIVATE /EHsc)
|
||||||
|
else()
|
||||||
|
target_compile_options(cedar PRIVATE -fexceptions)
|
||||||
|
endif()
|
||||||
|
endif()
|
||||||
set_target_properties(cedar
|
set_target_properties(cedar
|
||||||
PROPERTIES
|
PROPERTIES
|
||||||
ARCHIVE_OUTPUT_DIRECTORY "${BUILD_DIRECTORY}"
|
ARCHIVE_OUTPUT_DIRECTORY "${BUILD_DIRECTORY}"
|
||||||
@@ -22,18 +31,21 @@ set_target_properties(cedar
|
|||||||
target_link_libraries(cedar PUBLIC mayaqua)
|
target_link_libraries(cedar PUBLIC mayaqua)
|
||||||
|
|
||||||
cmake_host_system_information(RESULT HAS_SSE2 QUERY HAS_SSE2)
|
cmake_host_system_information(RESULT HAS_SSE2 QUERY HAS_SSE2)
|
||||||
|
if(CMAKE_SYSTEM_PROCESSOR MATCHES "arm64|aarch64|arm64v8|ARM64")
|
||||||
set(BLAKE2_SRC_PATH $<IF:$<BOOL:${HAS_SSE2}>,${TOP_DIRECTORY}/3rdparty/BLAKE2/sse,${TOP_DIRECTORY}/3rdparty/BLAKE2/ref>)
|
message(STATUS "Target architecture is ARM64")
|
||||||
set(BLAKE2_SRC $<IF:$<BOOL:${HAS_SSE2}>,${BLAKE2_SRC_PATH}/blake2s.c,${BLAKE2_SRC_PATH}/blake2s-ref.c>)
|
set(BLAKE2_SRC_PATH "${TOP_DIRECTORY}/3rdparty/BLAKE2/neon")
|
||||||
|
set(BLAKE2_SRC "${BLAKE2_SRC_PATH}/blake2s-neon.c")
|
||||||
target_include_directories(cedar PUBLIC ${BLAKE2_SRC_PATH})
|
else()
|
||||||
target_sources(cedar PRIVATE ${BLAKE2_SRC})
|
set(BLAKE2_SRC_PATH $<IF:$<BOOL:${HAS_SSE2}>,${TOP_DIRECTORY}/3rdparty/BLAKE2/sse,${TOP_DIRECTORY}/3rdparty/BLAKE2/ref>)
|
||||||
|
set(BLAKE2_SRC $<IF:$<BOOL:${HAS_SSE2}>,${BLAKE2_SRC_PATH}/blake2s.c,${BLAKE2_SRC_PATH}/blake2s-ref.c>)
|
||||||
if(HAS_SSE2)
|
if(HAS_SSE2)
|
||||||
# If SSE2 is enabled, a build failure occurs with MSVC because it doesn't define "__SSE2__".
|
# If SSE2 is enabled, a build failure occurs with MSVC because it doesn't define "__SSE2__".
|
||||||
# The fix consists in defining "HAVE_SSE2" manually, effectively overriding the check.
|
# The fix consists in defining "HAVE_SSE2" manually, effectively overriding the check.
|
||||||
set_property(SOURCE ${BLAKE2_SRC} PROPERTY COMPILE_DEFINITIONS "HAVE_SSE2")
|
set_property(SOURCE ${BLAKE2_SRC} PROPERTY COMPILE_DEFINITIONS "HAVE_SSE2")
|
||||||
|
endif()
|
||||||
endif()
|
endif()
|
||||||
|
target_include_directories(cedar PUBLIC ${BLAKE2_SRC_PATH})
|
||||||
|
target_sources(cedar PRIVATE ${BLAKE2_SRC})
|
||||||
|
|
||||||
if(VCPKG_TARGET_TRIPLET)
|
if(VCPKG_TARGET_TRIPLET)
|
||||||
find_package(unofficial-sodium CONFIG REQUIRED)
|
find_package(unofficial-sodium CONFIG REQUIRED)
|
||||||
|
|||||||
+15
-6
@@ -99,6 +99,8 @@ void CheckNetworkAcceptThread(THREAD *thread, void *param)
|
|||||||
|
|
||||||
Disconnect(s);
|
Disconnect(s);
|
||||||
ReleaseSock(s);
|
ReleaseSock(s);
|
||||||
|
|
||||||
|
Free(c);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@@ -155,15 +157,15 @@ void CheckNetworkListenThread(THREAD *thread, void *param)
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
CHECK_NETWORK_2 c;
|
CHECK_NETWORK_2 *c;
|
||||||
THREAD *t;
|
THREAD *t;
|
||||||
|
|
||||||
Zero(&c, sizeof(c));
|
c = ZeroMalloc(sizeof(CHECK_NETWORK_2));
|
||||||
c.s = new_sock;
|
c->s = new_sock;
|
||||||
c.k = pri;
|
c->k = pri;
|
||||||
c.x = x;
|
c->x = x;
|
||||||
|
|
||||||
t = NewThread(CheckNetworkAcceptThread, &c);
|
t = NewThread(CheckNetworkAcceptThread, c);
|
||||||
Insert(o, t);
|
Insert(o, t);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -11789,6 +11791,9 @@ UINT PsRadiusServerSet(CONSOLE *c, char *cmd_name, wchar_t *str, void *param)
|
|||||||
{"[server_name:port]", CmdPrompt, _UU("CMD_RadiusServerSet_Prompt_Host"), CmdEvalNotEmpty, NULL},
|
{"[server_name:port]", CmdPrompt, _UU("CMD_RadiusServerSet_Prompt_Host"), CmdEvalNotEmpty, NULL},
|
||||||
{"SECRET", CmdPromptChoosePassword, _UU("CMD_RadiusServerSet_Prompt_Secret"), NULL, NULL},
|
{"SECRET", CmdPromptChoosePassword, _UU("CMD_RadiusServerSet_Prompt_Secret"), NULL, NULL},
|
||||||
{"RETRY_INTERVAL", CmdPrompt, _UU("CMD_RadiusServerSet_Prompt_RetryInterval"), CmdEvalMinMax, &minmax},
|
{"RETRY_INTERVAL", CmdPrompt, _UU("CMD_RadiusServerSet_Prompt_RetryInterval"), CmdEvalMinMax, &minmax},
|
||||||
|
|
||||||
|
// Support for setting timeout through commandline not added
|
||||||
|
// {"RETRY_TIMEOUT", CmdPrompt, _UU("CMD_RadiusServerSet_Prompt_RetryTimeout"), CmdEvalMinMax, &minmax},
|
||||||
};
|
};
|
||||||
|
|
||||||
// If virtual HUB is not selected, it's an error
|
// If virtual HUB is not selected, it's an error
|
||||||
@@ -11813,6 +11818,7 @@ UINT PsRadiusServerSet(CONSOLE *c, char *cmd_name, wchar_t *str, void *param)
|
|||||||
StrCpy(t.RadiusServerName, sizeof(t.RadiusServerName), host);
|
StrCpy(t.RadiusServerName, sizeof(t.RadiusServerName), host);
|
||||||
StrCpy(t.RadiusSecret, sizeof(t.RadiusSecret), GetParamStr(o, "SECRET"));
|
StrCpy(t.RadiusSecret, sizeof(t.RadiusSecret), GetParamStr(o, "SECRET"));
|
||||||
t.RadiusRetryInterval = GetParamInt(o, "RETRY_INTERVAL");
|
t.RadiusRetryInterval = GetParamInt(o, "RETRY_INTERVAL");
|
||||||
|
// t.RadiusRetryTimeout = GetParamInt(o, "RETRY_TIMEOUT");
|
||||||
|
|
||||||
Free(host);
|
Free(host);
|
||||||
|
|
||||||
@@ -11936,6 +11942,9 @@ UINT PsRadiusServerGet(CONSOLE *c, char *cmd_name, wchar_t *str, void *param)
|
|||||||
|
|
||||||
UniToStri(tmp, t.RadiusRetryInterval);
|
UniToStri(tmp, t.RadiusRetryInterval);
|
||||||
CtInsert(ct, _UU("CMD_RadiusServerGet_RetryInterval"), tmp);
|
CtInsert(ct, _UU("CMD_RadiusServerGet_RetryInterval"), tmp);
|
||||||
|
|
||||||
|
UniToStri(tmp, t.RadiusRetryTimeout);
|
||||||
|
CtInsert(ct, _UU("CMD_RadiusServerGet_RetryTimeout"), tmp);
|
||||||
}
|
}
|
||||||
|
|
||||||
CtFree(ct, c);
|
CtFree(ct, c);
|
||||||
|
|||||||
+43
-1
@@ -1938,6 +1938,7 @@ bool PasswordPrompt(char *password, UINT size)
|
|||||||
c = _getch();
|
c = _getch();
|
||||||
#else // OS_WIN32
|
#else // OS_WIN32
|
||||||
c = getc(stdin);
|
c = getc(stdin);
|
||||||
|
PROCESS_CH:
|
||||||
#endif // OS_WIN32
|
#endif // OS_WIN32
|
||||||
|
|
||||||
if (c >= 0x20 && c <= 0x7E)
|
if (c >= 0x20 && c <= 0x7E)
|
||||||
@@ -1952,6 +1953,7 @@ bool PasswordPrompt(char *password, UINT size)
|
|||||||
else if (c == 0x03)
|
else if (c == 0x03)
|
||||||
{
|
{
|
||||||
// Break
|
// Break
|
||||||
|
RestoreConsole(console);
|
||||||
exit(0);
|
exit(0);
|
||||||
}
|
}
|
||||||
else if (c == 0x04 || c == 0x1a || c == 0x0D || c==0x0A)
|
else if (c == 0x04 || c == 0x1a || c == 0x0D || c==0x0A)
|
||||||
@@ -1977,7 +1979,47 @@ bool PasswordPrompt(char *password, UINT size)
|
|||||||
goto BACKSPACE;
|
goto BACKSPACE;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else if (c == 0x08)
|
#ifdef OS_UNIX // OS_UNIX
|
||||||
|
else if (c == 0x1B)
|
||||||
|
{
|
||||||
|
c = getc(stdin);
|
||||||
|
if (c != 0x5B && c != 0x4F)
|
||||||
|
{
|
||||||
|
// ESC key
|
||||||
|
goto PROCESS_CH;
|
||||||
|
}
|
||||||
|
|
||||||
|
c = getc(stdin);
|
||||||
|
if (c == 0x44)
|
||||||
|
{
|
||||||
|
// Left arrow key
|
||||||
|
goto BACKSPACE;
|
||||||
|
}
|
||||||
|
else if (c == 0x33)
|
||||||
|
{
|
||||||
|
c = getc(stdin);
|
||||||
|
if (c == 0x7E)
|
||||||
|
{
|
||||||
|
// Delete key
|
||||||
|
goto BACKSPACE;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
// Drain remaining sequence bytes (most are <= 6)
|
||||||
|
for (int i = 0; i < 6; i++)
|
||||||
|
{
|
||||||
|
if (c >= 0x40 && c <= 0x7E)
|
||||||
|
{
|
||||||
|
// End of sequence
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
c = getc(stdin);
|
||||||
|
}
|
||||||
|
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
#endif // OS_UNIX
|
||||||
|
else if (c == 0x08 || c == 0x7F)
|
||||||
{
|
{
|
||||||
BACKSPACE:
|
BACKSPACE:
|
||||||
// Backspace
|
// Backspace
|
||||||
|
|||||||
+33
-10
@@ -99,6 +99,7 @@ EAP_CLIENT *HubNewEapClient(CEDAR *cedar, char *hubname, char *client_ip_str, ch
|
|||||||
char radius_servers[MAX_PATH] = {0};
|
char radius_servers[MAX_PATH] = {0};
|
||||||
UINT radius_port = 0;
|
UINT radius_port = 0;
|
||||||
UINT radius_retry_interval = 0;
|
UINT radius_retry_interval = 0;
|
||||||
|
UINT radius_retry_timeout = 0;
|
||||||
char radius_secret[MAX_PATH] = {0};
|
char radius_secret[MAX_PATH] = {0};
|
||||||
char radius_suffix_filter[MAX_PATH] = {0};
|
char radius_suffix_filter[MAX_PATH] = {0};
|
||||||
if (cedar == NULL || hubname == NULL || client_ip_str == NULL || username == NULL)
|
if (cedar == NULL || hubname == NULL || client_ip_str == NULL || username == NULL)
|
||||||
@@ -115,8 +116,8 @@ EAP_CLIENT *HubNewEapClient(CEDAR *cedar, char *hubname, char *client_ip_str, ch
|
|||||||
|
|
||||||
if (hub != NULL)
|
if (hub != NULL)
|
||||||
{
|
{
|
||||||
if (GetRadiusServerEx2(hub, radius_servers, sizeof(radius_servers), &radius_port, radius_secret,
|
if (GetRadiusServerEx3(hub, radius_servers, sizeof(radius_servers), &radius_port, radius_secret,
|
||||||
sizeof(radius_secret), &radius_retry_interval, radius_suffix_filter, sizeof(radius_suffix_filter)))
|
sizeof(radius_secret), &radius_retry_interval, &radius_retry_timeout, radius_suffix_filter, sizeof(radius_suffix_filter)))
|
||||||
{
|
{
|
||||||
bool use_peap = hub->RadiusUsePeapInsteadOfEap;
|
bool use_peap = hub->RadiusUsePeapInsteadOfEap;
|
||||||
|
|
||||||
@@ -630,6 +631,7 @@ void DataToHubOptionStruct(HUB_OPTION *o, RPC_ADMIN_OPTION *ao)
|
|||||||
GetHubAdminOptionDataAndSet(ao, "UseHubNameAsDhcpUserClassOption", o->UseHubNameAsDhcpUserClassOption);
|
GetHubAdminOptionDataAndSet(ao, "UseHubNameAsDhcpUserClassOption", o->UseHubNameAsDhcpUserClassOption);
|
||||||
GetHubAdminOptionDataAndSet(ao, "UseHubNameAsRadiusNasId", o->UseHubNameAsRadiusNasId);
|
GetHubAdminOptionDataAndSet(ao, "UseHubNameAsRadiusNasId", o->UseHubNameAsRadiusNasId);
|
||||||
GetHubAdminOptionDataAndSet(ao, "AllowEapMatchUserByCert", o->AllowEapMatchUserByCert);
|
GetHubAdminOptionDataAndSet(ao, "AllowEapMatchUserByCert", o->AllowEapMatchUserByCert);
|
||||||
|
GetHubAdminOptionDataAndSet(ao, "DhcpDiscoverTimeoutMs", o->DhcpDiscoverTimeoutMs);
|
||||||
}
|
}
|
||||||
|
|
||||||
// Convert the contents of the HUB_OPTION to data
|
// Convert the contents of the HUB_OPTION to data
|
||||||
@@ -705,6 +707,7 @@ void HubOptionStructToData(RPC_ADMIN_OPTION *ao, HUB_OPTION *o, char *hub_name)
|
|||||||
Add(aol, NewAdminOption("UseHubNameAsDhcpUserClassOption", o->UseHubNameAsDhcpUserClassOption));
|
Add(aol, NewAdminOption("UseHubNameAsDhcpUserClassOption", o->UseHubNameAsDhcpUserClassOption));
|
||||||
Add(aol, NewAdminOption("UseHubNameAsRadiusNasId", o->UseHubNameAsRadiusNasId));
|
Add(aol, NewAdminOption("UseHubNameAsRadiusNasId", o->UseHubNameAsRadiusNasId));
|
||||||
Add(aol, NewAdminOption("AllowEapMatchUserByCert", o->AllowEapMatchUserByCert));
|
Add(aol, NewAdminOption("AllowEapMatchUserByCert", o->AllowEapMatchUserByCert));
|
||||||
|
Add(aol, NewAdminOption("DhcpDiscoverTimeoutMs", o->DhcpDiscoverTimeoutMs));
|
||||||
|
|
||||||
Zero(ao, sizeof(RPC_ADMIN_OPTION));
|
Zero(ao, sizeof(RPC_ADMIN_OPTION));
|
||||||
|
|
||||||
@@ -6413,17 +6416,23 @@ void ReleaseHub(HUB *h)
|
|||||||
bool GetRadiusServer(HUB *hub, char *name, UINT size, UINT *port, char *secret, UINT secret_size)
|
bool GetRadiusServer(HUB *hub, char *name, UINT size, UINT *port, char *secret, UINT secret_size)
|
||||||
{
|
{
|
||||||
UINT interval;
|
UINT interval;
|
||||||
|
|
||||||
return GetRadiusServerEx(hub, name, size, port, secret, secret_size, &interval);
|
return GetRadiusServerEx(hub, name, size, port, secret, secret_size, &interval);
|
||||||
}
|
}
|
||||||
bool GetRadiusServerEx(HUB *hub, char *name, UINT size, UINT *port, char *secret, UINT secret_size, UINT *interval)
|
bool GetRadiusServerEx(HUB *hub, char *name, UINT size, UINT *port, char *secret, UINT secret_size, UINT *interval) {
|
||||||
{
|
UINT timeout;
|
||||||
return GetRadiusServerEx2(hub, name, size, port, secret, secret_size, interval, NULL, 0);
|
|
||||||
|
return GetRadiusServerEx2(hub, name, size, port, secret, secret_size, interval, &timeout);
|
||||||
}
|
}
|
||||||
bool GetRadiusServerEx2(HUB *hub, char *name, UINT size, UINT *port, char *secret, UINT secret_size, UINT *interval, char *suffix_filter, UINT suffix_filter_size)
|
bool GetRadiusServerEx2(HUB *hub, char *name, UINT size, UINT *port, char *secret, UINT secret_size, UINT *interval, UINT *timeout)
|
||||||
|
{
|
||||||
|
return GetRadiusServerEx3(hub, name, size, port, secret, secret_size, interval, timeout, NULL, 0);
|
||||||
|
}
|
||||||
|
bool GetRadiusServerEx3(HUB *hub, char *name, UINT size, UINT *port, char *secret, UINT secret_size, UINT *interval, UINT *timeout, char *suffix_filter, UINT suffix_filter_size)
|
||||||
{
|
{
|
||||||
bool ret = false;
|
bool ret = false;
|
||||||
// Validate arguments
|
// Validate arguments
|
||||||
if (hub == NULL || name == NULL || port == NULL || secret == NULL || interval == NULL)
|
if (hub == NULL || name == NULL || port == NULL || secret == NULL || interval == NULL || timeout == NULL)
|
||||||
{
|
{
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
@@ -6437,6 +6446,7 @@ bool GetRadiusServerEx2(HUB *hub, char *name, UINT size, UINT *port, char *secre
|
|||||||
StrCpy(name, size, hub->RadiusServerName);
|
StrCpy(name, size, hub->RadiusServerName);
|
||||||
*port = hub->RadiusServerPort;
|
*port = hub->RadiusServerPort;
|
||||||
*interval = hub->RadiusRetryInterval;
|
*interval = hub->RadiusRetryInterval;
|
||||||
|
*timeout = hub->RadiusRetryTimeout;
|
||||||
|
|
||||||
tmp_size = hub->RadiusSecret->Size + 1;
|
tmp_size = hub->RadiusSecret->Size + 1;
|
||||||
tmp = ZeroMalloc(tmp_size);
|
tmp = ZeroMalloc(tmp_size);
|
||||||
@@ -6463,6 +6473,10 @@ void SetRadiusServer(HUB *hub, char *name, UINT port, char *secret)
|
|||||||
SetRadiusServerEx(hub, name, port, secret, RADIUS_RETRY_INTERVAL);
|
SetRadiusServerEx(hub, name, port, secret, RADIUS_RETRY_INTERVAL);
|
||||||
}
|
}
|
||||||
void SetRadiusServerEx(HUB *hub, char *name, UINT port, char *secret, UINT interval)
|
void SetRadiusServerEx(HUB *hub, char *name, UINT port, char *secret, UINT interval)
|
||||||
|
{
|
||||||
|
SetRadiusServerEx2(hub, name, port, secret, interval, RADIUS_RETRY_TIMEOUT);
|
||||||
|
}
|
||||||
|
void SetRadiusServerEx2(HUB *hub, char *name, UINT port, char *secret, UINT interval, UINT timeout)
|
||||||
{
|
{
|
||||||
// Validate arguments
|
// Validate arguments
|
||||||
if (hub == NULL)
|
if (hub == NULL)
|
||||||
@@ -6482,19 +6496,28 @@ void SetRadiusServerEx(HUB *hub, char *name, UINT port, char *secret, UINT inter
|
|||||||
hub->RadiusServerName = NULL;
|
hub->RadiusServerName = NULL;
|
||||||
hub->RadiusServerPort = 0;
|
hub->RadiusServerPort = 0;
|
||||||
hub->RadiusRetryInterval = RADIUS_RETRY_INTERVAL;
|
hub->RadiusRetryInterval = RADIUS_RETRY_INTERVAL;
|
||||||
|
hub->RadiusRetryTimeout = RADIUS_RETRY_TIMEOUT;
|
||||||
|
|
||||||
FreeBuf(hub->RadiusSecret);
|
FreeBuf(hub->RadiusSecret);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
hub->RadiusServerName = CopyStr(name);
|
hub->RadiusServerName = CopyStr(name);
|
||||||
hub->RadiusServerPort = port;
|
hub->RadiusServerPort = port;
|
||||||
|
|
||||||
|
if (timeout == 0) {
|
||||||
|
timeout = RADIUS_RETRY_TIMEOUT;
|
||||||
|
}
|
||||||
|
hub->RadiusRetryTimeout = timeout;
|
||||||
|
|
||||||
if (interval == 0)
|
if (interval == 0)
|
||||||
{
|
{
|
||||||
hub->RadiusRetryInterval = RADIUS_RETRY_INTERVAL;
|
hub->RadiusRetryInterval = RADIUS_RETRY_INTERVAL; ///What happens here is that RADIUS_RETRY_TIMEOUT is not configurable, and RADIUS_RETRY_INTERVAL is set to the timeout if it's larger.
|
||||||
}
|
}
|
||||||
else if (interval > RADIUS_RETRY_TIMEOUT)
|
|
||||||
|
if (interval > timeout)
|
||||||
{
|
{
|
||||||
hub->RadiusRetryInterval = RADIUS_RETRY_TIMEOUT;
|
hub->RadiusRetryInterval = timeout;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
|||||||
+8
-1
@@ -30,6 +30,9 @@
|
|||||||
// Default flooding queue length
|
// Default flooding queue length
|
||||||
#define DEFAULT_FLOODING_QUEUE_LENGTH (32 * 1024 * 1024)
|
#define DEFAULT_FLOODING_QUEUE_LENGTH (32 * 1024 * 1024)
|
||||||
|
|
||||||
|
// Default DHCP Discover Timeout
|
||||||
|
#define DEFAULT_DHCP_DISCOVER_TIMEOUT (5 * 1000)
|
||||||
|
|
||||||
// SoftEther link control packet
|
// SoftEther link control packet
|
||||||
struct SE_LINK
|
struct SE_LINK
|
||||||
{
|
{
|
||||||
@@ -183,6 +186,7 @@ struct HUB_OPTION
|
|||||||
bool UseHubNameAsDhcpUserClassOption; // Add HubName to DHCP request as User-Class option
|
bool UseHubNameAsDhcpUserClassOption; // Add HubName to DHCP request as User-Class option
|
||||||
bool UseHubNameAsRadiusNasId; // Add HubName to Radius request as NAS-Identifier attrioption
|
bool UseHubNameAsRadiusNasId; // Add HubName to Radius request as NAS-Identifier attrioption
|
||||||
bool AllowEapMatchUserByCert; // Allow matching EAP Identity with user certificate CNs
|
bool AllowEapMatchUserByCert; // Allow matching EAP Identity with user certificate CNs
|
||||||
|
UINT DhcpDiscoverTimeoutMs; // Timeout to wait for DHCP server response on DISCOVER request
|
||||||
};
|
};
|
||||||
|
|
||||||
// MAC table entry
|
// MAC table entry
|
||||||
@@ -337,6 +341,7 @@ struct HUB
|
|||||||
char *RadiusServerName; // Radius server name
|
char *RadiusServerName; // Radius server name
|
||||||
UINT RadiusServerPort; // Radius server port number
|
UINT RadiusServerPort; // Radius server port number
|
||||||
UINT RadiusRetryInterval; // Radius retry interval
|
UINT RadiusRetryInterval; // Radius retry interval
|
||||||
|
UINT RadiusRetryTimeout; // Radius timeout, it will no longer retry
|
||||||
BUF *RadiusSecret; // Radius shared key
|
BUF *RadiusSecret; // Radius shared key
|
||||||
char RadiusSuffixFilter[MAX_SIZE]; // Radius suffix filter
|
char RadiusSuffixFilter[MAX_SIZE]; // Radius suffix filter
|
||||||
char RadiusRealm[MAX_SIZE]; // Radius realm (optional)
|
char RadiusRealm[MAX_SIZE]; // Radius realm (optional)
|
||||||
@@ -478,9 +483,11 @@ void GetAccessListStr(char *str, UINT size, ACCESS *a);
|
|||||||
void DeleteOldIpTableEntry(LIST *o);
|
void DeleteOldIpTableEntry(LIST *o);
|
||||||
void SetRadiusServer(HUB *hub, char *name, UINT port, char *secret);
|
void SetRadiusServer(HUB *hub, char *name, UINT port, char *secret);
|
||||||
void SetRadiusServerEx(HUB *hub, char *name, UINT port, char *secret, UINT interval);
|
void SetRadiusServerEx(HUB *hub, char *name, UINT port, char *secret, UINT interval);
|
||||||
|
void SetRadiusServerEx2(HUB *hub, char *name, UINT port, char *secret, UINT interval, UINT timeout);
|
||||||
bool GetRadiusServer(HUB *hub, char *name, UINT size, UINT *port, char *secret, UINT secret_size);
|
bool GetRadiusServer(HUB *hub, char *name, UINT size, UINT *port, char *secret, UINT secret_size);
|
||||||
bool GetRadiusServerEx(HUB *hub, char *name, UINT size, UINT *port, char *secret, UINT secret_size, UINT *interval);
|
bool GetRadiusServerEx(HUB *hub, char *name, UINT size, UINT *port, char *secret, UINT secret_size, UINT *interval);
|
||||||
bool GetRadiusServerEx2(HUB *hub, char *name, UINT size, UINT *port, char *secret, UINT secret_size, UINT *interval, char *suffix_filter, UINT suffix_filter_size);
|
bool GetRadiusServerEx2(HUB *hub, char *name, UINT size, UINT *port, char *secret, UINT secret_size, UINT *interval, UINT *timeout);
|
||||||
|
bool GetRadiusServerEx3(HUB *hub, char *name, UINT size, UINT *port, char *secret, UINT secret_size, UINT *interval, UINT *timeout, char *suffix_filter, UINT suffix_filter_size);
|
||||||
int CompareCert(void *p1, void *p2);
|
int CompareCert(void *p1, void *p2);
|
||||||
void GetHubLogSetting(HUB *h, HUB_LOG *setting);
|
void GetHubLogSetting(HUB *h, HUB_LOG *setting);
|
||||||
void SetHubLogSetting(HUB *h, HUB_LOG *setting);
|
void SetHubLogSetting(HUB *h, HUB_LOG *setting);
|
||||||
|
|||||||
+8
-2
@@ -493,12 +493,14 @@ IPC *NewIPC(CEDAR *cedar, char *client_name, char *postfix, char *hubname, char
|
|||||||
{
|
{
|
||||||
UINTToIP(&ipc->DefaultGateway, hub->Option->DefaultGateway);
|
UINTToIP(&ipc->DefaultGateway, hub->Option->DefaultGateway);
|
||||||
UINTToIP(&ipc->SubnetMask, hub->Option->DefaultSubnet);
|
UINTToIP(&ipc->SubnetMask, hub->Option->DefaultSubnet);
|
||||||
|
ipc->DhcpDiscoverTimeoutMs = hub->Option->DhcpDiscoverTimeoutMs;
|
||||||
GetBroadcastAddress4(&ipc->BroadcastAddress, &ipc->DefaultGateway, &ipc->SubnetMask);
|
GetBroadcastAddress4(&ipc->BroadcastAddress, &ipc->DefaultGateway, &ipc->SubnetMask);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
ZeroIP4(&ipc->DefaultGateway);
|
ZeroIP4(&ipc->DefaultGateway);
|
||||||
ZeroIP4(&ipc->SubnetMask);
|
ZeroIP4(&ipc->SubnetMask);
|
||||||
|
ipc->DhcpDiscoverTimeoutMs = DEFAULT_DHCP_DISCOVER_TIMEOUT;
|
||||||
ZeroIP4(&ipc->BroadcastAddress);
|
ZeroIP4(&ipc->BroadcastAddress);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -565,6 +567,9 @@ IPC *NewIPCBySock(CEDAR *cedar, SOCK *s, void *mac_address)
|
|||||||
ipc->Sock = s;
|
ipc->Sock = s;
|
||||||
AddRef(s->ref);
|
AddRef(s->ref);
|
||||||
|
|
||||||
|
// Initialize to pass the validity check on the source IP address performed by IPCSendIPv4()
|
||||||
|
ZeroIP4(&ipc->ClientIPAddress);
|
||||||
|
|
||||||
Copy(ipc->MacAddress, mac_address, 6);
|
Copy(ipc->MacAddress, mac_address, 6);
|
||||||
|
|
||||||
ipc->Interrupt = NewInterruptManager();
|
ipc->Interrupt = NewInterruptManager();
|
||||||
@@ -793,7 +798,8 @@ bool IPCDhcpAllocateIP(IPC *ipc, DHCP_OPTION_LIST *opt, TUBE *discon_poll_tube)
|
|||||||
StrCpy(req.Hostname, sizeof(req.Hostname), ipc->ClientHostname);
|
StrCpy(req.Hostname, sizeof(req.Hostname), ipc->ClientHostname);
|
||||||
IPCDhcpSetConditionalUserClass(ipc, &req);
|
IPCDhcpSetConditionalUserClass(ipc, &req);
|
||||||
|
|
||||||
d = IPCSendDhcpRequest(ipc, NULL, tran_id, &req, DHCP_OFFER, IPC_DHCP_TIMEOUT, discon_poll_tube);
|
UINT discoverTimeout = ipc->DhcpDiscoverTimeoutMs > 0 ? ipc->DhcpDiscoverTimeoutMs : DEFAULT_DHCP_DISCOVER_TIMEOUT;
|
||||||
|
d = IPCSendDhcpRequest(ipc, NULL, tran_id, &req, DHCP_OFFER, discoverTimeout, discon_poll_tube);
|
||||||
if (d == NULL)
|
if (d == NULL)
|
||||||
{
|
{
|
||||||
return false;
|
return false;
|
||||||
@@ -896,7 +902,7 @@ DHCPV4_DATA *IPCSendDhcpRequest(IPC *ipc, IP *dest_ip, UINT tran_id, DHCP_OPTION
|
|||||||
}
|
}
|
||||||
|
|
||||||
// Retransmission interval
|
// Retransmission interval
|
||||||
resend_interval = MAX(1, (timeout / 3) - 100);
|
resend_interval = MIN(IPC_DHCP_MAX_RESEND_INTERVAL, MAX(1, (timeout / 3) - 100));
|
||||||
|
|
||||||
// Time-out time
|
// Time-out time
|
||||||
giveup_time = Tick64() + (UINT64)timeout;
|
giveup_time = Tick64() + (UINT64)timeout;
|
||||||
|
|||||||
@@ -19,6 +19,7 @@
|
|||||||
#define IPC_DHCP_TIMEOUT (5 * 1000)
|
#define IPC_DHCP_TIMEOUT (5 * 1000)
|
||||||
#define IPC_DHCP_MIN_LEASE 5
|
#define IPC_DHCP_MIN_LEASE 5
|
||||||
#define IPC_DHCP_DEFAULT_LEASE 3600
|
#define IPC_DHCP_DEFAULT_LEASE 3600
|
||||||
|
#define IPC_DHCP_MAX_RESEND_INTERVAL (3 * 1000)
|
||||||
|
|
||||||
#define IPC_MAX_PACKET_QUEUE_LEN 10000
|
#define IPC_MAX_PACKET_QUEUE_LEN 10000
|
||||||
|
|
||||||
@@ -149,6 +150,7 @@ struct IPC
|
|||||||
SHARED_BUFFER *IpcSessionSharedBuffer; // A shared buffer between IPC and Session
|
SHARED_BUFFER *IpcSessionSharedBuffer; // A shared buffer between IPC and Session
|
||||||
IPC_SESSION_SHARED_BUFFER_DATA *IpcSessionShared; // Shared data between IPC and Session
|
IPC_SESSION_SHARED_BUFFER_DATA *IpcSessionShared; // Shared data between IPC and Session
|
||||||
UINT Layer;
|
UINT Layer;
|
||||||
|
UINT DhcpDiscoverTimeoutMs; // Timeut to wait for DHCP server response on DISCOVER request
|
||||||
|
|
||||||
// IPv6 stuff
|
// IPv6 stuff
|
||||||
QUEUE *IPv6ReceivedQueue; // IPv6 reception queue
|
QUEUE *IPv6ReceivedQueue; // IPv6 reception queue
|
||||||
|
|||||||
+2
-2
@@ -457,10 +457,10 @@ void L3KnownArp(L3IF *f, UINT ip, UCHAR *mac)
|
|||||||
// Delete an ARP query entry to this IP address
|
// Delete an ARP query entry to this IP address
|
||||||
Zero(&t, sizeof(t));
|
Zero(&t, sizeof(t));
|
||||||
t.IpAddress = ip;
|
t.IpAddress = ip;
|
||||||
w = Search(f->IpWaitList, &t);
|
w = Search(f->ArpWaitTable, &t);
|
||||||
if (w != NULL)
|
if (w != NULL)
|
||||||
{
|
{
|
||||||
Delete(f->IpWaitList, w);
|
Delete(f->ArpWaitTable, w);
|
||||||
Free(w);
|
Free(w);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
+37
-3
@@ -11,6 +11,7 @@
|
|||||||
#include "Connection.h"
|
#include "Connection.h"
|
||||||
#include "Logging.h"
|
#include "Logging.h"
|
||||||
#include "Proto_EtherIP.h"
|
#include "Proto_EtherIP.h"
|
||||||
|
#include "Proto_IKEv2.h"
|
||||||
#include "Proto_IPsec.h"
|
#include "Proto_IPsec.h"
|
||||||
#include "Proto_L2TP.h"
|
#include "Proto_L2TP.h"
|
||||||
#include "Server.h"
|
#include "Server.h"
|
||||||
@@ -35,7 +36,25 @@ void ProcIKEPacketRecv(IKE_SERVER *ike, UDPPACKET *p)
|
|||||||
|
|
||||||
if (p->Type == IKE_UDP_TYPE_ISAKMP)
|
if (p->Type == IKE_UDP_TYPE_ISAKMP)
|
||||||
{
|
{
|
||||||
// ISAKMP (IKE) packet
|
IKE_HEADER *raw_hdr;
|
||||||
|
|
||||||
|
// Check packet is large enough for the IKE header
|
||||||
|
if (p->Size < sizeof(IKE_HEADER))
|
||||||
|
{
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
raw_hdr = (IKE_HEADER *)p->Data;
|
||||||
|
|
||||||
|
// Dispatch IKEv2 packets by version field
|
||||||
|
if (raw_hdr->Version == IKEv2_VERSION)
|
||||||
|
{
|
||||||
|
ProcIKEv2PacketRecv(ike, p);
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
// IKEv1 / ISAKMP packet
|
||||||
|
{
|
||||||
IKE_PACKET *header;
|
IKE_PACKET *header;
|
||||||
|
|
||||||
header = ParseIKEPacketHeader(p);
|
header = ParseIKEPacketHeader(p);
|
||||||
@@ -44,8 +63,6 @@ void ProcIKEPacketRecv(IKE_SERVER *ike, UDPPACKET *p)
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
//Debug("InitiatorCookie: %I64u, ResponderCookie: %I64u\n", header->InitiatorCookie, header->ResponderCookie);
|
|
||||||
|
|
||||||
switch (header->ExchangeType)
|
switch (header->ExchangeType)
|
||||||
{
|
{
|
||||||
case IKE_EXCHANGE_TYPE_MAIN: // Main mode
|
case IKE_EXCHANGE_TYPE_MAIN: // Main mode
|
||||||
@@ -70,6 +87,7 @@ void ProcIKEPacketRecv(IKE_SERVER *ike, UDPPACKET *p)
|
|||||||
|
|
||||||
IkeFree(header);
|
IkeFree(header);
|
||||||
}
|
}
|
||||||
|
}
|
||||||
else if (p->Type == IKE_UDP_TYPE_ESP)
|
else if (p->Type == IKE_UDP_TYPE_ESP)
|
||||||
{
|
{
|
||||||
// ESP packet
|
// ESP packet
|
||||||
@@ -5645,6 +5663,9 @@ void ProcessIKEInterrupts(IKE_SERVER *ike)
|
|||||||
}
|
}
|
||||||
while (ike->StateHasChanged);
|
while (ike->StateHasChanged);
|
||||||
|
|
||||||
|
// IKEv2 interrupt processing
|
||||||
|
ProcessIKEv2Interrupts(ike);
|
||||||
|
|
||||||
// Maintenance of the thread list
|
// Maintenance of the thread list
|
||||||
MaintainThreadList(ike->ThreadList);
|
MaintainThreadList(ike->ThreadList);
|
||||||
/*Debug("ike->ThreadList: %u\n", LIST_NUM(ike->ThreadList));
|
/*Debug("ike->ThreadList: %u\n", LIST_NUM(ike->ThreadList));
|
||||||
@@ -5823,6 +5844,17 @@ void FreeIKEServer(IKE_SERVER *ike)
|
|||||||
|
|
||||||
ReleaseList(ike->ClientList);
|
ReleaseList(ike->ClientList);
|
||||||
|
|
||||||
|
// Free IKEv2 SAs
|
||||||
|
{
|
||||||
|
UINT j;
|
||||||
|
for (j = 0; j < LIST_NUM(ike->IKEv2SaList); j++)
|
||||||
|
{
|
||||||
|
IKEv2_SA *sa2 = LIST_DATA(ike->IKEv2SaList, j);
|
||||||
|
IKEv2FreeSA(ike, sa2);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
ReleaseList(ike->IKEv2SaList);
|
||||||
|
|
||||||
ReleaseSockEvent(ike->SockEvent);
|
ReleaseSockEvent(ike->SockEvent);
|
||||||
|
|
||||||
IPsecLog(ike, NULL, NULL, NULL, "LI_STOP");
|
IPsecLog(ike, NULL, NULL, NULL, "LI_STOP");
|
||||||
@@ -5869,6 +5901,8 @@ IKE_SERVER *NewIKEServer(CEDAR *cedar, IPSEC_SERVER *ipsec)
|
|||||||
|
|
||||||
ike->ThreadList = NewThreadList();
|
ike->ThreadList = NewThreadList();
|
||||||
|
|
||||||
|
ike->IKEv2SaList = NewList(CmpIKEv2SA);
|
||||||
|
|
||||||
IPsecLog(ike, NULL, NULL, NULL, "LI_START");
|
IPsecLog(ike, NULL, NULL, NULL, "LI_START");
|
||||||
|
|
||||||
return ike;
|
return ike;
|
||||||
|
|||||||
@@ -268,6 +268,10 @@ struct IKE_SERVER
|
|||||||
|
|
||||||
// Setting data
|
// Setting data
|
||||||
char Secret[MAX_SIZE]; // Pre-shared key
|
char Secret[MAX_SIZE]; // Pre-shared key
|
||||||
|
|
||||||
|
// IKEv2 state
|
||||||
|
LIST *IKEv2SaList; // IKEv2 SA list
|
||||||
|
UINT CurrentIKEv2SaId; // IKEv2 SA ID counter
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
File diff suppressed because it is too large
Load Diff
@@ -0,0 +1,292 @@
|
|||||||
|
// SoftEther VPN Source Code - Developer Edition Master Branch
|
||||||
|
// Cedar Communication Module
|
||||||
|
|
||||||
|
|
||||||
|
// Proto_IKEv2.h
|
||||||
|
// Header for IKEv2 (RFC 7296) implementation
|
||||||
|
|
||||||
|
#ifndef PROTO_IKEV2_H
|
||||||
|
#define PROTO_IKEV2_H
|
||||||
|
|
||||||
|
#include "Proto_IKE.h"
|
||||||
|
#include "Proto_IkePacket.h"
|
||||||
|
|
||||||
|
//// IKEv2 Header Flags (RFC 7296 Section 3.1)
|
||||||
|
#define IKEv2_FLAG_RESPONSE 0x20
|
||||||
|
#define IKEv2_FLAG_VERSION 0x10
|
||||||
|
#define IKEv2_FLAG_INITIATOR 0x08
|
||||||
|
|
||||||
|
//// IKEv2 Payload Types (RFC 7296 Section 3.3)
|
||||||
|
#define IKEv2_PAYLOAD_NONE 0
|
||||||
|
#define IKEv2_PAYLOAD_SA 33
|
||||||
|
#define IKEv2_PAYLOAD_KE 34
|
||||||
|
#define IKEv2_PAYLOAD_IDi 35
|
||||||
|
#define IKEv2_PAYLOAD_IDr 36
|
||||||
|
#define IKEv2_PAYLOAD_CERT 37
|
||||||
|
#define IKEv2_PAYLOAD_CERTREQ 38
|
||||||
|
#define IKEv2_PAYLOAD_AUTH 39
|
||||||
|
#define IKEv2_PAYLOAD_NONCE 40
|
||||||
|
#define IKEv2_PAYLOAD_NOTIFY 41
|
||||||
|
#define IKEv2_PAYLOAD_DELETE 42
|
||||||
|
#define IKEv2_PAYLOAD_VENDOR 43
|
||||||
|
#define IKEv2_PAYLOAD_TSi 44
|
||||||
|
#define IKEv2_PAYLOAD_TSr 45
|
||||||
|
#define IKEv2_PAYLOAD_SK 46
|
||||||
|
#define IKEv2_PAYLOAD_CP 47
|
||||||
|
#define IKEv2_PAYLOAD_EAP 48
|
||||||
|
|
||||||
|
//// IKEv2 Transform Types
|
||||||
|
#define IKEv2_TF_ENCR 1
|
||||||
|
#define IKEv2_TF_PRF 2
|
||||||
|
#define IKEv2_TF_INTEG 3
|
||||||
|
#define IKEv2_TF_DH 4
|
||||||
|
#define IKEv2_TF_ESN 5
|
||||||
|
|
||||||
|
//// IKEv2 Encryption Algorithm IDs
|
||||||
|
#define IKEv2_ENCR_3DES 3
|
||||||
|
#define IKEv2_ENCR_AES_CBC 12
|
||||||
|
|
||||||
|
//// IKEv2 PRF Algorithm IDs
|
||||||
|
#define IKEv2_PRF_HMAC_MD5 1
|
||||||
|
#define IKEv2_PRF_HMAC_SHA1 2
|
||||||
|
#define IKEv2_PRF_HMAC_SHA2_256 5
|
||||||
|
#define IKEv2_PRF_HMAC_SHA2_384 6
|
||||||
|
#define IKEv2_PRF_HMAC_SHA2_512 7
|
||||||
|
|
||||||
|
//// IKEv2 Integrity Algorithm IDs
|
||||||
|
#define IKEv2_INTEG_HMAC_MD5_96 1 // key=16, icv=12
|
||||||
|
#define IKEv2_INTEG_HMAC_SHA1_96 2 // key=20, icv=12
|
||||||
|
#define IKEv2_INTEG_HMAC_SHA2_256_128 12 // key=32, icv=16
|
||||||
|
#define IKEv2_INTEG_HMAC_SHA2_384_192 13 // key=48, icv=24
|
||||||
|
#define IKEv2_INTEG_HMAC_SHA2_512_256 14 // key=64, icv=32
|
||||||
|
|
||||||
|
//// IKEv2 DH Groups (same wire values as IKEv1)
|
||||||
|
#define IKEv2_DH_1024_MODP 2
|
||||||
|
#define IKEv2_DH_1536_MODP 5
|
||||||
|
#define IKEv2_DH_2048_MODP 14
|
||||||
|
#define IKEv2_DH_3072_MODP 15
|
||||||
|
#define IKEv2_DH_4096_MODP 16
|
||||||
|
|
||||||
|
//// IKEv2 ESN Values
|
||||||
|
#define IKEv2_ESN_NO_ESN 0
|
||||||
|
#define IKEv2_ESN_YES 1
|
||||||
|
|
||||||
|
//// IKEv2 Notify Message Types (error types < 16384)
|
||||||
|
#define IKEv2_NOTIFY_UNSUPPORTED_CRITICAL_PAYLOAD 1
|
||||||
|
#define IKEv2_NOTIFY_INVALID_IKE_SPI 4
|
||||||
|
#define IKEv2_NOTIFY_INVALID_MAJOR_VERSION 5
|
||||||
|
#define IKEv2_NOTIFY_INVALID_SYNTAX 7
|
||||||
|
#define IKEv2_NOTIFY_INVALID_MESSAGE_ID 9
|
||||||
|
#define IKEv2_NOTIFY_INVALID_SPI 11
|
||||||
|
#define IKEv2_NOTIFY_NO_PROPOSAL_CHOSEN 14
|
||||||
|
#define IKEv2_NOTIFY_INVALID_KE_PAYLOAD 17
|
||||||
|
#define IKEv2_NOTIFY_AUTHENTICATION_FAILED 24
|
||||||
|
#define IKEv2_NOTIFY_TS_UNACCEPTABLE 38
|
||||||
|
|
||||||
|
//// IKEv2 Notify status types (>= 16384)
|
||||||
|
#define IKEv2_NOTIFY_NAT_DETECTION_SOURCE_IP 16388
|
||||||
|
#define IKEv2_NOTIFY_NAT_DETECTION_DESTINATION_IP 16389
|
||||||
|
#define IKEv2_NOTIFY_USE_TRANSPORT_MODE 16391
|
||||||
|
#define IKEv2_NOTIFY_ESP_TFC_PADDING_NOT_SUPPORTED 16394
|
||||||
|
|
||||||
|
//// IKEv2 ID Types
|
||||||
|
#define IKEv2_ID_IPV4_ADDR 1
|
||||||
|
#define IKEv2_ID_FQDN 2
|
||||||
|
#define IKEv2_ID_RFC822_ADDR 3
|
||||||
|
#define IKEv2_ID_IPV6_ADDR 5
|
||||||
|
#define IKEv2_ID_KEY_ID 11
|
||||||
|
|
||||||
|
//// IKEv2 Authentication Methods
|
||||||
|
#define IKEv2_AUTH_RSA_SIGN 1
|
||||||
|
#define IKEv2_AUTH_PSK 2
|
||||||
|
|
||||||
|
//// IKEv2 Traffic Selector Types
|
||||||
|
#define IKEv2_TS_IPV4_ADDR_RANGE 7
|
||||||
|
#define IKEv2_TS_IPV6_ADDR_RANGE 8
|
||||||
|
|
||||||
|
//// IKEv2 Protocol IDs
|
||||||
|
#define IKEv2_PROTO_IKE 1
|
||||||
|
#define IKEv2_PROTO_AH 2
|
||||||
|
#define IKEv2_PROTO_ESP 3
|
||||||
|
|
||||||
|
//// SA states
|
||||||
|
#define IKEv2_SA_STATE_HALF_OPEN 0
|
||||||
|
#define IKEv2_SA_STATE_ESTABLISHED 1
|
||||||
|
|
||||||
|
//// Sizes and limits
|
||||||
|
#define IKEv2_MAX_KEYMAT_SIZE 128
|
||||||
|
#define IKEv2_NONCE_SIZE 32
|
||||||
|
#define IKEv2_NONCE_MIN_SIZE 16
|
||||||
|
#define IKEv2_NONCE_MAX_SIZE 256
|
||||||
|
#define IKEv2_PSK_PAD "Key Pad for IKEv2"
|
||||||
|
#define IKEv2_PSK_PAD_LEN 17
|
||||||
|
|
||||||
|
//// Timeouts
|
||||||
|
#define IKEv2_SA_TIMEOUT_HALF_OPEN 30000
|
||||||
|
#define IKEv2_SA_TIMEOUT_ESTABLISHED (86400ULL * 1000)
|
||||||
|
#define IKEv2_SA_RESEND_INTERVAL 2000
|
||||||
|
#define IKEv2_CHILD_SA_LIFETIME_SECS 3600
|
||||||
|
|
||||||
|
|
||||||
|
//// Structures
|
||||||
|
|
||||||
|
// Negotiated IKE SA transform parameters
|
||||||
|
struct IKEv2_IKETF
|
||||||
|
{
|
||||||
|
UINT EncrAlg; // Encryption algorithm
|
||||||
|
UINT EncrKeyLen; // Encryption key length (bytes)
|
||||||
|
UINT PrfAlg; // PRF algorithm
|
||||||
|
UINT IntegAlg; // Integrity algorithm
|
||||||
|
UINT DhGroup; // DH group number
|
||||||
|
UINT BlockSize; // Cipher block size (bytes)
|
||||||
|
UINT PrfKeyLen; // PRF key length (bytes)
|
||||||
|
UINT PrfOutLen; // PRF output length (bytes)
|
||||||
|
UINT IntegKeyLen; // Integrity key length (bytes)
|
||||||
|
UINT IntegIcvLen; // Integrity ICV length (bytes)
|
||||||
|
};
|
||||||
|
typedef struct IKEv2_IKETF IKEv2_IKETF;
|
||||||
|
|
||||||
|
// Negotiated Child SA transform parameters
|
||||||
|
struct IKEv2_CHILDTF
|
||||||
|
{
|
||||||
|
UINT EncrAlg; // Encryption algorithm
|
||||||
|
UINT EncrKeyLen; // Encryption key length (bytes)
|
||||||
|
UINT IntegAlg; // Integrity algorithm
|
||||||
|
UINT IntegKeyLen; // Integrity key length (bytes)
|
||||||
|
UINT IntegIcvLen; // Integrity ICV length (bytes)
|
||||||
|
UINT DhGroup; // DH group (0 if none)
|
||||||
|
bool UseTransport; // True = transport mode
|
||||||
|
UINT BlockSize; // Cipher block size
|
||||||
|
};
|
||||||
|
typedef struct IKEv2_CHILDTF IKEv2_CHILDTF;
|
||||||
|
|
||||||
|
// IKEv2 SA (one per IKEv2 connection attempt)
|
||||||
|
struct IKEv2_SA
|
||||||
|
{
|
||||||
|
UINT Id;
|
||||||
|
UINT64 InitiatorSPI;
|
||||||
|
UINT64 ResponderSPI;
|
||||||
|
|
||||||
|
IP ClientIP;
|
||||||
|
UINT ClientPort;
|
||||||
|
IP ServerIP;
|
||||||
|
UINT ServerPort;
|
||||||
|
bool IsNatT;
|
||||||
|
|
||||||
|
UINT State;
|
||||||
|
bool Deleting;
|
||||||
|
UINT64 FirstCommTick;
|
||||||
|
UINT64 LastCommTick;
|
||||||
|
|
||||||
|
IKEv2_IKETF Transform;
|
||||||
|
|
||||||
|
// Nonces
|
||||||
|
BUF *Ni;
|
||||||
|
BUF *Nr;
|
||||||
|
|
||||||
|
// DH
|
||||||
|
DH_CTX *Dh;
|
||||||
|
BUF *GxI; // initiator KE value
|
||||||
|
BUF *GxR; // responder KE value (our public key)
|
||||||
|
|
||||||
|
// Derived IKE SA keys (max 64 bytes each)
|
||||||
|
UCHAR SK_d [IKEv2_MAX_KEYMAT_SIZE];
|
||||||
|
UCHAR SK_ai[IKEv2_MAX_KEYMAT_SIZE];
|
||||||
|
UCHAR SK_ar[IKEv2_MAX_KEYMAT_SIZE];
|
||||||
|
UCHAR SK_ei[IKEv2_MAX_KEYMAT_SIZE];
|
||||||
|
UCHAR SK_er[IKEv2_MAX_KEYMAT_SIZE];
|
||||||
|
UCHAR SK_pi[IKEv2_MAX_KEYMAT_SIZE];
|
||||||
|
UCHAR SK_pr[IKEv2_MAX_KEYMAT_SIZE];
|
||||||
|
|
||||||
|
// Crypto key objects for SK payload
|
||||||
|
IKE_CRYPTO_KEY *EncKeyI; // key for SK_ei (decrypt received)
|
||||||
|
IKE_CRYPTO_KEY *EncKeyR; // key for SK_er (encrypt sent)
|
||||||
|
|
||||||
|
// Original IKE_SA_INIT messages for AUTH
|
||||||
|
BUF *InitMsg; // IKE_SA_INIT request (from initiator)
|
||||||
|
BUF *RespMsg; // IKE_SA_INIT response (from us)
|
||||||
|
|
||||||
|
// Initiator identity from IKE_AUTH
|
||||||
|
UCHAR IDi_Type;
|
||||||
|
BUF *IDi_Data;
|
||||||
|
|
||||||
|
// Responder identity (from initiator's optional IDr payload, echoed back)
|
||||||
|
UCHAR IDr_Type;
|
||||||
|
BUF *IDr_Data;
|
||||||
|
|
||||||
|
// Message ID tracking
|
||||||
|
UINT NextExpectedMsgId;
|
||||||
|
|
||||||
|
// Retransmission: cache last response
|
||||||
|
BUF *LastResponse;
|
||||||
|
UINT LastRespMsgId;
|
||||||
|
UINT64 LastRespTick;
|
||||||
|
UINT NumResends;
|
||||||
|
|
||||||
|
// Pointer to IKEv1 IKE_CLIENT created after AUTH
|
||||||
|
IKE_CLIENT *IkeClient;
|
||||||
|
};
|
||||||
|
typedef struct IKEv2_SA IKEv2_SA;
|
||||||
|
|
||||||
|
|
||||||
|
//// Function prototypes
|
||||||
|
|
||||||
|
void ProcIKEv2PacketRecv(IKE_SERVER *ike, UDPPACKET *p);
|
||||||
|
void ProcessIKEv2Interrupts(IKE_SERVER *ike);
|
||||||
|
|
||||||
|
IKEv2_SA *IKEv2NewSA(IKE_SERVER *ike);
|
||||||
|
void IKEv2FreeSA(IKE_SERVER *ike, IKEv2_SA *sa);
|
||||||
|
void IKEv2MarkDeleting(IKE_SERVER *ike, IKEv2_SA *sa);
|
||||||
|
void IKEv2PurgeDeleting(IKE_SERVER *ike);
|
||||||
|
IKEv2_SA *IKEv2FindByInitSPI(IKE_SERVER *ike, UINT64 init_spi, IP *client_ip, UINT client_port);
|
||||||
|
IKEv2_SA *IKEv2FindBySPIPair(IKE_SERVER *ike, UINT64 init_spi, UINT64 resp_spi);
|
||||||
|
int CmpIKEv2SA(void *p1, void *p2);
|
||||||
|
|
||||||
|
void IKEv2ProcSAInit(IKE_SERVER *ike, UDPPACKET *p, IKE_HEADER *hdr);
|
||||||
|
void IKEv2ProcAuth(IKE_SERVER *ike, UDPPACKET *p, IKE_HEADER *hdr, IKEv2_SA *sa,
|
||||||
|
void *payload_data, UINT payload_size, UCHAR first_payload);
|
||||||
|
void IKEv2ProcInformational(IKE_SERVER *ike, UDPPACKET *p, IKE_HEADER *hdr, IKEv2_SA *sa,
|
||||||
|
void *payload_data, UINT payload_size);
|
||||||
|
|
||||||
|
bool IKEv2DeriveKeys(IKE_SERVER *ike, IKEv2_SA *sa);
|
||||||
|
void IKEv2PRF(UINT prf_alg, void *key, UINT key_len,
|
||||||
|
void *data, UINT data_len, void *out);
|
||||||
|
void IKEv2PRFPlus(UINT prf_alg, void *key, UINT key_len,
|
||||||
|
void *seed, UINT seed_len, void *out, UINT out_len);
|
||||||
|
|
||||||
|
bool IKEv2VerifyAuth(IKE_SERVER *ike, IKEv2_SA *sa,
|
||||||
|
UCHAR auth_method, void *auth_data, UINT auth_len);
|
||||||
|
void IKEv2ComputeOurAuth(IKE_SERVER *ike, IKEv2_SA *sa, void *out, UINT *out_len);
|
||||||
|
|
||||||
|
bool IKEv2CreateChildSAForClient(IKE_SERVER *ike, IKEv2_SA *sa,
|
||||||
|
IKEv2_CHILDTF *ctf, UINT spi_i, UINT spi_r,
|
||||||
|
BUF *ni, BUF *nr);
|
||||||
|
|
||||||
|
bool IKEv2ParseSAProposalIKE(void *data, UINT size, IKEv2_IKETF *out);
|
||||||
|
bool IKEv2ParseSAProposalChild(void *data, UINT size, IKEv2_CHILDTF *out, UINT *out_spi_i);
|
||||||
|
UINT IKEv2BuildSAProposalIKE(IKEv2_SA *sa, void *buf, UINT buf_size);
|
||||||
|
UINT IKEv2BuildSAProposalChild(IKEv2_CHILDTF *ctf, UINT spi_r, void *buf, UINT buf_size);
|
||||||
|
|
||||||
|
void IKEv2SendResponse(IKE_SERVER *ike, IKEv2_SA *sa, IKE_HEADER *req_hdr,
|
||||||
|
UCHAR exchange_type, void *payloads, UINT payloads_size,
|
||||||
|
bool encrypt);
|
||||||
|
void IKEv2SendNotifyError(IKE_SERVER *ike, UDPPACKET *p, IKE_HEADER *hdr,
|
||||||
|
UINT64 resp_spi, USHORT notify_type);
|
||||||
|
|
||||||
|
BUF *IKEv2EncryptSK(IKE_SERVER *ike, IKEv2_SA *sa, UCHAR next_payload,
|
||||||
|
void *inner, UINT inner_size);
|
||||||
|
BUF *IKEv2DecryptSK(IKE_SERVER *ike, IKEv2_SA *sa, bool is_init_sending,
|
||||||
|
void *sk_data, UINT sk_size);
|
||||||
|
|
||||||
|
UINT IKEv2PrfKeyLen(UINT prf_alg);
|
||||||
|
UINT IKEv2PrfOutLen(UINT prf_alg);
|
||||||
|
UINT IKEv2IntegKeyLen(UINT integ_alg);
|
||||||
|
UINT IKEv2IntegIcvLen(UINT integ_alg);
|
||||||
|
UINT IKEv2EncrKeyLen(UINT encr_alg, UINT requested);
|
||||||
|
UINT IKEv2EncrBlockSize(UINT encr_alg);
|
||||||
|
IKE_HASH *IKEv2GetHashForPrf(IKE_SERVER *ike, UINT prf_alg);
|
||||||
|
IKE_HASH *IKEv2GetHashForInteg(IKE_SERVER *ike, UINT integ_alg);
|
||||||
|
IKE_CRYPTO *IKEv2GetCrypto(IKE_SERVER *ike, UINT encr_alg);
|
||||||
|
IKE_DH *IKEv2GetDh(IKE_SERVER *ike, UINT dh_group);
|
||||||
|
|
||||||
|
#endif // PROTO_IKEV2_H
|
||||||
@@ -2562,9 +2562,16 @@ void OvsRecvPacket(OPENVPN_SERVER *s, LIST *recv_packet_list, UINT protocol)
|
|||||||
Debug("OpenVPN Channel %u Failed.\n", j);
|
Debug("OpenVPN Channel %u Failed.\n", j);
|
||||||
OvsLog(s, se, c, "LO_CHANNEL_FAILED");
|
OvsLog(s, se, c, "LO_CHANNEL_FAILED");
|
||||||
|
|
||||||
|
if ((se->IpcAsync->ErrorCode == ERR_AUTHTYPE_NOT_SUPPORTED) ||
|
||||||
|
(se->IpcAsync->ErrorCode == ERR_AUTH_FAILED) ||
|
||||||
|
(se->IpcAsync->ErrorCode == ERR_PROXY_AUTH_FAILED) ||
|
||||||
|
(se->IpcAsync->ErrorCode == ERR_USER_AUTHTYPE_NOT_PASSWORD) ||
|
||||||
|
(se->IpcAsync->ErrorCode == ERR_NOT_SUPPORTED_AUTH_ON_OPENSOURCE))
|
||||||
|
{
|
||||||
// Return the AUTH_FAILED
|
// Return the AUTH_FAILED
|
||||||
str = "AUTH_FAILED";
|
str = "AUTH_FAILED";
|
||||||
WriteFifo(c->SslPipe->SslInOut->SendFifo, str, StrSize(str));
|
WriteFifo(c->SslPipe->SslInOut->SendFifo, str, StrSize(str));
|
||||||
|
}
|
||||||
|
|
||||||
s->SessionEstablishedCount++;
|
s->SessionEstablishedCount++;
|
||||||
|
|
||||||
|
|||||||
+21
-3
@@ -5429,7 +5429,7 @@ void ClientUploadNoop(CONNECTION *c)
|
|||||||
}
|
}
|
||||||
|
|
||||||
p = PackError(0);
|
p = PackError(0);
|
||||||
PackAddInt(p, "noop", 1);
|
PackAddInt(p, "noop", NOOP);
|
||||||
(void)HttpClientSend(c->FirstSock, p);
|
(void)HttpClientSend(c->FirstSock, p);
|
||||||
FreePack(p);
|
FreePack(p);
|
||||||
|
|
||||||
@@ -5440,6 +5440,24 @@ void ClientUploadNoop(CONNECTION *c)
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void ServerUploadNoop(CONNECTION *c)
|
||||||
|
{
|
||||||
|
PACK *p;
|
||||||
|
// Validate arguments
|
||||||
|
if (c == NULL)
|
||||||
|
{
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
p = PackError(0);
|
||||||
|
PackAddInt(p, "noop", NOOP_IGNORE);
|
||||||
|
(void)HttpServerSend(c->FirstSock, p);
|
||||||
|
FreePack(p);
|
||||||
|
|
||||||
|
// Client can't re-respond to an HTTP "response"
|
||||||
|
// so we don't wait for it on the server side
|
||||||
|
}
|
||||||
|
|
||||||
// Add client version information to the PACK
|
// Add client version information to the PACK
|
||||||
void PackAddClientVersion(PACK *p, CONNECTION *c)
|
void PackAddClientVersion(PACK *p, CONNECTION *c)
|
||||||
{
|
{
|
||||||
@@ -5843,7 +5861,6 @@ bool ServerDownloadSignature(CONNECTION *c, char **error_detail_str)
|
|||||||
// Target is invalid
|
// Target is invalid
|
||||||
HttpSendNotFound(s, h->Target);
|
HttpSendNotFound(s, h->Target);
|
||||||
Free(data);
|
Free(data);
|
||||||
FreeHttpHeader(h);
|
|
||||||
*error_detail_str = "POST_Target_Wrong";
|
*error_detail_str = "POST_Target_Wrong";
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
@@ -5861,10 +5878,10 @@ bool ServerDownloadSignature(CONNECTION *c, char **error_detail_str)
|
|||||||
{
|
{
|
||||||
// WaterMark is incorrect
|
// WaterMark is incorrect
|
||||||
HttpSendForbidden(s, h->Target, NULL);
|
HttpSendForbidden(s, h->Target, NULL);
|
||||||
FreeHttpHeader(h);
|
|
||||||
*error_detail_str = "POST_WaterMark_Error";
|
*error_detail_str = "POST_WaterMark_Error";
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
FreeHttpHeader(h);
|
||||||
}
|
}
|
||||||
else if (StrCmpi(h->Method, "OPTIONS") == 0)
|
else if (StrCmpi(h->Method, "OPTIONS") == 0)
|
||||||
{
|
{
|
||||||
@@ -5884,6 +5901,7 @@ bool ServerDownloadSignature(CONNECTION *c, char **error_detail_str)
|
|||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
FreeHttpHeader(h);
|
||||||
}
|
}
|
||||||
else if (StrCmpi(h->Method, "SSTP_DUPLEX_POST") == 0 && (ProtoEnabled(server->Proto, "SSTP") || s->IsReverseAcceptedSocket) && GetServerCapsBool(server, "b_support_sstp"))
|
else if (StrCmpi(h->Method, "SSTP_DUPLEX_POST") == 0 && (ProtoEnabled(server->Proto, "SSTP") || s->IsReverseAcceptedSocket) && GetServerCapsBool(server, "b_support_sstp"))
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -169,6 +169,7 @@ bool GetSessionKeyFromPack(PACK *p, UCHAR *session_key, UINT *session_key_32);
|
|||||||
void CreateNodeInfo(NODE_INFO *info, CONNECTION *c);
|
void CreateNodeInfo(NODE_INFO *info, CONNECTION *c);
|
||||||
UINT SecureSign(SECURE_SIGN *sign, UINT device_id, char *pin);
|
UINT SecureSign(SECURE_SIGN *sign, UINT device_id, char *pin);
|
||||||
void ClientUploadNoop(CONNECTION *c);
|
void ClientUploadNoop(CONNECTION *c);
|
||||||
|
void ServerUploadNoop(CONNECTION *c);
|
||||||
bool ClientCheckServerCert(CONNECTION *c, bool *expired);
|
bool ClientCheckServerCert(CONNECTION *c, bool *expired);
|
||||||
void ClientCheckServerCertThread(THREAD *thread, void *param);
|
void ClientCheckServerCertThread(THREAD *thread, void *param);
|
||||||
bool ClientSecureSign(CONNECTION *c, UCHAR *sign, UCHAR *random, X **x);
|
bool ClientSecureSign(CONNECTION *c, UCHAR *sign, UCHAR *random, X **x);
|
||||||
|
|||||||
+15
-4
@@ -7,6 +7,7 @@
|
|||||||
|
|
||||||
#include "Radius.h"
|
#include "Radius.h"
|
||||||
|
|
||||||
|
#include "Protocol.h"
|
||||||
#include "Connection.h"
|
#include "Connection.h"
|
||||||
#include "IPC.h"
|
#include "IPC.h"
|
||||||
#include "Server.h"
|
#include "Server.h"
|
||||||
@@ -1767,7 +1768,7 @@ LABEL_ERROR:
|
|||||||
////////// Classical implementation
|
////////// Classical implementation
|
||||||
|
|
||||||
// Attempts Radius authentication (with specifying retry interval and multiple server)
|
// Attempts Radius authentication (with specifying retry interval and multiple server)
|
||||||
bool RadiusLogin(CONNECTION *c, char *server, UINT port, UCHAR *secret, UINT secret_size, wchar_t *username, char *password, UINT interval, UCHAR *mschap_v2_server_response_20,
|
bool RadiusLogin(CONNECTION *c, char *server, UINT port, UCHAR *secret, UINT secret_size, wchar_t *username, char *password, UINT interval, UINT timeout, UCHAR *mschap_v2_server_response_20,
|
||||||
RADIUS_LOGIN_OPTION *opt, char *hubname)
|
RADIUS_LOGIN_OPTION *opt, char *hubname)
|
||||||
{
|
{
|
||||||
UCHAR random[MD5_SIZE];
|
UCHAR random[MD5_SIZE];
|
||||||
@@ -2072,14 +2073,22 @@ bool RadiusLogin(CONNECTION *c, char *server, UINT port, UCHAR *secret, UINT sec
|
|||||||
|
|
||||||
// Transmission process start
|
// Transmission process start
|
||||||
start = Tick64();
|
start = Tick64();
|
||||||
|
|
||||||
|
// Limit timeout to be larger than hardcoded timeout
|
||||||
|
// Limit interval to be larger than the hardcoded interval and less than timeout
|
||||||
|
if (timeout < RADIUS_RETRY_TIMEOUT) {
|
||||||
|
timeout = RADIUS_RETRY_TIMEOUT;
|
||||||
|
}
|
||||||
|
|
||||||
if(interval < RADIUS_RETRY_INTERVAL)
|
if(interval < RADIUS_RETRY_INTERVAL)
|
||||||
{
|
{
|
||||||
interval = RADIUS_RETRY_INTERVAL;
|
interval = RADIUS_RETRY_INTERVAL;
|
||||||
}
|
}
|
||||||
else if(interval > RADIUS_RETRY_TIMEOUT)
|
else if(interval > timeout)
|
||||||
{
|
{
|
||||||
interval = RADIUS_RETRY_TIMEOUT;
|
interval = timeout;
|
||||||
}
|
}
|
||||||
|
|
||||||
next_send_time = start + (UINT64)interval;
|
next_send_time = start + (UINT64)interval;
|
||||||
|
|
||||||
while (true)
|
while (true)
|
||||||
@@ -2099,6 +2108,8 @@ SEND_RETRY:
|
|||||||
next_send_time = Tick64() + (UINT64)interval;
|
next_send_time = Tick64() + (UINT64)interval;
|
||||||
|
|
||||||
RECV_RETRY:
|
RECV_RETRY:
|
||||||
|
ServerUploadNoop(c);
|
||||||
|
|
||||||
now = Tick64();
|
now = Tick64();
|
||||||
if (next_send_time <= now)
|
if (next_send_time <= now)
|
||||||
{
|
{
|
||||||
@@ -2109,7 +2120,7 @@ RECV_RETRY:
|
|||||||
goto SEND_RETRY;
|
goto SEND_RETRY;
|
||||||
}
|
}
|
||||||
|
|
||||||
if ((start + RADIUS_RETRY_TIMEOUT) < now)
|
if ((start + timeout) < now)
|
||||||
{
|
{
|
||||||
// Time-out
|
// Time-out
|
||||||
break;
|
break;
|
||||||
|
|||||||
+1
-1
@@ -283,7 +283,7 @@ struct RADIUS_LOGIN_OPTION
|
|||||||
};
|
};
|
||||||
|
|
||||||
// Function prototype
|
// Function prototype
|
||||||
bool RadiusLogin(CONNECTION *c, char *server, UINT port, UCHAR *secret, UINT secret_size, wchar_t *username, char *password, UINT interval, UCHAR *mschap_v2_server_response_20,
|
bool RadiusLogin(CONNECTION *c, char *server, UINT port, UCHAR *secret, UINT secret_size, wchar_t *username, char *password, UINT interval, UINT timeout, UCHAR *mschap_v2_server_response_20,
|
||||||
RADIUS_LOGIN_OPTION *opt, char *hubname);
|
RADIUS_LOGIN_OPTION *opt, char *hubname);
|
||||||
BUF *RadiusEncryptPassword(char *password, UCHAR *random, UCHAR *secret, UINT secret_size);
|
BUF *RadiusEncryptPassword(char *password, UCHAR *random, UCHAR *secret, UINT secret_size);
|
||||||
BUF *RadiusCreateUserName(wchar_t *username);
|
BUF *RadiusCreateUserName(wchar_t *username);
|
||||||
|
|||||||
+3
-2
@@ -516,6 +516,7 @@ bool SamAuthUserByPlainPassword(CONNECTION *c, HUB *hub, char *username, char *p
|
|||||||
char suffix_filter[MAX_SIZE];
|
char suffix_filter[MAX_SIZE];
|
||||||
wchar_t suffix_filter_w[MAX_SIZE];
|
wchar_t suffix_filter_w[MAX_SIZE];
|
||||||
UINT interval;
|
UINT interval;
|
||||||
|
UINT timeout;
|
||||||
EAP_CLIENT *eap = NULL;
|
EAP_CLIENT *eap = NULL;
|
||||||
char password1[MAX_SIZE];
|
char password1[MAX_SIZE];
|
||||||
UCHAR client_challenge[16];
|
UCHAR client_challenge[16];
|
||||||
@@ -586,7 +587,7 @@ bool SamAuthUserByPlainPassword(CONNECTION *c, HUB *hub, char *username, char *p
|
|||||||
}
|
}
|
||||||
|
|
||||||
// Get the Radius server information
|
// Get the Radius server information
|
||||||
if (GetRadiusServerEx2(hub, radius_server_addr, sizeof(radius_server_addr), &radius_server_port, radius_secret, sizeof(radius_secret), &interval, suffix_filter, sizeof(suffix_filter)))
|
if (GetRadiusServerEx3(hub, radius_server_addr, sizeof(radius_server_addr), &radius_server_port, radius_secret, sizeof(radius_secret), &interval, &timeout, suffix_filter, sizeof(suffix_filter)))
|
||||||
{
|
{
|
||||||
Unlock(hub->lock);
|
Unlock(hub->lock);
|
||||||
|
|
||||||
@@ -597,7 +598,7 @@ bool SamAuthUserByPlainPassword(CONNECTION *c, HUB *hub, char *username, char *p
|
|||||||
// Attempt to login
|
// Attempt to login
|
||||||
b = RadiusLogin(c, radius_server_addr, radius_server_port,
|
b = RadiusLogin(c, radius_server_addr, radius_server_port,
|
||||||
radius_secret, StrLen(radius_secret),
|
radius_secret, StrLen(radius_secret),
|
||||||
name, password, interval, mschap_v2_server_response_20, opt, hub->Name);
|
name, password, interval, timeout, mschap_v2_server_response_20, opt, hub->Name);
|
||||||
|
|
||||||
if (b)
|
if (b)
|
||||||
{
|
{
|
||||||
|
|||||||
+21
-1
@@ -2337,6 +2337,7 @@ void SiSetDefaultHubOption(HUB_OPTION *o)
|
|||||||
o->AccessListIncludeFileCacheLifetime = ACCESS_LIST_INCLUDE_FILE_CACHE_LIFETIME;
|
o->AccessListIncludeFileCacheLifetime = ACCESS_LIST_INCLUDE_FILE_CACHE_LIFETIME;
|
||||||
o->RemoveDefGwOnDhcpForLocalhost = true;
|
o->RemoveDefGwOnDhcpForLocalhost = true;
|
||||||
o->FloodingSendQueueBufferQuota = DEFAULT_FLOODING_QUEUE_LENGTH;
|
o->FloodingSendQueueBufferQuota = DEFAULT_FLOODING_QUEUE_LENGTH;
|
||||||
|
o->DhcpDiscoverTimeoutMs = DEFAULT_DHCP_DISCOVER_TIMEOUT;
|
||||||
}
|
}
|
||||||
|
|
||||||
// Create a default virtual HUB
|
// Create a default virtual HUB
|
||||||
@@ -3942,6 +3943,11 @@ void SiLoadHubOptionCfg(FOLDER *f, HUB_OPTION *o)
|
|||||||
o->UseHubNameAsDhcpUserClassOption = CfgGetBool(f, "UseHubNameAsDhcpUserClassOption");
|
o->UseHubNameAsDhcpUserClassOption = CfgGetBool(f, "UseHubNameAsDhcpUserClassOption");
|
||||||
o->UseHubNameAsRadiusNasId = CfgGetBool(f, "UseHubNameAsRadiusNasId");
|
o->UseHubNameAsRadiusNasId = CfgGetBool(f, "UseHubNameAsRadiusNasId");
|
||||||
o->AllowEapMatchUserByCert = CfgGetBool(f, "AllowEapMatchUserByCert");
|
o->AllowEapMatchUserByCert = CfgGetBool(f, "AllowEapMatchUserByCert");
|
||||||
|
o->DhcpDiscoverTimeoutMs = CfgGetInt(f, "DhcpDiscoverTimeoutMs");
|
||||||
|
if (o->DhcpDiscoverTimeoutMs == 0)
|
||||||
|
{
|
||||||
|
o->DhcpDiscoverTimeoutMs = DEFAULT_DHCP_DISCOVER_TIMEOUT;
|
||||||
|
}
|
||||||
|
|
||||||
// Enabled by default
|
// Enabled by default
|
||||||
if (CfgIsItem(f, "ManageOnlyPrivateIP"))
|
if (CfgIsItem(f, "ManageOnlyPrivateIP"))
|
||||||
@@ -4048,6 +4054,7 @@ void SiWriteHubOptionCfg(FOLDER *f, HUB_OPTION *o)
|
|||||||
CfgAddBool(f, "UseHubNameAsDhcpUserClassOption", o->UseHubNameAsDhcpUserClassOption);
|
CfgAddBool(f, "UseHubNameAsDhcpUserClassOption", o->UseHubNameAsDhcpUserClassOption);
|
||||||
CfgAddBool(f, "UseHubNameAsRadiusNasId", o->UseHubNameAsRadiusNasId);
|
CfgAddBool(f, "UseHubNameAsRadiusNasId", o->UseHubNameAsRadiusNasId);
|
||||||
CfgAddBool(f, "AllowEapMatchUserByCert", o->AllowEapMatchUserByCert);
|
CfgAddBool(f, "AllowEapMatchUserByCert", o->AllowEapMatchUserByCert);
|
||||||
|
CfgAddInt(f, "DhcpDiscoverTimeoutMs", o->DhcpDiscoverTimeoutMs);
|
||||||
}
|
}
|
||||||
|
|
||||||
// Write the user
|
// Write the user
|
||||||
@@ -4848,6 +4855,7 @@ void SiWriteHubCfg(FOLDER *f, HUB *h)
|
|||||||
}
|
}
|
||||||
CfgAddInt(f, "RadiusServerPort", h->RadiusServerPort);
|
CfgAddInt(f, "RadiusServerPort", h->RadiusServerPort);
|
||||||
CfgAddInt(f, "RadiusRetryInterval", h->RadiusRetryInterval);
|
CfgAddInt(f, "RadiusRetryInterval", h->RadiusRetryInterval);
|
||||||
|
CfgAddInt(f, "RadiusRetryTimeout", h->RadiusRetryTimeout);
|
||||||
CfgAddStr(f, "RadiusSuffixFilter", h->RadiusSuffixFilter);
|
CfgAddStr(f, "RadiusSuffixFilter", h->RadiusSuffixFilter);
|
||||||
CfgAddStr(f, "RadiusRealm", h->RadiusRealm);
|
CfgAddStr(f, "RadiusRealm", h->RadiusRealm);
|
||||||
|
|
||||||
@@ -5013,9 +5021,11 @@ void SiLoadHubCfg(SERVER *s, FOLDER *f, char *name)
|
|||||||
BUF *secret;
|
BUF *secret;
|
||||||
UINT port;
|
UINT port;
|
||||||
UINT interval;
|
UINT interval;
|
||||||
|
UINT timeout;
|
||||||
|
|
||||||
port = CfgGetInt(f, "RadiusServerPort");
|
port = CfgGetInt(f, "RadiusServerPort");
|
||||||
interval = CfgGetInt(f, "RadiusRetryInterval");
|
interval = CfgGetInt(f, "RadiusRetryInterval");
|
||||||
|
timeout = CfgGetInt(f, "RadiusRetryTimeout");
|
||||||
|
|
||||||
CfgGetStr(f, "RadiusSuffixFilter", h->RadiusSuffixFilter, sizeof(h->RadiusSuffixFilter));
|
CfgGetStr(f, "RadiusSuffixFilter", h->RadiusSuffixFilter, sizeof(h->RadiusSuffixFilter));
|
||||||
CfgGetStr(f, "RadiusRealm", h->RadiusRealm, sizeof(h->RadiusRealm));
|
CfgGetStr(f, "RadiusRealm", h->RadiusRealm, sizeof(h->RadiusRealm));
|
||||||
@@ -5028,6 +5038,10 @@ void SiLoadHubCfg(SERVER *s, FOLDER *f, char *name)
|
|||||||
interval = RADIUS_RETRY_INTERVAL;
|
interval = RADIUS_RETRY_INTERVAL;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (timeout == 0) {
|
||||||
|
timeout = RADIUS_RETRY_TIMEOUT;
|
||||||
|
}
|
||||||
|
|
||||||
if (port != 0 && CfgGetStr(f, "RadiusServerName", name, sizeof(name)))
|
if (port != 0 && CfgGetStr(f, "RadiusServerName", name, sizeof(name)))
|
||||||
{
|
{
|
||||||
secret = CfgGetBuf(f, "RadiusSecret");
|
secret = CfgGetBuf(f, "RadiusSecret");
|
||||||
@@ -5041,7 +5055,7 @@ void SiLoadHubCfg(SERVER *s, FOLDER *f, char *name)
|
|||||||
}
|
}
|
||||||
secret_str[sizeof(secret_str) - 1] = 0;
|
secret_str[sizeof(secret_str) - 1] = 0;
|
||||||
//SetRadiusServer(h, name, port, secret_str);
|
//SetRadiusServer(h, name, port, secret_str);
|
||||||
SetRadiusServerEx(h, name, port, secret_str, interval);
|
SetRadiusServerEx2(h, name, port, secret_str, interval, timeout);
|
||||||
FreeBuf(secret);
|
FreeBuf(secret);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -7533,6 +7547,11 @@ void SiCalledUpdateHub(SERVER *s, PACK *p)
|
|||||||
o.UseHubNameAsDhcpUserClassOption = PackGetBool(p, "UseHubNameAsDhcpUserClassOption");
|
o.UseHubNameAsDhcpUserClassOption = PackGetBool(p, "UseHubNameAsDhcpUserClassOption");
|
||||||
o.UseHubNameAsRadiusNasId = PackGetBool(p, "UseHubNameAsRadiusNasId");
|
o.UseHubNameAsRadiusNasId = PackGetBool(p, "UseHubNameAsRadiusNasId");
|
||||||
o.AllowEapMatchUserByCert = PackGetBool(p, "AllowEapMatchUserByCert");
|
o.AllowEapMatchUserByCert = PackGetBool(p, "AllowEapMatchUserByCert");
|
||||||
|
o.DhcpDiscoverTimeoutMs = PackGetInt(p, "DhcpDiscoverTimeoutMs");
|
||||||
|
if (o.DhcpDiscoverTimeoutMs == 0)
|
||||||
|
{
|
||||||
|
o.DhcpDiscoverTimeoutMs = DEFAULT_DHCP_DISCOVER_TIMEOUT;
|
||||||
|
}
|
||||||
|
|
||||||
save_packet_log = PackGetInt(p, "SavePacketLog");
|
save_packet_log = PackGetInt(p, "SavePacketLog");
|
||||||
packet_log_switch_type = PackGetInt(p, "PacketLogSwitchType");
|
packet_log_switch_type = PackGetInt(p, "PacketLogSwitchType");
|
||||||
@@ -9368,6 +9387,7 @@ void SiPackAddCreateHub(PACK *p, HUB *h)
|
|||||||
PackAddBool(p, "UseHubNameAsDhcpUserClassOption", h->Option->UseHubNameAsDhcpUserClassOption);
|
PackAddBool(p, "UseHubNameAsDhcpUserClassOption", h->Option->UseHubNameAsDhcpUserClassOption);
|
||||||
PackAddBool(p, "UseHubNameAsRadiusNasId", h->Option->UseHubNameAsRadiusNasId);
|
PackAddBool(p, "UseHubNameAsRadiusNasId", h->Option->UseHubNameAsRadiusNasId);
|
||||||
PackAddBool(p, "AllowEapMatchUserByCert", h->Option->AllowEapMatchUserByCert);
|
PackAddBool(p, "AllowEapMatchUserByCert", h->Option->AllowEapMatchUserByCert);
|
||||||
|
PackAddInt(p, "DhcpDiscoverTimeoutMs", h->Option->DhcpDiscoverTimeoutMs);
|
||||||
|
|
||||||
SiAccessListToPack(p, h->AccessList);
|
SiAccessListToPack(p, h->AccessList);
|
||||||
|
|
||||||
|
|||||||
+3
-1
@@ -2815,6 +2815,7 @@ void NativeNatThread(THREAD *thread, void *param)
|
|||||||
if (a != NULL)
|
if (a != NULL)
|
||||||
{
|
{
|
||||||
char macstr[64];
|
char macstr[64];
|
||||||
|
IP dhcp_ip;
|
||||||
// Acquisition success
|
// Acquisition success
|
||||||
Debug("NnGetNextInterface Ok: %s\n", a->DeviceName);
|
Debug("NnGetNextInterface Ok: %s\n", a->DeviceName);
|
||||||
|
|
||||||
@@ -2842,9 +2843,10 @@ void NativeNatThread(THREAD *thread, void *param)
|
|||||||
|
|
||||||
Debug("NnMainLoop Start.\n");
|
Debug("NnMainLoop Start.\n");
|
||||||
MacToStr(macstr, sizeof(macstr), a->Ipc->MacAddress);
|
MacToStr(macstr, sizeof(macstr), a->Ipc->MacAddress);
|
||||||
|
UINTToIP(&dhcp_ip, a->CurrentDhcpOptionList.ServerAddress);
|
||||||
NLog(t->v, "LH_KERNEL_MODE_START", a->DeviceName,
|
NLog(t->v, "LH_KERNEL_MODE_START", a->DeviceName,
|
||||||
&a->Ipc->ClientIPAddress, &a->Ipc->SubnetMask, &a->Ipc->DefaultGateway, &a->Ipc->BroadcastAddress,
|
&a->Ipc->ClientIPAddress, &a->Ipc->SubnetMask, &a->Ipc->DefaultGateway, &a->Ipc->BroadcastAddress,
|
||||||
macstr, &a->CurrentDhcpOptionList.ServerAddress, &a->DnsServerIP);
|
macstr, &dhcp_ip, &a->DnsServerIP);
|
||||||
NnMainLoop(t, a);
|
NnMainLoop(t, a);
|
||||||
Debug("NnMainLoop End.\n");
|
Debug("NnMainLoop End.\n");
|
||||||
|
|
||||||
|
|||||||
Vendored
+1
-1
Submodule src/Mayaqua/3rdparty/liboqs updated: f4b96220e4...94b421ebb8
Vendored
+1
-1
Submodule src/Mayaqua/3rdparty/oqs-provider updated: ec1e8431f9...f076e91faa
@@ -18,20 +18,46 @@ set_target_properties(mayaqua
|
|||||||
|
|
||||||
find_package(OpenSSL REQUIRED)
|
find_package(OpenSSL REQUIRED)
|
||||||
|
|
||||||
if(OPENSSL_VERSION VERSION_LESS "3") # Disable oqsprovider when OpenSSL version < 3
|
if(OPENSSL_VERSION VERSION_GREATER_EQUAL "3")
|
||||||
add_definitions(-DSKIP_OQS_PROVIDER)
|
set(OQS_ENABLE ON CACHE BOOL "By setting this to OFF, Open Quantum Safe algorithms will not be built in")
|
||||||
else()
|
else()
|
||||||
|
# Disable oqsprovider when OpenSSL version < 3
|
||||||
|
set(OQS_ENABLE OFF)
|
||||||
|
endif()
|
||||||
|
|
||||||
|
if(OQS_ENABLE)
|
||||||
set(OQS_BUILD_ONLY_LIB ON CACHE BOOL "Set liboqs to build only the library (no tests)")
|
set(OQS_BUILD_ONLY_LIB ON CACHE BOOL "Set liboqs to build only the library (no tests)")
|
||||||
set(BUILD_TESTING OFF CACHE BOOL "By setting this to OFF, no tests or examples will be compiled.")
|
set(BUILD_TESTING OFF CACHE BOOL "By setting this to OFF, no tests or examples will be compiled.")
|
||||||
set(OQS_PROVIDER_BUILD_STATIC ON CACHE BOOL "Build a static library instead of a shared library") # Build oqsprovider as a static library (defaults to shared)
|
set(OQS_PROVIDER_BUILD_STATIC ON CACHE BOOL "Build a static library instead of a shared library") # Build oqsprovider as a static library (defaults to shared)
|
||||||
list(PREPEND CMAKE_MODULE_PATH "${CMAKE_SOURCE_DIR}/src/Mayaqua/3rdparty/")
|
list(PREPEND CMAKE_MODULE_PATH "${CMAKE_SOURCE_DIR}/src/Mayaqua/3rdparty/")
|
||||||
|
|
||||||
|
# Disable all other KEM families
|
||||||
|
set(OQS_ENABLE_KEM_FRODOKEM OFF)
|
||||||
|
set(OQS_ENABLE_KEM_NTRUPRIME OFF)
|
||||||
|
set(OQS_ENABLE_KEM_NTRU OFF)
|
||||||
|
set(OQS_ENABLE_KEM_CLASSIC_MCELIECE OFF)
|
||||||
|
set(OQS_ENABLE_KEM_HQC OFF)
|
||||||
|
set(OQS_ENABLE_KEM_BIKE OFF)
|
||||||
|
|
||||||
|
# Disable all SIG families
|
||||||
|
set(OQS_ENABLE_SIG_ML_DSA OFF)
|
||||||
|
set(OQS_ENABLE_SIG_FALCON OFF)
|
||||||
|
set(OQS_ENABLE_SIG_DILITHIUM OFF)
|
||||||
|
set(OQS_ENABLE_SIG_SPHINCS OFF)
|
||||||
|
set(OQS_ENABLE_SIG_MAYO OFF)
|
||||||
|
set(OQS_ENABLE_SIG_CROSS OFF)
|
||||||
|
set(OQS_ENABLE_SIG_UOV OFF)
|
||||||
|
set(OQS_ENABLE_SIG_SNOVA OFF)
|
||||||
|
set(OQS_ENABLE_SIG_SLH_DSA OFF)
|
||||||
|
|
||||||
add_subdirectory(3rdparty/liboqs)
|
add_subdirectory(3rdparty/liboqs)
|
||||||
add_subdirectory(3rdparty/oqs-provider)
|
add_subdirectory(3rdparty/oqs-provider)
|
||||||
|
|
||||||
target_include_directories(oqsprovider PUBLIC ${CMAKE_CURRENT_BINARY_DIR}/3rdparty/liboqs/include)
|
target_include_directories(oqsprovider PUBLIC ${CMAKE_CURRENT_BINARY_DIR}/3rdparty/liboqs/include)
|
||||||
set_property(TARGET oqsprovider PROPERTY POSITION_INDEPENDENT_CODE ON)
|
set_property(TARGET oqsprovider PROPERTY POSITION_INDEPENDENT_CODE ON)
|
||||||
target_link_libraries(mayaqua PRIVATE oqsprovider)
|
target_link_libraries(mayaqua PRIVATE oqsprovider)
|
||||||
|
else()
|
||||||
|
add_definitions(-DSKIP_OQS_PROVIDER)
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
include(CheckSymbolExists)
|
include(CheckSymbolExists)
|
||||||
@@ -125,8 +151,10 @@ if(UNIX)
|
|||||||
message("-- Using system's cpu_features")
|
message("-- Using system's cpu_features")
|
||||||
target_link_libraries(mayaqua PRIVATE cpu_features)
|
target_link_libraries(mayaqua PRIVATE cpu_features)
|
||||||
else()
|
else()
|
||||||
|
message("-- Using bundled cpu_features")
|
||||||
|
set(BUILD_SHARED_LIBS OFF)
|
||||||
|
set(CMAKE_POSITION_INDEPENDENT_CODE ON)
|
||||||
add_subdirectory(3rdparty/cpu_features)
|
add_subdirectory(3rdparty/cpu_features)
|
||||||
set_property(TARGET cpu_features PROPERTY POSITION_INDEPENDENT_CODE ON)
|
|
||||||
target_link_libraries(mayaqua PRIVATE cpu_features)
|
target_link_libraries(mayaqua PRIVATE cpu_features)
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
|
|||||||
@@ -4462,9 +4462,13 @@ bool IsAesNiSupported()
|
|||||||
|
|
||||||
// Unfortunately OpenSSL doesn't provide a function to do it
|
// Unfortunately OpenSSL doesn't provide a function to do it
|
||||||
#ifdef _MSC_VER
|
#ifdef _MSC_VER
|
||||||
|
#if defined(_M_X64) || defined(_M_IX86)
|
||||||
int regs[4]; // EAX, EBX, ECX, EDX
|
int regs[4]; // EAX, EBX, ECX, EDX
|
||||||
__cpuid(regs, 1);
|
__cpuid(regs, 1);
|
||||||
supported = (regs[2] >> 25) & 1;
|
supported = (regs[2] >> 25) & 1;
|
||||||
|
#elif defined(_M_ARM64)
|
||||||
|
return IsProcessorFeaturePresent(PF_ARM_V8_CRYPTO_INSTRUCTIONS_AVAILABLE);
|
||||||
|
#endif
|
||||||
#else // _MSC_VER
|
#else // _MSC_VER
|
||||||
#if defined(CPU_FEATURES_ARCH_X86)
|
#if defined(CPU_FEATURES_ARCH_X86)
|
||||||
const X86Features features = GetX86Info().features;
|
const X86Features features = GetX86Info().features;
|
||||||
@@ -4757,7 +4761,7 @@ static void MY_SHA0_Transform(MY_SHA0_CTX* ctx) {
|
|||||||
UCHAR* p = ctx->buf;
|
UCHAR* p = ctx->buf;
|
||||||
int t;
|
int t;
|
||||||
for(t = 0; t < 16; ++t) {
|
for(t = 0; t < 16; ++t) {
|
||||||
UINT tmp = *p++ << 24;
|
UINT tmp = (UINT)*p++ << 24;
|
||||||
tmp |= *p++ << 16;
|
tmp |= *p++ << 16;
|
||||||
tmp |= *p++ << 8;
|
tmp |= *p++ << 8;
|
||||||
tmp |= *p++;
|
tmp |= *p++;
|
||||||
|
|||||||
+26
-2
@@ -1207,12 +1207,14 @@ PACK *HttpClientRecv(SOCK *s)
|
|||||||
UINT size;
|
UINT size;
|
||||||
UCHAR *tmp;
|
UCHAR *tmp;
|
||||||
HTTP_VALUE *v;
|
HTTP_VALUE *v;
|
||||||
|
UINT num_noop = 0;
|
||||||
// Validate arguments
|
// Validate arguments
|
||||||
if (s == NULL)
|
if (s == NULL)
|
||||||
{
|
{
|
||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
START:
|
||||||
h = RecvHttpHeader(s);
|
h = RecvHttpHeader(s);
|
||||||
if (h == NULL)
|
if (h == NULL)
|
||||||
{
|
{
|
||||||
@@ -1257,6 +1259,22 @@ PACK *HttpClientRecv(SOCK *s)
|
|||||||
p = BufToPack(b);
|
p = BufToPack(b);
|
||||||
FreeBuf(b);
|
FreeBuf(b);
|
||||||
|
|
||||||
|
// Client shouldn't receive a noop other than NOOP_IGNORE
|
||||||
|
// because it can't respond without a full new HTTP request
|
||||||
|
UINT noop = PackGetInt(p, "noop");
|
||||||
|
if (noop == NOOP_IGNORE) {
|
||||||
|
Debug("recv: noop ignore\n");
|
||||||
|
FreePack(p);
|
||||||
|
|
||||||
|
num_noop++;
|
||||||
|
|
||||||
|
if (num_noop > MAX_NOOP_PER_SESSION)
|
||||||
|
{
|
||||||
|
return NULL;
|
||||||
|
}
|
||||||
|
|
||||||
|
goto START;
|
||||||
|
}
|
||||||
return p;
|
return p;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -1365,13 +1383,14 @@ START:
|
|||||||
FreeBuf(b);
|
FreeBuf(b);
|
||||||
|
|
||||||
// Determine whether it's a NOOP
|
// Determine whether it's a NOOP
|
||||||
if (PackGetInt(p, "noop") != 0)
|
UINT noop = PackGetInt(p, "noop");
|
||||||
|
if (noop == NOOP)
|
||||||
{
|
{
|
||||||
Debug("recv: noop\n");
|
Debug("recv: noop\n");
|
||||||
FreePack(p);
|
FreePack(p);
|
||||||
|
|
||||||
p = PackError(0);
|
p = PackError(0);
|
||||||
PackAddInt(p, "noop", 1);
|
PackAddInt(p, "noop", NOOP_IGNORE);
|
||||||
if (HttpServerSend(s, p) == false)
|
if (HttpServerSend(s, p) == false)
|
||||||
{
|
{
|
||||||
FreePack(p);
|
FreePack(p);
|
||||||
@@ -1387,6 +1406,11 @@ START:
|
|||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
goto START;
|
||||||
|
} else if (noop == NOOP_IGNORE) {
|
||||||
|
Debug("recv: noop ignore\n");
|
||||||
|
FreePack(p);
|
||||||
|
|
||||||
goto START;
|
goto START;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -63,7 +63,7 @@ static int ydays[] =
|
|||||||
0, 31, 59, 90, 120, 151, 181, 212, 243, 273, 304, 334, 365
|
0, 31, 59, 90, 120, 151, 181, 212, 243, 273, 304, 334, 365
|
||||||
};
|
};
|
||||||
|
|
||||||
static UINT current_num_thread = 0;
|
static COUNTER *current_num_thread = NULL;
|
||||||
static UINT cached_number_of_cpus = 0;
|
static UINT cached_number_of_cpus = 0;
|
||||||
|
|
||||||
|
|
||||||
@@ -776,6 +776,7 @@ void InitThreading()
|
|||||||
{
|
{
|
||||||
thread_pool = NewSk();
|
thread_pool = NewSk();
|
||||||
thread_count = NewCounter();
|
thread_count = NewCounter();
|
||||||
|
current_num_thread = NewCounter();
|
||||||
}
|
}
|
||||||
|
|
||||||
// Release of thread pool
|
// Release of thread pool
|
||||||
@@ -821,6 +822,9 @@ void FreeThreading()
|
|||||||
|
|
||||||
DeleteCounter(thread_count);
|
DeleteCounter(thread_count);
|
||||||
thread_count = NULL;
|
thread_count = NULL;
|
||||||
|
|
||||||
|
DeleteCounter(current_num_thread);
|
||||||
|
current_num_thread = NULL;
|
||||||
}
|
}
|
||||||
|
|
||||||
// Thread pool procedure
|
// Thread pool procedure
|
||||||
@@ -1028,9 +1032,9 @@ THREAD *NewThreadNamed(THREAD_PROC *thread_proc, void *param, char *name)
|
|||||||
|
|
||||||
Wait(pd->InitFinishEvent, INFINITE);
|
Wait(pd->InitFinishEvent, INFINITE);
|
||||||
|
|
||||||
current_num_thread++;
|
Inc(current_num_thread);
|
||||||
|
|
||||||
// Debug("current_num_thread = %u\n", current_num_thread);
|
// Debug("current_num_thread = %u\n", Count(current_num_thread));
|
||||||
|
|
||||||
return ret;
|
return ret;
|
||||||
}
|
}
|
||||||
@@ -1055,8 +1059,8 @@ void CleanupThread(THREAD *t)
|
|||||||
|
|
||||||
Free(t);
|
Free(t);
|
||||||
|
|
||||||
current_num_thread--;
|
Dec(current_num_thread);
|
||||||
//Debug("current_num_thread = %u\n", current_num_thread);
|
//Debug("current_num_thread = %u\n", Count(current_num_thread));
|
||||||
}
|
}
|
||||||
|
|
||||||
// Release thread (pool)
|
// Release thread (pool)
|
||||||
|
|||||||
+16
-1
@@ -72,11 +72,26 @@ int PASCAL WinMain(HINSTANCE hInst, HINSTANCE hPrev, char *CmdLine, int CmdShow)
|
|||||||
|
|
||||||
// Compiler dependent
|
// Compiler dependent
|
||||||
#ifndef OS_WIN32
|
#ifndef OS_WIN32
|
||||||
// Gcc compiler
|
// GCC or Clang compiler
|
||||||
#define GCC_PACKED __attribute__ ((__packed__))
|
#define GCC_PACKED __attribute__ ((__packed__))
|
||||||
|
// Clang compiler
|
||||||
|
#if defined(__has_feature)
|
||||||
|
#if __has_feature(thread_sanitizer)
|
||||||
|
#define ATTRIBUTE_NO_TSAN __attribute__((no_sanitize("thread")))
|
||||||
|
#endif // __has_feature(thread_sanitizer)
|
||||||
|
#endif // __has_feature
|
||||||
|
// GCC compiler
|
||||||
|
#if defined(__SANITIZE_THREAD__) && !defined(ATTRIBUTE_NO_TSAN)
|
||||||
|
#define ATTRIBUTE_NO_TSAN __attribute__((no_sanitize("thread")))
|
||||||
|
#endif // __SANITIZE_THREAD__
|
||||||
|
// Other or older Clang/GCC compiler
|
||||||
|
#ifndef ATTRIBUTE_NO_TSAN
|
||||||
|
#define ATTRIBUTE_NO_TSAN
|
||||||
|
#endif // ATTRIBUTE_NO_TSAN
|
||||||
#else // OS_WIN32
|
#else // OS_WIN32
|
||||||
// VC++ compiler
|
// VC++ compiler
|
||||||
#define GCC_PACKED
|
#define GCC_PACKED
|
||||||
|
#define ATTRIBUTE_NO_TSAN
|
||||||
#endif // OS_WIN32
|
#endif // OS_WIN32
|
||||||
|
|
||||||
// Macro that displays the current file name and line number
|
// Macro that displays the current file name and line number
|
||||||
|
|||||||
@@ -881,8 +881,6 @@ struct SSL_VERIFY_OPTION
|
|||||||
X *SavedCert; // Saved server certificate
|
X *SavedCert; // Saved server certificate
|
||||||
};
|
};
|
||||||
|
|
||||||
#define SSL_DEFAULT_CONNECT_TIMEOUT (15 * 1000) // SSL default timeout
|
|
||||||
|
|
||||||
// Header for TCP Pair
|
// Header for TCP Pair
|
||||||
struct TCP_PAIR_HEADER
|
struct TCP_PAIR_HEADER
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -38,6 +38,8 @@
|
|||||||
|
|
||||||
// The number of allowable NOOP
|
// The number of allowable NOOP
|
||||||
#define MAX_NOOP_PER_SESSION 30
|
#define MAX_NOOP_PER_SESSION 30
|
||||||
|
#define NOOP 1
|
||||||
|
#define NOOP_IGNORE 2 // A noop, but don't send a response noop
|
||||||
|
|
||||||
// VALUE object
|
// VALUE object
|
||||||
struct VALUE
|
struct VALUE
|
||||||
|
|||||||
@@ -470,6 +470,7 @@ LIST *LoadLangList()
|
|||||||
b = ReadDump(filename);
|
b = ReadDump(filename);
|
||||||
if (b == NULL)
|
if (b == NULL)
|
||||||
{
|
{
|
||||||
|
FreeLangList(o);
|
||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -651,6 +651,15 @@ struct IKE_HEADER
|
|||||||
#define IKE_EXCHANGE_TYPE_INFORMATION 5 // Information exchange
|
#define IKE_EXCHANGE_TYPE_INFORMATION 5 // Information exchange
|
||||||
#define IKE_EXCHANGE_TYPE_QUICK 32 // Quick mode
|
#define IKE_EXCHANGE_TYPE_QUICK 32 // Quick mode
|
||||||
|
|
||||||
|
// IKEv2 version identifier (in the Version field of IKE_HEADER)
|
||||||
|
#define IKEv2_VERSION 0x20 // 2.0
|
||||||
|
|
||||||
|
// IKEv2 exchange types (RFC 7296)
|
||||||
|
#define IKEv2_EXCHANGE_IKE_SA_INIT 34
|
||||||
|
#define IKEv2_EXCHANGE_IKE_AUTH 35
|
||||||
|
#define IKEv2_EXCHANGE_CREATE_CHILD_SA 36
|
||||||
|
#define IKEv2_EXCHANGE_INFORMATIONAL 37
|
||||||
|
|
||||||
// DHCPv4 data
|
// DHCPv4 data
|
||||||
struct DHCPV4_DATA
|
struct DHCPV4_DATA
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -2140,9 +2140,13 @@ void UnixMemoryFree(void *addr)
|
|||||||
// SIGCHLD handler
|
// SIGCHLD handler
|
||||||
void UnixSigChldHandler(int sig)
|
void UnixSigChldHandler(int sig)
|
||||||
{
|
{
|
||||||
|
int old_errno = errno;
|
||||||
|
|
||||||
// Recall the zombie processes
|
// Recall the zombie processes
|
||||||
while (waitpid(-1, NULL, WNOHANG) > 0);
|
while (waitpid(-1, NULL, WNOHANG) > 0);
|
||||||
signal(SIGCHLD, UnixSigChldHandler);
|
signal(SIGCHLD, UnixSigChldHandler);
|
||||||
|
|
||||||
|
errno = old_errno;
|
||||||
}
|
}
|
||||||
|
|
||||||
// Disable core dump
|
// Disable core dump
|
||||||
|
|||||||
+2
-1
@@ -5,7 +5,8 @@
|
|||||||
// NDIS6.c
|
// NDIS6.c
|
||||||
// Windows NDIS 6.2 Routine
|
// Windows NDIS 6.2 Routine
|
||||||
|
|
||||||
#include <GlobalConst.h>
|
//#include <GlobalConst.h>
|
||||||
|
#include "GlobalConst.h"
|
||||||
|
|
||||||
#define NEO_DEVICE_DRIVER
|
#define NEO_DEVICE_DRIVER
|
||||||
|
|
||||||
|
|||||||
+24
-12
@@ -12,22 +12,34 @@
|
|||||||
#ifndef CPU_64
|
#ifndef CPU_64
|
||||||
#define _X86_
|
#define _X86_
|
||||||
#else // CPU_64
|
#else // CPU_64
|
||||||
#ifndef NEO_IA64
|
#ifdef CPU_ARM64
|
||||||
#define _AMD64_
|
//#define _ARM64_
|
||||||
#define AMD64
|
//#define ARM64
|
||||||
#else // NEO_IA64
|
#elif defined(NEO_IA64)
|
||||||
#define _IA64_
|
#define _IA64_
|
||||||
#define IA64
|
#define IA64
|
||||||
#endif // NEO_IA64
|
#else
|
||||||
|
#define _AMD64_
|
||||||
|
#define AMD64
|
||||||
|
#endif
|
||||||
#endif // CPU_64
|
#endif // CPU_64
|
||||||
#define NDIS_MINIPORT_DRIVER
|
#define NDIS_MINIPORT_DRIVER
|
||||||
// NDIS 6.2
|
#ifdef CPU_ARM64
|
||||||
#define NDIS620_MINIPORT
|
#define NDIS640_MINIPORT
|
||||||
#define NDIS_SUPPORT_NDIS61 1
|
#define NDIS_MINIPORT_MINIMUM_MAJOR_VERSION 6
|
||||||
#define NDIS_SUPPORT_NDIS620 1
|
#define NDIS_MINIPORT_MINIMUM_MINOR_VERSION 40
|
||||||
#define NEO_NDIS_MAJOR_VERSION 6
|
#define NEO_NDIS_MAJOR_VERSION 6
|
||||||
#define NEO_NDIS_MINOR_VERSION 20
|
#define NEO_NDIS_MINOR_VERSION 40
|
||||||
#define NDIS_WDM 1
|
#else
|
||||||
|
// NDIS 6.2
|
||||||
|
#define NDIS620_MINIPORT
|
||||||
|
#define NDIS_SUPPORT_NDIS61 1
|
||||||
|
#define NDIS_SUPPORT_NDIS620 1
|
||||||
|
#define NEO_NDIS_MAJOR_VERSION 6
|
||||||
|
#define NEO_NDIS_MINOR_VERSION 20
|
||||||
|
#define NDIS_WDM 1
|
||||||
|
#endif
|
||||||
|
|
||||||
|
|
||||||
#include <wdm.h>
|
#include <wdm.h>
|
||||||
#include <ndis.h>
|
#include <ndis.h>
|
||||||
|
|||||||
@@ -0,0 +1,107 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<Project DefaultTargets="Build" ToolsVersion="Current" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||||
|
<ItemGroup Label="ProjectConfigurations">
|
||||||
|
<ProjectConfiguration Include="Release|ARM64">
|
||||||
|
<Configuration>Release</Configuration>
|
||||||
|
<Platform>ARM64</Platform>
|
||||||
|
</ProjectConfiguration>
|
||||||
|
</ItemGroup>
|
||||||
|
<PropertyGroup Label="Globals">
|
||||||
|
<VCProjectVersion>17.0</VCProjectVersion>
|
||||||
|
<ProjectGuid>{F7679B65-2FEC-469A-8BAC-B07BF4439422}</ProjectGuid>
|
||||||
|
<RootNamespace>Neo6</RootNamespace>
|
||||||
|
<Keyword>Win32Proj</Keyword>
|
||||||
|
</PropertyGroup>
|
||||||
|
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
|
||||||
|
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|ARM64'" Label="Configuration">
|
||||||
|
<TargetVersion>Windows10</TargetVersion>
|
||||||
|
<UseDebugLibraries>false</UseDebugLibraries>
|
||||||
|
<PlatformToolset>WindowsKernelModeDriver10.0</PlatformToolset>
|
||||||
|
<ConfigurationType>Driver</ConfigurationType>
|
||||||
|
<DriverType>KMDF</DriverType>
|
||||||
|
<DriverTargetPlatform>Universal</DriverTargetPlatform>
|
||||||
|
<TargetName>Neo6_arm64_unsigned</TargetName>
|
||||||
|
<TargetExt>.sys</TargetExt>
|
||||||
|
</PropertyGroup>
|
||||||
|
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
|
||||||
|
<ImportGroup Label="ExtensionSettings">
|
||||||
|
</ImportGroup>
|
||||||
|
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="PropertySheets">
|
||||||
|
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||||
|
</ImportGroup>
|
||||||
|
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="PropertySheets">
|
||||||
|
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||||
|
</ImportGroup>
|
||||||
|
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release|ARM64'" Label="PropertySheets">
|
||||||
|
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||||
|
</ImportGroup>
|
||||||
|
<PropertyGroup Label="UserMacros" />
|
||||||
|
<PropertyGroup>
|
||||||
|
<_ProjectFileVersion>17.0.36310.24</_ProjectFileVersion>
|
||||||
|
</PropertyGroup>
|
||||||
|
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|ARM64'">
|
||||||
|
<IntDir>$(Platform)_$(Configuration)\</IntDir>
|
||||||
|
<IgnoreImportLibrary>true</IgnoreImportLibrary>
|
||||||
|
<LinkIncremental>false</LinkIncremental>
|
||||||
|
<GenerateManifest>false</GenerateManifest>
|
||||||
|
</PropertyGroup>
|
||||||
|
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|ARM64'">
|
||||||
|
<Midl />
|
||||||
|
<ClCompile>
|
||||||
|
<Optimization>MaxSpeed</Optimization>
|
||||||
|
<InlineFunctionExpansion>Default</InlineFunctionExpansion>
|
||||||
|
<IntrinsicFunctions>false</IntrinsicFunctions>
|
||||||
|
<FavorSizeOrSpeed>Neither</FavorSizeOrSpeed>
|
||||||
|
<TreatWarningAsError>false</TreatWarningAsError>
|
||||||
|
<AdditionalIncludeDirectories>$(ProjectDir)\..\;$(SolutionDir);%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||||
|
<PreprocessorDefinitions>ARM64;_ARM64_;CPU_64;WIN32;CPU_ARM64;NDEBUG;_WINDOWS;_USRDLL;NEO_EXPORTS;VPN_SPEED;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||||
|
<StringPooling>false</StringPooling>
|
||||||
|
<ExceptionHandling>
|
||||||
|
</ExceptionHandling>
|
||||||
|
<RuntimeLibrary>MultiThreaded</RuntimeLibrary>
|
||||||
|
<StructMemberAlignment>8Bytes</StructMemberAlignment>
|
||||||
|
<BufferSecurityCheck>false</BufferSecurityCheck>
|
||||||
|
<FunctionLevelLinking>false</FunctionLevelLinking>
|
||||||
|
<PrecompiledHeader>
|
||||||
|
</PrecompiledHeader>
|
||||||
|
<WarningLevel>Level3</WarningLevel>
|
||||||
|
<DebugInformationFormat>ProgramDatabase</DebugInformationFormat>
|
||||||
|
|
||||||
|
<CompileAs>CompileAsC</CompileAs>
|
||||||
|
<DisableSpecificWarnings>4996;%(DisableSpecificWarnings)</DisableSpecificWarnings>
|
||||||
|
</ClCompile>
|
||||||
|
<!-- <PreLinkEvent>
|
||||||
|
<Command>$(SolutionDir)bin\BuildUtil.exe /CMD:GenerateVersionResource "$(TargetPath)" /OUT:"$(SolutionDir)tmp\VersionResources\$(ProjectName)_$(Platform).res" /PRODUCT:"SoftEther VPN"</Command>
|
||||||
|
</PreLinkEvent> -->
|
||||||
|
<ProjectReference>
|
||||||
|
<LinkLibraryDependencies>false</LinkLibraryDependencies>
|
||||||
|
</ProjectReference>
|
||||||
|
<Link>
|
||||||
|
<OutputFile>$(OutDir)Neo6_arm64_unsigned.sys</OutputFile>
|
||||||
|
<AdditionalLibraryDirectories>%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
||||||
|
<AdditionalDependencies>ntoskrnl.lib;wdm.lib;hal.lib;;ucrt.lib;ndis.lib;wdmsec.lib;ntdll.lib;Kernel32.lib;fwpkclnt.lib;libcntpr.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||||
|
<!-- <ImportLibrary>$(SolutionDir)tmp\lib\$(Platform)_$(Configuration)\$(ProjectName).lib</ImportLibrary> -->
|
||||||
|
<TargetMachine>MachineARM64</TargetMachine>
|
||||||
|
</Link>
|
||||||
|
<!-- <PostBuildEvent>
|
||||||
|
<Command>$(SolutionDir)bin\BuildUtil.exe /CMD:SignCode "$(TargetPath)" /DEST:"$(TargetDir)Neo6_ARM64.sys" /COMMENT:"VPN Software" /KERNEL:yes /CERTID:0 /SHAMODE:0
|
||||||
|
$(SolutionDir)bin\BuildUtil.exe /CMD:SignCode "$(TargetPath)" /DEST:"$(TargetDir)Neo6_ARM64_win10.sys" /COMMENT:"VPN Software" /KERNEL:yes /CERTID:0 /SHAMODE:2
|
||||||
|
</Command>
|
||||||
|
</PostBuildEvent> -->
|
||||||
|
</ItemDefinitionGroup>
|
||||||
|
<ItemGroup>
|
||||||
|
<ClCompile Include="NDIS6.c" />
|
||||||
|
<ClCompile Include="Neo6.c" />
|
||||||
|
</ItemGroup>
|
||||||
|
<ItemGroup>
|
||||||
|
<ClInclude Include="NDIS6.h" />
|
||||||
|
<ClInclude Include="Neo6.h" />
|
||||||
|
<ClInclude Include="resource.h" />
|
||||||
|
</ItemGroup>
|
||||||
|
<ItemGroup>
|
||||||
|
<ResourceCompile Include="Neo6.rc" />
|
||||||
|
</ItemGroup>
|
||||||
|
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
|
||||||
|
<ImportGroup Label="ExtensionTargets">
|
||||||
|
</ImportGroup>
|
||||||
|
</Project>
|
||||||
@@ -0,0 +1,114 @@
|
|||||||
|
; VPN Client Device Driver for Windows 2000 and Greater
|
||||||
|
;
|
||||||
|
; Copyright (c) SoftEther Corporation. All Rights Reserved.
|
||||||
|
; http://www.softether.co.jp/
|
||||||
|
;
|
||||||
|
; BUILD 9658
|
||||||
|
|
||||||
|
[Version]
|
||||||
|
Signature = "$Windows NT$"
|
||||||
|
Class = Net
|
||||||
|
ClassGUID = {4D36E972-E325-11CE-BFC1-08002BE10318}
|
||||||
|
Provider = %CompanyName%
|
||||||
|
DriverVer = 02/04/2018, 4.25.0.9658
|
||||||
|
CatalogFile.NT = Neo6_arm64_VPN.cat
|
||||||
|
|
||||||
|
[Manufacturer]
|
||||||
|
%CompanyName% = SoftEther, NTarm64
|
||||||
|
|
||||||
|
[SourceDisksNames]
|
||||||
|
1=%DiskDescription%, "", ,
|
||||||
|
|
||||||
|
[SourceDisksFiles]
|
||||||
|
Neo6_arm64_VPN.sys = 1
|
||||||
|
|
||||||
|
[DestinationDirs]
|
||||||
|
DefaultDestDir = 12
|
||||||
|
Neo.CopyFiles.Sys = 12
|
||||||
|
|
||||||
|
[Neo.CopyFiles.Sys]
|
||||||
|
Neo6_arm64_VPN.sys, , , 2
|
||||||
|
|
||||||
|
[SoftEther.NTarm64]
|
||||||
|
%NeoAdapter.DeviceDesc% = NeoAdapter.Install, NeoAdapter_VPN
|
||||||
|
|
||||||
|
[NeoAdapter.Install]
|
||||||
|
Characteristics = 0x1
|
||||||
|
AddReg = Neo.Reg, NeoAdapter.Ndi
|
||||||
|
CopyFiles = Neo.CopyFiles.Sys
|
||||||
|
*IfType = 53
|
||||||
|
*MediaType = 0
|
||||||
|
*PhysicalMediaType = 0
|
||||||
|
|
||||||
|
[NeoAdapter.Install.Services]
|
||||||
|
AddService = %Neo.Service.Name%, 2, Neo.Service, Neo.EventLog, , %Neo, EventLog.Name%
|
||||||
|
|
||||||
|
[NeoAdapter.Ndi]
|
||||||
|
HKR, , NetworkAddress, 0, %DefaultAddress%
|
||||||
|
HKR, Ndi, DeviceID, , "NeoAdapter_VPN"
|
||||||
|
HKR, , DevLoader, , ndis
|
||||||
|
HKR, , DeviceVxDs, , Neo6_arm64_VPN.sys
|
||||||
|
HKR, NDIS, LogDriverName, , "Neo_VPN"
|
||||||
|
HKR, NDIS, MajorNdisVersion, 1, 5
|
||||||
|
HKR, NDIS, MinorNdisVersion, 1, 0
|
||||||
|
HKR, Ndi\Interfaces, DefUpper, , "ndis5"
|
||||||
|
HKR, Ndi\Interfaces, UpperRange, , "ndis5"
|
||||||
|
HKR, Ndi\Interfaces, LowerRange, , "ethernet"
|
||||||
|
HKR, Ndi\Interfaces, DefLower, , "ethernet"
|
||||||
|
HKR, Ndi\Install, ndis5, , "Neo.CopyFiles.Sys"
|
||||||
|
HKR, Ndi\Params\NetworkAddress, ParamDesc, 0, %NetworkAddress%
|
||||||
|
HKR, Ndi\Params\NetworkAddress, type, 0, "edit"
|
||||||
|
HKR, Ndi\Params\NetworkAddress, LimitText, 0, "12"
|
||||||
|
HKR, Ndi\Params\NetworkAddress, UpperCase, 0, "1"
|
||||||
|
HKR, Ndi\Params\NetworkAddress, default, 0, %DefaultAddress%
|
||||||
|
HKR, Ndi\Params\NetworkAddress, optional, 0, "0"
|
||||||
|
HKR, Ndi\Params\MaxSpeed, ParamDesc, 0, %MaxSpeed%
|
||||||
|
HKR, Ndi\Params\MaxSpeed, type, 0, "int"
|
||||||
|
HKR, Ndi\Params\MaxSpeed, default, 0, "100"
|
||||||
|
HKR, Ndi\Params\MaxSpeed, min, 0, "0"
|
||||||
|
HKR, Ndi\Params\MaxSpeed, max, 0, "2000"
|
||||||
|
HKR, Ndi\Params\MaxSpeed, step, 0, "1"
|
||||||
|
HKR, Ndi\Params\MaxSpeed, Base, 0, "10"
|
||||||
|
HKR, Ndi\Params\KeepLink, ParamDesc, 0, %KeepLink%
|
||||||
|
HKR, Ndi\Params\KeepLink, type, 0, "enum"
|
||||||
|
HKR, Ndi\Params\KeepLink\enum, "1", 0, %On%
|
||||||
|
HKR, Ndi\Params\KeepLink\enum, "0", 0, %Off%
|
||||||
|
HKR, Ndi\Params\KeepLink, default, 0, "0"
|
||||||
|
|
||||||
|
|
||||||
|
[Neo.Service]
|
||||||
|
DisplayName = %Neo.Service.DispName%
|
||||||
|
Description = %Neo.Service.Desc%
|
||||||
|
ServiceType = 1
|
||||||
|
StartType = 3
|
||||||
|
ErrorControl = 1
|
||||||
|
ServiceBinary = %12%\Neo6_arm64_VPN.sys
|
||||||
|
LoadOrderGroup = NDIS
|
||||||
|
|
||||||
|
[Neo.Reg]
|
||||||
|
HKR, Ndi, Service, 0, Neo.Service.Name
|
||||||
|
HKR, Ndi\Interfaces, LowerRange, 0, "ethernet"
|
||||||
|
HKR, Ndi\Interfaces, UpperRange, 0, "ndis5"
|
||||||
|
|
||||||
|
[Neo.EventLog]
|
||||||
|
HKR, , EventMessageFile, 0x00020000, "%11%\IoLogMsg.dll;%12%\Neo6_arm64_VPN.sys"
|
||||||
|
HKR, , TypesSupported, 0x00010001, 7
|
||||||
|
|
||||||
|
[Strings]
|
||||||
|
CompanyName = "SoftEther Corporation"
|
||||||
|
DiskDescription = "VPN Client Device Driver Install Disk"
|
||||||
|
Neo.Service.Name = "Neo_VPN"
|
||||||
|
Neo.Service.DispName = "VPN Client Device Driver - VPN"
|
||||||
|
Neo.Service.Desc = "VPN Client Adapter - VPN"
|
||||||
|
NeoAdapter.DeviceDesc = "VPN Client Adapter - VPN"
|
||||||
|
Neo.EventLog.Name = "Neo"
|
||||||
|
NetworkAddress = "MAC Address"
|
||||||
|
DefaultAddress = "000001000001"
|
||||||
|
MaxSpeed = "Indicate Speed (Mbps)"
|
||||||
|
KeepLink = "Keep Link"
|
||||||
|
On = "On"
|
||||||
|
Off = "Off"
|
||||||
|
|
||||||
|
|
||||||
|
; Auto Generated 20180205_163621.454
|
||||||
|
|
||||||
Binary file not shown.
@@ -10,3 +10,4 @@
|
|||||||
5 ru Russian Русский 1049 ru
|
5 ru Russian Русский 1049 ru
|
||||||
6 pt_br Portuguese-Brazil Português-Brasil 1046 pt_br
|
6 pt_br Portuguese-Brazil Português-Brasil 1046 pt_br
|
||||||
7 id Indonesian Bahasa 1057 id
|
7 id Indonesian Bahasa 1057 id
|
||||||
|
8 tr Turkish Türkçe 1055 tr
|
||||||
|
|||||||
@@ -3,4 +3,4 @@
|
|||||||
|
|
||||||
# 番号 識別子 英語表記 ローカル表記 Windowsロケール番号 UNIXロケール文字一覧
|
# 番号 識別子 英語表記 ローカル表記 Windowsロケール番号 UNIXロケール文字一覧
|
||||||
1 en English English 1033 en,us,c
|
1 en English English 1033 en,us,c
|
||||||
|
8 tr Turkish Türkçe 1055 tr
|
||||||
|
|||||||
@@ -200,7 +200,7 @@ ERR_133 The specified Dynamic DNS hostname is already used. Please change th
|
|||||||
ERR_134 The specified Dynamic DNS hostname has an invalid characters. Please change the hostname.
|
ERR_134 The specified Dynamic DNS hostname has an invalid characters. Please change the hostname.
|
||||||
ERR_135 The length of the specified Dynamic DNS hostname is too long. A hostname must be equal or shorter than 31 letters.
|
ERR_135 The length of the specified Dynamic DNS hostname is too long. A hostname must be equal or shorter than 31 letters.
|
||||||
ERR_136 The Dynamic DNS hostname is not specified.
|
ERR_136 The Dynamic DNS hostname is not specified.
|
||||||
ERR_137 The length of the specified Dynamic DNS hostname is too long. A hostname must be equal of longer than 3 letters.
|
ERR_137 The length of the specified Dynamic DNS hostname is too short. A hostname must be equal or longer than 3 letters.
|
||||||
ERR_138 The password of the specified user in the Virtual Hub must be reset before using MS-CHAP v2 authentication. Please ask the administrator of the VPN Server to reset the password by the VPN Server Manager or vpncmd which internal version is 4.0 or greater. Or you can change the password with VPN Client by yourself.
|
ERR_138 The password of the specified user in the Virtual Hub must be reset before using MS-CHAP v2 authentication. Please ask the administrator of the VPN Server to reset the password by the VPN Server Manager or vpncmd which internal version is 4.0 or greater. Or you can change the password with VPN Client by yourself.
|
||||||
ERR_139 The connection to the Dynamic DNS server has been disconnected.
|
ERR_139 The connection to the Dynamic DNS server has been disconnected.
|
||||||
ERR_140 Failed to initialize the ICMP (Ping) protocol. The process of the VPN Server might be running in a normal-user privileges. In such case, run the VPN Server as a system service. (in Linux / UNIX, run it in root privileges.)
|
ERR_140 Failed to initialize the ICMP (Ping) protocol. The process of the VPN Server might be running in a normal-user privileges. In such case, run the VPN Server as a system service. (in Linux / UNIX, run it in root privileges.)
|
||||||
@@ -7422,3 +7422,4 @@ SW_LINK_NAME_LANGUAGE_COMMENT Change the display language setting of %s.
|
|||||||
|
|
||||||
SW_LINK_NAME_DEBUG Debugging Information Collecting Tool
|
SW_LINK_NAME_DEBUG Debugging Information Collecting Tool
|
||||||
SW_LINK_NAME_DEBUG_COMMENT Collects debugging information of SoftEther VPN. Use this tool only if your support staff asks you to do so.
|
SW_LINK_NAME_DEBUG_COMMENT Collects debugging information of SoftEther VPN. Use this tool only if your support staff asks you to do so.
|
||||||
|
|
||||||
|
|||||||
File diff suppressed because it is too large
Load Diff
+1206
-601
File diff suppressed because it is too large
Load Diff
@@ -0,0 +1,28 @@
|
|||||||
|
# This file contains suppressions for Thread Sanitizer.
|
||||||
|
# For the specification, refer to: https://github.com/google/sanitizers/wiki/threadsanitizersuppressions
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
## Set/Wait
|
||||||
|
# This provides synchronization equivalent to a lock, but Thread Sanitizer cannot recognize it.
|
||||||
|
|
||||||
|
# Thread Sanitizer reports data race on Halt in TK64.
|
||||||
|
# https://github.com/SoftEtherVPN/SoftEtherVPN/pull/2221
|
||||||
|
race_top:FreeTick64
|
||||||
|
|
||||||
|
# Thread Sanitizer reports data races on Finished and NoDelayFlag in CONNECT_SERIAL_PARAM,
|
||||||
|
# shared between BindConnectThreadForIPv4, BindConnectThreadForIPv6, and BindConnectEx5.
|
||||||
|
# https://github.com/SoftEtherVPN/SoftEtherVPN/pull/2222
|
||||||
|
race_top:BindConnectThreadForIPv4
|
||||||
|
race_top:BindConnectThreadForIPv6
|
||||||
|
race_top:BindConnectEx5
|
||||||
|
|
||||||
|
|
||||||
|
## Manual PTHREAD_MUTEX_RECURSIVE
|
||||||
|
# The Lock/Unlock mechanism on Unix is a manual, hand-coded implementation of PTHREAD_MUTEX_RECURSIVE.
|
||||||
|
# We avoid using the PTHREAD_MUTEX_RECURSIVE directly because it exhibits critical bugs, such as deadlocks
|
||||||
|
# on certain older systems(Linux, Solaris, or macOS). While Thread Sanitizer will report data races,
|
||||||
|
# these warnings should be ignored as the logic has been carefully implemented to ensure thread safety.
|
||||||
|
# https://github.com/SoftEtherVPN/SoftEtherVPN/pull/2219
|
||||||
|
race_top:UnixLock
|
||||||
|
race_top:UnixUnlockEx
|
||||||
Reference in New Issue
Block a user