将IP名单默认范围改为global

This commit is contained in:
刘祥超
2021-10-21 09:31:31 +08:00
parent 8bb47fb915
commit 36f9effbf2

View File

@@ -52,7 +52,7 @@ func (this *IPList) Add(ipType string, scope firewallconfigs.FirewallScope, serv
case firewallconfigs.FirewallScopeService:
ip = types.String(serverId) + "@" + ip + "@" + ipType
default:
ip = types.String(serverId) + "@" + ip + "@" + ipType
ip = "*@" + ip + "@" + ipType
}
var id = this.nextId()
@@ -71,7 +71,7 @@ func (this *IPList) Contains(ipType string, scope firewallconfigs.FirewallScope,
case firewallconfigs.FirewallScopeService:
ip = types.String(serverId) + "@" + ip + "@" + ipType
default:
ip = types.String(serverId) + "@" + ip + "@" + ipType
ip = "*@" + ip + "@" + ipType
}
this.locker.RLock()