I have a program which sends email to customers using Yandex SMTP server. But I frequently get:
554 5.7.1 [2] Message rejected under suspicion of SPAM; https://ya.cc/1IrBc 1593708139-nzbnbCCRfk-gIZ4AKCg
I have set following headers on each email request:
headers["Content-Type"] = "text/html; charset=UTF-8"
headers["Date"] = time.Now().Format("Mon, 02 Jan 2006 15:04:05 MST")
How can I prevent this error? Is there any settings or header which I can set for that?
The answer lies in your question: "program which sends email to customers". Yandex doesn't allow these type of emails. Its stated here
Messages that are similar, use a template, or contain commercial or advertizing proposals are sent from your mailbox. Yandex.Mail doesn't allow you to send these types of email. Our service is intended for actual communication between people.
I faced the similar problem. I checked the MX, SPF configuration for any misconfig but those were set correctly. The solution was, I removed the signature template/ signatures from emails and it worked fine then.
Nevertheless, you should move to Mailgun, Sendgrid or STMP2Go for your emails to avoid such issues or suspension by Yandex.
Related
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.
My iOS application uses Mailcore to access a user's email account. Sending and receiving is done via SMTP and IMAP, and both processes work as expected for Gmail and Outlook (which both use OAuth for login).
I just added Yahoo (as well as some other providers to the app who do not use OAuth) and for all of these providers I am having an issue specifically with sending messages.
The issue is that although messages DO get sent successfully from my application, they do not appear in the sent folder on the web for the provider.
For example, if I log into my Yahoo account in my application, and send a message to my Gmail account, the message appears in my Gmail inbox on the web, but not in my Yahoo sent box on the web.
I tried adding Yahoo to the regular mail app on iPhone and sending a message from this account - this worked fine - the message shows up Yahoo sent box on the web. So, I then compared the headers of the two messages (the one sent from mail app and the one sent from my app) and the only obvious difference I see is in the line 'X-Rocket-Received':
Mail App:
X-Rocket-Received: from [11.180.250.219] (userName#71.208.72.234 with xymcookie [216.39.61.254])
by smtp203.mail.ne1.yahoo.com with SMTP; 23 May 2014 08:19:54 -0700 PDT
My App:
X-Rocket-Received: from (userName#118.41.27.139 with plain [98.138.105.21])
by smtp214.mail.ne1.yahoo.com with SMTP; 23 May 2014 08:58:29 -0700 PDT
Can anyone answer any of the following questions for me:
1) What does X-Rocket-Received mean?
2) What is the significance of "with xymcookie" versus "with plain"?
3) Is my issue likely to do with my not having an xymcookie?
4) Where might I begin to solve this issue?
Many thanks.
Additional information:
It was placed there by some server along the way. It is a non-standard header. It appears similar to a standard SMTP Received header though.
'xymcookie' is a non-standard authentication method used by Yahoo. It is not, as far as I can tell, publicly documented.
No.
See Remy's answer. Use IMAP Append for most servers. Gmail does not require it, but that is non-standard.
Sending an email with SMTP directly does not put the email in the provider's Sent folder. You have to log into the provider with IMAP and put a copy of the email into the Sent folder as a separate operation. Higher level apps, like iPhone's mail app, handle these details internally.
I am using our email server at [mydomainhere].com to send emails through a web site UI. I just used the UI to send an email from [myemail]#yahoo.com. And received an Undeliverable message at my yahoo email address.
mta1400.mail.ne1.yahoo.com rejected your message to the following e-mail addresses:
[myemail]#yahoo.com
mta1400.mail.ne1.yahoo.com gave this error:
Message not accepted for policy reasons. See http://postmaster.yahoo.com/errors/postmaster-28.html
More information can be found here:
http://www.pcworld.com/article/2141120/yahoo-email-antispoofing-policy-breaks-mailing-lists.html
Any help would be appreciated.
Yes Allan, you are correct in assuming that the anti-spoofing that Yahoo (and now AOL) have turned on is permanent. The technology they are using is called DMARC. Yahoo has published a DMARC record in their DNS:
$ dig TXT _dmarc.yahoo.com. +short
"v=DMARC1; p=reject; sp=none; pct=100; rua=mailto:dmarc-yahoo-rua#yahoo-inc.com, mailto:dmarc_y_rua#yahoo.com;"
Every mail server that supports DMARC will look up that record in Yahoo's DNS and apply Yahoo's p=reject policy. In effect, what Yahoo has done is stated to the world, "if the email does not originate from this list of IPs (SPF) or bear this crytographic signature (DKIM), then reject (p=reject) it." Since your mail server is not in their list of mail servers IPs nor are the messages signed with Yahoo's DKIM key, a substantial and growing portion of the mail servers on the internet are going to reject it or deliver it to the Spam folder (Gmail).
In addition to the SPF & DKIM checks, DMARC also introduces the concept of alignment. In addition to passing SPF checks (which apply to the Envelope Sender), DMARC requires that the domain in the messages 'From' header passes SPF. This prevents you (and bad actors) from sending messages with a header From domain of Yahoo.com and an Envelope Sender domain of attacker.com, which the recipient will never see. This alignment also extends to the DKIM signature, requiring not just that the message is signed with DKIM, but also that the dkim signature domain (d= property) matches the From header domain.
we will just have to prevent users from using their yahoo email address in the sender email field
Coding in a check for the yahoo.com domain is a hack that won't last long. AOL has already joined the thousands of domain owners with DMARC p=reject policies. They won't be the last of the Very Large Email providers to publish p=reject DMARC policies. A much safer approach is to evaluate SPF against your mail servers public IP and the domain in the users selected email address. If the SPF check fails, then choose an option:
Inform the user that their choice of domains doesn't permit 3rd party senders and they should choose another.
Alter the From header to send from a domain you control:
From: "user#yahoo.com via" <my-app#my-domain.com>
As already stated, you could define Reply-To if you wish for replies to expose the senders real email address.
Set up local usernames that forward to the sender's real email address. If you've used Craigslist, you're familiar with the idea. You maintain a mapping of local addresses and the email address they forward to.
Based on what you've said about your web application, it seems like #2 is the best fit.
I have had a similar problem with mailing lists that I maintain (e-mails with a From address something#yahoo.com bounced). I solved my problem by changing the From, Reply-to and Errors-to fields of the e-mails' headers as follows:
From: Organization name <no-reply#somedomain.org>
Reply-to: my-email-address#yahoo.com
Errors-to: my-email-address#yahoo.com
I suspect that similar changes will fix your problem.
Our Current email2fax gateway does not handle bounced emails very well. When a email is sent to the gateway the content is faxed out and a notification is sent to the original sender of the message.
Problems happen when the original user turns on a out of office agent and messages will bounces between the 2 email gateways.
I have tried to set in the outbound notification the following headers
From
Reply-To
But as this is a proprietary gateway it does not allow me to set a custom Return-PATH
some silly mail servers send replies back to that.
Are there any extra email headers that maybe I could set to say "Do not send a Notification back"
If not is there a email gateway that would be able to act like a proxy and sit in front of the gateway that would then allow me to programmable check the messages as they came in and drop out of office messages.
I would have thought an anti-spam program like SpamAssassin could be fine-tuned to catch out-of-office replies.
If your mail gateway can't even have an anti-spam system plugged into it then it really is a bad system to have around!
Try setting the Precedence: bulk-header (or junk) in your notifications. Usually OOO-notifiers like Unix vacation do not send notifications for incoming mails with that header.
As this header is slightly discouraged, you could try setting an empty Return-Path, as suggested in Precedence: header in email.
Is it possible to retrieve the SMTP response of a mail. For example, I am sending a mail to non existing email id. Surely our server will send us a mailer daemon failure mail to our mail id. I need to capture that failure mail.
How its possible? please explain me. Some time we may enter more than one non existing email id, so i have to retrieve all the failure mail alone for every corresponding emails
Please guide me!
Thanks in advance,
Praveen J
I think I understood your question correctly now. As I understand, you are writing an application to send mail. And in your application, whenever you send a mail, you also want verify that if mail was delivered and also if it was not delivered then you want to get hold of the failure message in your application. Is that how you mean?
Well, if that is how you mean, then I think it is impossible to track the mail status with your apllication code. For instance if you are using java sendMail in your apllication you can only ensure that the send happened from your code successfully(without any send exceptions like java.net.SocketException or javax.mail.MessagingException). But, you can never ensure if the mail really reached the recepient. i.e. you can never track in your application if the mail was rejected due to wrong recepient address or any other error like illegal attachment at receipient mail server or errors like blocked sender id etc.
That is because any such error condition will be communicated by the receipient mail server to the sending mail server the information of which is present in the sent mail's header.
Does that answer your question? (Or did I understand your question correctly? ;-))
I am not sure if I am getting your question right. If you send an email to any non existent address say xxx#gmail.com from your address yyy#yourhost.com, the mail server at gmail.com replies to the mail server at yourhost.com with failure message and reason, with your delivery address and you receive the fialure mail automatically. you don't have to do anything extra in this.
If you are talking about seeing mail headers, then it depends on which client you are using. For instace, if you are using MS outlook, you can right-click on the message and click options and then see internet headers section to get mail headers. If you are using some web based mail then i am sure there will some option to view detailed mail headers.
The bounced messages are going to return to a mailbox. You should be able to configure that mailbox by properly setting the headers on the messages you send out. You would then need to monitor that mailbox, or have that mailbox deliver the messages to your program.
I would suggest you consider using VERP for all messages you send out. It will make it much easier for you to identify which email address a particular bounce belongs too. To do this you would need control of your mail server though. It takes some work configuring things.
To answer the question with more detail you need to tell us how your are sending messages, what type of mail server you are running, and how much control you have over the mail server.
On Unix, you can use "procmail" for this. Procmail is a service which can intercept your mails and process them following rules.
If you can access your mail my IMAP, I suggest to look at the Python module imaplib.