public inbox for netdev@vger.kernel.org 
 help / color / mirror / Atom feed
From: Jakub Kicinski <kuba@kernel•org>
To: Kuniyuki Iwashima <kuniyu@amazon•com>
Cc: "David S. Miller" <davem@davemloft•net>,
	Eric Dumazet <edumazet@google•com>,
	Paolo Abeni <pabeni@redhat•com>,
	Kuniyuki Iwashima <kuni1840@gmail•com>, <netdev@vger•kernel.org>
Subject: Re: [PATCH v1 net] net: Allow larger buffer than peer address for SO_PEERNAME.
Date: Mon, 21 Aug 2023 19:11:13 -0700	[thread overview]
Message-ID: <20230821191113.72311580@kernel.org> (raw)
In-Reply-To: <20230819005552.39751-1-kuniyu@amazon.com>

On Fri, 18 Aug 2023 17:55:52 -0700 Kuniyuki Iwashima wrote:
> For example, we usually do not know the peer name if we get an AF_UNIX
> socket by accept(), FD passing, or pidfd_getfd().  Then we get -EINVAL
> if we pass sizeof(struct sockaddr_un) to getsockopt(SO_PEERNAME).  So,
> we need to do binary search to get the exact peer name.

Sounds annoying indeed, but is it really a fix?

  reply	other threads:[~2023-08-22  2:11 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-08-19  0:55 [PATCH v1 net] net: Allow larger buffer than peer address for SO_PEERNAME Kuniyuki Iwashima
2023-08-22  2:11 ` Jakub Kicinski [this message]
2023-08-22  2:40   ` Kuniyuki Iwashima
2023-08-22  8:43     ` Paolo Abeni
2023-08-22 16:24       ` Kuniyuki Iwashima

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=20230821191113.72311580@kernel.org \
    --to=kuba@kernel$(echo .)org \
    --cc=davem@davemloft$(echo .)net \
    --cc=edumazet@google$(echo .)com \
    --cc=kuni1840@gmail$(echo .)com \
    --cc=kuniyu@amazon$(echo .)com \
    --cc=netdev@vger$(echo .)kernel.org \
    --cc=pabeni@redhat$(echo .)com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html
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