You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@httpd.apache.org by Andrus Moor <ee...@online.ee> on 2004/01/11 21:53:05 UTC

[users@httpd] Re: How to create file which can be deleted by other

>Andrus, I write apps in Perl and PHP mainly but I don't think the language
>used is relevant. At the time you create the file change the permissions to
>777, or the least restrictive you can arrange; e.g. if the other user can
>be put in the same group as the creator of the file then 664 might be
enough.

Marty,

this is exactly what I tried to do by calling

umask(0);

before fopen().
For some strange reason, umask(0) makes file readable and writeable by all
but does not allow its deletion like umode 0777 shell command.

I don'nt know how to correct my C code to allow deletion.


---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
   "   from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org


Re: [users@httpd] Re: How to create file which can be deleted by other

Posted by Marty Landman <ML...@face2interface.com>.
At 03:53 PM 1/11/2004, Andrus Moor wrote:
> >Andrus, I write apps in Perl and PHP mainly but I don't think the language
> >used is relevant. At the time you create the file change the permissions to
> >777, or the least restrictive you can arrange; e.g. if the other user can
> >be put in the same group as the creator of the file then 664 might be
>enough.
>
>Marty,
>
>this is exactly what I tried to do by calling
>
>umask(0);
>
>before fopen().
>For some strange reason, umask(0) makes file readable and writeable by all
>but does not allow its deletion like umode 0777 shell command.
>
>I don'nt know how to correct my C code to allow deletion.
>
>
>---------------------------------------------------------------------
>The official User-To-User support forum of the Apache HTTP Server Project.
>See <URL:http://httpd.apache.org/userslist.html> for more info.
>To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
>    "   from the digest: users-digest-unsubscribe@httpd.apache.org
>For additional commands, e-mail: users-help@httpd.apache.org

Marty Landman   Face 2 Interface Inc 845-679-9387
Sign On Required: Web membership software for your site
Make a Website: http://face2interface.com/Home/Demo.shtml


---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
   "   from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org