Here is the output: > $ sockstat -6 > USER COMMAND PID FD PROTO LOCAL ADDRESS FOREIGN ADDRESS > mosipov socat 61935 5 tcp6 ::1:20000 *:* > redis redis-serv 1031 7 tcp6 *:6379 *:* > root sshd 1016 3 tcp6 *:22 *:* > ntpd ntpd 944 20 udp6 *:123 *:* > ntpd ntpd 944 22 udp6 fe80::yyy:9466%em0:123 *:* > ntpd ntpd 944 24 udp6 2003:xxx:yyy:9466:123 *:* > ntpd ntpd 944 25 udp6 ::1:123 *:* > ntpd ntpd 944 26 udp6 fe80::1%lo0:123 *:* while I would expect to see: > $ sockstat -6 > USER COMMAND PID FD PROTO LOCAL ADDRESS FOREIGN ADDRESS > mosipov socat 61935 5 tcp6 [::1]:20000 *:* > redis redis-serv 1031 7 tcp6 *:6379 *:* > root sshd 1016 3 tcp6 *:22 *:* > ntpd ntpd 944 20 udp6 *:123 *:* > ntpd ntpd 944 22 udp6 [fe80::yyy:9466%em0]:123 *:* > ntpd ntpd 944 24 udp6 [2003:xxx:yyy:9466]:123 *:* > ntpd ntpd 944 25 udp6 [::1:]123 *:* > ntpd ntpd 944 26 udp6 [fe80::1%lo0]:123 *:* As most software outputs inet6 socket address string representation to avoid confusion.
Issue still exists on: # uname -a FreeBSD deblndw013x10v.innomotics.net 16.0-CURRENT FreeBSD 16.0-CURRENT
A commit in branch main references this bug: URL: https://cgit.FreeBSD.org/src/commit/?id=fe81e3944c085e765c83c4f78941d7529ceb556e commit fe81e3944c085e765c83c4f78941d7529ceb556e Author: Michael Osipov <michaelo@FreeBSD.org> AuthorDate: 2025-12-26 17:27:12 +0000 Commit: Michael Osipov <michaelo@FreeBSD.org> CommitDate: 2026-01-31 20:48:56 +0000 sockstat: Surround explicit IPv6 addresses with brackets PR: 254611 Approved by: otis, tuexen, des MFC after: 1 week Differential Revision: https://reviews.freebsd.org/D54375 usr.bin/sockstat/main.c | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-)
A commit in branch stable/15 references this bug: URL: https://cgit.FreeBSD.org/src/commit/?id=58a369a6f6ce6786ef7aa4715c96548f36ae3962 commit 58a369a6f6ce6786ef7aa4715c96548f36ae3962 Author: Michael Osipov <michaelo@FreeBSD.org> AuthorDate: 2025-12-26 17:27:12 +0000 Commit: Michael Osipov <michaelo@FreeBSD.org> CommitDate: 2026-02-07 09:51:50 +0000 sockstat: Surround explicit IPv6 addresses with brackets PR: 254611 Approved by: otis, tuexen, des MFC after: 1 week Differential Revision: https://reviews.freebsd.org/D54375 (cherry picked from commit fe81e3944c085e765c83c4f78941d7529ceb556e) usr.bin/sockstat/main.c | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-)
A commit in branch stable/14 references this bug: URL: https://cgit.FreeBSD.org/src/commit/?id=03c8e3e77114530f61e0dd9f2b1757eeea033d0e commit 03c8e3e77114530f61e0dd9f2b1757eeea033d0e Author: Michael Osipov <michaelo@FreeBSD.org> AuthorDate: 2025-12-26 17:27:12 +0000 Commit: Michael Osipov <michaelo@FreeBSD.org> CommitDate: 2026-02-07 12:17:08 +0000 sockstat: Surround explicit IPv6 addresses with brackets PR: 254611 Approved by: otis, tuexen, des MFC after: 1 week Differential Revision: https://reviews.freebsd.org/D54375 (cherry picked from commit fe81e3944c085e765c83c4f78941d7529ceb556e) usr.bin/sockstat/sockstat.c | 9 +++++++++ 1 file changed, 9 insertions(+)
A commit in branch stable/13 references this bug: URL: https://cgit.FreeBSD.org/src/commit/?id=e5cb813ac4779d46b2dd9a483d2983ae5d104bcb commit e5cb813ac4779d46b2dd9a483d2983ae5d104bcb Author: Michael Osipov <michaelo@FreeBSD.org> AuthorDate: 2025-12-26 17:27:12 +0000 Commit: Michael Osipov <michaelo@FreeBSD.org> CommitDate: 2026-02-07 12:18:27 +0000 sockstat: Surround explicit IPv6 addresses with brackets PR: 254611 Approved by: otis, tuexen, des MFC after: 1 week Differential Revision: https://reviews.freebsd.org/D54375 (cherry picked from commit fe81e3944c085e765c83c4f78941d7529ceb556e) usr.bin/sockstat/sockstat.c | 9 +++++++++ 1 file changed, 9 insertions(+)
A commit in branch releng/14.4 references this bug: URL: https://cgit.FreeBSD.org/src/commit/?id=11b616d9de3f1d106cd9f2bfe4c45013f3b1528f commit 11b616d9de3f1d106cd9f2bfe4c45013f3b1528f Author: Michael Osipov <michaelo@FreeBSD.org> AuthorDate: 2025-12-26 17:27:12 +0000 Commit: Colin Percival <cperciva@FreeBSD.org> CommitDate: 2026-02-09 03:09:35 +0000 sockstat: Surround explicit IPv6 addresses with brackets Approved by: re (cperciva) PR: 254611 Approved by: otis, tuexen, des MFC after: 1 week Differential Revision: https://reviews.freebsd.org/D54375 (cherry picked from commit fe81e3944c085e765c83c4f78941d7529ceb556e) (cherry picked from commit 03c8e3e77114530f61e0dd9f2b1757eeea033d0e) usr.bin/sockstat/sockstat.c | 9 +++++++++ 1 file changed, 9 insertions(+)