diff --git a/CHANGELOG.asciidoc b/CHANGELOG.asciidoc index 46cb7ed69e66..a97fe2376b59 100644 --- a/CHANGELOG.asciidoc +++ b/CHANGELOG.asciidoc @@ -38,6 +38,8 @@ https://github.com/elastic/beats/compare/v6.0.0-alpha1...master[Check the HEAD d *Packetbeat* +- Enabled /proc/net/tcp6 scanning and fixed ip v6 parsing. {pull}4442[4442] + *Winlogbeat* ==== Added @@ -113,7 +115,7 @@ https://github.com/elastic/beats/compare/v6.0.0-alpha1...v6.0.0-alpha2[View comm - Fix type of field `haproxy.stat.check.health.last`. {issue}4407[4407] *Packetbeat* - +- Enable memcache filtering only if a port is specified in the config file. {issue}4335[4335] - Enable memcache filtering only if a port is specified in the config file. {issue}4335[4335] ==== Added diff --git a/packetbeat/procs/procs.go b/packetbeat/procs/procs.go index 6b34cf7d48cc..233cfafaf45c 100644 --- a/packetbeat/procs/procs.go +++ b/packetbeat/procs/procs.go @@ -244,7 +244,7 @@ func hexToIpv4(word string) (net.IP, error) { func hexToIpv6(word string) (net.IP, error) { p := make(net.IP, net.IPv6len) for i := 0; i < 4; i++ { - part, err := strconv.ParseInt(word[i*8:(i+1)*8], 16, 32) + part, err := strconv.ParseUint(word[i*8:(i+1)*8], 16, 32) if err != nil { return nil, err } @@ -324,12 +324,12 @@ func (proc *ProcessesWatcher) updateMap() { } func socketsFromProc(filename string, ipv6 bool) ([]*socketInfo, error) { - file, err := os.Open("/proc/net/tcp") + file, err := os.Open(filename) if err != nil { return nil, err } defer file.Close() - return parseProcNetTCP(file, false) + return parseProcNetTCP(file, ipv6) } // Parses the /proc/net/tcp file