Imap proxy patch

Hi list,

My company has a mail storage system (proprietary). It receives email
via lmtp and customers can get email from imap and pop3. This system
does not support imap subfolders. For particular reason we need to put a
imap proxy in front of this system and I choose nginx to do that. But
now we have a problem, our customers need to have subfolder features.

So I thought about a solution in imap proxy source code, intercept the
commands and get subfolder creation/access and change data. All imap
access (webmail/outlook) will use this proxy.

Example,

If one create a parent folder, let it do this, (ex. Sent)

If one request to create a sub-folder (Sent/2007) we change the request
and create _xxx_Sent_2007 (as parent folder), When client (through
proxy) will list or access the folder Sent, we intercept the request,
read the original folder name and change the response to subfolder
style.

In other words, our sub-folder protocol would be

xxx (prefix)
_xxx_parent-folder_subfolder

It’s a little bit comlex, but the big question is, what do you think
about it.

Do you know any solution that implement any variation of this idea?

Best Regards,
Fernando

On Mon, Aug 18, 2008 at 08:52:39PM -0300, Fernando - Dfcom wrote:

In other words, our sub-folder protocol would be

xxx (prefix)
_xxx_parent-folder_subfolder

It’s a little bit comlex, but the big question is, what do you think about it.

Do you know any solution that implement any variation of this idea?

This requires parsing all IMAP commands while proxying.
nginx does not support it.

Fernando - Dfcom wrote:

imap access (webmail/outlook) will use this proxy.

Example,

If one create a parent folder, let it do this, (ex. Sent)

If one request to create a sub-folder (Sent/2007) we change the
request and create _xxx_Sent_2007 (as parent folder), When client
(through proxy) will list or access the folder Sent, we intercept the
request, read the original folder name and change the response to
subfolder style.

You can do some funky stuff with namespaces in dovecot, also dovecot has
a reasonable IMAP proxy feature. Possibly the two bits can be brought
together to achieve what you need? Otherwise the author accepts paid
work so you might be able to pay for your required feature

Just another avenue you might try…

I guess it’s not possible to switch to a new mail server such as
Dovecot/Cyrus then?

Ed W

This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.

| Privacy Policy | Terms of Service | Remote Ruby Jobs