This commit is contained in:
2026-07-22 17:30:42 -03:00
parent b903775fb7
commit 3d64d6394b
11 changed files with 173 additions and 223 deletions
+6 -10
View File
@@ -761,28 +761,24 @@ Object.assign(I18N_TEXT["en-US"], {
"Native Xray scale tuning":"Native Xray scale tuning",
"Go CPU threads (GOMAXPROCS)":"Go CPU threads (GOMAXPROCS)",
"Global mux backend sessions":"Global mux backend sessions",
"Global transport connections":"Global transport connections",
"XHTTP web request cap":"XHTTP web request cap",
"disabled for VPN traffic":"disabled for VPN traffic",
"Active XHTTP sessions":"Active XHTTP sessions",
"Transport and XHTTP admission":"Transport and XHTTP admission",
"Unlimited for VPN traffic. There is no global HTTP request, HTTP/2 stream, transport-connection, or XHTTP-session count cap.":"Unlimited for VPN traffic. There is no global HTTP request, HTTP/2 stream, transport-connection, or XHTTP-session count cap.",
"Trace every XHTTP/mux packet":"Trace every XHTTP/mux packet",
"debug only, slows QUIC":"debug only, slows QUIC",
"Apply high-traffic VPN defaults":"Apply high-traffic VPN defaults",
"Apply safe defaults":"Apply safe defaults",
"XHTTP is handled as VPN tunnel traffic: packet requests use bounded backpressure and are never rejected by an HTTP request-rate ceiling. At the transport ceiling, new sockets wait in the kernel backlog instead of being reset. Keep the safe defaults unless the server is sized and load-tested for the high-traffic profile. HTTP/2 retains a 1024-stream flow-control guard per connection, while upload memory stays globally bounded. Saved in the panel config and applied live on restart/reload.":"XHTTP is handled as VPN tunnel traffic: packet requests use bounded backpressure and are never rejected by an HTTP request-rate ceiling. At the transport ceiling, new sockets wait in the kernel backlog instead of being reset. Keep the safe defaults unless the server is sized and load-tested for the high-traffic profile. HTTP/2 retains a 1024-stream flow-control guard per connection, while upload memory stays globally bounded. Saved in the panel config and applied live on restart/reload."
"XHTTP is handled as VPN tunnel traffic: packet requests and reassembly are limited only by bounded byte backpressure, never by a request count. Existing saved web-style caps are ignored automatically after update. Per-user max_conns, quota, and bandwidth policies still work normally.":"XHTTP is handled as VPN tunnel traffic: packet requests and reassembly are limited only by bounded byte backpressure, never by a request count. Existing saved web-style caps are ignored automatically after update. Per-user max_conns, quota, and bandwidth policies still work normally."
});
Object.assign(I18N_TEXT["pt-BR"], {
"Sort by":"Ordenar por","Show":"Mostrar","All":"Todos","Offline":"Offline","Connections":"Conexões","Usage":"Uso","Quota reached":"Cota atingida","{visible} of {total} users":"{visible} de {total} usuários","No Xray users match this filter.":"Nenhum usuário Xray corresponde a este filtro.","No SSH users match this filter.":"Nenhum usuário SSH corresponde a este filtro.",
"Native Xray scale tuning":"Ajustes de escala do Xray nativo",
"Go CPU threads (GOMAXPROCS)":"Threads de CPU do Go (GOMAXPROCS)",
"Global mux backend sessions":"Sessões globais de backend Mux",
"Global transport connections":"Conexões globais de transporte",
"XHTTP web request cap":"Limite web de requisições XHTTP",
"disabled for VPN traffic":"desativado para tráfego VPN",
"Active XHTTP sessions":"Sessões XHTTP ativas",
"Transport and XHTTP admission":"Admissão de transporte e XHTTP",
"Unlimited for VPN traffic. There is no global HTTP request, HTTP/2 stream, transport-connection, or XHTTP-session count cap.":"Ilimitado para tráfego VPN. Não existe limite global por quantidade de requisições HTTP, streams HTTP/2, conexões de transporte ou sessões XHTTP.",
"Trace every XHTTP/mux packet":"Registrar cada pacote XHTTP/Mux",
"debug only, slows QUIC":"somente debug, reduz a velocidade do QUIC",
"Apply high-traffic VPN defaults":"Aplicar padrão VPN de alto tráfego",
"Apply safe defaults":"Aplicar padrões seguros",
"XHTTP is handled as VPN tunnel traffic: packet requests use bounded backpressure and are never rejected by an HTTP request-rate ceiling. At the transport ceiling, new sockets wait in the kernel backlog instead of being reset. Keep the safe defaults unless the server is sized and load-tested for the high-traffic profile. HTTP/2 retains a 1024-stream flow-control guard per connection, while upload memory stays globally bounded. Saved in the panel config and applied live on restart/reload.":"O XHTTP é tratado como tráfego de túnel VPN: as requisições de pacotes usam backpressure com memória limitada e nunca são rejeitadas por um limite de requisições web. Ao atingir o teto de transporte, novos sockets aguardam no backlog do kernel em vez de serem resetados. Mantenha os padrões seguros, exceto se o servidor estiver dimensionado e testado para o perfil de alto tráfego. O HTTP/2 mantém um controle de fluxo de 1024 streams por conexão, e a memória de upload continua limitada globalmente. Salvo na configuração do painel e aplicado ao vivo ao reiniciar ou recarregar."
"XHTTP is handled as VPN tunnel traffic: packet requests and reassembly are limited only by bounded byte backpressure, never by a request count. Existing saved web-style caps are ignored automatically after update. Per-user max_conns, quota, and bandwidth policies still work normally.":"O XHTTP é tratado como tráfego de túnel VPN: requisições de pacotes e remontagem usam somente backpressure com limite de bytes, nunca limite por quantidade de requisições. Limites web antigos já salvos são ignorados automaticamente após a atualização. As regras por usuário de max_conns, cota e banda continuam funcionando normalmente."
});
+13 -10
View File
@@ -29,24 +29,24 @@ function toggleUdpgwFields(on) {
}
// Only operator-safe knobs remain. Transport buffers (HTTP/2 flow control, XHTTP
// reorder buffer, mux/UDP buffers) are fixed to xray-core defaults in the backend
// and are no longer exposed here, so they cannot be misconfigured.
// Only operator-safe knobs remain. Global transport/XHTTP count admission is
// fixed to unlimited; byte backpressure and protocol buffers stay internal so a
// panel value cannot turn normal VPN traffic into HTTP overload responses.
const XRAY_NATIVE_TUNING_DEFAULTS = {
safe: {
runtime_gomaxprocs: 0,
mux_global_sessions: 32768,
max_concurrent_connections: 32768,
max_concurrent_connections: -1,
max_concurrent_xhttp_requests: -1,
xhttp_max_sessions: 32768,
xhttp_max_sessions: -1,
trace_packets: false,
},
"high": {
runtime_gomaxprocs: 0,
mux_global_sessions: 65536,
max_concurrent_connections: 65536,
max_concurrent_connections: -1,
max_concurrent_xhttp_requests: -1,
xhttp_max_sessions: 65536,
xhttp_max_sessions: -1,
trace_packets: false,
},
};
@@ -54,9 +54,6 @@ const XRAY_NATIVE_TUNING_DEFAULTS = {
const XRAY_NATIVE_TUNING_FIELDS = {
runtime_gomaxprocs: "cfgXrayRuntimeGomaxprocs",
mux_global_sessions: "cfgXrayMuxGlobalSessions",
max_concurrent_connections: "cfgXrayMaxConnections",
max_concurrent_xhttp_requests: "cfgXrayMaxXHTTPRequests",
xhttp_max_sessions: "cfgXrayMaxXHTTPSessions",
};
function setXrayNativeTuningDefaults(profile = "high") {
@@ -80,6 +77,12 @@ function readXrayNativeTuning() {
const el = document.getElementById(id);
out[key] = parseInt(el?.value || "0", 10) || 0;
});
// These legacy JSON keys are intentionally fixed at unlimited. Keeping them
// in saved configs makes upgrades/downgrades explicit without exposing web
// request ceilings that do not belong on a VPN transport.
out.max_concurrent_connections = -1;
out.max_concurrent_xhttp_requests = -1;
out.xhttp_max_sessions = -1;
out.trace_packets = !!document.getElementById("cfgXrayTracePackets")?.checked;
return out;
}
+4 -6
View File
@@ -1532,15 +1532,13 @@
<div class="grid2" style="margin-top:10px;gap:8px;">
<div class="field"><label>Go CPU threads (GOMAXPROCS)</label><input type="number" min="0" id="cfgXrayRuntimeGomaxprocs" placeholder="0 = all CPU cores"/></div>
<div class="field"><label>Global mux backend sessions</label><input type="number" min="1" id="cfgXrayMuxGlobalSessions" placeholder="32768"/></div>
<div class="field"><label>Global transport connections <span class="hint">0=32768, -1=unlimited</span></label><input type="number" min="-1" id="cfgXrayMaxConnections" placeholder="32768"/></div>
<div class="field"><label>XHTTP web request cap <span class="hint">disabled for VPN traffic</span></label><input type="number" min="-1" id="cfgXrayMaxXHTTPRequests" value="-1" readonly/></div>
<div class="field"><label>Active XHTTP sessions <span class="hint">0=32768, -1=unlimited</span></label><input type="number" min="-1" id="cfgXrayMaxXHTTPSessions" placeholder="32768"/></div>
<div class="field" style="grid-column:1/-1;"><label>Transport and XHTTP admission</label><div class="hint">Unlimited for VPN traffic. There is no global HTTP request, HTTP/2 stream, transport-connection, or XHTTP-session count cap.</div></div>
<label style="font-size:.73rem;display:flex;align-items:center;gap:5px;cursor:pointer;grid-column:1/-1"><input type="checkbox" id="cfgXrayTracePackets"/> Trace every XHTTP/mux packet <span class="hint">debug only, slows QUIC</span></label>
<div class="card-actions" style="grid-column:1/-1;">
<button class="btn btn-ghost btn-sm" type="button" onclick="setXrayNativeTuningDefaults('high')">Apply high-traffic VPN defaults</button>
<button class="btn btn-ghost btn-sm" type="button" onclick="setXrayNativeTuningDefaults('safe')">Apply safe defaults</button>
</div>
<div class="hint" style="grid-column:1/-1;margin-top:-4px;">XHTTP is handled as VPN tunnel traffic: packet requests use bounded backpressure and are never rejected by an HTTP request-rate ceiling. At the transport ceiling, new sockets wait in the kernel backlog instead of being reset. Keep the safe defaults unless the server is sized and load-tested for the high-traffic profile. HTTP/2 retains a 1024-stream flow-control guard per connection, while upload memory stays globally bounded. Saved in the panel config and applied live on restart/reload.</div>
<div class="hint" style="grid-column:1/-1;margin-top:-4px;">XHTTP is handled as VPN tunnel traffic: packet requests and reassembly are limited only by bounded byte backpressure, never by a request count. Existing saved web-style caps are ignored automatically after update. Per-user max_conns, quota, and bandwidth policies still work normally.</div>
</div>
</details>
</div>
@@ -1580,14 +1578,14 @@
<!-- app.js was split into ordered modules for maintainability. They are plain
classic scripts sharing one global scope; `defer` preserves execution order,
so behavior is identical to the old single file. Keep this load order. -->
<script defer src="assets/js/01-core.js?v=20260720sshfilters1"></script>
<script defer src="assets/js/01-core.js?v=20260722xhttpunlimited2"></script>
<script defer src="assets/js/02-shell.js?v=20260714pamfix1"></script>
<script defer src="assets/js/03-ssh-users.js?v=20260720sshfilters1"></script>
<script defer src="assets/js/04-xray.js?v=20260720sshfilters1"></script>
<script defer src="assets/js/05-resellers.js?v=20260714pamfix1"></script>
<script defer src="assets/js/06-servers.js?v=20260714pamfix1"></script>
<script defer src="assets/js/07-stats-logs.js?v=20260714pamfix1"></script>
<script defer src="assets/js/08-server-config.js?v=20260719xhttp502fix1"></script>
<script defer src="assets/js/08-server-config.js?v=20260722xhttpunlimited2"></script>
<script defer src="assets/js/09-xray-wizard.js?v=20260714quota1"></script>
<script defer src="assets/js/11-update-status.js?v=20260714pamfix1"></script>
<script defer src="assets/js/12-bot.js?v=20260714pamfix1"></script>