feat: add -ntp flag to disable TCP supplementary probe

This commit is contained in:
ZacharyZcR
2026-05-12 15:29:08 +08:00
parent 265e855fc3
commit 2e9321837f
6 changed files with 13 additions and 0 deletions
+4
View File
@@ -82,6 +82,10 @@ func CheckLive(ctx context.Context, hostslist []string, Ping bool, session *comm
// tcpSupplementaryProbe TCP 补充探测
// 当 ICMP 响应率过低时(<10%),对未响应主机进行 TCP 探测
func tcpSupplementaryProbe(ctx context.Context, allHosts []string, aliveHosts []string, session *common.ScanSession) []string {
if session.Config.DisableTcpProbe {
return aliveHosts
}
totalHosts := len(allHosts)
if totalHosts == 0 {
return aliveHosts