LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (http://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   How To Divert Email While Receiving And Sending? (http://www.linuxquestions.org/questions/linux-newbie-8/how-to-divert-email-while-receiving-and-sending-362935/)

kiranprashant 09-13-2005 08:43 AM

How To Divert Email While Receiving And Sending?
 
Hi,
suppose I am using mozilla thunderbird as a Mail User Agent(MUA) or for example take any one, which sends/recieves(smtp/pop3) emails from a particular mail server.

Now i want to write an application, which will receive emails before reaching to MUA, i want to edit that mail and then want to send it to the MUA. simillarly while sending emails from MUA it should come to my application and then my application should send it to the server.
How can i do that?
I found one way. as follows:
step 1: first my application will connect to the two ports on which email works(port 110 and 25).
step 2: i will change the MUA server settings as a localhost, so whenever MUA send anything my application will get the data and it will send it to the server(as i know the ip of server)
step 3: when server sends any thing, my application will receive it and then send to the MUA.

I havn't tried it yet. Is it a efficient way? or is there any other way possible?
The drawback i can see in this is:
The coding is application base and i want is more system base.

waiting for help.

regards,

prashant

jtshaw 09-13-2005 09:24 AM

Please do not post the same thread in more than one forum. Picking the most relevant forum and posting it once there makes it easier for other members to help you and keeps the discussion all in one place.

http://www.linuxquestions.org/rules.php

Tinkster 09-13-2005 01:51 PM

closed per the above.


All times are GMT -5. The time now is 08:50 AM.