Repository navigation
fix(xray): do not fail SyncUser over an empty WireGuard message - #118
Merged
Merged
Conversation
Panels send an empty WireGuard message for every user without WireGuard keys. SyncUser rejected those users with "wireguard public_key is required" before touching any inbound, so with bridges that sync users one at a time (0.9.1) users could not be added, changed or removed. A WireGuard message without a public key now means no WireGuard account, as full sync and UpdateUsers already treat it: the user is applied to its other inbounds and removed from WireGuard inbounds. Invalid WireGuard settings that carry a key still keep the live peer and return an error, but no longer block the user's other inbounds or a removal.
…n error Start logged "wireguard public_key is required" for every user without WireGuard keys listed on a WireGuard inbound. Skip them quietly, the same rule SyncUser now uses.
|
Important Review skippedAuto reviews are disabled on base/target branches other than the default branch. Please check the settings in the CodeRabbit UI or the ⚙️ Run configuration
You can disable this status message by setting the Use the checkbox below for a quick retry:
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Free-Guy-IR
added a commit
to Free-Guy-IR/node
that referenced
this pull request
Nov 3, 2026
d309483 (PasarGuard#115) is now ported by c2e15f2 and its waiver goes. 47857d4 (the v0.5.5 version bump) is not applicable: the fork keeps its own NodeVersion line. bb40094 (PasarGuard#111) is superseded while the fork pins Xray v26.3.27 and checks the geo files by sha256. d359a8f (PasarGuard#117) is not applicable without StartOrAttach. bd745b5 (PasarGuard#118) is not applicable until PasarGuard#64 brings Xray WireGuard accounts and goes with it. 1549c96 (PasarGuard#116) and 8ad52fe (PasarGuard#112) stay pending to 2026-11-08 under NODE-LEAD, each with its exact remaining work.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Panels send an empty
proxies.wireguardmessage for every user without WireGuard keys.SyncUserrejected those users withwireguard public_key is requiredbefore applying any inbound, so with bridge 0.9.1 (which syncs batches under 1000 users one user at a time) users could not be added, changed or removed; disabled and deleted users kept access.A WireGuard message without a public key now means "no WireGuard account", as full sync and
UpdateUsersalready treat it: the user is applied to its other inbounds and removed from WireGuard inbounds.Invalid WireGuard settings that carry a key still keep the live peer and return an error, but no longer block the user's other inbounds or a removal.
Start no longer logs
wireguard public_key is requiredfor every keyless user listed on a WireGuard inbound.Note: a user whose stored WireGuard public key is present but malformed still gets an error from
SyncUser(the #64 semantics). Bridge 0.9.1 requeues such a batch (gRPC) or that user (REST); 0.9.4 usesUpdateUsersand is unaffected.Tests: the exact wire bytes the bridge sends, add and removal through
SyncUser, valid keys unchanged, invalid keys applied to the other inbounds. Full suite with-racegreen.