× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.



Brian,

Thanks I finally did find a note in the C/C++ runtime manual that fopen
will give public *RWX.

Unfortunately I am not an expert of the C or run time API environment.
We may have to revert to using open instead but I'm wondering about the
umask 022 that you referenced.  You will have to assume that I don't
have a clue as to what umask is......

-----Original Message-----
From: c400-l-bounces+mike.crump=saint-gobain.com@xxxxxxxxxxxx
[mailto:c400-l-bounces+mike.crump=saint-gobain.com@xxxxxxxxxxxx] On
Behalf Of Brian Lewis
Sent: Monday, July 17, 2006 5:50 PM
To: c400-l@xxxxxxxxxxxx
Subject: Re: [C400-L] fopen default authority

On Mon, 17 Jul 2006 17:38:45 -0400
"Crump, Mike" <Mike.Crump@xxxxxxxxxxxxxxxx> wrote:

I have created directories that have *PUBLIC *EXCLUDE and use an AUTL
list for the authorized users.  However, the file gets created with
*PUBLIC *RWX and no AUTL.  I'm assuming that the fopen runtime has a
default authority setup but can't seem to find that documented
anywhere.
Does it have a default *PUBLIC authority and can I change it so that
the
authority is pulled from the directory that the file is being created
in?

Some documentation on fopen that I have says
    Any created files will have mode "S_IRUSR | S_IWUSR | S_IRGRP |
S_IWGRP
    | S_IROTH | S_IWOTH" (0666), as modified by the process' umask value
    (see umask(2)).

So maybe you want to use something other than fopen (I think open allows
you
to specify the permissions of created files) or set your umask to 022
(or
whatever you prefer) before you create the file.

As an Amazon Associate we earn from qualifying purchases.

This thread ...

Follow-Ups:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.