You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
fix(subscription): include the MASQUE login in Xray JSON - #1290
Xray JSON subscriptions included the MASQUE password but omitted the login, so the server rejected authentication even with the correct password.
Use the panel user's ID as streamSettings.masqueSettings.user when no login is supplied. This matches the account email sent to the node. An explicit login is preserved.
No actionable comments were generated in the recent review.
Walkthrough
MASQUE outbound construction now uses the nested masque settings when available. If the configured user is empty, it uses _user_id as the login. A parameterized test checks fallback and explicit usernames, and verifies password serialization.
Changes
MASQUE Login Fallback
Layer / File(s)
Summary
Credential selection and serialization tests app/subscription/xray.py, tests/test_subscription_masque.py
_build_masque falls back to the string form of _user_id when the configured user is empty. The test checks the fallback, an explicit username, and the rendered password.
This fixes MASQUE Xray JSON subscriptions that omitted the login, which made authentication fail. The change is small and tested, and no actionable merge risk remains.
Pre-merge checks: 4
Check name
Status
Explanation
Description Check
Check skipped - CodeRabbit’s high-level summary is enabled.
Title check
The title names the fix and its scope: the MASQUE login is now included in the Xray JSON subscription output. The raw summary confirms _build_masque now derives the user from the nested masque map…
Linked Issues check
Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check
Check skipped because no linked issues were found for this pull request.
Full details: Title check
Explanation
The title names the fix and its scope: the MASQUE login is now included in the Xray JSON subscription output. The raw summary confirms _build_masque now derives the user from the nested masque mapping or from _user_id when no user is set, and the test module checks the serialized user value. The title matches the main change, so the check passes.
Finishing Touches
Generate unit tests (beta)
Create a new PR
Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts
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.
A rabbit checks the login string, And sees the panel ID spring. The password stays in place, Both usernames pass the test with grace. Hop, the outbound takes its wing.
Recent review info
Run configuration
Source mode: Auto
Repository: Unavailable
Branch: Unavailable
File: No configuration file from this repository applied
Commit: Unavailable
Layers: Organization UI
Review profile: CHILL
Plan: Advanced
Run ID: f3134428-740a-443b-a000-f7126671292e
Commits
Reviewing files that changed from the base of the PR and between aa8d84d and d5faebf.
Files selected for processing: 2
app/subscription/xray.py
tests/test_subscription_masque.py
Included review availability: This review used your included allowance. Your plan provides up to 8 included reviews per hour; 7 remain after this review.
Note: CodeRabbit is an incremental review system and does not re-review already reviewed commits. This command is applicable only when automatic reviews are paused.
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
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.
Summary
Xray JSON subscriptions included the MASQUE password but omitted the login, so the server rejected authentication even with the correct password.
Use the panel user's ID as
streamSettings.masqueSettings.userwhen no login is supplied. This matches the account email sent to the node. An explicit login is preserved.Type of change
Checklist
Testing
python -m pytest -q tests/test_subscription_*.py— 318 passed, 1 skipped.Screenshots
Not applicable.
Notes for reviewers
No database migrations, API changes, or UI changes.
Summary by CodeRabbit