delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2013/03/07/09:39:38

X-Recipient: archive-cygwin AT delorie DOT com
X-Spam-Check-By: sourceware.org
Date: Thu, 7 Mar 2013 15:37:12 +0100
From: Corinna Vinschen <corinna-cygwin AT cygwin DOT com>
To: cygwin AT cygwin DOT com
Subject: Re: Unix domain accept() and getperrname() doesn't return the client address.
Message-ID: <20130307143712.GA12359@calimero.vinschen.de>
Reply-To: cygwin AT cygwin DOT com
Mail-Followup-To: cygwin AT cygwin DOT com
References: <CANjopZEy2_yzpPpmxFtqBC_jhHNPyh7MHdeCY-QrizRoYM1_7Q AT mail DOT gmail DOT com> <20130304093836 DOT GB5468 AT calimero DOT vinschen DOT de> <CANjopZHUZ-Azy+n5P1ZkNJuTb3c3zfj93bGz-pHfWra2aXTfRA AT mail DOT gmail DOT com>
MIME-Version: 1.0
In-Reply-To: <CANjopZHUZ-Azy+n5P1ZkNJuTb3c3zfj93bGz-pHfWra2aXTfRA@mail.gmail.com>
User-Agent: Mutt/1.5.21 (2010-09-15)
Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm
List-Id: <cygwin.cygwin.com>
List-Unsubscribe: <mailto:cygwin-unsubscribe-archive-cygwin=delorie DOT com AT cygwin DOT com>
List-Subscribe: <mailto:cygwin-subscribe AT cygwin DOT com>
List-Archive: <http://sourceware.org/ml/cygwin/>
List-Post: <mailto:cygwin AT cygwin DOT com>
List-Help: <mailto:cygwin-help AT cygwin DOT com>, <http://sourceware.org/ml/#faqs>
Sender: cygwin-owner AT cygwin DOT com
Mail-Followup-To: cygwin AT cygwin DOT com
Delivered-To: mailing list cygwin AT cygwin DOT com

On Mar  7 22:48, Tanaka Akira wrote:
> 2013/3/4 Corinna Vinschen:
> 
> > It's not exactly intentional, but known.  The socket's peername is not
> > transmitted during the local socket credential exchange.  So far the
> > server assumes an unbound socket on the client side because, well, I
> > guess the reason is "nobody asked for it yet".  This could probably
> > be implemented with not too much effort, if necessary.
> 
> I see.  Thank you.
> 
> Is it also known that recvfrom() on Unix domain datagram socket
> returns an AF_INET address?

Not really, no.  This is another "nobody asked for it yet", but I think
that's a bug.  I'll have a look to fix that for 1.7.18.  But the above
restriction will apply.  If we have no peer address, you get a
sockaddr_un with empty path.


Corinna

-- 
Corinna Vinschen                  Please, send mails regarding Cygwin to
Cygwin Maintainer                 cygwin AT cygwin DOT com
Red Hat

--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019