This is the mail archive of the cygwin-apps@cygwin.com 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: /WINDOWS


On Dec  8 10:17, Bruce Ingalls wrote:
> This allows to keep the above described code to set $PATH in the
> 
> >affected tools, just by redefining, say _PATH_DEFPATH like this:
> >
> >#ifdef _PATH_DEFPATH
> >#undef _PATH_DEFPATH
> >#define _PATH_DEFPATH 
> >"/usr/bin:/bin:/WINDOWS/system32:/WINDOWS:/WINDOWS/COMMAND/WINDOWS/system32/Wbem"
> >#endif
> >
> >which contains both, NT and 9x paths.  We could perhaps even change
> >/usr/include/paths.h to reflect this, at one point.
> >
> > 
> >
> This is not correct. the NT paths are (combined with your above paths)
> 
> "/usr/bin:/bin:$SYSTEMROOT/system32:$SYSTEMROOT:$SYSTEMROOT/COMMAND:$SYSTEMROOT/system32/Wbem"
> (and actually a few more paths, with some variation by w32 version)

Huh?  I was talking about /WINDOWS in a Cygwin sense.  /WINDOWS gets
resolved by either a symlink, a mount point or in Cygwin internally.
/WINDOWS is not C:/WINDOWS but the path given by GetWindowsDirectory().
C:/WINDOWS is just an obvious example.

> OTOH, a cracker could try to modify your PATH setting script to
> "/cracker/bin:/usr/bin:/bin:..."

I'm talking about daemon process which set $PATH to something minimized
and reliable.  That's not a path coming from the outside but a fixed
string compiled into the daemon binary.

Corinna

-- 
Corinna Vinschen                  Please, send mails regarding Cygwin to
Cygwin Developer                                mailto:cygwin@cygwin.com
Red Hat, Inc.


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