Commit Graph

597 Commits

Author SHA1 Message Date
世界 0e494074a6 usbip: trim ADR + narrative comments, rename locks, drop one-use helpers
- Delete docs/adr/0001 and every code reference; the immutability contract
  is now a four-line comment on the Export interface where it applies.
- Inline applyStaleClones at the linux/darwin reconcile call sites and
  drop the helper plus the parallel staleBusIDs/pendingByBusID maps the
  darwin host built only to match its signature.
- Inline single-use sentinel errors in iso_scheduler.go and
  endpoint_darwin.go (no errors.Is callers).
- Rename exportLedger.fast/inventory to broadcastAccess/inventoryAccess
  to match the Access suffix used by every other lock in the package.
- Strip narrative doc comments on exportLedger, the with* helpers,
  IssueLease, ConsumeLeaseAndReserve, TryReserveForImport, host.go
  interfaces, cgoCallbackHandle, and cloneDarwinExport; keep only the
  non-obvious WHY required by .claude/rules/code-comment.md.

Net: 8 files, 99 insertions / 291 deletions, no behaviour change.
2026-06-09 10:42:33 +08:00
世界 9c8147f234 usbip: enforce broadcast invariant and clone-on-stale to close recurring races
- Route every reserved-state mutation through withInventoryWrite; the
  lease insert path now broadcasts so extended subscribers see the busy
  transition immediately instead of waiting for the next mutation. Folds
  cleanupExpiredLocked changes into the broadcast decision on every
  IssueLease early-reject path. Rename the field to inventory and force
  read/write/write-quiet sites through dedicated accessors so future
  callers cannot bypass the invariant.
- Mirror the linux clone-then-swap pattern in darwinExportHost.Reconcile
  via cloneDarwinExport, so the ledger's unlocked Snapshot / LeaseCheck
  reads never observe a half-mutated stale flag. Documented as
  docs/adr/0001-export-pointer-immutability.md and on the Export
  interface; both hosts now share the applyStaleClones helper.
- Rewrite 27 if (_, )?err := …; err != nil sites to assign-then-check
  per .claude/rules/go-syntax.md.
- Delete parse / builder / tautological tests forbidden by
  .claude/rules/code-test.md (option/usbip_test.go,
  iso_scheduler_test.go, usbhost_darwin_status_test.go).
- Tag nine more usbip files with linux || (darwin && cgo); fixes
  pre-existing windows / android lint failures because the protocol
  types were only consumed by tagged code.
2026-06-09 10:42:32 +08:00
世界 8a42af329c Bump version 2026-06-08 08:52:25 +08:00
世界 dc110f51d2 platform: Add tailscale device name and logout 2026-06-08 08:51:52 +08:00
世界 b2a9c4990c tailscale: Add tailssh server 2026-06-08 08:51:51 +08:00
世界 45be67c977 hysteria2: Add gecko obfs 2026-06-08 08:51:51 +08:00
世界 701f165e30 tailscale: Revert dialer deprecation and remove control_http_client 2026-06-08 08:51:50 +08:00
世界 098fd90b5e Fix hysteria2 realm server 2026-06-08 08:51:48 +08:00
世界 aa290a6772 Update hysteria2 realm 2026-06-08 08:51:47 +08:00
世界 0662aa41ad Add hysteria2 realm service and support 2026-06-08 08:51:47 +08:00
macronut a130000741 Add more spoof method
Signed-off-by: macronut <4027187+macronut@users.noreply.github.com>
2026-06-08 08:51:47 +08:00
世界 61c4d2dd12 Allow customizing TUN DNS mode and hijack interface DNS by default 2026-06-08 08:51:47 +08:00
世界 b9c596f9e3 dns: Add mDNS server 2026-06-08 08:51:46 +08:00
世界 db08f3f699 dns: Add preferred_by rule item 2026-06-08 08:51:46 +08:00
世界 f842580f33 dns: Add neighbor-based hostname resolution to local server 2026-06-08 08:51:46 +08:00
世界 c8792e7fe6 dns: Add timeout configuration 2026-06-08 08:51:46 +08:00
世界 664db8929a ssh: Add cipher, MAC, and key exchange configuration 2026-06-08 08:51:45 +08:00
nekohasekai 0807b71b14 Add Windows TLS engine 2026-06-08 08:51:45 +08:00
世界 12a462142a Add ACME profile support for IP address certificates 2026-06-08 08:51:44 +08:00
世界 8597592976 Add search domain support for Tailscale DNS 2026-06-08 08:51:43 +08:00
世界 aabaa42634 Reject pure-IP rule-set references without match_response
DNS rules referencing rule-sets that contain only ip_cidr predicates
silently stopped matching when legacy DNS mode was disabled, because the
IP-CIDR branch cannot match against an in-flight DNS query. The existing
validation intentionally let every rule_set through on the premise that
mixed sets still work via their non-IP branches, which is only true when
such a branch exists. Track whether a rule-set carries any non-IP-CIDR
predicate and reject pure-IP references the same way bare ip_cidr fields
are already rejected.
2026-06-08 08:51:41 +08:00
世界 44ee81ccb4 Add TLS spoof support 2026-06-08 08:51:41 +08:00
世界 ab2a90d5e7 Refactor: HTTP clients, unified HTTP2/QUIC options, Apple engines 2026-06-08 08:51:40 +08:00
世界 0525f6cb1c Add optimistic DNS cache 2026-06-08 08:51:40 +08:00
世界 adeea0f707 documentation: Fix missing update for ip_version and query_type 2026-06-08 08:51:39 +08:00
世界 d1ac250f4b Add cloudflared inbound 2026-06-08 08:51:38 +08:00
世界 d70d15f913 Add package_name_regex route, DNS and headless rule item 2026-06-08 08:51:38 +08:00
世界 849cdb6d72 documentation: Fixes 2026-06-08 08:51:37 +08:00
世界 5e02c705ff Un-deprecate ip_accept_any DNS rule item 2026-06-08 08:51:37 +08:00
nekohasekai 9a3dcca616 Add evaluate DNS rule action and related rule items 2026-06-08 08:51:34 +08:00
世界 d37626ea25 Add BBR profile and hop interval randomization for Hysteria2 2026-06-08 08:51:34 +08:00
nekohasekai 2c01a637a6 Refactor ACME support to certificate provider 2026-06-08 08:51:34 +08:00
世界 880d753de6 documentation: Update descriptions for neighbor rules 2026-06-08 08:51:33 +08:00
世界 179d0818a7 Add MAC and hostname rule items 2026-06-08 08:51:33 +08:00
世界 78b2e12fbd Bump version 2026-06-03 16:33:44 +08:00
世界 1086ab2563 Bump version 1.13.12 2026-05-14 15:11:09 +08:00
世界 553cfa1f9f Bump version 2026-04-23 07:30:34 +08:00
世界 a3fc14f35f Bump version 2026-04-22 13:40:36 +08:00
世界 d942ecc904 Bump version 1.13.9 2026-04-20 09:49:39 +08:00
世界 c3de6a25fb documentation: Remove warp ads 2026-04-20 09:49:39 +08:00
世界 bb3ad9c694 documentation: Fix typo 2026-04-14 16:00:47 +08:00
世界 d5adb54bc6 Bump version 2026-04-14 14:33:19 +08:00
世界 025b947a24 Bump version 2026-04-10 16:23:45 +08:00
世界 813b634d08 Bump version 2026-04-06 23:09:11 +08:00
世界 7ffdc48b49 Bump version 2026-03-30 23:03:43 +08:00
世界 d09182614c Bump version 2026-03-26 13:28:33 +08:00
世界 b0c6762bc1 route: merge rule_set branches into outer rules
Treat rule_set items as merged branches instead of standalone boolean
sub-items.

Evaluate each branch inside a referenced rule-set as if it were merged
into the outer rule and keep OR semantics between branches. This lets
outer grouped fields satisfy matching groups inside a branch without
introducing a standalone outer fallback or cross-branch state union.

Keep inherited grouped state outside inverted default and logical
branches. Negated rule-set branches now evaluate !(...) against their
own conditions and only reapply the outer grouped match after negation
succeeds, so configs like outer-group && !inner-condition continue to
work.

Add regression tests for same-group merged matches, cross-group and
extra-AND failures, DNS merged-branch behaviour, and inverted merged
branches. Update the route and DNS rule docs to clarify that rule-set
branches merge into the outer rule while keeping OR semantics between
branches.
2026-03-25 14:00:29 +08:00
世界 686cf1f304 documentation: Fix Chinese link anchors 2026-03-16 12:24:10 +08:00
世界 d3768cca36 Bump version 2026-03-15 17:56:37 +08:00
深鸣 f46fbf188a documentation: Minor fixes 2026-03-15 17:56:37 +08:00