From: Stephen Hemminger <stephen@networkplumber.org>
To: Isaac Boukris <iboukris@gmail.com>
Cc: netdev@vger.kernel.org
Subject: Re: iproute: ss truncates abstract unix domain socket embedding null
Date: Wed, 26 Oct 2016 10:15:54 -0700 [thread overview]
Message-ID: <20161026101554.15d8d37b@xeon-e3> (raw)
In-Reply-To: <CAC-fF8SdbDHPMZbOwHg=cOpsy+4ewTq9KGi-Cp=uaaG0hEJ8Fg@mail.gmail.com>
On Tue, 18 Oct 2016 21:46:48 +0300
Isaac Boukris <iboukris@gmail.com> wrote:
> Hi again,
>
> On Sun, Oct 16, 2016 at 11:43 PM, Isaac Boukris <iboukris@gmail.com> wrote:
> > Hello,
> >
> > The unix(7) man page says that null have no special meaning in
> > abstract unix domain socket address (the length is specified
> > therefore).
> >
> > However, when such name (embedding null) is used, ss (and netstat)
> > will only show up to the first null occurrence (second technically, if
> > we count the null prefix).
> > e.g. the name "\0/tmp/fo\0.sock" is displayed as: "@/tmp/fo" (whilst
> > strace tool shows it as: sun_path=@"/tmp/fo\0.sock").
> >
> > Would it be more useful if it printed the whole name and escaped the null?
> > If so, would '\0' be ok for escaping the null?
>
>
> Meanwhile, I've got it to escape the null character with with '\0' as suggested.
> Can anyone take a look and advise if I'm on the right track? Thanks!
I did a little investigation and current ss behavior matches the output
of other commands (netstat and lsof). Therefore I really can't see the motivation
to fix this.
next prev parent reply other threads:[~2016-10-26 17:15 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-10-16 20:43 iproute: ss truncates abstract unix domain socket embedding null Isaac Boukris
2016-10-18 18:46 ` Isaac Boukris
2016-10-26 17:15 ` Stephen Hemminger [this message]
2016-10-26 18:49 ` Isaac Boukris
2016-10-26 22:22 ` Stephen Hemminger
2016-10-29 19:35 ` Isaac Boukris
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20161026101554.15d8d37b@xeon-e3 \
--to=stephen@networkplumber.org \
--cc=iboukris@gmail.com \
--cc=netdev@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).