Skip to content

fix: stale tun - #57

Merged
franklinkim merged 2 commits into
mainfrom
fix/stale-tun
Nov 18, 2026
Merged

franklinkim merged 2 commits into
mainfrom
fix/stale-tun

Conversation

@franklinkim

Copy link
Copy Markdown
Member

Description

Fix a stale VPN gateway route that blocks openconnect upstreams in tun mode on macOS.

Type of Change

  • 🐛 Bug fix
  • ✨ New feature
  • 💥 Breaking change
  • 📝 Documentation
  • ♻️ Refactoring
  • 🏃‍➡️ Performance
  • ✅ Tests
  • 🔐 Security
  • 🔧 Build/CI

Changes

  • Remove the leftover host route to the VPN gateway before openconnect starts.
  • Run this cleanup in dockprox. openconnect connects before any vpnc-script hook runs.
  • Add a narrow route line to the sudoers drop-in on macOS.
  • Update the tun install reference and the usage guide.
flowchart LR
    A[Start tun upstream] --> B[Remove leftover gateway host route]
    B --> C[Start openconnect]
Loading

Checklist

  • My code adheres to the coding and style guidelines of the project.
  • I have performed a self-review of my own code.
  • I have commented on my code, particularly in hard-to-understand areas.
  • I have made corresponding changes to the documentation.

Notes

  • Cause: vpnc-script removes the route only on a clean disconnect. A SIGKILL after the 3s stop timeout, or a crash, leaves it behind.
  • After a network change, the route points to a gateway that no longer exists.
  • Users must reinstall the sudoers drop-in: run dockprox tun install or use Settings > Install VPN sudoers.

@franklinkim franklinkim changed the title Fix/stale tun fix: stale tun Nov 17, 2026
@codecov-commenter

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 77.77778% with 12 lines in your changes missing coverage. Please review.
✅ Project coverage is 74.03%. Comparing base (977aaa1) to head (1f0c7f3).
⚠️ Report is 24 commits behind head on main.

Files with missing lines Patch % Lines
pkg/openconnect/client.go 79.16% 10 Missing ⚠️
internal/cli/tun.go 0.00% 2 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main      #57      +/-   ##
==========================================
+ Coverage   71.76%   74.03%   +2.27%     
==========================================
  Files          39       41       +2     
  Lines        1937     2261     +324     
==========================================
+ Hits         1390     1674     +284     
- Misses        547      587      +40     

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@franklinkim
franklinkim merged commit 5a7fbef into main Nov 18, 2026
4 checks passed
@franklinkim
franklinkim deleted the fix/stale-tun branch November 18, 2026 07:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants