Rick Widmer wrote:
mkdir
auth: SA - restricted to vpopmail domain directories
auth: DA - restricted to DA domain directory
auth: U - restricted to users directory
usage: mkdir <directory>
OK - on success
ERROR <error code> <error message>


What is <directory>, and how do I specify them.  I think my favorite
would be:

SA - prepend ~vpopmail/domains/ to <directory>

DA - prepend ~vpopmail/domains/mydomain/ to <directory>

U - prepend ~vpopmail/domains/mydomain/myuser/ to <directory>

On the other hand that requires the programmer on the PHP side to
describe the directory differently depending on the access level of the
user that is logged in.  Maybe it is better to just prepend
~vpopmail/domains to the directory and require the user to send the
directory part below no matter what access is available.  That way I
don't have to change how I specify a directory based on the user's rights.

Is there _any_ reason the daemon should ever access any file or
directory above  ~vpopmail/domains?


The more I think about this, the more I prefer to have vpopmaild always prepend ~vpopmail/domains/ to all entries, and no matter what kind of user is logged in, the program using the daemon always has to include the domain and user directories in the request.

The daemon would allow SA users any directory under ~vpopmail/domains, require DA users to specify their domain directory, and U users must specify their domain directory and user directory.

I think that would simplify code on both sides of the connection.


Also...


I forgot to list these missing commands:


getdir auth: SA - restricted to vpopmail domain directories auth: DA - restricted to DA domain directory auth: U - restricted to users directory usage: getdir <directory> OK - on success ERROR <error code> <error message>

Returns a list of files and directories, one per line. Is there any information in a ls that we want to have besides just the file/dir name?


getfile auth: SA - restricted to vpopmail domain directories auth: DA - restricted to DA domain directory auth: U - restricted to users directory usage: getfile <filename> OK - on success ERROR <error code> <error message>

Returns the contents of a file, followed by a blank line, then the status. Maybe we need the size of the file, in lines; just in case the file being received has blank lines followed with things that look like a status report. Maybe we need some kind of unique terminator. I'm not sure, but I do need to be able to do things like list the current contents of a mail robot Message file.





Reply via email to