π Xray-knife v11.2.0 (JOIN THE TELEGRAM CHANNEL)
Deduplication was quietly eating good configs, and subscription fetching now has limits you control. π οΈ
β Nothing breaks. No flags moved, no names changed β upgrade and carry on.
π³οΈ Dedup dropped configs that weren't duplicates
xray-knife http -f deduplicates by connection identity (--dedup-semantic, on by default). The identity it built ignored fields that decide which server you actually reach:
- π REALITY public key (
pbk) β different REALITY servers looked identical - π€ SOCKS / Shadowsocks username and password β two accounts on one host collapsed into one
- β any parameter the parser didn't already know about
A list of REALITY configs sharing one host:port could shrink to a single entry, and the rest were never tested. π¬
Semantic dedup removed 49 duplicate config link(s). Testing 1 unique configs.
Identity is now a SHA-256 over the whole parsed link minus the #remark β unknown options included. Re-skinned duplicates still collapse; distinct configs survive.
π₯ Subscription fetching is bounded
A subscription used to be read with no ceiling: whole body into memory, no deadline on the read. A small gzip response that expanded to gigabytes took the process with it. π₯
Per source, defaults are 64 MiB, 100,000 links and 30s. Raise them when you need to:
xray-knife subs fetch --all --max-bytes 134217728 --max-links 200000 --fetch-timeout 2m- ποΈ the size limit applies after decompression
- β±οΈ the timeout covers the body read, not just the connect
- π§Ύ a malformed body now fails loudly instead of returning half a list
π§© New: pkg/subscription for Go programs
Fetching and decoding moved into a standalone package β no CLI flags, no database, no globals. Bring your own http.Client, context and limits:
res, err := subscription.Fetch(ctx, client, url, subscription.FetchOptions{})core.ConnectionFingerprint(core, link) is exported alongside it, so you can dedupe against your own storage with the same identity the tester uses.
π¦ Install
Grab a prebuilt binary from the assets below, or install with Go:
go install github.com/lilendian0x00/xray-knife/v11@latestFull Changelog: v11.1.0...v11.2.0