public inbox for cygwin@cygwin.com
 help / color / mirror / Atom feed
* B20.1: File permissions
@ 2000-01-31  2:55 Kevin Wright
  2000-01-31  3:36 ` Corinna Vinschen
  0 siblings, 1 reply; 2+ messages in thread
From: Kevin Wright @ 2000-01-31  2:55 UTC (permalink / raw)
  To: Cygwin

Can any one explain to me the cygwin philosophy of file permissions ?

I originally ran into trouble with test -w.  ls -l would report a file as
being writable, but test -w would say it wasn't.  When I tried to report
this as a bug, I was told it wasn't a bug but was by design !  Now I've not
seen any documentation anywhere on Unix that says that test -w only reports
files with 3w's as writable, so this must be an inconsistency at least.

Anyway I was informed if I downloaded a later snapshot, and set CYGWIN=ntsec
then this would solve my problem.

Sure enough the ls -l and test -w inconsistency disappeared under these
conditions.  Now I have the marvellous state of affairs where ls -l says a
file is writable and attrib says the file is read only.

Am I alone in trying to mix cygwin with normal NT commands ?

What is wrong with checking NT's and cygwin's version of permissions
throughout the code in a consistent manner ?

The above problems don't seem to fit with this quote from the cygwin FAQ
"What is it ?"

"Even if the development tools are of little to no use to you, you may have
interest in the many standard Unix utilities provided with the package. They
can be used both from the bash shell (provided) or from the standard Windows
command shell. "

Which doesn't state, but implies that cygwin utilities can be used in
conjunction with Windows based utilities.

My initial contact with cygwin was using B17 and I was impressed with the
range of utilities available and the ability to intermix commands.  However
the occasional command crashes when using pipes seemed to get more frequent,
so I upgraded to B20.1.  The command crashes went away, but I still haven't
found a configuration that works for me.

Would purchasing Cygwin 1.0 help to solve my problems ?






--
Want to unsubscribe from this list?
Send a message to cygwin-unsubscribe@sourceware.cygnus.com

^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: B20.1: File permissions
  2000-01-31  2:55 B20.1: File permissions Kevin Wright
@ 2000-01-31  3:36 ` Corinna Vinschen
  0 siblings, 0 replies; 2+ messages in thread
From: Corinna Vinschen @ 2000-01-31  3:36 UTC (permalink / raw)
  To: Kevin Wright; +Cc: Cygwin

Kevin Wright wrote:
> [...]
> Anyway I was informed if I downloaded a later snapshot, and set CYGWIN=ntsec
> then this would solve my problem.
> 
> Sure enough the ls -l and test -w inconsistency disappeared under these
> conditions.  Now I have the marvellous state of affairs where ls -l says a
> file is writable and attrib says the file is read only.

It's a bug in the latest snapshots. When ntsec is set, only the
security attributes are taken into account but the old DOS file
attributes are ignored.

The problem is that NTFS has both attribute types which may differ.
You, as the owner of the file, have security attributes that allow
writing while the old DOS type file attribute has the read-only bit
set. This is sick, IMHO, but you are right: It should be handled.

I will fix it in one of the next snapshots.

Nevertheless I would like to suggest _not_ using the old DOS
attributes on NTFS. When using ntsec, you have nearly full access
to the NTFS security attributes. The latest snapshots include
tools named 'getfacl' and 'setfacl' to additionally  get/set
attributes that are not related to user/group/other.

> Would purchasing Cygwin 1.0 help to solve my problems ?

No.

Corinna

--
Want to unsubscribe from this list?
Send a message to cygwin-unsubscribe@sourceware.cygnus.com

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2000-01-31  3:36 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2000-01-31  2:55 B20.1: File permissions Kevin Wright
2000-01-31  3:36 ` Corinna Vinschen

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).