Preventing Recipients from getting an email. - How Email Processing Works? - smtp

When you send an email with this:
From: Jeff#yahoo.com
To: XXX#aol.com, XXX#aol.com, XXX#aol.com
CC: james#gmail.com
Which Mail Server sends the message via email to the recipients in the TO & CC field? Is it the SMTP server or the server owned by the recipient (like aol.com)?

When you write an email and send it, you will hand it off to some SMTP server you have access to. That server will then contact the recipients server (or intermediate server) and deliver the email to that SMTP server. The SMTP server on the receiving end will somehow, depending on their setup, deliver the email to their users.
In your example, you will properly give yahoo.com's SMTP server the email. Then that server will contact aol.com and deliver the email there. It will also contact gmail.com and deliver the email to their SMTP server.
You should read this part of the SMTP rfc which have a very good explanation about the process.
How you will go about preventing that an email is delivered, is to somehow control one of the SMTP servers that is contacted in the process - or not send the email at all. When you see the email delivered in your own mailbox, it is properly way to late trying to prevent the other recipients receiving the email.

Related

Setting up mail smtp relay service to send and receive mail

I have very limited knowledge about SMTP and IMAP/POP. SMTP --> sending message, IMAP--> Mainly for receiving messages.
I have a woocommerce website and i already did setup my email system to use SMTP relay using zoho. I believe zoho also provide mailbox services since I am able to communicate with my customer(both two and fro) using its email service. They have their app and i can receive and send mail from that app. Obviously, I have set up all the records including MX to send/receive the email to my zoho inbox.
No i want to move my email services to postmark or like sendinblue. All i can see the setting related to sending the mail but how/where will I receive the mail when user reply on that??
On the postmark website it says:
Since Postmark is not a mailbox provider there's not the ability to generate mailboxes for receiving email using IMAP or POP3.
Question 1) Does the SMTP relay server is actually a different physical machine from IMAP server for sending/receiving messages. I guess both are different but why are these companies not providing solutions like zoho. Pardon me if I did not understand the use case.
Question 2) What to do in this case ???. My case is simple. I send notifications to customers regarding their orders. If they want they can reply or enquire. I receive the email on my phone and I can reply on the same mail-chain like we have on Gmail.
Question 3)
Do i need to buy some another service along with these to receive and reply back on the email ??? Like from godaddy or somewhere else.

Emails sent through smtp server is not received to educational domain accounts

I am trying to send email using flask_mail that has configuration as:
MAIL_SERVER = "smtp.gmail.com"
MAIL_USERNAME = "dummy#gmail.com"
username is my personal verified gmail account.
The smtp server is able to send emails to #gmail and #xyz.edu accounts as I see no error.
But I cannot see emails in #xyz.edu accounts.
I can see the emails sent to my other #gmail accounts.
I am not sure why I cannot see the emails sent by smtp to my #xyz.edu account.
Any help is appreciated.
Thanks
If you can't telnet from the exchange box to that specific IP/SMTP then the problem could be on their end or on the path to their end.
The problem was with the ISP on the other end.
They need to configure
Exchange to accept mail for multiple authoritative domains.

Java Mail API host name

I have implemented IMAP server mail box and one valid user account on that mail box for receiving email and reading mail.
Now I want to send mail through that user account. After goggling for some time , I found that we can't send mail using IMAP server.
So now the problem is I want to send mail using that mail account only. Is there any way?

Is SMTP protocol only for sending?

Is it possible to use SMTP as described in RFC 5321 to receive mail or is it prohibited by this spec?
SMTP is used only for sending mail - transferring mail to mail servers, and between mail servers. POP and IMAP are two popular protocols (but not the only protocols) for mail user agents (end-user email clients) to retrieve mail, which I'm guessing is what you're asking about.
To put it a different way, an SMTP conversation is initiated by software that wishes to transmit email to another device. It's not usually used as the last-hop step to deliver email to a user - those conversations are usually initiated by software that wishes to receive the email.
ESMTP extensions for email receiving
SMTP is used to receive email servers listed in MX recerds from "all internet".
If you want to use it to receive your email from relay accepting emails from "all internet":
with static IP address but without permanent internet connection you may use ETRN command [RFC-1985]
https://en.wikipedia.org/wiki/ETRN#ETRN
with dynamic IP address you may use ATRN [RFC-2625]
https://en.wikipedia.org/wiki/On-Demand_Mail_Relay
Both extensions are designed for "for domain emails" not for "single mailbox emails".

How does a mail relayer doesn't send a mail to already received recipients?

i was wondering.
Suppose i have an exchange server, (the domain can be me#company.com),
also, i have a relay server, that accepts requests to internet domains (gmail/yahoo/etc).
suppose i send a mail to: (you#company.com; him#gmail.com) - from a user in the domain (me#company.com)
The mail is sent to the exchange server, then the exchange groups the domains (company.com and gmail.com) => it puts the mail into you#company.com mailbox.
then, the exchange sees that it needs to send into him#gmail.com, so it will send it to the relay server.
the relay server will get the SMTP request:
from: me#company.com
to: you#company.com; him#gmail.com
the question is - how does the smtp relay server knows not to send it to you#company.com - thus causing duplicate mails received?
also, how does the gmail server knows not to try to send the mails it receives again? (because they only get smtp requests, similar to a client that sends the mail)
thanks in advanced!
The content of the mail is not parsed by either exchange or the relay for determining where the mail should go. Everyone in this context is talking SMTP with one another, and specify recipients with the RCPT protocol message. So your mail client tells exchange two RCPT, exchange decides one of them is remote, then says one RCPT to the relay, and so on and so forth. This document specifies the SMTP protocol where you may read about the RCPT verb.
The headers you see are not used to deliver the message. Instead, SMTP defines a concept called envelope which has a completely different set of headers. As a common illustration, this is how Bcc: works, too; the recipient address is copied to the envelope, then removed from the message which goes inside the envelope.
When a message is delivered, the envelope sender is usually copied into the Return-Path: header, and you can sometimes see the envelope recipient information copied into the Received: headers.
At the point where a mail server decides to which destinations a message should go, there is commonly one copy of the message (spool file, queue entry, what have you) for each distinct destination. So if you send to from you#company to me#company, you#private, and friend#gmail, the first server might determine that the external addresses should both go to the same outbound relay, while the internal copy is delivered locally. Then the relay similarly decides that it needs to contact two distinct destination, so the single incoming message gets copied to two outbound messages, one to you#private and the other to friend#gmail.