This is the mail archive of the cygwin mailing list for the Cygwin project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: sshd: fatal: seteuid XXX : No such device or address


On Mar 15 14:06, Houder wrote:
> On Thu, 14 Mar 2019 18:29:18, Corinna Vinschen  wrote:
> 
> > On Mar 14 16:53, Houder wrote:
> 
> > > On Thu, 14 Mar 2019 12:39:30, XXXXX wrote:
> > > > Hello the list
> [snip]
> > > > sshd: PID 3777: fatal: seteuid 1049076: No such device or address
> 
> > > Corinna,
> > >
> > > As far as I know, seteuid() can either return EINVAL or EPERM in case of
> > > an error.
> > >
> > > EPERM (=3D  1) "Operation not permitted"
> > > EINVAL(=3D 22) "Invalid argument"
> > >
> > > "No such device or address" appears to correspond to ENXIO (=3D  6). Is it
> > > sshd, or is it Cygwin, that is confused here?
> > 
> > No confusion as such.  The underlying Windows function returns a NT
> > status code, which is converted to a Win32 error code by a Windows
> > function, and that Win32 error code is converted to a POSIX errno by
> > Cygwin.  There are much more NT status codes than Win32 error codes, and
> > there are much more Win32 error codses than POSIX errno values, so the
> > mapping is inevitably unsatisfying.
> 
> .. yes, I am aware of the situation (winsup/cygwin/errno.cc) ...
> 
> However, in the end this kind of error messages is of NOT much use in order
> to ascertain what is going on (i.e. what is causing the problem).
> 
> One is forced to create the exact same environment (system) as the person
> who is complaining, fire up the debugger (like sticking a thermometer in a
> patient's rear end) in order to find out where the code failed ...
> 
> Meaning, within the context of the recent sshd problems, possibly only you
> know where the error ERROR_FILE_INVALID (resulting in the error message "No
> such device or address") was generated ... (and by which Windows function).

The only interface an application has is by checking the POSIX
errno value.  This is what Cygwin is about :)

If you need more details what's going on under the hood, you have
to use strace.

> Oh well, this cannot be helped ...

Well, there *is* a solution by using strace.  And hey, we now know what
ENXIO returned from seteuid means, don't we?  It's not all bad :)


Corinna

-- 
Corinna Vinschen
Cygwin Maintainer

Attachment: signature.asc
Description: PGP signature


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]