mirror of
https://github.com/MHSanaei/3x-ui.git
synced 2026-07-15 17:16:07 +00:00
fix(warp): persist client_id so WARP outbound gets reserved bytes (#4781)
RegWarp now stores config.client_id from the Cloudflare registration, and WarpModal sources the reserved bytes from the live config response (falling back to stored creds). Previously reservedFor read an always-missing client_id, producing an empty reserved array.
This commit is contained in:
@@ -38,6 +38,7 @@ interface WarpConfig {
|
||||
model?: string;
|
||||
enabled?: boolean;
|
||||
config?: {
|
||||
client_id?: string;
|
||||
interface?: { addresses?: { v4?: string; v6?: string } };
|
||||
peers?: { public_key?: string; endpoint?: { host?: string } }[];
|
||||
};
|
||||
@@ -99,7 +100,7 @@ export default function WarpModal({
|
||||
mtu: 1420,
|
||||
secretKey: data?.private_key,
|
||||
address: addressesFor(cfg.interface?.addresses || {}),
|
||||
reserved: reservedFor(data?.client_id),
|
||||
reserved: reservedFor(cfg.client_id ?? data?.client_id),
|
||||
domainStrategy: 'ForceIP',
|
||||
peers: [{ publicKey: peer.public_key, endpoint: peer.endpoint?.host }],
|
||||
noKernelTun: false,
|
||||
|
||||
Reference in New Issue
Block a user