On Mon, Sep 1, 2008 at 9:03 AM, Alvaro Lopez Ortega <[EMAIL PROTECTED]> wrote:

>> So, why if it is running as www-data, it can write to log files owned
>> by root but it can't do it when it receives SIGUSR1?.
>
> Because it opened it while it was root. Then, it dropped the privileges and
> became www-data. So, from that point on there is no way it can become root
> again (that's the whole point to becoming another user).

Yes, I understand, and I think that it should create (when it not
exists) log files as www-data, so when it will have to reopen them, it
can.

>> (Have you changed it now to SIGUSR2?).
>
> Yes, only in trunk (the upcoming 0.9) though.  Yesterday I spent quite some
> time unifying the Cherokee interfaces; so, unless I have made a mistake it
> should remain like that.

Ok!.

>>> What would be for you the expected behavior?
>>
>> I expect this:
>>
>> 1.- Cherokee is executed as root, but I want it to drop privileges
>> 2.- It becomes www-data.
>> 3.- It opens the log files (as www-data)
>> 4.- Works for a while, until it receives SIGUSR2
>> 5.- It tries to reopen the files and it can.
>
> Since it *IS* running as www-data, there is no way it can reopen a root file
> with perms 644.

Sure!... but logs files "must" be created as www-data. I don't want
this log files owned by root.

> Have you done this with other software? I might be missing something.

I don't know... and I can't do too much to know at the moment, because
I'm at the beach with an USB HSDPA modem and an "unbelievable" speed
of 12Kbps!.

-- 
Saludos:
Antonio Pérez

ATENCIÓN: Antes de imprimir este mensaje valora si verdaderamente es necesario.
De esta forma contribuimos a la preservación del Medio Ambiente.
_______________________________________________
Cherokee mailing list
[email protected]
http://lists.octality.com/listinfo/cherokee

Reply via email to