14 Commits
Author SHA1 Message Date
cfal a150125c6b Add conditions syntax for routing rules (#278)
* feat(config): add conditions while preserving mask rules

Accept conditions alongside the existing masks and mask spellings, rejecting conflicting matching fields and flat-source combinations. Normalize all forms into the existing predicate engine.

Add explicit masks leaves for composed expressions and source groups. Keep simple address exports compact and serialize richer rules under conditions.

Cover round-trips, nested source discovery, controller payloads, warning-free compatibility, and routing across accepted and rejected reloads.

* docs(routing): explain conditions and compatible mask syntax

Document expression composition, conflicting fields, source shorthand, and canonical serialization in English and Chinese. Record the controller diagnostic shape in the changelog.

Add a complete conditions example, validate it through the native configuration pipeline, and show conditions in the rule-source example.

* fix(config): clarify invalid rule conditions diagnostics

Name the mutually exclusive matching fields explicitly, including legacy aliases, instead of reporting an unwritten duplicate conditions key.

Explain that nested masks leaves accept only strings or nonempty string lists, with regression tests for JSON/YAML conflicts and invalid leaf shapes.

* refactor(tests): simplify rule conditions coverage

Stage all spelling and format variants before checking their shared canonical form. Restore that form once while preserving per-variant compilation and the complete decision matrix.

Remove conflict inputs already covered by stronger diagnostic assertions, clarify controller payload names, and validate all five rule forms in one fixture per CLI mode.

* fix(rules): correct source-group predicate guidance

Recommend the rule_source_group predicate without a masks wrapper so the rename hint works in nested expressions and source groups. Cover the suggested syntax and diagnostic in regression tests.

Update both documentation locales to describe source-group references under conditions or masks, including boolean composition.
2026-11-06 15:51:49 +08:00
cfal 0f1aec2939 Refresh dependencies and CI tooling (#277)
* Refresh dependencies and CI tooling while preserving fork pins

* Make privileged test fixtures compatible with Ubuntu 26
2026-11-06 14:59:25 +08:00
cfal 70a192ab72 Fix duplicated group ancestry in Clash connection chains (#274)
Report shared selector and group ancestry once per selected occurrence while preserving reverse hop order, independently repeated references, routing behavior, and catalog identities. Cover nested selections and pinned TCP/UDP flows, simplify reporting metadata assembly, and clarify chain ordering, client naming, and DIRECT-to-proxy semantics in both controller guides.
2026-11-05 16:24:03 +08:00
cfal 42b85673f9 Support managed TUN on single-stack and offline networks (#273)
Keep managed desktop capture working without native default routes or usable loopback addresses. Add local-only fallback routing with fail-closed TUN egress guards, preserve strict ownership and native exclusions, enable IPv6 only on the owned TUN, and keep automatic DNS reachable with split routes.
2026-11-05 11:44:43 +08:00
cfal 0b51ab370f Allow accessible rule cache directories and create missing parents (#272)
Allow rule caches in directories accessible through group permissions or ACLs without requiring directory ownership, and create missing cache directories and parents automatically. Existing ownership and permissions remain unchanged, while world-writable directories, unsafe cache files, and conflicting cache leases remain rejected. Clarify the startup and cache-save permission requirements.
2026-11-04 18:57:43 +08:00
cfal 79cfce6ac0 Add opt-in NTP application clock correction (#270)
Add optional NTP synchronization for hosts where shoes cannot set the system clock. Share the corrected time across REALITY, VMess, Shadowsocks 2022, and TLS certificate validation, using protected direct UDP with bounded synchronization, periodic refresh, and reload-safe ownership. Preserve timestamp windows and replay protection, retain the last correction on refresh failure, and document configuration and clock limitations.
2026-11-03 21:50:41 +08:00
cfal 0d5377806f docs: use shoes icon in site header and favicon (#268)
* docs: use shoes mark in site header and favicon

* docs: keep favicon shoes horizontal
2026-11-02 01:22:48 +08:00
cfal 0a00c5e927 Add offline tendns generation and staged resolver support (#265)
Add offline encrypted A/AAAA/CNAME TXT generation through `shoes generate-tendns-txt`, using `TENDNS_KEY` without DNS-provider integration. Stage an internal tendns resolver adapter for future encrypted discovery support, preserving unclaimed native lookups and enforcing protected-name deadlines and fail-closed behavior. Include bilingual publishing guidance and dependency notices; runtime activation remains disabled.
2026-11-01 22:55:14 +08:00
cfal d8481fae2d Add global default DNS configuration (#264)
Add optional global_settings.default_dns so listeners, TUN entries, and WireGuard inbounds can share DNS configuration without repetition. Omitted or null inbound DNS inherits the default, while explicit objects override it completely. Inline fake-IP defaults share one pool, and independent bootstrap and service lookups remain unchanged. Includes validation, regression coverage, and English and Chinese documentation.
2026-11-01 21:49:50 +08:00
cfal ab770fe05c Support whole-path client groups with resolved routing plans (#256)
Allow client groups to select complete paths of different lengths consistently across forwarding, DNS, downloads, and carrier routes. Separate source configuration from bounded runtime plans, preserve selection boundaries and per-flow path pinning, and keep TCP/UDP rotation and automatic selection independent. Unify chain syntax while retaining legacy proxy-list alternatives, and cache up to 16 NaiveProxy sessions by selected prefix, pruning closed entries before LRU eviction without interrupting active tunnels. Add routing measurements, lifecycle coverage, and updated English and Chinese configuration guidance.
2026-11-01 18:49:23 +08:00
cfal ea472a97bc docs: add Simplified Chinese and language selector (#263) 2026-11-01 17:01:17 +08:00
cfal 31955c3b49 docs: make the site the README entry point (#262) 2026-11-01 15:11:15 +08:00
cfal ab9402f65f docs: introduce Shoes and show dev source in the header (#261) 2026-11-01 15:07:33 +08:00
cfal 53282c5019 Add configuration documentation site (#260)
* Validate published configuration examples

* Move configuration reference into Starlight site

* Check documentation site in CI

* Complete optional docs dependency lock entries
2026-11-01 03:15:45 +08:00