diff --git a/go.mod b/go.mod index dec8fcdd5..23a4550da 100644 --- a/go.mod +++ b/go.mod @@ -11,7 +11,7 @@ require ( github.com/go-openapi/swag v0.22.3 github.com/go-openapi/validate v0.22.0 github.com/jessevdk/go-flags v1.5.0 - github.com/loxilb-io/loxilib v0.8.8-0.20230522072824-40657d491e9b + github.com/loxilb-io/loxilib v0.8.8-0.20230531161727-0b99321ae61d github.com/osrg/gobgp/v3 v3.5.0 github.com/prometheus-community/pro-bing v0.1.0 github.com/prometheus/client_model v0.3.0 diff --git a/go.sum b/go.sum index 3dda3b46e..714452efb 100644 --- a/go.sum +++ b/go.sum @@ -265,6 +265,10 @@ github.com/loxilb-io/loxilib v0.8.8-0.20230522072540-4ba9ddf4efcf h1:342+g1s7I27 github.com/loxilb-io/loxilib v0.8.8-0.20230522072540-4ba9ddf4efcf/go.mod h1:LoQCxBz+N0fO9rGwRmPHrQPHol/jUf4MNpph63Cydkg= github.com/loxilb-io/loxilib v0.8.8-0.20230522072824-40657d491e9b h1:CWgBppsB/keRY38bqOwObd4+pdc2O2e38zUTIb+kCX8= github.com/loxilb-io/loxilib v0.8.8-0.20230522072824-40657d491e9b/go.mod h1:LoQCxBz+N0fO9rGwRmPHrQPHol/jUf4MNpph63Cydkg= +github.com/loxilb-io/loxilib v0.8.8-0.20230531161000-c08bcd884fea h1:5D0q0JN4sxd3y0DjnM8gt3YzCeu3JzdpHMI22ngHpVg= +github.com/loxilb-io/loxilib v0.8.8-0.20230531161000-c08bcd884fea/go.mod h1:LoQCxBz+N0fO9rGwRmPHrQPHol/jUf4MNpph63Cydkg= +github.com/loxilb-io/loxilib v0.8.8-0.20230531161727-0b99321ae61d h1:LzQJ4F0FsEBzLPsETfC9Yu5MNhOcSle/ZWGhBQd8v78= +github.com/loxilb-io/loxilib v0.8.8-0.20230531161727-0b99321ae61d/go.mod h1:LoQCxBz+N0fO9rGwRmPHrQPHol/jUf4MNpph63Cydkg= github.com/loxilb-io/sctp v0.0.0-20230512061258-63a8bc8f1b80 h1:rYO3BYcHt0ILY0sOeygtpUEEFsNS8KZBTbuEIW2foLk= github.com/loxilb-io/sctp v0.0.0-20230512061258-63a8bc8f1b80/go.mod h1:1a6hv8ISVQhnW5IVpW9o+OL6BAFlWiVpC0O4d19g+wQ= github.com/loxilb-io/sctp v0.0.0-20230512152123-70e9c76eb88a h1:ASVCk3Mk5n9fNJYJm1+QF9bsFCHysudzE8sj5nhj5P4= diff --git a/loxinet/rules.go b/loxinet/rules.go index 7a4b08887..7e5c2e619 100644 --- a/loxinet/rules.go +++ b/loxinet/rules.go @@ -1620,6 +1620,10 @@ func (R *RuleH) epCheckNow(ep *epHost) { } sName := fmt.Sprintf("%s:%d", ep.hostName, ep.opts.probePort) + if tk.IsNetIPv6(ep.hostName) { + sName = fmt.Sprintf("[%s]:%d", ep.hostName, ep.opts.probePort) + } + if ep.opts.probeType == HostProbeConnectTcp || ep.opts.probeType == HostProbeConnectUdp || ep.opts.probeType == HostProbeConnectSctp {