mirror of
https://github.com/oneclickvirt/ecs.git
synced 2025-12-20 16:29:07 +08:00
Compare commits
13 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
3d78128f6a | ||
|
|
9c67a8d446 | ||
|
|
014dba0ce6 | ||
|
|
b5fdab4b27 | ||
|
|
16c4c2ff92 | ||
|
|
e1991c850f | ||
|
|
0b7c7865ff | ||
|
|
238ea3eb6f | ||
|
|
b859c52ba3 | ||
|
|
f1642843dd | ||
|
|
90ba076afb | ||
|
|
d31d20e16f | ||
|
|
a4084835f9 |
40
README.md
40
README.md
@@ -74,35 +74,43 @@ Shell 版本:[https://github.com/spiritLHLS/ecs](https://github.com/spiritLHLS
|
|||||||
|
|
||||||
#### **一键命令**
|
#### **一键命令**
|
||||||
|
|
||||||
**一键命令**将**默认安装依赖**,**默认更新包管理器**,**默认非互动模式**
|
**一键命令**将默认**不安装依赖**,默认**不更新包管理器**,默认**非互动模式**
|
||||||
|
|
||||||
- **国际用户无加速:**
|
- **国际用户无加速:**
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
export noninteractive=true && curl -L https://raw.githubusercontent.com/oneclickvirt/ecs/master/goecs.sh -o goecs.sh && chmod +x goecs.sh && ./goecs.sh env && ./goecs.sh install && goecs
|
export noninteractive=true && curl -L https://raw.githubusercontent.com/oneclickvirt/ecs/master/goecs.sh -o goecs.sh && chmod +x goecs.sh && ./goecs.sh install && goecs
|
||||||
```
|
```
|
||||||
|
|
||||||
- **国际/国内使用 CDN 加速:**
|
- **国际/国内使用 CDN 加速:**
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
export noninteractive=true && curl -L https://cdn.spiritlhl.net/https://raw.githubusercontent.com/oneclickvirt/ecs/master/goecs.sh -o goecs.sh && chmod +x goecs.sh && ./goecs.sh env && ./goecs.sh install && goecs
|
export noninteractive=true && curl -L https://cdn.spiritlhl.net/https://raw.githubusercontent.com/oneclickvirt/ecs/master/goecs.sh -o goecs.sh && chmod +x goecs.sh && ./goecs.sh install && goecs
|
||||||
```
|
```
|
||||||
|
|
||||||
- **国内用户使用 CNB 加速:**
|
- **国内用户使用 CNB 加速:**
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
export noninteractive=true && curl -L https://cnb.cool/oneclickvirt/ecs/-/git/raw/main/goecs.sh -o goecs.sh && chmod +x goecs.sh && ./goecs.sh env && ./goecs.sh install && goecs
|
export noninteractive=true && curl -L https://cnb.cool/oneclickvirt/ecs/-/git/raw/main/goecs.sh -o goecs.sh && chmod +x goecs.sh && ./goecs.sh install && goecs
|
||||||
```
|
```
|
||||||
|
|
||||||
- **短链接:**
|
- **短链接:**
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
export noninteractive=true && curl -L https://bash.spiritlhl.net/goecs -o goecs.sh && chmod +x goecs.sh && ./goecs.sh env && ./goecs.sh install && goecs
|
export noninteractive=true && curl -L https://bash.spiritlhl.net/goecs -o goecs.sh && chmod +x goecs.sh && ./goecs.sh install && goecs
|
||||||
```
|
```
|
||||||
|
|
||||||
|
或
|
||||||
|
|
||||||
|
```bash
|
||||||
|
export noninteractive=true && curl -L https://ba.sh/JrVa -o goecs.sh && chmod +x goecs.sh && ./goecs.sh install && goecs
|
||||||
|
```
|
||||||
|
|
||||||
|
**如果需要测试更准确,请按照下面的详细说明进行安装,添加非必需的依赖**
|
||||||
|
|
||||||
#### **详细说明**
|
#### **详细说明**
|
||||||
|
|
||||||
**详细说明**中的命令**可控制是否安装依赖**,**是否更新包管理器**,**默认互动模式可进行选择**
|
以下命令可控制**是否安装依赖**,**是否更新包管理器**,**互动模式和非交互模式**
|
||||||
|
|
||||||
<details>
|
<details>
|
||||||
<summary>展开查看详细说明</summary>
|
<summary>展开查看详细说明</summary>
|
||||||
@@ -190,12 +198,18 @@ Usage: goecs [options]
|
|||||||
Enable/Disable CPU test (default true)
|
Enable/Disable CPU test (default true)
|
||||||
-cpum string
|
-cpum string
|
||||||
Set CPU test method (supported: sysbench, geekbench, winsat) (default "sysbench")
|
Set CPU test method (supported: sysbench, geekbench, winsat) (default "sysbench")
|
||||||
|
-cpu-method string
|
||||||
|
Set CPU test method (supported: sysbench, geekbench, winsat) (default "sysbench")
|
||||||
-cput string
|
-cput string
|
||||||
Set CPU test thread mode (supported: single, multi) (default "multi")
|
Set CPU test thread mode (supported: single, multi) (default "multi")
|
||||||
|
-cpu-thread string
|
||||||
|
Set CPU test thread mode (supported: single, multi) (default "multi")
|
||||||
-disk
|
-disk
|
||||||
Enable/Disable disk test (default true)
|
Enable/Disable disk test (default true)
|
||||||
-diskm string
|
-diskm string
|
||||||
Set disk test method (supported: fio, dd, winsat) (default "fio")
|
Set disk test method (supported: fio, dd, winsat) (default "fio")
|
||||||
|
-disk-method string
|
||||||
|
Set disk test method (supported: fio, dd, winsat) (default "fio")
|
||||||
-diskmc
|
-diskmc
|
||||||
Enable/Disable multiple disk checks, e.g., -diskmc=false
|
Enable/Disable multiple disk checks, e.g., -diskmc=false
|
||||||
-diskp string
|
-diskp string
|
||||||
@@ -207,20 +221,28 @@ Usage: goecs [options]
|
|||||||
Show help information
|
Show help information
|
||||||
-l string
|
-l string
|
||||||
Set language (supported: en, zh) (default "zh")
|
Set language (supported: en, zh) (default "zh")
|
||||||
|
-lang string
|
||||||
|
Set language (supported: en, zh) (default "zh")
|
||||||
-log
|
-log
|
||||||
Enable/Disable logging in the current path
|
Enable/Disable logging in the current path
|
||||||
-memory
|
-memory
|
||||||
Enable/Disable memory test (default true)
|
Enable/Disable memory test (default true)
|
||||||
-memorym string
|
-memorym string
|
||||||
Set memory test method (supported: stream, sysbench, dd, winsat, auto) (default "stream")
|
Set memory test method (supported: stream, sysbench, dd, winsat, auto) (default "stream")
|
||||||
|
-memory-method string
|
||||||
|
Set memory test method (supported: stream, sysbench, dd, winsat, auto) (default "stream")
|
||||||
-menu
|
-menu
|
||||||
Enable/Disable menu mode, disable example: -menu=false (default true)
|
Enable/Disable menu mode, disable example: -menu=false (default true)
|
||||||
-nt3
|
-nt3
|
||||||
Enable/Disable NT3 test (in 'en' language or on windows it always false) (default true)
|
Enable/Disable NT3 test (in 'en' language or on windows it always false) (default true)
|
||||||
-nt3loc string
|
-nt3loc string
|
||||||
Specify NT3 test location (supported: GZ, SH, BJ, CD, ALL for Guangzhou, Shanghai, Beijing, Chengdu and all) (default "GZ")
|
Specify NT3 test location (supported: GZ, SH, BJ, CD, ALL for Guangzhou, Shanghai, Beijing, Chengdu and all) (default "GZ")
|
||||||
|
-nt3-location string
|
||||||
|
Specify NT3 test location (supported: GZ, SH, BJ, CD, ALL for Guangzhou, Shanghai, Beijing, Chengdu and all) (default "GZ")
|
||||||
-nt3t string
|
-nt3t string
|
||||||
Set NT3 test type (supported: both, ipv4, ipv6) (default "ipv4")
|
Set NT3 test type (supported: both, ipv4, ipv6) (default "ipv4")
|
||||||
|
-nt3-type string
|
||||||
|
Set NT3 test type (supported: both, ipv4, ipv6) (default "ipv4")
|
||||||
-ping
|
-ping
|
||||||
Enable/Disable ping test
|
Enable/Disable ping test
|
||||||
-security
|
-security
|
||||||
@@ -233,8 +255,6 @@ Usage: goecs [options]
|
|||||||
Enable/Disable Telegram DC test
|
Enable/Disable Telegram DC test
|
||||||
-upload
|
-upload
|
||||||
Enable/Disable upload the result (default true)
|
Enable/Disable upload the result (default true)
|
||||||
-ut
|
|
||||||
Enable/Disable unlock media test (default true)
|
|
||||||
-v Display version information
|
-v Display version information
|
||||||
-version
|
-version
|
||||||
Display version information
|
Display version information
|
||||||
@@ -384,7 +404,9 @@ GOOS=darwin GOARCH=amd64 go build -o goecs_darwin
|
|||||||
|
|
||||||
## 致谢
|
## 致谢
|
||||||
|
|
||||||
感谢 [he.net](https://he.net) [bgp.tools](https://bgp.tools) [ipinfo.io](https://ipinfo.io) [maxmind.com](https://www.maxmind.com/en/home) [cloudflare.com](https://www.cloudflare.com/) [ip.sb](https://ip.sb) [scamalytics.com](https://scamalytics.com) [abuseipdb.com](https://www.abuseipdb.com/) [ip2location.com](https://ip2location.com/) [ip-api.com](https://ip-api.com) [ipregistry.co](https://ipregistry.co/) [ipdata.co](https://ipdata.co/) [ipgeolocation.io](https://ipgeolocation.io) [ipwhois.io](https://ipwhois.io) [ipapi.com](https://ipapi.com/) [ipapi.is](https://ipapi.is/) [ipqualityscore.com](https://www.ipqualityscore.com/) [bigdatacloud.com](https://www.bigdatacloud.com/) [dkly.net](https://data.dkly.net) [virustotal.com](https://www.virustotal.com/) [ipfighter.com](https://ipfighter.com/) [getipintel.net](http://check.getipintel.net/) [fraudlogix.com](https://fraudlogix.com) 等网站提供的API进行检测,感谢互联网各网站提供的查询资源
|
感谢
|
||||||
|
[DKLYDataHub - IP Geolocation Data](https://data.dkly.net)
|
||||||
|
[he.net](https://he.net) [bgp.tools](https://bgp.tools) [ipinfo.io](https://ipinfo.io) [maxmind.com](https://www.maxmind.com/en/home) [cloudflare.com](https://www.cloudflare.com/) [ip.sb](https://ip.sb) [scamalytics.com](https://scamalytics.com) [abuseipdb.com](https://www.abuseipdb.com/) [ip2location.com](https://ip2location.com/) [ip-api.com](https://ip-api.com) [ipregistry.co](https://ipregistry.co/) [ipdata.co](https://ipdata.co/) [ipgeolocation.io](https://ipgeolocation.io) [ipwhois.io](https://ipwhois.io) [ipapi.com](https://ipapi.com/) [ipapi.is](https://ipapi.is/) [ipqualityscore.com](https://www.ipqualityscore.com/) [bigdatacloud.com](https://www.bigdatacloud.com/) [virustotal.com](https://www.virustotal.com/) [ipfighter.com](https://ipfighter.com/) [getipintel.net](http://check.getipintel.net/) [fraudlogix.com](https://fraudlogix.com) 等网站提供的API进行检测,感谢互联网各网站提供的查询资源
|
||||||
|
|
||||||
感谢
|
感谢
|
||||||
|
|
||||||
|
|||||||
38
README_EN.md
38
README_EN.md
@@ -74,35 +74,43 @@ Shell version: [https://github.com/spiritLHLS/ecs/blob/main/README_EN.md](https:
|
|||||||
|
|
||||||
#### **One-click command**
|
#### **One-click command**
|
||||||
|
|
||||||
**One-Click Command** will **Install Dependencies by Default**, **Update Package Manager by Default**, **Default Non-Interactive Mode***
|
**One-Click Command** will **Not install Dependencies** by Default, **Not update Package Manager** by Default, **Non-Interactive Mode** by Default.
|
||||||
|
|
||||||
- **International users without acceleration:**
|
- **International users without acceleration:**
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
export noninteractive=true && curl -L https://raw.githubusercontent.com/oneclickvirt/ecs/master/goecs.sh -o goecs.sh && chmod +x goecs.sh && ./goecs.sh env && ./goecs.sh install && goecs
|
export noninteractive=true && curl -L https://raw.githubusercontent.com/oneclickvirt/ecs/master/goecs.sh -o goecs.sh && chmod +x goecs.sh && ./goecs.sh install && goecs
|
||||||
```
|
```
|
||||||
|
|
||||||
- **International/domestic users with CDN acceleration:**
|
- **International/domestic users with CDN acceleration:**
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
export noninteractive=true && curl -L https://cdn.spiritlhl.net/https://raw.githubusercontent.com/oneclickvirt/ecs/master/goecs.sh -o goecs.sh && chmod +x goecs.sh && ./goecs.sh env && ./goecs.sh install && goecs
|
export noninteractive=true && curl -L https://cdn.spiritlhl.net/https://raw.githubusercontent.com/oneclickvirt/ecs/master/goecs.sh -o goecs.sh && chmod +x goecs.sh && ./goecs.sh install && goecs
|
||||||
```
|
```
|
||||||
|
|
||||||
- **Domestic users with CNB acceleration:**
|
- **Domestic users with CNB acceleration:**
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
export noninteractive=true && curl -L https://cnb.cool/oneclickvirt/ecs/-/git/raw/main/goecs.sh -o goecs.sh && chmod +x goecs.sh && ./goecs.sh env && ./goecs.sh install && goecs
|
export noninteractive=true && curl -L https://cnb.cool/oneclickvirt/ecs/-/git/raw/main/goecs.sh -o goecs.sh && chmod +x goecs.sh && ./goecs.sh install && goecs
|
||||||
```
|
```
|
||||||
|
|
||||||
- **Short Link:**
|
- **Short Link:**
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
export noninteractive=true && curl -L https://bash.spiritlhl.net/goecs -o goecs.sh && chmod +x goecs.sh && bash goecs.sh env && bash goecs.sh install && goecs
|
export noninteractive=true && curl -L https://bash.spiritlhl.net/goecs -o goecs.sh && chmod +x goecs.sh && bash goecs.sh install && goecs
|
||||||
``
|
```
|
||||||
|
|
||||||
|
OR
|
||||||
|
|
||||||
|
```bash
|
||||||
|
export noninteractive=true && curl -L https://ba.sh/JrVa -o goecs.sh && chmod +x goecs.sh && ./goecs.sh install && goecs
|
||||||
|
```
|
||||||
|
|
||||||
|
**For more accurate testing, please follow the detailed instructions below to install and add non-essential dependencies**
|
||||||
|
|
||||||
#### **Detailed instructions**
|
#### **Detailed instructions**
|
||||||
|
|
||||||
**Detailed description** of the commands in **Command **Controls whether to install dependencies**, **Whether to update the package manager**, **Default interaction mode can be selected***
|
The following commands control whether dependencies are installed, whether the package manager is updated, and whether interactive or non-interactive mode is used.
|
||||||
|
|
||||||
<details>
|
<details>
|
||||||
<summary>Expand to view detailed instructions</summary>
|
<summary>Expand to view detailed instructions</summary>
|
||||||
@@ -189,12 +197,18 @@ Usage: goecs [options]
|
|||||||
Enable/Disable CPU test (default true)
|
Enable/Disable CPU test (default true)
|
||||||
-cpum string
|
-cpum string
|
||||||
Set CPU test method (supported: sysbench, geekbench, winsat) (default "sysbench")
|
Set CPU test method (supported: sysbench, geekbench, winsat) (default "sysbench")
|
||||||
|
-cpu-method string
|
||||||
|
Set CPU test method (supported: sysbench, geekbench, winsat) (default "sysbench")
|
||||||
-cput string
|
-cput string
|
||||||
Set CPU test thread mode (supported: single, multi) (default "multi")
|
Set CPU test thread mode (supported: single, multi) (default "multi")
|
||||||
|
-cpu-thread string
|
||||||
|
Set CPU test thread mode (supported: single, multi) (default "multi")
|
||||||
-disk
|
-disk
|
||||||
Enable/Disable disk test (default true)
|
Enable/Disable disk test (default true)
|
||||||
-diskm string
|
-diskm string
|
||||||
Set disk test method (supported: fio, dd, winsat) (default "fio")
|
Set disk test method (supported: fio, dd, winsat) (default "fio")
|
||||||
|
-disk-method string
|
||||||
|
Set disk test method (supported: fio, dd, winsat) (default "fio")
|
||||||
-diskmc
|
-diskmc
|
||||||
Enable/Disable multiple disk checks, e.g., -diskmc=false
|
Enable/Disable multiple disk checks, e.g., -diskmc=false
|
||||||
-diskp string
|
-diskp string
|
||||||
@@ -206,20 +220,28 @@ Usage: goecs [options]
|
|||||||
Show help information
|
Show help information
|
||||||
-l string
|
-l string
|
||||||
Set language (supported: en, zh) (default "zh")
|
Set language (supported: en, zh) (default "zh")
|
||||||
|
-lang string
|
||||||
|
Set language (supported: en, zh) (default "zh")
|
||||||
-log
|
-log
|
||||||
Enable/Disable logging in the current path
|
Enable/Disable logging in the current path
|
||||||
-memory
|
-memory
|
||||||
Enable/Disable memory test (default true)
|
Enable/Disable memory test (default true)
|
||||||
-memorym string
|
-memorym string
|
||||||
Set memory test method (supported: stream, sysbench, dd, winsat, auto) (default "stream")
|
Set memory test method (supported: stream, sysbench, dd, winsat, auto) (default "stream")
|
||||||
|
-memory-method string
|
||||||
|
Set memory test method (supported: stream, sysbench, dd, winsat, auto) (default "stream")
|
||||||
-menu
|
-menu
|
||||||
Enable/Disable menu mode, disable example: -menu=false (default true)
|
Enable/Disable menu mode, disable example: -menu=false (default true)
|
||||||
-nt3
|
-nt3
|
||||||
Enable/Disable NT3 test (in 'en' language or on windows it always false) (default true)
|
Enable/Disable NT3 test (in 'en' language or on windows it always false) (default true)
|
||||||
-nt3loc string
|
-nt3loc string
|
||||||
Specify NT3 test location (supported: GZ, SH, BJ, CD, ALL for Guangzhou, Shanghai, Beijing, Chengdu and all) (default "GZ")
|
Specify NT3 test location (supported: GZ, SH, BJ, CD, ALL for Guangzhou, Shanghai, Beijing, Chengdu and all) (default "GZ")
|
||||||
|
-nt3-location string
|
||||||
|
Specify NT3 test location (supported: GZ, SH, BJ, CD, ALL for Guangzhou, Shanghai, Beijing, Chengdu and all) (default "GZ")
|
||||||
-nt3t string
|
-nt3t string
|
||||||
Set NT3 test type (supported: both, ipv4, ipv6) (default "ipv4")
|
Set NT3 test type (supported: both, ipv4, ipv6) (default "ipv4")
|
||||||
|
-nt3-type string
|
||||||
|
Set NT3 test type (supported: both, ipv4, ipv6) (default "ipv4")
|
||||||
-ping
|
-ping
|
||||||
Enable/Disable ping test
|
Enable/Disable ping test
|
||||||
-security
|
-security
|
||||||
@@ -232,8 +254,6 @@ Usage: goecs [options]
|
|||||||
Enable/Disable Telegram DC test
|
Enable/Disable Telegram DC test
|
||||||
-upload
|
-upload
|
||||||
Enable/Disable upload the result (default true)
|
Enable/Disable upload the result (default true)
|
||||||
-ut
|
|
||||||
Enable/Disable unlock media test (default true)
|
|
||||||
-v Display version information
|
-v Display version information
|
||||||
-version
|
-version
|
||||||
Display version information
|
Display version information
|
||||||
|
|||||||
@@ -243,33 +243,36 @@ AMD的7950x单核满血性能得分在6500左右,AMD的5950x单核满血性能
|
|||||||
|
|
||||||
检测18个数据库的IP相关信息,多个平台比较对应检测项目都为对应值,证明当前IP确实如此,不要仅相信一个数据库源的信息:
|
检测18个数据库的IP相关信息,多个平台比较对应检测项目都为对应值,证明当前IP确实如此,不要仅相信一个数据库源的信息:
|
||||||
|
|
||||||
[ipinfo.io](https://ipinfo.io) [scamalytics.com](https://scamalytics.com) [abuseipdb.com](https://www.abuseipdb.com/) [ip2location.com](https://ip2location.com/) [ip-api.com](https://ip-api.com) [ipregistry.co](https://ipregistry.co/) [ipdata.co](https://ipdata.co/) [ipgeolocation.io](https://ipgeolocation.io) [ipwhois.io](https://ipwhois.io) [ipapi.com](https://ipapi.com/) [ipapi.is](https://ipapi.is/) [ipqualityscore.com](https://www.ipqualityscore.com/) [bigdatacloud.com](https://www.bigdatacloud.com/) [dkly.net](https://data.dkly.net) [virustotal.com](https://www.virustotal.com/) [ipfighter.com](https://ipfighter.com/) [getipintel.net](http://check.getipintel.net/) [fraudlogix.com](https://fraudlogix.com)
|
[ipinfo.io](https://ipinfo.io) [scamalytics.com](https://scamalytics.com) [abuseipdb.com](https://www.abuseipdb.com/) [ip2location.com](https://ip2location.com/) [ip-api.com](https://ip-api.com) [ipregistry.co](https://ipregistry.co/) [ipdata.co](https://ipdata.co/) [ipgeolocation.io](https://ipgeolocation.io) [ipwhois.io](https://ipwhois.io) [ipapi.com](https://ipapi.com/) [ipapi.is](https://ipapi.is/) [ipqualityscore.com](https://www.ipqualityscore.com/) [bigdatacloud.com](https://www.bigdatacloud.com/) [dkly.net](https://data.dkly.net) [virustotal.com](https://www.virustotal.com/) [ipfighter.com](https://ipfighter.com/) [getipintel.net](http://check.getipintel.net/) [fraudlogix.com](https://fraudlogix.com) [cloudflare.com](https://www.cloudflare.com/)
|
||||||
|
|
||||||
以下为每个字段的对应的含义
|
以下为每个字段的对应的含义
|
||||||
|
|
||||||
| 字段类别 | 字段名称 | 字段说明 | 可能的值 | 评分规则 |
|
| 字段类别 | 字段名称 | 字段说明 | 可能的值 | 评分规则 |
|
||||||
|---------|---------|---------|---------|---------|
|
|---------|---------|---------|---------|---------|
|
||||||
| 安全得分 | 声誉(Reputation) | IP地址在安全社区中的信誉评分 | 0-100的数值 | 越高越好 |
|
| 安全得分 | 声誉 | IP地址在安全社区中的信誉评分 | 0-100的数值 | 越高越好 |
|
||||||
| | 信任得分(Trust Score) | IP地址的可信任程度评分 | 0-100的数值 | 越高越好 |
|
| | 信任得分 | IP地址的可信任程度评分 | 0-100的数值 | 越高越好 |
|
||||||
| | VPN得分(VPN Score) | IP被识别为VPN的可能性评分 | 0-100的数值 | 越低越好 |
|
| | VPN得分 | IP被识别为VPN的可能性评分 | 0-100的数值 | 越低越好 |
|
||||||
| | 代理得分(Proxy Score) | IP被识别为代理的可能性评分 | 0-100的数值 | 越低越好 |
|
| | 代理得分 | IP被识别为代理的可能性评分 | 0-100的数值 | 越低越好 |
|
||||||
| | 社区投票-无害 | 社区成员投票认为该IP无害的分数 | 非负整数 | 越高越好 |
|
| | 社区投票-无害 | 社区成员投票认为该IP无害的分数 | 非负整数 | 越高越好 |
|
||||||
| | 社区投票-恶意 | 社区成员投票认为该IP恶意的分数 | 非负整数 | 越低越好 |
|
| | 社区投票-恶意 | 社区成员投票认为该IP恶意的分数 | 非负整数 | 越低越好 |
|
||||||
| | 威胁得分(Threat Score) | IP地址的整体威胁程度评分 | 0-100的数值 | 越低越好 |
|
| | 威胁得分 | IP地址的整体威胁程度评分 | 0-100的数值 | 越低越好 |
|
||||||
| | 欺诈得分(Fraud Score) | IP地址涉及欺诈活动的可能性评分 | 0-100的数值 | 越低越好 |
|
| | 欺诈得分 | IP地址涉及欺诈活动的可能性评分 | 0-100的数值 | 越低越好 |
|
||||||
| | 滥用得分(Abuse Score) | IP地址被报告滥用行为的评分 | 0-100的数值 | 越低越好 |
|
| | 滥用得分 | IP地址被报告滥用行为的评分 | 0-100的数值 | 越低越好 |
|
||||||
| | ASN滥用得分 | 该IP所属ASN(自治系统)的滥用评分 | 0-1的小数,可能带有风险等级标注(Low/Medium/High) | 越低越好 |
|
| | ASN滥用得分 | 该IP所属ASN(自治系统)的滥用评分 | 0-1的小数,可能带有风险等级标注(Low/Medium/High) | 越低越好 |
|
||||||
| | 公司滥用得分 | 该IP所属公司的滥用评分 | 0-1的小数,可能带有风险等级标注(Low/Medium/High) | 越低越好 |
|
| | 公司滥用得分 | 该IP所属公司的滥用评分 | 0-1的小数,可能带有风险等级标注(Low/Medium/High) | 越低越好 |
|
||||||
| | 威胁级别(Threat Level) | IP地址的威胁等级分类 | low/medium/high/critical等文本描述 | low为最佳 |
|
| | 威胁级别 | IP地址的威胁等级分类 | low/medium/high/critical等文本描述 | low为最佳 |
|
||||||
| 黑名单记录 | 无害记录数(Harmless) | 在各黑名单数据库中被标记为无害的次数 | 非负整数 | 数值本身无好坏 |
|
| | 流量占比 | 真人和机器人在本机IP的ASN所在国家的占比 | 百分数 | 真人比越高越好 |
|
||||||
| | 恶意记录数(Malicious) | 在各黑名单数据库中被标记为恶意的次数 | 非负整数 | 越低越好 |
|
| 黑名单记录 | 无害记录数 | 在各黑名单数据库中被标记为无害的次数 | 非负整数 | 数值本身无好坏 |
|
||||||
| | 可疑记录数(Suspicious) | 在各黑名单数据库中被标记为可疑的次数 | 非负整数 | 越低越好 |
|
| | 恶意记录数 | 在各黑名单数据库中被标记为恶意的次数 | 非负整数 | 越低越好 |
|
||||||
| | 无记录数(Undetected) | 在各黑名单数据库中无任何记录的次数 | 非负整数 | 数值本身无好坏 |
|
| | 可疑记录数 | 在各黑名单数据库中被标记为可疑的次数 | 非负整数 | 越低越好 |
|
||||||
|
| | 无记录数 | 在各黑名单数据库中无任何记录的次数 | 非负整数 | 数值本身无好坏 |
|
||||||
| | DNS黑名单-总检查数 | 检查的DNS黑名单数据库总数量 | 正整数 | 数值本身无好坏 |
|
| | DNS黑名单-总检查数 | 检查的DNS黑名单数据库总数量 | 正整数 | 数值本身无好坏 |
|
||||||
| | DNS黑名单-干净 | 在DNS黑名单中显示为干净(未列入)的数量 | 非负整数 | 越高越好 |
|
| | DNS黑名单-干净 | 在DNS黑名单中显示为干净(未列入)的数量 | 非负整数 | 越高越好 |
|
||||||
| | DNS黑名单-已列入 | 在DNS黑名单中已被列入的数量 | 非负整数 | 越低越好 |
|
| | DNS黑名单-已列入 | 在DNS黑名单中已被列入的数量 | 非负整数 | 越低越好 |
|
||||||
| | DNS黑名单-其他 | 在DNS黑名单检查中返回其他状态的数量 | 非负整数 | 数值本身无好坏 |
|
| | DNS黑名单-其他 | 在DNS黑名单检查中返回其他状态的数量 | 非负整数 | 数值本身无好坏 |
|
||||||
|
|
||||||
|
当本机的IP所在的ASN拥有的IP数量比较少时,流量占比可以给你提供网络邻居中有多少是真实流量的占比,目前全球的互联网流量的占比约是70%真人30%机器人(IPV4),如果需要比较你就按这个基准对比就行了,就知道是不是当前IP的ASN在本国的使用达到了互联网平均水平。如果需要具体国家的基准查询,可使用 https://trafficbenchmark.spiritlhl.net/ 自行搜索查找对比。
|
||||||
|
|
||||||
一般来说看下面的使用类型公司类型还有安全信息的判别足矣,上面的安全得分只有多个数据库确认一致才可信,不看也没啥问题。(IDC: 一般买服务器识别成这个的多,就是正常的在数据中心机房广播使用的类型)
|
一般来说看下面的使用类型公司类型还有安全信息的判别足矣,上面的安全得分只有多个数据库确认一致才可信,不看也没啥问题。(IDC: 一般买服务器识别成这个的多,就是正常的在数据中心机房广播使用的类型)
|
||||||
|
|
||||||
| 使用类型 | 说明 |
|
| 使用类型 | 说明 |
|
||||||
@@ -296,6 +299,9 @@ AMD的7950x单核满血性能得分在6500左右,AMD的5950x单核满血性能
|
|||||||
|
|
||||||
| 字段类别 | 字段名称 | 字段说明 | 可能的值 | 评分规则 |
|
| 字段类别 | 字段名称 | 字段说明 | 可能的值 | 评分规则 |
|
||||||
|---------|---------|---------|---------|---------|
|
|---------|---------|---------|---------|---------|
|
||||||
|
| 浏览器类型 | 是否为主流浏览器 | 本机IP的ASN所在国家的占比 | 百分比 | 主流的越多越好 |
|
||||||
|
| 设备类型 | 是否为桌面移动设备 | 本机IP的ASN所在国家的占比 | 百分比 | 桌面移动设备占比越多越好 |
|
||||||
|
| 操作系统类型 | 是否为主流操作系统 | 本机IP的ASN所在国家的占比 | 百分比 | 主流的越多越好 |
|
||||||
| 云提供商 | 是否云提供商(Cloud Provider) | 该IP是否属于云服务提供商 | Yes/No | 无好坏之分,仅标识 |
|
| 云提供商 | 是否云提供商(Cloud Provider) | 该IP是否属于云服务提供商 | Yes/No | 无好坏之分,仅标识 |
|
||||||
| 数据中心 | 是否数据中心(Data Center) | 该IP是否位于数据中心 | Yes/No | 如果关注解锁No为最佳 |
|
| 数据中心 | 是否数据中心(Data Center) | 该IP是否位于数据中心 | Yes/No | 如果关注解锁No为最佳 |
|
||||||
| 移动设备 | 是否移动设备(Mobile) | 该IP是否来自移动设备网络 | Yes/No | 如果关注解锁Yes为最佳 |
|
| 移动设备 | 是否移动设备(Mobile) | 该IP是否来自移动设备网络 | Yes/No | 如果关注解锁Yes为最佳 |
|
||||||
@@ -681,7 +687,7 @@ Dependency project: [https://github.com/oneclickvirt/securityCheck](https://gith
|
|||||||
|
|
||||||
Detect IP-related information from 18 databases. Multiple platforms comparing corresponding detection items all show corresponding values, proving that the current IP is indeed as such. Do not only trust information from a single database source:
|
Detect IP-related information from 18 databases. Multiple platforms comparing corresponding detection items all show corresponding values, proving that the current IP is indeed as such. Do not only trust information from a single database source:
|
||||||
|
|
||||||
[ipinfo.io](https://ipinfo.io) [scamalytics.com](https://scamalytics.com) [abuseipdb.com](https://www.abuseipdb.com/) [ip2location.com](https://ip2location.com/) [ip-api.com](https://ip-api.com) [ipregistry.co](https://ipregistry.co/) [ipdata.co](https://ipdata.co/) [ipgeolocation.io](https://ipgeolocation.io) [ipwhois.io](https://ipwhois.io) [ipapi.com](https://ipapi.com/) [ipapi.is](https://ipapi.is/) [ipqualityscore.com](https://www.ipqualityscore.com/) [bigdatacloud.com](https://www.bigdatacloud.com/) [dkly.net](https://data.dkly.net) [virustotal.com](https://www.virustotal.com/) [ipfighter.com](https://ipfighter.com/) [getipintel.net](http://check.getipintel.net/) [fraudlogix.com](https://fraudlogix.com)
|
[ipinfo.io](https://ipinfo.io) [scamalytics.com](https://scamalytics.com) [abuseipdb.com](https://www.abuseipdb.com/) [ip2location.com](https://ip2location.com/) [ip-api.com](https://ip-api.com) [ipregistry.co](https://ipregistry.co/) [ipdata.co](https://ipdata.co/) [ipgeolocation.io](https://ipgeolocation.io) [ipwhois.io](https://ipwhois.io) [ipapi.com](https://ipapi.com/) [ipapi.is](https://ipapi.is/) [ipqualityscore.com](https://www.ipqualityscore.com/) [bigdatacloud.com](https://www.bigdatacloud.com/) [dkly.net](https://data.dkly.net) [virustotal.com](https://www.virustotal.com/) [ipfighter.com](https://ipfighter.com/) [getipintel.net](http://check.getipintel.net/) [fraudlogix.com](https://fraudlogix.com) [cloudflare.com](https://www.cloudflare.com/)
|
||||||
|
|
||||||
The following are the meanings corresponding to each field
|
The following are the meanings corresponding to each field
|
||||||
|
|
||||||
@@ -699,6 +705,7 @@ The following are the meanings corresponding to each field
|
|||||||
| | ASN Abuse Score | Abuse score of the ASN (Autonomous System) to which this IP belongs | Decimal from 0-1, may include risk level notation (Low/Medium/High) | Lower is better |
|
| | ASN Abuse Score | Abuse score of the ASN (Autonomous System) to which this IP belongs | Decimal from 0-1, may include risk level notation (Low/Medium/High) | Lower is better |
|
||||||
| | Company Abuse Score | Abuse score of the company to which this IP belongs | Decimal from 0-1, may include risk level notation (Low/Medium/High) | Lower is better |
|
| | Company Abuse Score | Abuse score of the company to which this IP belongs | Decimal from 0-1, may include risk level notation (Low/Medium/High) | Lower is better |
|
||||||
| | Threat Level | Threat level classification of IP address | Text descriptions such as low/medium/high/critical | low is best |
|
| | Threat Level | Threat level classification of IP address | Text descriptions such as low/medium/high/critical | low is best |
|
||||||
|
| | Traffic Proportion | Proportion of humans versus bots within the ASN country of the local IP address | Percentage | Higher human proportion is preferable |
|
||||||
| Blacklist Records | Harmless Count | Number of times marked as harmless in various blacklist databases | Non-negative integer | Value itself has no good or bad |
|
| Blacklist Records | Harmless Count | Number of times marked as harmless in various blacklist databases | Non-negative integer | Value itself has no good or bad |
|
||||||
| | Malicious Count | Number of times marked as malicious in various blacklist databases | Non-negative integer | Lower is better |
|
| | Malicious Count | Number of times marked as malicious in various blacklist databases | Non-negative integer | Lower is better |
|
||||||
| | Suspicious Count | Number of times marked as suspicious in various blacklist databases | Non-negative integer | Lower is better |
|
| | Suspicious Count | Number of times marked as suspicious in various blacklist databases | Non-negative integer | Lower is better |
|
||||||
@@ -708,6 +715,8 @@ The following are the meanings corresponding to each field
|
|||||||
| | DNS Blacklist-Listed | Number already listed in DNS blacklists | Non-negative integer | Lower is better |
|
| | DNS Blacklist-Listed | Number already listed in DNS blacklists | Non-negative integer | Lower is better |
|
||||||
| | DNS Blacklist-Other | Number returning other statuses in DNS blacklist checks | Non-negative integer | Value itself has no good or bad |
|
| | DNS Blacklist-Other | Number returning other statuses in DNS blacklist checks | Non-negative integer | Value itself has no good or bad |
|
||||||
|
|
||||||
|
When the ASN to which this device's IP belongs has a relatively small number of IP addresses, the traffic proportion can indicate what percentage of your network neighbors constitute genuine traffic. Currently, global internet traffic is roughly 70% human and 30% bot (IPV4). If you need a comparison, use this benchmark to determine whether the ASN of your current IP has reached the internet average usage level within your country. For country-specific benchmark inquiries, you may use https://trafficbenchmark.spiritlhl.net/ to conduct your own searches and comparisons.
|
||||||
|
|
||||||
Generally speaking, checking the usage type, company type, and security information below is sufficient. The security score above is only reliable when confirmed by multiple databases, so it's not a problem to skip it. (IDC: generally buy vps identified as this much, is normal in the data center room broadcasting the type of use)
|
Generally speaking, checking the usage type, company type, and security information below is sufficient. The security score above is only reliable when confirmed by multiple databases, so it's not a problem to skip it. (IDC: generally buy vps identified as this much, is normal in the data center room broadcasting the type of use)
|
||||||
|
|
||||||
| Usage Type | Description |
|
| Usage Type | Description |
|
||||||
@@ -734,6 +743,9 @@ The above type descriptions represent the original query information types. Duri
|
|||||||
|
|
||||||
| Field Category | Field Name | Field Description | Possible Values | Scoring Rules |
|
| Field Category | Field Name | Field Description | Possible Values | Scoring Rules |
|
||||||
|---------|---------|---------|---------|---------|
|
|---------|---------|---------|---------|---------|
|
||||||
|
| BrowserType | Mainstream Browser | Proportion of ASN Country for Local IP | Percentage | Higher mainstream proportion preferable |
|
||||||
|
| DeviceType | Desktop or Mobile Device | Percentage of ASN Country for Local IP | Percentage | Higher proportion of desktop/mobile devices is preferable |
|
||||||
|
| OSType | Mainstream Operating System | Percentage of ASN Country for Local IP | Percentage | Higher proportion of mainstream systems is preferable |
|
||||||
| Cloud Provider | Is Cloud Provider | Whether this IP belongs to a cloud service provider | Yes/No | No good or bad, identification only |
|
| Cloud Provider | Is Cloud Provider | Whether this IP belongs to a cloud service provider | Yes/No | No good or bad, identification only |
|
||||||
| Data Center | Is Data Center | Whether this IP is located in a data center | Yes/No | No is best if concerned about unblocking |
|
| Data Center | Is Data Center | Whether this IP is located in a data center | Yes/No | No is best if concerned about unblocking |
|
||||||
| Mobile | Is Mobile | Whether this IP is from a mobile device network | Yes/No | Yes is best if concerned about unblocking |
|
| Mobile | Is Mobile | Whether this IP is from a mobile device network | Yes/No | Yes is best if concerned about unblocking |
|
||||||
@@ -1014,7 +1026,7 @@ IP品質によるアクセス制限に敏感なのは、実際には主要なAI
|
|||||||
|
|
||||||
18個のデータベースのIP関連情報を検出し、複数のプラットフォームで対応する検出項目がすべて対応する値である場合、現在のIPが確かにそうであることを証明します。1つのデータベースソースの情報のみを信じないでください:
|
18個のデータベースのIP関連情報を検出し、複数のプラットフォームで対応する検出項目がすべて対応する値である場合、現在のIPが確かにそうであることを証明します。1つのデータベースソースの情報のみを信じないでください:
|
||||||
|
|
||||||
[ipinfo.io](https://ipinfo.io) [scamalytics.com](https://scamalytics.com) [abuseipdb.com](https://www.abuseipdb.com/) [ip2location.com](https://ip2location.com/) [ip-api.com](https://ip-api.com) [ipregistry.co](https://ipregistry.co/) [ipdata.co](https://ipdata.co/) [ipgeolocation.io](https://ipgeolocation.io) [ipwhois.io](https://ipwhois.io) [ipapi.com](https://ipapi.com/) [ipapi.is](https://ipapi.is/) [ipqualityscore.com](https://www.ipqualityscore.com/) [bigdatacloud.com](https://www.bigdatacloud.com/) [dkly.net](https://data.dkly.net) [virustotal.com](https://www.virustotal.com/) [ipfighter.com](https://ipfighter.com/) [getipintel.net](http://check.getipintel.net/) [fraudlogix.com](https://fraudlogix.com)
|
[ipinfo.io](https://ipinfo.io) [scamalytics.com](https://scamalytics.com) [abuseipdb.com](https://www.abuseipdb.com/) [ip2location.com](https://ip2location.com/) [ip-api.com](https://ip-api.com) [ipregistry.co](https://ipregistry.co/) [ipdata.co](https://ipdata.co/) [ipgeolocation.io](https://ipgeolocation.io) [ipwhois.io](https://ipwhois.io) [ipapi.com](https://ipapi.com/) [ipapi.is](https://ipapi.is/) [ipqualityscore.com](https://www.ipqualityscore.com/) [bigdatacloud.com](https://www.bigdatacloud.com/) [dkly.net](https://data.dkly.net) [virustotal.com](https://www.virustotal.com/) [ipfighter.com](https://ipfighter.com/) [getipintel.net](http://check.getipintel.net/) [fraudlogix.com](https://fraudlogix.com) [cloudflare.com](https://www.cloudflare.com/)
|
||||||
|
|
||||||
以下は各フィールドの対応する意味です
|
以下は各フィールドの対応する意味です
|
||||||
|
|
||||||
@@ -1032,6 +1044,7 @@ IP品質によるアクセス制限に敏感なのは、実際には主要なAI
|
|||||||
| | ASN不正使用スコア | このIPが属するASN(自律システム)の不正使用スコア | 0-1の小数、リスクレベル表記付き(Low/Medium/High)の場合あり | 低いほど良い |
|
| | ASN不正使用スコア | このIPが属するASN(自律システム)の不正使用スコア | 0-1の小数、リスクレベル表記付き(Low/Medium/High)の場合あり | 低いほど良い |
|
||||||
| | 企業不正使用スコア | このIPが属する企業の不正使用スコア | 0-1の小数、リスクレベル表記付き(Low/Medium/High)の場合あり | 低いほど良い |
|
| | 企業不正使用スコア | このIPが属する企業の不正使用スコア | 0-1の小数、リスクレベル表記付き(Low/Medium/High)の場合あり | 低いほど良い |
|
||||||
| | 脅威レベル(Threat Level) | IPアドレスの脅威レベル分類 | low/medium/high/criticalなどのテキスト記述 | lowが最良 |
|
| | 脅威レベル(Threat Level) | IPアドレスの脅威レベル分類 | low/medium/high/criticalなどのテキスト記述 | lowが最良 |
|
||||||
|
| | トラフィック比率 | 本機IPのASN所在国における人間とボットの比率 | パーセンテージ | 人間比率が高いほど良い |
|
||||||
| ブラックリスト記録 | 無害記録数(Harmless) | 各ブラックリストデータベースで無害とマークされた回数 | 非負整数 | 数値自体に良し悪しなし |
|
| ブラックリスト記録 | 無害記録数(Harmless) | 各ブラックリストデータベースで無害とマークされた回数 | 非負整数 | 数値自体に良し悪しなし |
|
||||||
| | 悪意記録数(Malicious) | 各ブラックリストデータベースで悪意があるとマークされた回数 | 非負整数 | 低いほど良い |
|
| | 悪意記録数(Malicious) | 各ブラックリストデータベースで悪意があるとマークされた回数 | 非負整数 | 低いほど良い |
|
||||||
| | 疑わしい記録数(Suspicious) | 各ブラックリストデータベースで疑わしいとマークされた回数 | 非負整数 | 低いほど良い |
|
| | 疑わしい記録数(Suspicious) | 各ブラックリストデータベースで疑わしいとマークされた回数 | 非負整数 | 低いほど良い |
|
||||||
@@ -1041,6 +1054,8 @@ IP品質によるアクセス制限に敏感なのは、実際には主要なAI
|
|||||||
| | DNSブラックリスト-掲載済み | DNSブラックリストに既に掲載されている数 | 非負整数 | 低いほど良い |
|
| | DNSブラックリスト-掲載済み | DNSブラックリストに既に掲載されている数 | 非負整数 | 低いほど良い |
|
||||||
| | DNSブラックリスト-その他 | DNSブラックリストチェックで他のステータスを返した数 | 非負整数 | 数値自体に良し悪しなし |
|
| | DNSブラックリスト-その他 | DNSブラックリストチェックで他のステータスを返した数 | 非負整数 | 数値自体に良し悪しなし |
|
||||||
|
|
||||||
|
本機のIPが属するASNが保有するIP数が少ない場合、トラフィック比率からネットワーク内の実際のトラフィック割合を把握できます。現在の全世界インターネットトラフィックの割合は約70%が人間、30%がボットです(IPV4)。比較が必要な場合はこの基準値を基に照らし合わせれば、当該IPのASNが自国内でインターネット平均水準に達しているか判断できます。 特定の国の基準を照会する必要がある場合は、https://trafficbenchmark.spiritlhl.net/ で自ら検索し比較することができます。
|
||||||
|
|
||||||
一般的に以下の使用タイプ、会社タイプ、そしてセキュリティ情報の判別で十分です。上記のセキュリティスコアは複数のデータベースで一致が確認された場合のみ信頼できるため、見なくても特に問題ありません。(IDC: サーバーを購入する際、一般的にこの識別されることが多い。データセンターのサーバールームでブロードキャストに使用される通常のタイプである)
|
一般的に以下の使用タイプ、会社タイプ、そしてセキュリティ情報の判別で十分です。上記のセキュリティスコアは複数のデータベースで一致が確認された場合のみ信頼できるため、見なくても特に問題ありません。(IDC: サーバーを購入する際、一般的にこの識別されることが多い。データセンターのサーバールームでブロードキャストに使用される通常のタイプである)
|
||||||
|
|
||||||
| 使用タイプ | 説明 |
|
| 使用タイプ | 説明 |
|
||||||
@@ -1067,6 +1082,9 @@ IP品質によるアクセス制限に敏感なのは、実際には主要なAI
|
|||||||
|
|
||||||
| フィールドカテゴリ | フィールド名 | フィールド説明 | 可能な値 | 評価ルール |
|
| フィールドカテゴリ | フィールド名 | フィールド説明 | 可能な値 | 評価ルール |
|
||||||
|---------|---------|---------|---------|---------|
|
|---------|---------|---------|---------|---------|
|
||||||
|
| ブラウザタイプ | 主流ブラウザかどうか | 本機IPのASN所在国の割合 | パーセンテージ | 主流であるほど良い |
|
||||||
|
| デバイスタイプ | デスクトップ/モバイルデバイスか | 本機IPのASN所在国の割合 | パーセンテージ | デスクトップとモバイルデバイスの割合が高いほど良い |
|
||||||
|
| オペレーティングシステムタイプ | 主流OSか | 本機IPのASN所在国の割合 | パーセンテージ | 主流OSが多いほど良い |
|
||||||
| クラウドプロバイダー | クラウドプロバイダーかどうか(Cloud Provider) | このIPがクラウドサービスプロバイダーに属しているか | Yes/No | 良し悪しはなく、識別のみ |
|
| クラウドプロバイダー | クラウドプロバイダーかどうか(Cloud Provider) | このIPがクラウドサービスプロバイダーに属しているか | Yes/No | 良し悪しはなく、識別のみ |
|
||||||
| データセンター | データセンターかどうか(Data Center) | このIPがデータセンターに位置しているか | Yes/No | アンブロックを重視する場合はNoが最適 |
|
| データセンター | データセンターかどうか(Data Center) | このIPがデータセンターに位置しているか | Yes/No | アンブロックを重視する場合はNoが最適 |
|
||||||
| モバイルデバイス | モバイルデバイスかどうか(Mobile) | このIPがモバイルデバイスネットワークからのものか | Yes/No | アンブロックを重視する場合はYesが最適 |
|
| モバイルデバイス | モバイルデバイスかどうか(Mobile) | このIPがモバイルデバイスネットワークからのものか | Yes/No | アンブロックを重視する場合はYesが最適 |
|
||||||
|
|||||||
8
go.mod
8
go.mod
@@ -4,18 +4,18 @@ go 1.25.3
|
|||||||
|
|
||||||
require (
|
require (
|
||||||
github.com/imroc/req/v3 v3.54.0
|
github.com/imroc/req/v3 v3.54.0
|
||||||
github.com/oneclickvirt/UnlockTests v0.0.31-20251111095646
|
github.com/oneclickvirt/UnlockTests v0.0.33-20251126065725
|
||||||
github.com/oneclickvirt/backtrace v0.0.8-20251109090457
|
github.com/oneclickvirt/backtrace v0.0.8-20251109090457
|
||||||
github.com/oneclickvirt/basics v0.0.16-20251030093657
|
github.com/oneclickvirt/basics v0.0.16-20251112033526
|
||||||
github.com/oneclickvirt/cputest v0.0.12-20251111095842
|
github.com/oneclickvirt/cputest v0.0.12-20251111095842
|
||||||
github.com/oneclickvirt/defaultset v0.0.2-20240624082446
|
github.com/oneclickvirt/defaultset v0.0.2-20240624082446
|
||||||
github.com/oneclickvirt/disktest v0.0.10-20250924030424
|
github.com/oneclickvirt/disktest v0.0.10-20250924030424
|
||||||
github.com/oneclickvirt/gostun v0.0.5-20250727155022
|
github.com/oneclickvirt/gostun v0.0.5-20250727155022
|
||||||
github.com/oneclickvirt/memorytest v0.0.10-20250924154648
|
github.com/oneclickvirt/memorytest v0.0.10-20251218032900
|
||||||
github.com/oneclickvirt/nt3 v0.0.10-20251111095706
|
github.com/oneclickvirt/nt3 v0.0.10-20251111095706
|
||||||
github.com/oneclickvirt/pingtest v0.0.9-20251104112920
|
github.com/oneclickvirt/pingtest v0.0.9-20251104112920
|
||||||
github.com/oneclickvirt/portchecker v0.0.3-20250728015900
|
github.com/oneclickvirt/portchecker v0.0.3-20250728015900
|
||||||
github.com/oneclickvirt/security v0.0.7-20251109090041
|
github.com/oneclickvirt/security v0.0.8-20251112080734
|
||||||
github.com/oneclickvirt/speedtest v0.0.11-20251102151740
|
github.com/oneclickvirt/speedtest v0.0.11-20251102151740
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|||||||
16
go.sum
16
go.sum
@@ -94,12 +94,12 @@ github.com/modern-go/reflect2 v1.0.2 h1:xBagoLtFs94CBntxluKeaWgTMpvLxC4ur3nMaC9G
|
|||||||
github.com/modern-go/reflect2 v1.0.2/go.mod h1:yWuevngMOJpCy52FWWMvUC8ws7m/LJsjYzDa0/r8luk=
|
github.com/modern-go/reflect2 v1.0.2/go.mod h1:yWuevngMOJpCy52FWWMvUC8ws7m/LJsjYzDa0/r8luk=
|
||||||
github.com/nxtrace/NTrace-core v1.4.3-rc.1 h1:V19tkw3kKAMQOOh7Ibb/jZFBk4kMUfQYmpxxtsOfYWo=
|
github.com/nxtrace/NTrace-core v1.4.3-rc.1 h1:V19tkw3kKAMQOOh7Ibb/jZFBk4kMUfQYmpxxtsOfYWo=
|
||||||
github.com/nxtrace/NTrace-core v1.4.3-rc.1/go.mod h1:lGhfZ916pEUJh+VzWZTYu7bKBo06pAn+/gXb0A/7gGg=
|
github.com/nxtrace/NTrace-core v1.4.3-rc.1/go.mod h1:lGhfZ916pEUJh+VzWZTYu7bKBo06pAn+/gXb0A/7gGg=
|
||||||
github.com/oneclickvirt/UnlockTests v0.0.31-20251111095646 h1:GXwimPara6aY88GNYnTkFQfr/aLPsFATT4aDTRDdVsU=
|
github.com/oneclickvirt/UnlockTests v0.0.33-20251126065725 h1:VaaK2v17nLGU8FQmJRXPe2bEESzRePbGws0bfq7s/2o=
|
||||||
github.com/oneclickvirt/UnlockTests v0.0.31-20251111095646/go.mod h1:oOa6wj/qECtRMxwBO6D7o0L0F0Q/5sQ747OCnFQqoGE=
|
github.com/oneclickvirt/UnlockTests v0.0.33-20251126065725/go.mod h1:oOa6wj/qECtRMxwBO6D7o0L0F0Q/5sQ747OCnFQqoGE=
|
||||||
github.com/oneclickvirt/backtrace v0.0.8-20251109090457 h1:599/R/qMAtfPCPG1bPoi6KbjNJzVkKtxm8dvVIdtn5o=
|
github.com/oneclickvirt/backtrace v0.0.8-20251109090457 h1:599/R/qMAtfPCPG1bPoi6KbjNJzVkKtxm8dvVIdtn5o=
|
||||||
github.com/oneclickvirt/backtrace v0.0.8-20251109090457/go.mod h1:mj9TSow7FNszBb3bQj2Hhm41LwBo7HQP6sgaPtovKdM=
|
github.com/oneclickvirt/backtrace v0.0.8-20251109090457/go.mod h1:mj9TSow7FNszBb3bQj2Hhm41LwBo7HQP6sgaPtovKdM=
|
||||||
github.com/oneclickvirt/basics v0.0.16-20251030093657 h1:6SWWILNjJfMTXbspqYRpktUEOe/QIVhGonKO8ODC7n4=
|
github.com/oneclickvirt/basics v0.0.16-20251112033526 h1:bgoLaqStV3a6mbPiM++0mYizd278GVa6J6yeIiusV+A=
|
||||||
github.com/oneclickvirt/basics v0.0.16-20251030093657/go.mod h1:2PV+1ge01zb0Sqzj2V2I7P0wAdFSLF1XgAiumchJJbg=
|
github.com/oneclickvirt/basics v0.0.16-20251112033526/go.mod h1:2PV+1ge01zb0Sqzj2V2I7P0wAdFSLF1XgAiumchJJbg=
|
||||||
github.com/oneclickvirt/cputest v0.0.12-20251111095842 h1:ixZUvIkSlsIZfsg+dNDKq/FTofEtUjfA2LtpTrNr/6s=
|
github.com/oneclickvirt/cputest v0.0.12-20251111095842 h1:ixZUvIkSlsIZfsg+dNDKq/FTofEtUjfA2LtpTrNr/6s=
|
||||||
github.com/oneclickvirt/cputest v0.0.12-20251111095842/go.mod h1:vjlH8tkPFft1tlLOpeNskXVvurxkHaJ3+dgFxQGLXY4=
|
github.com/oneclickvirt/cputest v0.0.12-20251111095842/go.mod h1:vjlH8tkPFft1tlLOpeNskXVvurxkHaJ3+dgFxQGLXY4=
|
||||||
github.com/oneclickvirt/dd v0.0.2-20250808062818 h1:0KHrKkdpL5oBE1OHsrRd2siRw4/2k6f9LBaP7T4JpOc=
|
github.com/oneclickvirt/dd v0.0.2-20250808062818 h1:0KHrKkdpL5oBE1OHsrRd2siRw4/2k6f9LBaP7T4JpOc=
|
||||||
@@ -114,16 +114,16 @@ github.com/oneclickvirt/gostun v0.0.5-20250727155022 h1:/e3gSUrOp1tg/1NTRx+P8B51
|
|||||||
github.com/oneclickvirt/gostun v0.0.5-20250727155022/go.mod h1:pfp7MFZJK9n/KTLAVqqFcCAns4xqMykmjI+1UeF/vdE=
|
github.com/oneclickvirt/gostun v0.0.5-20250727155022/go.mod h1:pfp7MFZJK9n/KTLAVqqFcCAns4xqMykmjI+1UeF/vdE=
|
||||||
github.com/oneclickvirt/mbw v0.0.1-20250808061222 h1:WGXOe6QvHiDRhPVMI0VcctjzW08kGvJf50yq5YeZCtw=
|
github.com/oneclickvirt/mbw v0.0.1-20250808061222 h1:WGXOe6QvHiDRhPVMI0VcctjzW08kGvJf50yq5YeZCtw=
|
||||||
github.com/oneclickvirt/mbw v0.0.1-20250808061222/go.mod h1:0Vq6NRpyLmGUdfHfL3uDcFsuZhi7KlG+OCs5ky2757Y=
|
github.com/oneclickvirt/mbw v0.0.1-20250808061222/go.mod h1:0Vq6NRpyLmGUdfHfL3uDcFsuZhi7KlG+OCs5ky2757Y=
|
||||||
github.com/oneclickvirt/memorytest v0.0.10-20250924154648 h1:trk6oZ7xs1eVtr+6oIv5IX8LDVtEMG+E6GVzQ810BtU=
|
github.com/oneclickvirt/memorytest v0.0.10-20251218032900 h1:SmRFfPLyGfTVWIgC50lEGgOpbqahtMHIlyOMSbrhj9Y=
|
||||||
github.com/oneclickvirt/memorytest v0.0.10-20250924154648/go.mod h1:4kiHsEWkW9r3/1ZcV5xIweU0smiKP0IRfQj74AUIiVI=
|
github.com/oneclickvirt/memorytest v0.0.10-20251218032900/go.mod h1:4kiHsEWkW9r3/1ZcV5xIweU0smiKP0IRfQj74AUIiVI=
|
||||||
github.com/oneclickvirt/nt3 v0.0.10-20251111095706 h1:GEdgL6oAWXY80NIq23mLjcTR3gvLGh9iusFzJK6SoDo=
|
github.com/oneclickvirt/nt3 v0.0.10-20251111095706 h1:GEdgL6oAWXY80NIq23mLjcTR3gvLGh9iusFzJK6SoDo=
|
||||||
github.com/oneclickvirt/nt3 v0.0.10-20251111095706/go.mod h1:yo1ufkduFt9QjqG7nqSUf1D3YlQOmFpdlTYniJfclQI=
|
github.com/oneclickvirt/nt3 v0.0.10-20251111095706/go.mod h1:yo1ufkduFt9QjqG7nqSUf1D3YlQOmFpdlTYniJfclQI=
|
||||||
github.com/oneclickvirt/pingtest v0.0.9-20251104112920 h1:j3Fjhy0YHT/VF7iuAVVELaRXkquvRd64tWWfFLJs01o=
|
github.com/oneclickvirt/pingtest v0.0.9-20251104112920 h1:j3Fjhy0YHT/VF7iuAVVELaRXkquvRd64tWWfFLJs01o=
|
||||||
github.com/oneclickvirt/pingtest v0.0.9-20251104112920/go.mod h1:gxwsxxwitNQiGq2OI0ZogYoOLwc8DtuOdSRe6/EvRqs=
|
github.com/oneclickvirt/pingtest v0.0.9-20251104112920/go.mod h1:gxwsxxwitNQiGq2OI0ZogYoOLwc8DtuOdSRe6/EvRqs=
|
||||||
github.com/oneclickvirt/portchecker v0.0.3-20250728015900 h1:AomzdppSOFB70AJESQhlp0IPbsHTTJGimAWDk2TzCWM=
|
github.com/oneclickvirt/portchecker v0.0.3-20250728015900 h1:AomzdppSOFB70AJESQhlp0IPbsHTTJGimAWDk2TzCWM=
|
||||||
github.com/oneclickvirt/portchecker v0.0.3-20250728015900/go.mod h1:9sjMDPCd4Z40wkYB0S9gQPGH8YPtnNE1ZJthVIuHUzA=
|
github.com/oneclickvirt/portchecker v0.0.3-20250728015900/go.mod h1:9sjMDPCd4Z40wkYB0S9gQPGH8YPtnNE1ZJthVIuHUzA=
|
||||||
github.com/oneclickvirt/security v0.0.7-20251109090041 h1:H5Brkx2pKNRZAnvk1wABFcg+krXAygHgWV9R3+LU7xE=
|
github.com/oneclickvirt/security v0.0.8-20251112080734 h1:WpwdGbwpiBP2YA1lNsymati5uvBbWFlN9CXHYgd3/fE=
|
||||||
github.com/oneclickvirt/security v0.0.7-20251109090041/go.mod h1:YfDilPFW22szjdUNgv4VOuSwHnZzsFsdPOfRYiMoc3I=
|
github.com/oneclickvirt/security v0.0.8-20251112080734/go.mod h1:aPMIwqsz7wiUH1cqvtRr9+QcQRkKzlUWecDM6SGVddc=
|
||||||
github.com/oneclickvirt/speedtest v0.0.11-20251102151740 h1:1NUrNt5ay6/xVNC5x62UrQjPqK8jgbKtyjBml/3boZg=
|
github.com/oneclickvirt/speedtest v0.0.11-20251102151740 h1:1NUrNt5ay6/xVNC5x62UrQjPqK8jgbKtyjBml/3boZg=
|
||||||
github.com/oneclickvirt/speedtest v0.0.11-20251102151740/go.mod h1:fy0II2Wo7kDWVBKTwcHdodZwyfmJo0g8N9V02EwQDZE=
|
github.com/oneclickvirt/speedtest v0.0.11-20251102151740/go.mod h1:fy0II2Wo7kDWVBKTwcHdodZwyfmJo0g8N9V02EwQDZE=
|
||||||
github.com/oneclickvirt/stream v0.0.2-20250924154001 h1:GuJWdiPkoK84+y/+oHKr2Ghl3c/MzS9Z5m1nM+lMmy4=
|
github.com/oneclickvirt/stream v0.0.2-20250924154001 h1:GuJWdiPkoK84+y/+oHKr2Ghl3c/MzS9Z5m1nM+lMmy4=
|
||||||
|
|||||||
2
goecs.go
2
goecs.go
@@ -27,7 +27,7 @@ import (
|
|||||||
)
|
)
|
||||||
|
|
||||||
var (
|
var (
|
||||||
ecsVersion = "v0.1.103" // 融合怪版本号
|
ecsVersion = "v0.1.106" // 融合怪版本号
|
||||||
configs = params.NewConfig(ecsVersion) // 全局配置实例
|
configs = params.NewConfig(ecsVersion) // 全局配置实例
|
||||||
userSetFlags = make(map[string]bool) // 用于跟踪哪些参数是用户显式设置的
|
userSetFlags = make(map[string]bool) // 用于跟踪哪些参数是用户显式设置的
|
||||||
)
|
)
|
||||||
|
|||||||
6
goecs.sh
6
goecs.sh
@@ -152,7 +152,7 @@ goecs_check() {
|
|||||||
os=$(uname -s 2>/dev/null || echo "Unknown")
|
os=$(uname -s 2>/dev/null || echo "Unknown")
|
||||||
arch=$(uname -m 2>/dev/null || echo "Unknown")
|
arch=$(uname -m 2>/dev/null || echo "Unknown")
|
||||||
check_china
|
check_china
|
||||||
ECS_VERSION="0.1.102"
|
ECS_VERSION="0.1.105"
|
||||||
for api in \
|
for api in \
|
||||||
"https://api.github.com/repos/oneclickvirt/ecs/releases/latest" \
|
"https://api.github.com/repos/oneclickvirt/ecs/releases/latest" \
|
||||||
"https://githubapi.spiritlhl.workers.dev/repos/oneclickvirt/ecs/releases/latest" \
|
"https://githubapi.spiritlhl.workers.dev/repos/oneclickvirt/ecs/releases/latest" \
|
||||||
@@ -164,8 +164,8 @@ goecs_check() {
|
|||||||
sleep 1
|
sleep 1
|
||||||
done
|
done
|
||||||
if [ -z "$ECS_VERSION" ]; then
|
if [ -z "$ECS_VERSION" ]; then
|
||||||
_yellow "Unable to get version info, using default version 0.1.102"
|
_yellow "Unable to get version info, using default version 0.1.105"
|
||||||
ECS_VERSION="0.1.102"
|
ECS_VERSION="0.1.105"
|
||||||
fi
|
fi
|
||||||
version_output=""
|
version_output=""
|
||||||
for cmd_path in "goecs" "./goecs" "/usr/bin/goecs" "/usr/local/bin/goecs"; do
|
for cmd_path in "goecs" "./goecs" "/usr/bin/goecs" "/usr/local/bin/goecs"; do
|
||||||
|
|||||||
@@ -53,11 +53,19 @@ func NewConfig(version string) *Config {
|
|||||||
return &Config{
|
return &Config{
|
||||||
EcsVersion: version,
|
EcsVersion: version,
|
||||||
MenuMode: true,
|
MenuMode: true,
|
||||||
|
OnlyChinaTest: false,
|
||||||
|
Input: "",
|
||||||
|
Choice: "",
|
||||||
|
ShowVersion: false,
|
||||||
|
EnableLogger: false,
|
||||||
Language: "zh",
|
Language: "zh",
|
||||||
CpuTestMethod: "sysbench",
|
CpuTestMethod: "sysbench",
|
||||||
CpuTestThreadMode: "multi",
|
CpuTestThreadMode: "multi",
|
||||||
MemoryTestMethod: "stream",
|
MemoryTestMethod: "stream",
|
||||||
DiskTestMethod: "fio",
|
DiskTestMethod: "fio",
|
||||||
|
DiskTestPath: "",
|
||||||
|
DiskMultiCheck: false,
|
||||||
|
Nt3CheckType: "ipv4",
|
||||||
SpNum: 2,
|
SpNum: 2,
|
||||||
Width: 82,
|
Width: 82,
|
||||||
BasicStatus: true,
|
BasicStatus: true,
|
||||||
@@ -70,11 +78,15 @@ func NewConfig(version string) *Config {
|
|||||||
BacktraceStatus: true,
|
BacktraceStatus: true,
|
||||||
Nt3Status: true,
|
Nt3Status: true,
|
||||||
SpeedTestStatus: true,
|
SpeedTestStatus: true,
|
||||||
Nt3Location: "GZ",
|
PingTestStatus: false,
|
||||||
Nt3CheckType: "ipv4",
|
TgdcTestStatus: false,
|
||||||
|
WebTestStatus: false,
|
||||||
AutoChangeDiskMethod: true,
|
AutoChangeDiskMethod: true,
|
||||||
FilePath: "goecs.txt",
|
FilePath: "goecs.txt",
|
||||||
EnableUpload: true,
|
EnableUpload: true,
|
||||||
|
OnlyIpInfoCheck: false,
|
||||||
|
Help: false,
|
||||||
|
Finish: false,
|
||||||
UserSetFlags: make(map[string]bool),
|
UserSetFlags: make(map[string]bool),
|
||||||
GoecsFlag: flag.NewFlagSet("goecs", flag.ContinueOnError),
|
GoecsFlag: flag.NewFlagSet("goecs", flag.ContinueOnError),
|
||||||
}
|
}
|
||||||
@@ -87,6 +99,7 @@ func (c *Config) ParseFlags(args []string) {
|
|||||||
c.GoecsFlag.BoolVar(&c.ShowVersion, "v", false, "Display version information")
|
c.GoecsFlag.BoolVar(&c.ShowVersion, "v", false, "Display version information")
|
||||||
c.GoecsFlag.BoolVar(&c.ShowVersion, "version", false, "Display version information")
|
c.GoecsFlag.BoolVar(&c.ShowVersion, "version", false, "Display version information")
|
||||||
c.GoecsFlag.BoolVar(&c.MenuMode, "menu", true, "Enable/Disable menu mode, disable example: -menu=false")
|
c.GoecsFlag.BoolVar(&c.MenuMode, "menu", true, "Enable/Disable menu mode, disable example: -menu=false")
|
||||||
|
c.GoecsFlag.StringVar(&c.Language, "lang", "zh", "Set language (supported: en, zh)")
|
||||||
c.GoecsFlag.StringVar(&c.Language, "l", "zh", "Set language (supported: en, zh)")
|
c.GoecsFlag.StringVar(&c.Language, "l", "zh", "Set language (supported: en, zh)")
|
||||||
c.GoecsFlag.BoolVar(&c.BasicStatus, "basic", true, "Enable/Disable basic test")
|
c.GoecsFlag.BoolVar(&c.BasicStatus, "basic", true, "Enable/Disable basic test")
|
||||||
c.GoecsFlag.BoolVar(&c.CpuTestStatus, "cpu", true, "Enable/Disable CPU test")
|
c.GoecsFlag.BoolVar(&c.CpuTestStatus, "cpu", true, "Enable/Disable CPU test")
|
||||||
@@ -102,13 +115,19 @@ func (c *Config) ParseFlags(args []string) {
|
|||||||
c.GoecsFlag.BoolVar(&c.TgdcTestStatus, "tgdc", false, "Enable/Disable Telegram DC test")
|
c.GoecsFlag.BoolVar(&c.TgdcTestStatus, "tgdc", false, "Enable/Disable Telegram DC test")
|
||||||
c.GoecsFlag.BoolVar(&c.WebTestStatus, "web", false, "Enable/Disable popular websites test")
|
c.GoecsFlag.BoolVar(&c.WebTestStatus, "web", false, "Enable/Disable popular websites test")
|
||||||
c.GoecsFlag.StringVar(&c.CpuTestMethod, "cpum", "sysbench", "Set CPU test method (supported: sysbench, geekbench, winsat)")
|
c.GoecsFlag.StringVar(&c.CpuTestMethod, "cpum", "sysbench", "Set CPU test method (supported: sysbench, geekbench, winsat)")
|
||||||
|
c.GoecsFlag.StringVar(&c.CpuTestMethod, "cpu-method", "sysbench", "Set CPU test method (supported: sysbench, geekbench, winsat)")
|
||||||
c.GoecsFlag.StringVar(&c.CpuTestThreadMode, "cput", "multi", "Set CPU test thread mode (supported: single, multi)")
|
c.GoecsFlag.StringVar(&c.CpuTestThreadMode, "cput", "multi", "Set CPU test thread mode (supported: single, multi)")
|
||||||
|
c.GoecsFlag.StringVar(&c.CpuTestThreadMode, "cpu-thread", "multi", "Set CPU test thread mode (supported: single, multi)")
|
||||||
c.GoecsFlag.StringVar(&c.MemoryTestMethod, "memorym", "stream", "Set memory test method (supported: stream, sysbench, dd, winsat, auto)")
|
c.GoecsFlag.StringVar(&c.MemoryTestMethod, "memorym", "stream", "Set memory test method (supported: stream, sysbench, dd, winsat, auto)")
|
||||||
|
c.GoecsFlag.StringVar(&c.MemoryTestMethod, "memory-method", "stream", "Set memory test method (supported: stream, sysbench, dd, winsat, auto)")
|
||||||
c.GoecsFlag.StringVar(&c.DiskTestMethod, "diskm", "fio", "Set disk test method (supported: fio, dd, winsat)")
|
c.GoecsFlag.StringVar(&c.DiskTestMethod, "diskm", "fio", "Set disk test method (supported: fio, dd, winsat)")
|
||||||
|
c.GoecsFlag.StringVar(&c.DiskTestMethod, "disk-method", "fio", "Set disk test method (supported: fio, dd, winsat)")
|
||||||
c.GoecsFlag.StringVar(&c.DiskTestPath, "diskp", "", "Set disk test path, e.g., -diskp /root")
|
c.GoecsFlag.StringVar(&c.DiskTestPath, "diskp", "", "Set disk test path, e.g., -diskp /root")
|
||||||
c.GoecsFlag.BoolVar(&c.DiskMultiCheck, "diskmc", false, "Enable/Disable multiple disk checks, e.g., -diskmc=false")
|
c.GoecsFlag.BoolVar(&c.DiskMultiCheck, "diskmc", false, "Enable/Disable multiple disk checks, e.g., -diskmc=false")
|
||||||
c.GoecsFlag.StringVar(&c.Nt3Location, "nt3loc", "GZ", "Specify NT3 test location (supported: GZ, SH, BJ, CD, ALL for Guangzhou, Shanghai, Beijing, Chengdu and all)")
|
c.GoecsFlag.StringVar(&c.Nt3Location, "nt3loc", "GZ", "Specify NT3 test location (supported: GZ, SH, BJ, CD, ALL for Guangzhou, Shanghai, Beijing, Chengdu and all)")
|
||||||
|
c.GoecsFlag.StringVar(&c.Nt3Location, "nt3-location", "GZ", "Specify NT3 test location (supported: GZ, SH, BJ, CD, ALL for Guangzhou, Shanghai, Beijing, Chengdu and all)")
|
||||||
c.GoecsFlag.StringVar(&c.Nt3CheckType, "nt3t", "ipv4", "Set NT3 test type (supported: both, ipv4, ipv6)")
|
c.GoecsFlag.StringVar(&c.Nt3CheckType, "nt3t", "ipv4", "Set NT3 test type (supported: both, ipv4, ipv6)")
|
||||||
|
c.GoecsFlag.StringVar(&c.Nt3CheckType, "nt3-type", "ipv4", "Set NT3 test type (supported: both, ipv4, ipv6)")
|
||||||
c.GoecsFlag.IntVar(&c.SpNum, "spnum", 2, "Set the number of servers per operator for speed test")
|
c.GoecsFlag.IntVar(&c.SpNum, "spnum", 2, "Set the number of servers per operator for speed test")
|
||||||
c.GoecsFlag.BoolVar(&c.EnableLogger, "log", false, "Enable/Disable logging in the current path")
|
c.GoecsFlag.BoolVar(&c.EnableLogger, "log", false, "Enable/Disable logging in the current path")
|
||||||
c.GoecsFlag.BoolVar(&c.EnableUpload, "upload", true, "Enable/Disable upload the result")
|
c.GoecsFlag.BoolVar(&c.EnableUpload, "upload", true, "Enable/Disable upload the result")
|
||||||
@@ -176,16 +195,16 @@ func (c *Config) SaveUserSetParams() map[string]interface{} {
|
|||||||
if c.UserSetFlags["web"] {
|
if c.UserSetFlags["web"] {
|
||||||
saved["web"] = c.WebTestStatus
|
saved["web"] = c.WebTestStatus
|
||||||
}
|
}
|
||||||
if c.UserSetFlags["cpum"] {
|
if c.UserSetFlags["cpum"] || c.UserSetFlags["cpu-method"] {
|
||||||
saved["cpum"] = c.CpuTestMethod
|
saved["cpum"] = c.CpuTestMethod
|
||||||
}
|
}
|
||||||
if c.UserSetFlags["cput"] {
|
if c.UserSetFlags["cput"] || c.UserSetFlags["cpu-thread"] {
|
||||||
saved["cput"] = c.CpuTestThreadMode
|
saved["cput"] = c.CpuTestThreadMode
|
||||||
}
|
}
|
||||||
if c.UserSetFlags["memorym"] {
|
if c.UserSetFlags["memorym"] || c.UserSetFlags["memory-method"] {
|
||||||
saved["memorym"] = c.MemoryTestMethod
|
saved["memorym"] = c.MemoryTestMethod
|
||||||
}
|
}
|
||||||
if c.UserSetFlags["diskm"] {
|
if c.UserSetFlags["diskm"] || c.UserSetFlags["disk-method"] {
|
||||||
saved["diskm"] = c.DiskTestMethod
|
saved["diskm"] = c.DiskTestMethod
|
||||||
}
|
}
|
||||||
if c.UserSetFlags["diskp"] {
|
if c.UserSetFlags["diskp"] {
|
||||||
@@ -194,10 +213,10 @@ func (c *Config) SaveUserSetParams() map[string]interface{} {
|
|||||||
if c.UserSetFlags["diskmc"] {
|
if c.UserSetFlags["diskmc"] {
|
||||||
saved["diskmc"] = c.DiskMultiCheck
|
saved["diskmc"] = c.DiskMultiCheck
|
||||||
}
|
}
|
||||||
if c.UserSetFlags["nt3loc"] {
|
if c.UserSetFlags["nt3loc"] || c.UserSetFlags["nt3-location"] {
|
||||||
saved["nt3loc"] = c.Nt3Location
|
saved["nt3loc"] = c.Nt3Location
|
||||||
}
|
}
|
||||||
if c.UserSetFlags["nt3t"] {
|
if c.UserSetFlags["nt3t"] || c.UserSetFlags["nt3-type"] {
|
||||||
saved["nt3t"] = c.Nt3CheckType
|
saved["nt3t"] = c.Nt3CheckType
|
||||||
}
|
}
|
||||||
if c.UserSetFlags["spnum"] {
|
if c.UserSetFlags["spnum"] {
|
||||||
|
|||||||
@@ -25,51 +25,132 @@ func MemoryTest(language, testMethod string) (realTestMethod, res string) {
|
|||||||
if runtime.GOOS == "windows" {
|
if runtime.GOOS == "windows" {
|
||||||
switch testMethod {
|
switch testMethod {
|
||||||
case "stream":
|
case "stream":
|
||||||
res = memory.WinsatTest(language)
|
res = memory.StreamTest(language)
|
||||||
realTestMethod = "winsat"
|
if res == "" || strings.TrimSpace(res) == "" {
|
||||||
|
res = memory.WinsatTest(language)
|
||||||
|
if res == "" || strings.TrimSpace(res) == "" {
|
||||||
|
res = memory.WindowsDDTest(language)
|
||||||
|
if res == "" || strings.TrimSpace(res) == "" {
|
||||||
|
realTestMethod = ""
|
||||||
|
} else {
|
||||||
|
realTestMethod = "dd"
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
realTestMethod = "winsat"
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
realTestMethod = "stream"
|
||||||
|
}
|
||||||
case "dd":
|
case "dd":
|
||||||
res = memory.WindowsDDTest(language)
|
res = memory.WindowsDDTest(language)
|
||||||
if res == "" || strings.TrimSpace(res) == "" {
|
if res == "" || strings.TrimSpace(res) == "" {
|
||||||
res += memory.WinsatTest(language)
|
res = memory.WinsatTest(language)
|
||||||
realTestMethod = "winsat"
|
if res == "" || strings.TrimSpace(res) == "" {
|
||||||
|
res = memory.StreamTest(language)
|
||||||
|
if res == "" || strings.TrimSpace(res) == "" {
|
||||||
|
realTestMethod = ""
|
||||||
|
} else {
|
||||||
|
realTestMethod = "stream"
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
realTestMethod = "winsat"
|
||||||
|
}
|
||||||
} else {
|
} else {
|
||||||
realTestMethod = "dd"
|
realTestMethod = "dd"
|
||||||
}
|
}
|
||||||
case "sysbench":
|
case "sysbench":
|
||||||
|
// Windows下不支持sysbench,使用stream → winsat → dd
|
||||||
|
res = memory.StreamTest(language)
|
||||||
|
if res == "" || strings.TrimSpace(res) == "" {
|
||||||
|
res = memory.WinsatTest(language)
|
||||||
|
if res == "" || strings.TrimSpace(res) == "" {
|
||||||
|
res = memory.WindowsDDTest(language)
|
||||||
|
if res == "" || strings.TrimSpace(res) == "" {
|
||||||
|
realTestMethod = ""
|
||||||
|
} else {
|
||||||
|
realTestMethod = "dd"
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
realTestMethod = "winsat"
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
realTestMethod = "stream"
|
||||||
|
}
|
||||||
|
case "auto":
|
||||||
|
res = memory.StreamTest(language)
|
||||||
|
if res == "" || strings.TrimSpace(res) == "" {
|
||||||
|
res = memory.WinsatTest(language)
|
||||||
|
if res == "" || strings.TrimSpace(res) == "" {
|
||||||
|
res = memory.WindowsDDTest(language)
|
||||||
|
if res == "" || strings.TrimSpace(res) == "" {
|
||||||
|
realTestMethod = ""
|
||||||
|
} else {
|
||||||
|
realTestMethod = "dd"
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
realTestMethod = "winsat"
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
realTestMethod = "stream"
|
||||||
|
}
|
||||||
|
case "winsat":
|
||||||
res = memory.WinsatTest(language)
|
res = memory.WinsatTest(language)
|
||||||
realTestMethod = "winsat"
|
if res == "" || strings.TrimSpace(res) == "" {
|
||||||
case "auto", "winsat":
|
res = memory.StreamTest(language)
|
||||||
res = memory.WinsatTest(language)
|
if res == "" || strings.TrimSpace(res) == "" {
|
||||||
realTestMethod = "winsat"
|
res = memory.WindowsDDTest(language)
|
||||||
|
if res == "" || strings.TrimSpace(res) == "" {
|
||||||
|
realTestMethod = ""
|
||||||
|
} else {
|
||||||
|
realTestMethod = "dd"
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
realTestMethod = "stream"
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
realTestMethod = "winsat"
|
||||||
|
}
|
||||||
default:
|
default:
|
||||||
res = memory.WinsatTest(language)
|
res = memory.StreamTest(language)
|
||||||
realTestMethod = "winsat"
|
if res == "" || strings.TrimSpace(res) == "" {
|
||||||
|
res = memory.WinsatTest(language)
|
||||||
|
if res == "" || strings.TrimSpace(res) == "" {
|
||||||
|
res = memory.WindowsDDTest(language)
|
||||||
|
if res == "" || strings.TrimSpace(res) == "" {
|
||||||
|
realTestMethod = ""
|
||||||
|
} else {
|
||||||
|
realTestMethod = "dd"
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
realTestMethod = "winsat"
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
realTestMethod = "stream"
|
||||||
|
}
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
switch testMethod {
|
switch testMethod {
|
||||||
case "stream":
|
case "stream":
|
||||||
res = memory.StreamTest(language)
|
res = memory.StreamTest(language)
|
||||||
if res == "" || strings.TrimSpace(res) == "" {
|
if res == "" || strings.TrimSpace(res) == "" {
|
||||||
res += memory.DDTest(language)
|
res = memory.SysBenchTest(language)
|
||||||
realTestMethod = "dd"
|
if res == "" || strings.TrimSpace(res) == "" {
|
||||||
|
res = memory.DDTest(language)
|
||||||
|
if res == "" || strings.TrimSpace(res) == "" {
|
||||||
|
realTestMethod = ""
|
||||||
|
} else {
|
||||||
|
realTestMethod = "dd"
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
realTestMethod = "sysbench"
|
||||||
|
}
|
||||||
} else {
|
} else {
|
||||||
realTestMethod = "stream"
|
realTestMethod = "stream"
|
||||||
}
|
}
|
||||||
case "dd":
|
case "dd":
|
||||||
res = memory.DDTest(language)
|
res = memory.DDTest(language)
|
||||||
realTestMethod = "dd"
|
|
||||||
case "sysbench":
|
|
||||||
res = memory.SysBenchTest(language)
|
|
||||||
if res == "" || strings.TrimSpace(res) == "" {
|
if res == "" || strings.TrimSpace(res) == "" {
|
||||||
res += memory.DDTest(language)
|
res = memory.StreamTest(language)
|
||||||
realTestMethod = "dd"
|
|
||||||
} else {
|
|
||||||
realTestMethod = "sysbench"
|
|
||||||
}
|
|
||||||
case "auto":
|
|
||||||
res = memory.StreamTest(language)
|
|
||||||
if res == "" || strings.TrimSpace(res) == "" {
|
|
||||||
res = memory.DDTest(language)
|
|
||||||
if res == "" || strings.TrimSpace(res) == "" {
|
if res == "" || strings.TrimSpace(res) == "" {
|
||||||
res = memory.SysBenchTest(language)
|
res = memory.SysBenchTest(language)
|
||||||
if res == "" || strings.TrimSpace(res) == "" {
|
if res == "" || strings.TrimSpace(res) == "" {
|
||||||
@@ -78,15 +159,68 @@ func MemoryTest(language, testMethod string) (realTestMethod, res string) {
|
|||||||
realTestMethod = "sysbench"
|
realTestMethod = "sysbench"
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
realTestMethod = "dd"
|
realTestMethod = "stream"
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
realTestMethod = "dd"
|
||||||
|
}
|
||||||
|
case "sysbench":
|
||||||
|
res = memory.SysBenchTest(language)
|
||||||
|
if res == "" || strings.TrimSpace(res) == "" {
|
||||||
|
res = memory.StreamTest(language)
|
||||||
|
if res == "" || strings.TrimSpace(res) == "" {
|
||||||
|
res = memory.SysBenchTest(language)
|
||||||
|
if res == "" || strings.TrimSpace(res) == "" {
|
||||||
|
res = memory.DDTest(language)
|
||||||
|
if res == "" || strings.TrimSpace(res) == "" {
|
||||||
|
realTestMethod = ""
|
||||||
|
} else {
|
||||||
|
realTestMethod = "dd"
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
realTestMethod = "sysbench"
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
realTestMethod = "stream"
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
realTestMethod = "sysbench"
|
||||||
|
}
|
||||||
|
case "auto":
|
||||||
|
res = memory.StreamTest(language)
|
||||||
|
if res == "" || strings.TrimSpace(res) == "" {
|
||||||
|
res = memory.SysBenchTest(language)
|
||||||
|
if res == "" || strings.TrimSpace(res) == "" {
|
||||||
|
res = memory.DDTest(language)
|
||||||
|
if res == "" || strings.TrimSpace(res) == "" {
|
||||||
|
realTestMethod = ""
|
||||||
|
} else {
|
||||||
|
realTestMethod = "dd"
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
realTestMethod = "sysbench"
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
realTestMethod = "stream"
|
realTestMethod = "stream"
|
||||||
}
|
}
|
||||||
case "winsat":
|
case "winsat":
|
||||||
// winsat 仅 Windows 支持,非 Windows fallback 到 dd
|
// winsat 仅 Windows 支持,非 Windows fallback 到 stream → sysbench → dd
|
||||||
res = memory.DDTest(language)
|
res = memory.StreamTest(language)
|
||||||
realTestMethod = "dd"
|
if res == "" || strings.TrimSpace(res) == "" {
|
||||||
|
res = memory.SysBenchTest(language)
|
||||||
|
if res == "" || strings.TrimSpace(res) == "" {
|
||||||
|
res = memory.DDTest(language)
|
||||||
|
if res == "" || strings.TrimSpace(res) == "" {
|
||||||
|
realTestMethod = ""
|
||||||
|
} else {
|
||||||
|
realTestMethod = "dd"
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
realTestMethod = "sysbench"
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
realTestMethod = "stream"
|
||||||
|
}
|
||||||
default:
|
default:
|
||||||
res = "Unsupported test method"
|
res = "Unsupported test method"
|
||||||
realTestMethod = ""
|
realTestMethod = ""
|
||||||
|
|||||||
Reference in New Issue
Block a user