Skip to content

Bypass without a server: settings, the adapter and the rules (groundwork) - #11

Merged
limeflash merged 4 commits into
mainfrom
bypass-settings
Dec 2, 2026
Merged

limeflash merged 4 commits into
mainfrom
bypass-settings

Conversation

@limeflash

Copy link
Copy Markdown
Contributor

Groundwork for the mode that needs no server. Nothing changes for a VPN session.

  • Settings: mode (vpn | bypass, default vpn) and bypass_direct (default true). Settings.KillSwitchNow() replaces every read of kill_switch: in bypass the network is never held. The service start connects in bypass without a last_server; the network check does not take a bypass session for a tunnel.
  • Adapter: netcfg.Configure takes an empty server address and adds no route to it.
  • Rules: a bypass selection (no programs; rules saved before it read as an empty one), service:<id> collections whose domains come from a catalogue given by geo.Store.SetServices, the RuleBypass verdict (after block, direct and vpn; today's callers read it as no rule), routes.set takes bypass, routes.check answers bypass.

Not here yet, on purpose:

  • The engine has no bypass branch: with mode: bypass a connect is still a VPN one, without the kill switch. The window does not set the key. Not to be released before that branch lands.
  • Nobody gives the catalogue, so a service:<id> has no domains.
  • No flow gets a strategy, so routes.check says bypass: never.

Checked: go vet ./... and go test ./... on Windows, go vet ./internal/... for darwin/arm64.

🤖 Generated with Claude Code

limeflash and others added 4 commits December 2, 2026 22:38
Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
…s.check says of the bypass

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@limeflash
limeflash merged commit b91dd36 into main Dec 2, 2026
5 of 6 checks passed
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.

1 participant