Page 1 of 1

[solved] c_AddUserDirectory : permissions not applied

Posted: Mon Jan 06, 2014 4:21 pm
by fred9176
Hi,

I created a php script which calls lua commands to create users with an associated folder.
Everything works fine, my user is created and the associated folder is visible in the Directory tab.

However, whatever permissions I set in the c_AddUserDirectory command, they are all checked in the web interface and the user can do what he wants (create folder,...).

For example, when I run the following command :
c_AddUserDirectory("mydomain.com","test", "/datas/accounts/test","/",1,0,0,0,0,0,0,0,0,0,0,0), all permissions are checked.

Do you have any idea on how to correct this ?

Thanks for your help,

Fred

Re: c_AddUserDirectory : permissions not applied

Posted: Tue Jan 07, 2014 7:41 am
by fred9176
I also noticed that home dir parameter is systematically set to 1 when adding a folder which is a big problem when adding multiple directories to an account.

Re: c_AddUserDirectory : permissions not applied

Posted: Tue Jan 07, 2014 7:56 am
by fred9176
I solved my problem : I just replaced 0 and 1 by false and true respectively.