Today at work I had to check if the email of a client exists. Using the method below you can get this information directly from the mail server responsible. In this example I am querying my SMTP server at work (the domain is obviously fake, but the replies are legit).
1. check if any MX record exists
# host -t MX myworkdomain.com myworkdomain.com mail is handled by 10 mail.myworkdomain.com.
2. connect to the SMTP server
# telnet mail.myworkdomain.com 25 Connected to mail.myworkdomain.com. 220 mail.myworkdomain.com ESMTP
3. greet the email server
helo yourdomain.com 250 mail.myworkdomain.com at your service
4. define where you’re sending the email from (don’t forget < and >)
mail from: <ma[email protected]> 250 sender <[email protected]> ok
5. define who you’re sending the email to
rcpt to: <[email protected]> 550 #5.1.0 Address rejected. rcpt to: <[email protected]> 250 recipient <[email protected]> ok
quit 221 See ya in cyberspace