diff --git a/web/controller/xray_setting.go b/web/controller/xray_setting.go
index 2af08094..a48726de 100644
--- a/web/controller/xray_setting.go
+++ b/web/controller/xray_setting.go
@@ -54,7 +54,7 @@ func (a *XraySettingController) getXraySetting(c *gin.Context) {
}
outboundTestUrl, _ := a.SettingService.GetXrayOutboundTestUrl()
if outboundTestUrl == "" {
- outboundTestUrl = "http://www.google.com/gen_204"
+ outboundTestUrl = "https://www.google.com/generate_204"
}
urlJSON, _ := json.Marshal(outboundTestUrl)
xrayResponse := "{ \"xraySetting\": " + xraySetting + ", \"inboundTags\": " + inboundTags + ", \"outboundTestUrl\": " + string(urlJSON) + " }"
@@ -70,7 +70,7 @@ func (a *XraySettingController) updateSetting(c *gin.Context) {
}
outboundTestUrl := c.PostForm("outboundTestUrl")
if outboundTestUrl == "" {
- outboundTestUrl = "http://www.google.com/gen_204"
+ outboundTestUrl = "https://www.google.com/generate_204"
}
_ = a.SettingService.SetXrayOutboundTestUrl(outboundTestUrl)
jsonMsg(c, I18nWeb(c, "pages.settings.toasts.modifySettings"), nil)
diff --git a/web/html/settings/xray/basics.html b/web/html/settings/xray/basics.html
index 728c8e4d..9a31038a 100644
--- a/web/html/settings/xray/basics.html
+++ b/web/html/settings/xray/basics.html
@@ -4,18 +4,22 @@
-
+
{{ i18n "pages.xray.generalConfigsDesc" }}
{{ i18n "pages.xray.FreedomStrategy" }}
- {{ i18n "pages.xray.FreedomStrategyDesc" }}
+ {{ i18n "pages.xray.FreedomStrategyDesc"
+ }}
-
-
+
[[ s ]]
@@ -23,11 +27,14 @@
{{ i18n "pages.xray.RoutingStrategy" }}
- {{ i18n "pages.xray.RoutingStrategyDesc" }}
+ {{ i18n "pages.xray.RoutingStrategyDesc"
+ }}
-
-
+
[[ s ]]
@@ -35,37 +42,48 @@
{{ i18n "pages.xray.outboundTestUrl" }}
- {{ i18n "pages.xray.outboundTestUrlDesc" }}
+ {{ i18n "pages.xray.outboundTestUrlDesc"
+ }}
-
+
- {{ i18n "pages.xray.statsInboundUplink" }}
- {{ i18n "pages.xray.statsInboundUplinkDesc" }}
+ {{ i18n "pages.xray.statsInboundUplink"
+ }}
+ {{ i18n "pages.xray.statsInboundUplinkDesc"
+ }}
- {{ i18n "pages.xray.statsInboundDownlink" }}
- {{ i18n "pages.xray.statsInboundDownlinkDesc" }}
+ {{ i18n "pages.xray.statsInboundDownlink"
+ }}
+ {{ i18n "pages.xray.statsInboundDownlinkDesc"
+ }}
- {{ i18n "pages.xray.statsOutboundUplink" }}
- {{ i18n "pages.xray.statsOutboundUplinkDesc" }}
+ {{ i18n "pages.xray.statsOutboundUplink"
+ }}
+ {{ i18n "pages.xray.statsOutboundUplinkDesc"
+ }}
- {{ i18n "pages.xray.statsOutboundDownlink" }}
- {{ i18n "pages.xray.statsOutboundDownlinkDesc" }}
+ {{ i18n "pages.xray.statsOutboundDownlink"
+ }}
+ {{ i18n
+ "pages.xray.statsOutboundDownlinkDesc" }}
@@ -75,16 +93,20 @@
-
+
{{ i18n "pages.xray.logConfigsDesc" }}
{{ i18n "pages.xray.logLevel" }}
- {{ i18n "pages.xray.logLevelDesc" }}
+ {{ i18n "pages.xray.logLevelDesc"
+ }}
-
+
[[ s ]]
@@ -93,10 +115,13 @@
{{ i18n "pages.xray.accessLog" }}
- {{ i18n "pages.xray.accessLogDesc" }}
+ {{ i18n "pages.xray.accessLogDesc"
+ }}
-
-
+
+
Empty
@@ -107,10 +132,13 @@
{{ i18n "pages.xray.errorLog" }}
- {{ i18n "pages.xray.errorLogDesc" }}
+ {{ i18n "pages.xray.errorLogDesc"
+ }}
-
-
+
+
Empty
@@ -121,11 +149,13 @@
{{ i18n "pages.xray.maskAddress" }}
- {{ i18n "pages.xray.maskAddressDesc" }}
+ {{ i18n "pages.xray.maskAddressDesc"
+ }}
-
-
+
Empty
@@ -146,7 +176,8 @@
-
+
{{ i18n "pages.xray.blockConfigsDesc" }}
@@ -160,17 +191,21 @@
-
- {{ i18n "pages.xray.blockConnectionsConfigsDesc" }}
+
+ {{ i18n "pages.xray.blockConnectionsConfigsDesc"
+ }}
{{ i18n "pages.xray.blockips" }}
-
-
+
[[ p.label ]]
@@ -179,28 +214,35 @@
{{ i18n "pages.xray.blockdomains" }}
-
-
+
[[ p.label ]]
-
+
-
- {{ i18n "pages.xray.directConnectionsConfigsDesc" }}
+
+ {{ i18n "pages.xray.directConnectionsConfigsDesc"
+ }}
{{ i18n "pages.xray.directips" }}
-
-
+
[[ p.label ]]
@@ -209,18 +251,22 @@
{{ i18n "pages.xray.directdomains" }}
-
-
+
[[ p.label ]]
-
+
-
+
{{ i18n "pages.xray.ipv4RoutingDesc" }}
@@ -228,18 +274,22 @@
{{ i18n "pages.xray.ipv4Routing" }}
-
-
+
[[ p.label ]]
-
+
-
+
{{ i18n "pages.xray.warpRoutingDesc" }}
@@ -248,20 +298,24 @@
{{ i18n "pages.xray.warpRouting" }}
-
-
+
[[ p.label ]]
- WARP
+ WARP
-
+
{{ i18n "pages.settings.resetDefaultConfig" }}
diff --git a/web/html/settings/xray/outbounds.html b/web/html/settings/xray/outbounds.html
index fdc2ae4a..3995760f 100644
--- a/web/html/settings/xray/outbounds.html
+++ b/web/html/settings/xray/outbounds.html
@@ -4,17 +4,22 @@
- {{ i18n "pages.xray.outbound.addOutbound" }}
+ {{ i18n
+ "pages.xray.outbound.addOutbound" }}
- WARP
+ WARP
-
-
+
@@ -23,8 +28,10 @@
-
[[ index+1 ]]
@@ -32,7 +39,8 @@
e.preventDefault()" type="more"
:style="{ fontSize: '16px', textDecoration: 'bold' }">
-
+
{{ i18n "pages.xray.rules.first"}}
@@ -56,15 +64,21 @@
- [[ addr ]]
+ [[ addr ]]
- [[ outbound.protocol ]]
+ [[ outbound.protocol
+ ]]
- [[ outbound.streamSettings.network ]]
- tls
- [[
+ outbound.streamSettings.network ]]
+ tls
+ reality
@@ -73,30 +87,37 @@
- {{ i18n "pages.xray.outbound.test" }}
- {{ i18n "pages.xray.outbound.test"
+ }}
+
+ :disabled="(outbound.protocol === 'blackhole' || outbound.tag === 'blocked') || (outboundTestStates[index] && outboundTestStates[index].testing)">
-
-
+
+
[[ outboundTestStates[index].result.delay ]]ms
- (HTTP [[ outboundTestStates[index].result.statusCode ]])
+
+ ([[ outboundTestStates[index].result.statusCode
+ ]])
-
+
Failed
-
+
-
diff --git a/web/html/xray.html b/web/html/xray.html
index 7ca6885c..a350ee57 100644
--- a/web/html/xray.html
+++ b/web/html/xray.html
@@ -1,7 +1,10 @@
{{ template "page/head_start" .}}
-
-
-
+
+
+
{{ template "page/head_end" .}}
@@ -10,10 +13,13 @@
-
+
-
+
@@ -26,19 +32,25 @@
-
+
-
+
{{ i18n "pages.xray.save" }}
-
+
{{ i18n "pages.xray.restart" }}
-
- {{ i18n "pages.index.xrayErrorPopoverTitle" }}
+
+ {{ i18n
+ "pages.index.xrayErrorPopoverTitle" }}
- [[ line
+ [[ line
]]
@@ -48,10 +60,13 @@
@@ -60,7 +75,8 @@
- { this.changePage(activeKey); }"
+ { this.changePage(activeKey); }"
:class="themeSwitcher.currentTheme">
@@ -83,21 +99,24 @@
{{ template "settings/xray/outbounds" . }}
-
+
{{ i18n "pages.xray.outbound.reverse"}}
{{ template "settings/xray/reverse" . }}
-
+
{{ i18n "pages.xray.Balancers"}}
{{ template "settings/xray/balancers" . }}
-
+
DNS
@@ -120,14 +139,18 @@
{{template "page/body_scripts" .}}
-
-
+
+
-
-
+
+
@@ -230,8 +253,8 @@
},
oldXraySetting: '',
xraySetting: '',
- outboundTestUrl: 'http://www.google.com/gen_204',
- oldOutboundTestUrl: 'http://www.google.com/gen_204',
+ outboundTestUrl: 'https://www.google.com/generate_204',
+ oldOutboundTestUrl: 'https://www.google.com/generate_204',
inboundTags: [],
outboundsTraffic: [],
outboundTestStates: {}, // Track testing state and results for each outbound
@@ -342,14 +365,14 @@
},
defaultObservatory: {
subjectSelector: [],
- probeURL: "http://www.google.com/gen_204",
+ probeURL: "https://www.google.com/generate_204",
probeInterval: "10m",
enableConcurrency: true
},
defaultBurstObservatory: {
subjectSelector: [],
pingConfig: {
- destination: "http://www.google.com/gen_204",
+ destination: "https://www.google.com/generate_204",
interval: "30m",
connectivity: "http://connectivitycheck.platform.hicloud.com/generate_204",
timeout: "10s",
@@ -380,7 +403,7 @@
this.oldXraySetting = xs;
this.xraySetting = xs;
this.inboundTags = result.inboundTags;
- this.outboundTestUrl = result.outboundTestUrl || 'http://www.google.com/gen_204';
+ this.outboundTestUrl = result.outboundTestUrl || 'https://www.google.com/generate_204';
this.oldOutboundTestUrl = this.outboundTestUrl;
this.saveBtnDisable = true;
}
@@ -389,7 +412,7 @@
this.loading(true);
const msg = await HttpUtil.post("/panel/xray/update", {
xraySetting: this.xraySetting,
- outboundTestUrl: this.outboundTestUrl || 'http://www.google.com/gen_204'
+ outboundTestUrl: this.outboundTestUrl || 'https://www.google.com/generate_204'
});
this.loading(false);
if (msg.success) {
@@ -612,6 +635,11 @@
return;
}
+ if (outbound.protocol === 'blackhole' || outbound.tag === 'blocked') {
+ Vue.prototype.$message.warning('{{ i18n "pages.xray.outbound.testError" }}: blocked/blackhole outbound');
+ return;
+ }
+
// Initialize test state for this outbound if not exists
if (!this.outboundTestStates[index]) {
this.$set(this.outboundTestStates, index, {
@@ -626,7 +654,7 @@
try {
const outboundJSON = JSON.stringify(outbound);
- const testURL = this.outboundTestUrl || 'http://www.google.com/gen_204';
+ const testURL = this.outboundTestUrl || 'https://www.google.com/generate_204';
const allOutboundsJSON = JSON.stringify(this.templateSettings.outbounds || []);
const msg = await HttpUtil.post("/panel/xray/testOutbound", {
@@ -644,7 +672,7 @@
if (result.success) {
Vue.prototype.$message.success(
- `{{ i18n "pages.xray.outbound.testSuccess" }}: ${result.delay}ms (HTTP ${result.statusCode})`
+ `{{ i18n "pages.xray.outbound.testSuccess" }}: ${result.delay}ms (${result.statusCode})`
);
} else {
Vue.prototype.$message.error(
diff --git a/web/job/xray_traffic_job.go b/web/job/xray_traffic_job.go
index 33a432b5..8d2bfbd6 100644
--- a/web/job/xray_traffic_job.go
+++ b/web/job/xray_traffic_job.go
@@ -71,7 +71,7 @@ func (j *XrayTrafficJob) Run() {
}
// Broadcast traffic update via WebSocket with accumulated values from database
- trafficUpdate := map[string]interface{}{
+ trafficUpdate := map[string]any{
"traffics": traffics,
"clientTraffics": clientTraffics,
"onlineClients": onlineClients,
diff --git a/web/service/outbound.go b/web/service/outbound.go
index 7267e61c..c55999b3 100644
--- a/web/service/outbound.go
+++ b/web/service/outbound.go
@@ -1,12 +1,15 @@
package service
import (
+ "crypto/tls"
"encoding/json"
"fmt"
+ "io"
"net"
"net/http"
"net/url"
"os"
+ "sync"
"time"
"github.com/mhsanaei/3x-ui/v2/config"
@@ -24,6 +27,9 @@ import (
// It handles outbound traffic monitoring and statistics.
type OutboundService struct{}
+// testSemaphore limits concurrent outbound tests to prevent resource exhaustion.
+var testSemaphore sync.Mutex
+
func (s *OutboundService) AddTraffic(traffics []*xray.Traffic, clientTraffics []*xray.ClientTraffic) (error, bool) {
var err error
db := database.GetDB()
@@ -125,11 +131,20 @@ type TestOutboundResult struct {
// Only the test inbound and a route rule (to the tested outbound tag) are added.
func (s *OutboundService) TestOutbound(outboundJSON string, testURL string, allOutboundsJSON string) (*TestOutboundResult, error) {
if testURL == "" {
- testURL = "http://www.google.com/gen_204"
+ testURL = "https://www.google.com/generate_204"
}
+ // Limit to one concurrent test at a time
+ if !testSemaphore.TryLock() {
+ return &TestOutboundResult{
+ Success: false,
+ Error: "Another outbound test is already running, please wait",
+ }, nil
+ }
+ defer testSemaphore.Unlock()
+
// Parse the outbound being tested to get its tag
- var testOutbound map[string]interface{}
+ var testOutbound map[string]any
if err := json.Unmarshal([]byte(outboundJSON), &testOutbound); err != nil {
return &TestOutboundResult{
Success: false,
@@ -143,9 +158,15 @@ func (s *OutboundService) TestOutbound(outboundJSON string, testURL string, allO
Error: "Outbound has no tag",
}, nil
}
+ if protocol, _ := testOutbound["protocol"].(string); protocol == "blackhole" || outboundTag == "blocked" {
+ return &TestOutboundResult{
+ Success: false,
+ Error: "Blocked/blackhole outbound cannot be tested",
+ }, nil
+ }
// Use all outbounds when provided; otherwise fall back to single outbound
- var allOutbounds []interface{}
+ var allOutbounds []any
if allOutboundsJSON != "" {
if err := json.Unmarshal([]byte(allOutboundsJSON), &allOutbounds); err != nil {
return &TestOutboundResult{
@@ -155,7 +176,7 @@ func (s *OutboundService) TestOutbound(outboundJSON string, testURL string, allO
}
}
if len(allOutbounds) == 0 {
- allOutbounds = []interface{}{testOutbound}
+ allOutbounds = []any{testOutbound}
}
// Find an available port for test inbound
@@ -185,8 +206,6 @@ func (s *OutboundService) TestOutbound(outboundJSON string, testURL string, allO
defer func() {
if testProcess.IsRunning() {
testProcess.Stop()
- // Give it a moment to clean up
- time.Sleep(500 * time.Millisecond)
}
}()
@@ -198,8 +217,20 @@ func (s *OutboundService) TestOutbound(outboundJSON string, testURL string, allO
}, nil
}
- // Wait a bit for xray to start
- time.Sleep(1 * time.Second)
+ // Wait for xray to start listening on the test port
+ if err := waitForPort(testPort, 3*time.Second); err != nil {
+ if !testProcess.IsRunning() {
+ result := testProcess.GetResult()
+ return &TestOutboundResult{
+ Success: false,
+ Error: fmt.Sprintf("Xray process exited: %s", result),
+ }, nil
+ }
+ return &TestOutboundResult{
+ Success: false,
+ Error: fmt.Sprintf("Xray failed to start listening: %v", err),
+ }, nil
+ }
// Check if process is still running
if !testProcess.IsRunning() {
@@ -228,7 +259,7 @@ func (s *OutboundService) TestOutbound(outboundJSON string, testURL string, allO
// createTestConfig creates a test config by copying all outbounds unchanged and adding
// only the test inbound (SOCKS) and a route rule that sends traffic to the given outbound tag.
-func (s *OutboundService) createTestConfig(outboundTag string, allOutbounds []interface{}, testPort int) *xray.Config {
+func (s *OutboundService) createTestConfig(outboundTag string, allOutbounds []any, testPort int) *xray.Config {
// Test inbound (SOCKS proxy) - only addition to inbounds
testInbound := xray.InboundConfig{
Tag: "test-inbound",
@@ -239,16 +270,20 @@ func (s *OutboundService) createTestConfig(outboundTag string, allOutbounds []in
}
// Outbounds: copy all, but set noKernelTun=true for WireGuard outbounds
- processedOutbounds := make([]interface{}, len(allOutbounds))
+ processedOutbounds := make([]any, len(allOutbounds))
for i, ob := range allOutbounds {
- outbound := ob.(map[string]interface{})
+ outbound, ok := ob.(map[string]any)
+ if !ok {
+ processedOutbounds[i] = ob
+ continue
+ }
if protocol, ok := outbound["protocol"].(string); ok && protocol == "wireguard" {
// Set noKernelTun to true for WireGuard outbounds
- if settings, ok := outbound["settings"].(map[string]interface{}); ok {
+ if settings, ok := outbound["settings"].(map[string]any); ok {
settings["noKernelTun"] = true
} else {
// Create settings if it doesn't exist
- outbound["settings"] = map[string]interface{}{
+ outbound["settings"] = map[string]any{
"noKernelTun": true,
}
}
@@ -258,7 +293,7 @@ func (s *OutboundService) createTestConfig(outboundTag string, allOutbounds []in
outboundsJSON, _ := json.Marshal(processedOutbounds)
// Create routing rule to route all traffic through test outbound
- routingRules := []map[string]interface{}{
+ routingRules := []map[string]any{
{
"type": "field",
"outboundTag": outboundTag,
@@ -266,19 +301,23 @@ func (s *OutboundService) createTestConfig(outboundTag string, allOutbounds []in
},
}
- routingJSON, _ := json.Marshal(map[string]interface{}{
+ routingJSON, _ := json.Marshal(map[string]any{
"domainStrategy": "AsIs",
"rules": routingRules,
})
+ // Disable logging for test process to avoid creating orphaned log files
+ logConfig := map[string]any{
+ "loglevel": "warning",
+ "access": "none",
+ "error": "none",
+ "dnsLog": false,
+ }
+ logJSON, _ := json.Marshal(logConfig)
+
// Create minimal config
- config := &xray.Config{
- LogConfig: json_util.RawMessage(`{
- "loglevel":"info",
- "access":"` + config.GetBinFolderPath() + `/access_tests.log",
- "error":"` + config.GetBinFolderPath() + `/error_tests.log",
- "dnsLog":true
- }`),
+ cfg := &xray.Config{
+ LogConfig: json_util.RawMessage(logJSON),
InboundConfigs: []xray.InboundConfig{
testInbound,
},
@@ -288,10 +327,12 @@ func (s *OutboundService) createTestConfig(outboundTag string, allOutbounds []in
Stats: json_util.RawMessage(`{}`),
}
- return config
+ return cfg
}
-// testConnection tests the connection through the proxy and measures delay
+// testConnection tests the connection through the proxy and measures delay.
+// It performs a warmup request first to establish the SOCKS connection and populate DNS caches,
+// then measures the second request for a more accurate latency reading.
func (s *OutboundService) testConnection(proxyPort int, testURL string) (int64, int, error) {
// Create SOCKS5 proxy URL
proxyURL := fmt.Sprintf("socks5://127.0.0.1:%d", proxyPort)
@@ -302,18 +343,32 @@ func (s *OutboundService) testConnection(proxyPort int, testURL string) (int64,
return 0, 0, common.NewErrorf("Invalid proxy URL: %v", err)
}
- // Create HTTP client with proxy
+ // Create HTTP client with proxy and keep-alive for connection reuse
client := &http.Client{
- Timeout: 30 * time.Second,
+ Timeout: 10 * time.Second,
Transport: &http.Transport{
Proxy: http.ProxyURL(proxyURLParsed),
DialContext: (&net.Dialer{
- Timeout: 10 * time.Second,
+ Timeout: 5 * time.Second,
+ KeepAlive: 30 * time.Second,
}).DialContext,
+ TLSClientConfig: &tls.Config{InsecureSkipVerify: true},
+ MaxIdleConns: 1,
+ IdleConnTimeout: 10 * time.Second,
+ DisableCompression: true,
},
}
- // Measure time
+ // Warmup request: establishes SOCKS/TLS connection, DNS, and TCP to the target.
+ // This mirrors real-world usage where connections are reused.
+ warmupResp, err := client.Get(testURL)
+ if err != nil {
+ return 0, 0, common.NewErrorf("Request failed: %v", err)
+ }
+ io.Copy(io.Discard, warmupResp.Body)
+ warmupResp.Body.Close()
+
+ // Measure the actual request on the warm connection
startTime := time.Now()
resp, err := client.Get(testURL)
delay := time.Since(startTime).Milliseconds()
@@ -321,11 +376,26 @@ func (s *OutboundService) testConnection(proxyPort int, testURL string) (int64,
if err != nil {
return 0, 0, common.NewErrorf("Request failed: %v", err)
}
- defer resp.Body.Close()
+ io.Copy(io.Discard, resp.Body)
+ resp.Body.Close()
return delay, resp.StatusCode, nil
}
+// waitForPort polls until the given TCP port is accepting connections or the timeout expires.
+func waitForPort(port int, timeout time.Duration) error {
+ deadline := time.Now().Add(timeout)
+ for time.Now().Before(deadline) {
+ conn, err := net.DialTimeout("tcp", fmt.Sprintf("127.0.0.1:%d", port), 100*time.Millisecond)
+ if err == nil {
+ conn.Close()
+ return nil
+ }
+ time.Sleep(50 * time.Millisecond)
+ }
+ return fmt.Errorf("port %d not ready after %v", port, timeout)
+}
+
// findAvailablePort finds an available port for testing
func findAvailablePort() (int, error) {
listener, err := net.Listen("tcp", ":0")
@@ -339,7 +409,7 @@ func findAvailablePort() (int, error) {
}
// createTestConfigPath returns a unique path for a temporary xray config file in the bin folder.
-// The file is not created; the path is reserved by creating and then removing an empty temp file.
+// The temp file is created and closed so the path is reserved; Start() will overwrite it.
func createTestConfigPath() (string, error) {
tmpFile, err := os.CreateTemp(config.GetBinFolderPath(), "xray_test_*.json")
if err != nil {
@@ -350,8 +420,5 @@ func createTestConfigPath() (string, error) {
os.Remove(path)
return "", err
}
- if err := os.Remove(path); err != nil {
- return "", err
- }
return path, nil
}
diff --git a/web/service/setting.go b/web/service/setting.go
index e2feb3a7..495dc522 100644
--- a/web/service/setting.go
+++ b/web/service/setting.go
@@ -78,6 +78,8 @@ var defaultValueMap = map[string]string{
"warp": "",
"externalTrafficInformEnable": "false",
"externalTrafficInformURI": "",
+ "xrayOutboundTestUrl": "https://www.google.com/generate_204",
+
// LDAP defaults
"ldapEnable": "false",
"ldapHost": "",
@@ -99,7 +101,6 @@ var defaultValueMap = map[string]string{
"ldapDefaultTotalGB": "0",
"ldapDefaultExpiryDays": "0",
"ldapDefaultLimitIP": "0",
- "xrayOutboundTestUrl": "http://www.google.com/gen_204",
}
// SettingService provides business logic for application settings management.
diff --git a/web/translation/translate.en_US.toml b/web/translation/translate.en_US.toml
index 6edcf035..4ea136ec 100644
--- a/web/translation/translate.en_US.toml
+++ b/web/translation/translate.en_US.toml
@@ -427,8 +427,6 @@
"information" = "Information"
"language" = "Language"
"telegramBotLanguage" = "Telegram Bot Language"
-"outboundTestURL" = "Outbound Test URL"
-"outboundTestURLDesc" = "URL used to test outbound connection"
[pages.xray]
"title" = "Xray Configs"
@@ -463,7 +461,7 @@
"RoutingStrategy" = "Overall Routing Strategy"
"RoutingStrategyDesc" = "Set the overall traffic routing strategy for resolving all requests."
"outboundTestUrl" = "Outbound Test URL"
-"outboundTestUrlDesc" = "URL used when testing outbound connectivity. Default is http://www.google.com/gen_204"
+"outboundTestUrlDesc" = "URL used when testing outbound connectivity."
"Torrent" = "Block BitTorrent Protocol"
"Inbounds" = "Inbounds"
"InboundsDesc" = "Accepting the specific clients."
diff --git a/web/translation/translate.fa_IR.toml b/web/translation/translate.fa_IR.toml
index 04f8bead..8cf1671f 100644
--- a/web/translation/translate.fa_IR.toml
+++ b/web/translation/translate.fa_IR.toml
@@ -427,8 +427,6 @@
"information" = "اطلاعات"
"language" = "زبان"
"telegramBotLanguage" = "زبان ربات تلگرام"
-"outboundTestURL" = "آدرس تست خروجی"
-"outboundTestURLDesc" = "آدرسی که برای تست اتصال خروجی استفاده میشود"
[pages.xray]
"title" = "پیکربندی ایکسری"
@@ -463,7 +461,7 @@
"RoutingStrategy" = "استراتژی کلی مسیریابی"
"RoutingStrategyDesc" = "استراتژی کلی مسیریابی برای حل تمام درخواستها را تعیین میکند"
"outboundTestUrl" = "آدرس تست خروجی"
-"outboundTestUrlDesc" = "آدرسی که برای تست اتصال خروجی استفاده میشود. پیشفرض: http://www.google.com/gen_204"
+"outboundTestUrlDesc" = "آدرسی که برای تست اتصال خروجی استفاده میشود."
"Torrent" = "مسدودسازی پروتکل بیتتورنت"
"Inbounds" = "ورودیها"
"InboundsDesc" = "پذیرش کلاینت خاص"
diff --git a/web/translation/translate.ru_RU.toml b/web/translation/translate.ru_RU.toml
index 3142fb56..04af2630 100644
--- a/web/translation/translate.ru_RU.toml
+++ b/web/translation/translate.ru_RU.toml
@@ -427,8 +427,6 @@
"information" = "Информация"
"language" = "Язык интерфейса"
"telegramBotLanguage" = "Язык Telegram-бота"
-"outboundTestURL" = "URL для тестирования исходящего подключения"
-"outboundTestURLDesc" = "URL, используемый для тестирования исходящего подключения"
[pages.xray]
"title" = "Настройки Xray"
@@ -463,7 +461,7 @@
"RoutingStrategy" = "Настройка маршрутизации доменов"
"RoutingStrategyDesc" = "Установка общей стратегии маршрутизации разрешения DNS"
"outboundTestUrl" = "URL для теста исходящего"
-"outboundTestUrlDesc" = "URL для проверки подключения исходящего. По умолчанию: http://www.google.com/gen_204"
+"outboundTestUrlDesc" = "URL для проверки подключения исходящего"
"Torrent" = "Заблокировать BitTorrent"
"Inbounds" = "Входящие подключения"
"InboundsDesc" = "Изменение шаблона конфигурации для подключения определенных клиентов"
diff --git a/web/translation/translate.zh_CN.toml b/web/translation/translate.zh_CN.toml
index 37d33331..93592b98 100644
--- a/web/translation/translate.zh_CN.toml
+++ b/web/translation/translate.zh_CN.toml
@@ -427,8 +427,6 @@
"information" = "信息"
"language" = "语言"
"telegramBotLanguage" = "Telegram 机器人语言"
-"outboundTestURL" = "出站测试 URL"
-"outboundTestURLDesc" = "用于测试出站连接的 URL"
[pages.xray]
"title" = "Xray 配置"
@@ -463,7 +461,7 @@
"RoutingStrategy" = "配置路由域策略"
"RoutingStrategyDesc" = "设置 DNS 解析的整体路由策略"
"outboundTestUrl" = "出站测试 URL"
-"outboundTestUrlDesc" = "测试出站连接时使用的 URL,默认为 http://www.google.com/gen_204"
+"outboundTestUrlDesc" = "测试出站连接时使用的 URL"
"Torrent" = "屏蔽 BitTorrent 协议"
"Inbounds" = "入站规则"
"InboundsDesc" = "接受来自特定客户端的流量"
diff --git a/web/websocket/notifier.go b/web/websocket/notifier.go
index 91e52c7c..74cf61b2 100644
--- a/web/websocket/notifier.go
+++ b/web/websocket/notifier.go
@@ -49,7 +49,7 @@ func BroadcastInbounds(inbounds any) {
}
// BroadcastOutbounds broadcasts outbounds list update to all connected clients
-func BroadcastOutbounds(outbounds interface{}) {
+func BroadcastOutbounds(outbounds any) {
hub := GetHub()
if hub != nil {
hub.Broadcast(MessageTypeOutbounds, outbounds)