[asterisk-users] Access rights between AGI and Web server?

Mojo with Horan & Company, LLC mojo at horanappraisals.com
Mon Mar 24 16:57:53 CDT 2008


Glad you got it!

Moj

P.S.   This is not typical, right? If I do NOT have write access to a 
directory, I can still write to files that already exist in that 
directory, as long as I have write access to said files, I think...  
Maybe I'm just talking out loud, but it seems like if you had write 
access to temp.sqlite, you could do what you need to do, /unless/ sqlite 
tries to create a temporary file and mv it over the top of temp.sqlite, 
as this would require write access in the directory.

Vincent wrote:
> On Mon, 24 Mar 2008 12:09:00 -0800, "Mojo with Horan & Company, LLC"
> <mojo at horanappraisals.com> wrote:
>   
>> Now, that was run under a webserver. right? not under asterisk as an 
>> AGI?  I thought we were expecting to see root:wheel :)
>>     
>
> Yup, sorry about: I forgot to say that I use a single SQLite database
> to share data between Asterisk and some PHP scripts.
>
> Found what it was: Even if a file is set to 664 and owned by the right
> user, the _directory_ in which the file lives has precedence. In this
> case, I just chowned it to root:www, and chmoded it to 664:
>
> [/usr/local/share/asterisk/agi-bin]# ll
> drwxrwxr-x  3 root  www      512 Mar 24 22:05 .
> drwxr-xr-x  9 root  wheel    512 Mar 14 08:05 ..
> -rw-rw-r--  1 www   www     3072 Mar 24 22:05 test.sqlite
>
> Learned something new today. Thanks for the help.
>
>
> _______________________________________________
> -- Bandwidth and Colocation Provided by http://www.api-digital.com --
>
> asterisk-users mailing list
> To UNSUBSCRIBE or update options visit:
>    http://lists.digium.com/mailman/listinfo/asterisk-users
>   




More information about the asterisk-users mailing list