I want to write a script that sends an e-mail with attachments (different sizes, different recipients). I wish prior to sending e-mail, somehow detect if recipient's mail server can handle the size of it. Is there a way to do this?

link|improve this question
feedback

1 Answer

up vote 2 down vote accepted

You can try to telnet to the recipients email server on port 25 and issue the EHLO command. The server should respond with the EHLO commands that it supports and should list the size limit that it supports. This is not a guaranteee that the recipient mailbox will accept an email of the same size though.

link|improve this answer
feedback

Your Answer

 
or
required, but never shown

Not the answer you're looking for? Browse other questions tagged or ask your own question.