I want to write a script to automatically train spam assassin. I plan on using read messages in the inbox as ham and the contents of the junk folder as spam.
I've figured out how to get user/folder read/unread status out of mysql I think:
zimbra.mailbox.id corresponds to mailboxx db and zimbra/store/0/x/msg
and mailboxx.mail_item.folder_id corresponds to the imap folders
and unread is boolean
what I'm missing is how to infer the directory under zimbra/store/ and the directory under zimbra/store/x/x/msg/