ss fixes from an OSS scan
Status from this message: This series was applied to iproute2/iproute2.git (main)
Get series with b4
b4 am [email protected]Versions newest first
Patches in v1 Applied
| # | Subject and files | Size | Replies | Applied |
|---|---|---|---|---|
| 1/11 | ss: fix double close on sock_diag send failuremisc/ | +1 | 0 replies | |
| 2/11 | ss: drop /proc fallback for socket listingmisc/ | +28 | 0 replies | |
| 3/11 | ss: escape names chosen by the socket ownerlib/ misc/ | +15 | 0 replies | |
| 4/11 | ss: size the TCPDIAG_FILE buffer to the recordmisc/ | +35 | 0 replies | |
| 5/11 | ss: replay all dumps in TCPDIAG_FILEmisc/ testsuite/ | +32 | 0 replies | |
| 6/11 | ss: bound state and type name lookupsmisc/ | +22 | 0 replies | |
| 7/11 | ss: fix rpcbind service cachemisc/ | +26 | 0 replies | |
| 8/11 | ss: read socket SELinux context only for -zmisc/ | +34 | 0 replies | |
| 9/11 | ss: check owner before naming a netlink socketman/ misc/ | +48 | 0 replies | |
| 10/11 | ss: keep following events after ENOBUFSmisc/ | +7 | 0 replies | |
| 11/11 | ss: report a failed SCTP or MPTCP dumpmisc/ | +4 | 0 replies |
Reviews trailers per patch
No Reviewed-by, Acked-by or Tested-by trailers for v1 yet.
Cover letter [PATCH iproute2 00/11] ss fixes from an OSS scan
Fixes for the ss findings of scan iproute2-20261015-004, plus bugs found while confirming them.
The biggest change is removing the fallback /proc parsing.
It was buggy and fixing it is not worth bothering.
Every family ss lists that way has had sock_diag support since well before the oldest supported LTS kernel, and the parsers were untested and trusted file contents that an unprivileged user can partly control. A kernel built without netlink socket diagnostics now gets an error instead of a silent fallback.
The rest escape names chosen by whoever owns the socket, bound state and type values from the kernel before indexing name tables, stop treating a netlink port id as the owner's pid, and size the TCPDIAG_FILE read buffer to the record while rejecting lengths the parser cannot use.
Stephen Hemminger (11):
ss: fix double close on sock_diag send failure
ss: drop /proc fallback for socket listing
ss: escape names chosen by the socket owner
ss: size the TCPDIAG_FILE buffer to the record
ss: replay all dumps in TCPDIAG_FILE
ss: bound state and type name lookups
ss: fix rpcbind service cache
ss: read socket SELinux context only for -z
ss: check owner before naming a netlink socket
ss: keep following events after ENOBUFS
ss: report a failed SCTP or MPTCP dump
lib/escape.c | 7 +- man/man8/ss.8 | 3 +- misc/ss.c | 884 +++++++++------------------------- testsuite/tests/ss/ssfilter.t | 26 +- 4 files changed, 249 insertions(+), 671 deletions(-)
Signature · 1 line
2.53.0