From 6f28a3a2fe47637a7bddc1b1cff4535f2f61b45e Mon Sep 17 00:00:00 2001 From: MHSanaei Date: Thu, 25 May 2023 03:21:31 +0330 Subject: change blockedips to AllowedIps now only those IPs that are allowed are able to establish a connection; other connections are dropped it will happen every 10 sec after user offline that IPs will be removed from AllowedIps --- xray/process.go | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'xray') diff --git a/xray/process.go b/xray/process.go index 3f6bf294..41742f3a 100644 --- a/xray/process.go +++ b/xray/process.go @@ -51,8 +51,8 @@ func GetIranPath() string { return config.GetBinFolderPath() + "/iran.dat" } -func GetBlockedIPsPath() string { - return config.GetBinFolderPath() + "/blockedIPs" +func GetAllowedIPsPath() string { + return config.GetBinFolderPath() + "/AllowedIPs" } func stopProcess(p *Process) { @@ -173,7 +173,7 @@ func (p *process) Start() (err error) { return common.NewErrorf("Failed to write configuration file: %v", err) } - cmd := exec.Command(GetBinaryPath(), "-c", configPath, "-restrictedIPsPath", GetBlockedIPsPath()) + cmd := exec.Command(GetBinaryPath(), "-c", configPath, "-restrictedIPsPath", GetAllowedIPsPath()) p.cmd = cmd stdReader, err := cmd.StdoutPipe() -- cgit v1.2.3