Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Subscriptions: REALITY config and array in Json #47

Open
savimisha opened this issue Jan 21, 2025 · 2 comments
Open

Subscriptions: REALITY config and array in Json #47

savimisha opened this issue Jan 21, 2025 · 2 comments

Comments

@savimisha
Copy link

Hello! First of all, thanks for this project! Cool and light application which very good working.

I've been tested subscription feature with links from my 3x-ui panel and found 2 issues:

  1. Not originally from your code, but affects yours. It's related to usual (not json) subscription with REALITY security.
    After fetching, a link is converting to json by ConvertShareLinksToXrayJson function from libXray. And in case with REALITY it compiles "realitySettings" object in json with all possible keys (like "dest", "serverNames", etc.), but most of them don't used on client side and final json check in application fails.
    "realitySettings": { "masterKeyLog": "", "show": false, "target": null, "dest": null, "type": "", "xver": 0, "serverNames": null, "privateKey": "", "minClientVer": "", "maxClientVer": "", "maxTimeDiff": 0, "shortIds": null, "fingerprint": "chrome", "serverName": "www.example.com", "publicKey": "public_key", "shortId": "short_id", "spiderX": "spider_x" }
    For client side need only 5 last parameters.
    It seems import from clipboard fails by the same issue.

  2. It is like feature request or something like that. Json subscription expects only 1 JsonObject, but subscription can produce multiple configs. So when fetching json subscription application should expect json array with json objects (configs) or just 1 json object.

@SaeedDev94
Copy link
Owner

SaeedDev94 commented Jan 22, 2025

1- This is how XTLS/libXray works, Check this: XTLS/libXray#62 (comment)
2- TBH I didn't see a Json subscription till now, Is it a standard feature ? If the answer is yes send an example here

@savimisha
Copy link
Author

savimisha commented Jan 22, 2025

  1. Ohhh, I see. Anyway, I'd think about some workaround until it's not fixed... Because for now, configs with extra fields aren't importing from subscription.
  2. As per discussion here, yes. There is an example.
    3x-ui panel and v2rayN and v2rayNG works with this format.

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

No branches or pull requests

2 participants