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: Turning off execute permission


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

According to Paul McFerrin on 3/7/2009 12:49 AM:
> 
> I've been reading:
> http://cygwin.com/1.7/cygwin-ug-net/ntsec.html#ntsec-files
> on the execute permissions.  Did I read that it was impossible to deny
> execute permissions??  In my tests, the follow is always "true" if a
> file has no execute permissions: (mode 666 or 000)
>  [ -x apachectl ]
>  test -x apachectl
> for all of the shells

Are you operating as an administrator?  Just as in Linux, the superuser
has the privilege of executing any file regardless of its permissions.
test -x uses access() and not stat() to determine the answer of whether
the file is executable for the currently logged on user, so this is
accurately reporting what you are able to do with the file, regardless of
what the permission bits are on the file.

- --
Don't work too hard, make some time for fun as well!

Eric Blake             ebb9@byu.net
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.9 (Cygwin)
Comment: Public key at home.comcast.net/~ericblake/eblake.gpg
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iEYEARECAAYFAkmylGQACgkQ84KuGfSFAYCsrACgx/8PRpoCiDiBYeO/sP7MJDpu
N38An0eaQa8N2U1a2VixH9w+sluTIBTe
=oAqC
-----END PGP SIGNATURE-----

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


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