Hi
I found a problem which can prevent users from deleting their files in htdocs.
Given
- customer with domain1.tld and an alias domain2.tld.
- FTP-User ftp@domain2.tld with home /domain2.tld
- Customer uses FTP to put a file in domain2.tld/htdocs/test.php
- Customer cannot delete this file with this FTP-User.
I went deeper and tried to figure out the reason... because all Limit-Configs seem ok.
If one of the following is true, then the customer can delete the file:
- ftp-users home is / (home of domain1.tld)
- "Include /etc/proftpd/root_domain.conf" is commented
- "Include /etc/proftpd/imscp/*" is commented
This looks strange... only if both config files with the Limit directives are loaded, then the problem caan occur.
And inside theese files: customer can delete when either changing the line
<Directory ~/htdocs>
to
<Directory ~/htdocs1>
or the line
<Directory /var/www/virtual/domain1.tld/domain2.tld/htdocs/*>
to
<Directory /var/www/virtual/domain1.tld/domain2.tld/htdocs1/*>
(should be clear where theese lines are written).
first one is from a deny rule, the second one is a allow rule...
It's really strange!
Can others confirm?
/Joxi