bug-hurd
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Update: Failing tests: Re: RFC: [PATCH] SCM_CREDS support


From: Samuel Thibault
Subject: Re: Update: Failing tests: Re: RFC: [PATCH] SCM_CREDS support
Date: Mon, 14 Mar 2016 00:57:11 +0100
User-agent: Mutt/1.5.21+34 (58baf7c9f32f) (2010-12-30)

Hello,

Svante Signell, on Sun 13 Mar 2016 14:19:35 +0100, wrote:
> Running the code reveals that the current implementation in glibc is buggy:
> 
> ./scm_rights+creds_recv
> Number of SCM_RIGHTS [<=3], SCM_CREDS [<=2]: [1,1] 
> Input error: Using defaults: 
> NRIGHTS = 1, NCREDS = 1
> scm_rights+creds_send.c: msgh.msg_controllen = 112 (from control_un)
> Receiving via datagram socket
> recvmsg: (os/kern) invalid right

I've had a closer look, what happens here is that the
mach_port_mod_refs() call on the rendezvous port fails because the port
type of the rendezvous port is DEADNAME, i.e. the other end dropped the
port.  Indeed, your sending program terminates as soon as it has sent
its message.  You need to make it wait at least a bit for the receiver
to get to receive the credentials.

Samuel



reply via email to

[Prev in Thread] Current Thread [Next in Thread]