My goal is to copy the whole folder structure with all mails from one imap account to another. The tool I am using for this is imapcopy (the java based version from code.google.com since the unix/linux tool packaged with debian doesn't support imaps).
Now, there is one problem: The tool only copies the top-level folders and not the nested ones.
To narrow down the problem I have downloaded the source code of imapcopy and debugged into the code. There I noticed that the
folder.list() (which is mapped to the
list "%" imap command) returns an empty list. But when I do a
getFolder(<subfoldername>) I can access those subfolders. After reading some documentation about the features of imap I think that the problem might be some misconfigured ACLs which prohibit the listing of those folders but allow to read ad write to them.
How should I check this ACLs? which tools do I need for this task?