Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
22 commits
Select commit Hold shift + click to select a range
a700b6a
Add Windows support via wintun and in-process PPP engine
claude Mar 30, 2026
70b3c49
Add release workflow and Windows installer
claude Mar 30, 2026
a94dcfa
Fix Windows release workflow
claude Mar 30, 2026
ea62217
Fix MSVC build and runtime bugs for Windows support
hkirste Mar 30, 2026
162a324
Fix getopt_long to support GNU-style argument permutation
hkirste Mar 30, 2026
7d24ef5
Fix MinGW build and coding style issues
hkirste Mar 30, 2026
5f89419
Fix MinGW getline and ppp.c coding style
hkirste Mar 30, 2026
9d1ee89
Fix log_win.c for MinGW: use POSIX isatty/fileno
hkirste Mar 30, 2026
e1023fe
Fix coding style issues in ppp.c and ipv4_win.c
hkirste Mar 30, 2026
558ef81
Fix astyle coding style violations
hkirste Mar 30, 2026
a3d4948
Fix Linux kernel coding style violations
hkirste Mar 30, 2026
2d8857b
Remove macros with flow control to satisfy checkpatch
hkirste Mar 30, 2026
8ed1044
Fix stdin password reading when stdin is a pipe
hkirste Apr 2, 2026
22ffc56
Replace pthread_cancel with cooperative shutdown in io_win.c
hkirste Apr 2, 2026
3fc6e57
Fix split route installation on Windows
hkirste Apr 2, 2026
226cbaf
Fix tunnel_win.c: remove bogus GetAdapterLUID(NULL), store adapter ha…
hkirste Apr 2, 2026
7930195
Preserve structured exit codes from run_tunnel
hkirste Apr 2, 2026
fcbaf3d
Add structured JSON event stream and exit codes
hkirste Apr 2, 2026
ea460df
Fix split string warnings and add event.c to autotools build
hkirste Apr 2, 2026
fe3a063
Fix broken event_emit calls from string join
hkirste Apr 2, 2026
811a521
Fix event_emit: use snprintf buffer for long JSON fields
hkirste Apr 2, 2026
409de94
Typed event emitters: eliminate split string warnings
hkirste Apr 2, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
120 changes: 120 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,120 @@
---
name: Release

on:
push:
tags:
- 'v*'

permissions:
contents: write

jobs:
build-windows:
name: Build Windows Release
runs-on: windows-latest

defaults:
run:
shell: msys2 {0}

steps:
- name: Checkout Code
uses: actions/checkout@v6

- name: Setup MSYS2
uses: msys2/setup-msys2@v2
with:
msystem: MINGW64
update: true
install: >-
mingw-w64-x86_64-gcc
mingw-w64-x86_64-cmake
mingw-w64-x86_64-openssl
mingw-w64-x86_64-ninja
p7zip
wget

- name: Configure
run: |
mkdir build
cd build
cmake .. -G Ninja -DCMAKE_BUILD_TYPE=Release -DBUILD_TESTING=ON

- name: Build
run: |
cd build
ninja

- name: Download wintun
shell: pwsh
run: |
cd build
Invoke-WebRequest -Uri "https://www.wintun.net/builds/wintun-0.14.1.zip" -OutFile wintun.zip
Expand-Archive -Path wintun.zip -DestinationPath wintun
Copy-Item wintun/wintun/bin/amd64/wintun.dll .

- name: Collect Runtime DLLs
run: |
cd build
cp /mingw64/bin/libssl-*.dll . 2>/dev/null || true
cp /mingw64/bin/libcrypto-*.dll . 2>/dev/null || true
cp /mingw64/bin/libwinpthread-*.dll . 2>/dev/null || true
cp /mingw64/bin/libgcc_s_seh-*.dll . 2>/dev/null || true

- name: Run Tests
run: |
cd build
./test_ppp.exe || true

- name: Package
shell: pwsh
run: |
cd build
New-Item -ItemType Directory -Force -Path openfortivpn-windows-x64
Copy-Item openfortivpn.exe openfortivpn-windows-x64/
Copy-Item wintun.dll openfortivpn-windows-x64/ -ErrorAction SilentlyContinue
Copy-Item libssl-*.dll openfortivpn-windows-x64/ -ErrorAction SilentlyContinue
Copy-Item libcrypto-*.dll openfortivpn-windows-x64/ -ErrorAction SilentlyContinue
Copy-Item libwinpthread-*.dll openfortivpn-windows-x64/ -ErrorAction SilentlyContinue
Copy-Item libgcc_s_seh-*.dll openfortivpn-windows-x64/ -ErrorAction SilentlyContinue
Copy-Item ../README.md openfortivpn-windows-x64/
Compress-Archive -Path openfortivpn-windows-x64/* -DestinationPath openfortivpn-windows-x64.zip

- name: Upload Release
uses: softprops/action-gh-release@v2
with:
files: build/openfortivpn-windows-x64.zip
generate_release_notes: true

build-linux:
name: Build Linux Release
runs-on: ubuntu-latest

steps:
- name: Checkout Code
uses: actions/checkout@v6

- name: Install Dependencies
run: |
sudo apt-get update
sudo apt-get install -y pkg-config libssl-dev

- name: Build (autotools)
run: |
./autogen.sh
./configure --prefix=/usr --sysconfdir=/etc
make -j$(nproc)

- name: Package
run: |
mkdir -p openfortivpn-linux-x64
cp openfortivpn openfortivpn-linux-x64/
cp README.md openfortivpn-linux-x64/
tar czf openfortivpn-linux-x64.tar.gz openfortivpn-linux-x64/

- name: Upload Release
uses: softprops/action-gh-release@v2
with:
files: openfortivpn-linux-x64.tar.gz
generate_release_notes: true
99 changes: 99 additions & 0 deletions .github/workflows/windows.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,99 @@
---
name: Windows Build

on:
push:

pull_request:
branches:
- master

permissions:
contents: read

jobs:
build-mingw:
name: Build (MinGW-w64)
runs-on: windows-latest

defaults:
run:
shell: msys2 {0}

steps:
- name: Checkout Code
uses: actions/checkout@v6

- name: Setup MSYS2
uses: msys2/setup-msys2@v2
with:
msystem: MINGW64
update: true
install: >-
mingw-w64-x86_64-gcc
mingw-w64-x86_64-cmake
mingw-w64-x86_64-openssl
mingw-w64-x86_64-ninja
make

- name: Configure (CMake)
run: |
mkdir build
cd build
cmake .. -G Ninja -DBUILD_TESTING=ON

- name: Build
run: |
cd build
ninja

- name: Run PPP Unit Tests
run: |
cd build
ctest --output-on-failure

- name: Verify Binary
run: |
cd build
./openfortivpn.exe --version

build-cmake-linux:
name: Build (CMake on Linux)
runs-on: ubuntu-latest

steps:
- name: Checkout Code
uses: actions/checkout@v6

- name: Install Dependencies
run: |
sudo apt-get update
sudo apt-get install -y cmake libssl-dev pkg-config

- name: Configure (CMake)
run: |
mkdir build
cd build
cmake .. -DBUILD_TESTING=ON

- name: Build
run: |
cd build
make -j$(nproc)

- name: Run PPP Unit Tests
run: |
cd build
ctest --output-on-failure

- name: Verify Binary
run: |
cd build
./openfortivpn --version

- name: Verify Autotools Build Still Works
run: |
make distclean 2>/dev/null || true
autoreconf -fi
./configure --prefix=/usr --sysconfdir=/etc
make -j$(nproc)
Loading