[Mailman-Users] Permissions problem accessing commands via php

John Dennis jdennis at redhat.com
Fri Dec 9 21:12:39 CET 2005

On Fri, 2005-12-09 at 12:46 -0600, Dave B wrote:
> I am trying to create some php forms that use the shell_exec function 
> to run some of the Mailman command line commands. i.e. I have a script 
> that lets an admin user enter an email address and then uses the 
> find_member script to return all lists that email address is in. To do 
> this I had to set the permissions on the config.pck files to 664 (I am 
> the only one with shell access to the server).
> This works fine except that for some reason the permissions will 
> sometimes revert back to 660 and then the script won't work. Only one 
> config.pck file has to have 660 permissions for the script not to work. 
> When I change that particular file back to 664 - the script works 
> again. ANy ideas on what would cause the permissions to change back to 
> 660?
> I would also like to be able to add members or remove members etc using 
> this method but I get permissions errors even if I change the 
> permissions to 666 on all the files in particular list directory. Any 
> ideas on what I would need to do to be able to do this?
> Thanks for any help on this one.

Essentially you have two choices:

1) The php script executes as a member of the mailman group

2) The php script invokes a wrapper just like the CGI does. This is
preferred for a variety of security reasons. It would not be hard to
create a new wrapper from the existing wrapper src code.
John Dennis <jdennis at redhat.com>

More information about the Mailman-Users mailing list