I run a simple mybb forum on AWS EC2 and I wish to send notifications to my users.
I have tried to request aws regarding upgrade of my email sending quota but they have refused.
Also tried SES but request is refused again.
Is there any way out I can reach my audience?
Wondering if I can do a http GET request to a SMTP server to send emails?
You definitely don't want to send emails directly from your ec2 server, and I would generally recommend SES instead - but if for whatever reason that doesn't suit your needs, any SMTP server should work fine - doesn't need to be an GET request, just plug in your SMTP credentials to whatever service you are using - gmail, ses, mailchimp, sendgrid, mailgun - pretty much any service is available to you and should work fine.
Related
I set up a WHM server on AWS EC2 instance and configured it to host a site. I also planned to use the WHM email service to send and receive mails but found that the emails were received on those email users created in WHM but were not able to send the emails.
Is there any way to send emails from the WHM server without using AWS SES or other email relay services?
I have a requirement where GCP VM instance which is behind a squid proxy and NAT gateway should be able to send emails to AWS SES.
SES: email-smtp.eu-west-1.amazonaws.com
as far as I know, GCP has port 25 blocked and after referring to few articles on stackoverflow, it seems squid does not support SMTP as well.
can someone please help if they have worked on similar thing before?.
Thanks
Max
Use port 587. As per AWS SES and GCP documentation port 587 is without any restriction.
Option 1, AWS SES HTTP API:
If the email sending application could support sending emails via AWS SES with the use of their HTTP API instead of the SMTP protocol, you could allow that regional HTTPS endpoint in the outbound firewall (Squid in your case.)
The advantages of this approach address your concerns on bypassing the proxy by going through Cloud NAT directly, and maintaining restrictions on traffic originating from the source subnet.
Option 2, AWS SES SMTP over TLS:
Configure the application to connect with AWS SES SMTP endpoints on port 465 or 2465 while using TLS. This is also called SMTPS (where the trailing S stands for SSL/TLS, just like in HTTPS.) This is documented under TLS Wrapper in AWS' documentation.
Since Squid is primarily a proxy for HTTP, you will be better of replacing it with an outbound firewall that supports filtering traffic by FQDNs for SSL/TLS connections wrapping any protocol within. (In this case, SMTP wrapped in TLS.) These are typically called NGFW and available from the GCP marketplace on a free trial. One advantage of using these is the applications don't need explicit proxy settings for connecting to the Internet as the operation is completely transparent.
I currently have a backend running in a container (ECS), this backend has a SES service for sending e-mail (user password recovery).
I implemented this same scenario using SUBNET for my backend, but sending e-mail is no longer working.
In both my old scenario (without using a subnet) and localhost, sending the email works perfectly.
I did a ping test from the container and got a timeout answer:
In this case it looks like you have the wrong address, you have
email-smtp.us-east-1.amazonaws.com (email-smtp) defined on your endpoint, and
email.us-east-1.amazonaws.com (email) in your ping.
Remember that a Ping may not respond if ICMP is not allowed through.
For a wider answer to this question, you have 2 options:
Make sure that you have an Internet Gateway configured correctly on your Subnet, and the security group added to your ECS host allows outgoing traffic to port 25 (this is throttled by AWS), 587 or 2587 depending on what you are using to talk to SES: https://docs.aws.amazon.com/ses/latest/DeveloperGuide/smtp-connect.html
Create an SES VPC Endpoint on your subnet, then direct all of your SES requests to this new endpoint/IP Address: https://docs.aws.amazon.com/ses/latest/DeveloperGuide/send-email-set-up-vpc-endpoints.html
If any of these are not working, check:
You are not in SES Sandbox mode (raise a support request)
You are not being throttled on port 25 from your host (use port 587 or raise a support request)
You can connect to the internet from your EC2/ECS instance
Port 587 is enabled on your security group
The URL Address is correct (email-smtp.us-east-1.amazonaws.com)
The IAM Role on your EC2/ECS Host (or IAM User) is enabled for SES Sending.
I have used Gmail SMTP service with port 587 on the local server and it's working fine.
But it's not working on AWS EC2 instance. So I added SMTP rules on EC2 instance security inbound rules see below image but SMTP port can not be editable.
Now the issue is if your domain does not configure secured connections. Gmail does not offer port 25 in an unsecured connection.
So, there is any way to use SMTP on unsecured connection with 25 port or any other way.
I have fixed issue as of now for a development server. Please, not it's not the correct way to a production site.
For sending an email from AWS EC2 using Gmail SMTP service please follow below steps.
Edit security group of your EC2 Instance.
Edit inbound rules of the security group.
Add 587 port in inbound rules. See below image.
you need to set your instance inbound rules for coming mail and outbound for send.
After that, you can send email using 587 SMTP port from AWS EC2.
Please read this article. https://support.google.com/accounts/answer/6010255?hl=en
https://myaccount.google.com/lesssecureapps
Because of the spam abuse that has historically been sent from people using EC2 instances, virtually ALL popular mail providers block the receipt of email from EC2 instances. The world of email and anti-spam measures is part-technical, part-political. For this reason, AWS offers Amazon Simple Email Service.
Step to fix it-
Go to google account setting and Turn on Two-step verification.
Now generate an app password for the app you want to send mail.
Use the generated password for the app in SMTP with the same Email.
That's it.
To send email from C# hosted on Amazon EC2, make sure you have two things done.
Use following setting in your Web.config
<mailSettings>
<smtp deliveryMethod="Network" from="<from email goes here>">
<network host="smtp.gmail.com" port="587" enableSsl="true" userName="email id goes here" password="<password goes here> />
</smtp>
</mailSettings>
Login the above gmail account onto the Amazon EC2. If you do not login, then gmail blocks the email being sent from code due to security reasons.
According to Googles documentation, you can use the G Suite SMTP relay service through port 25. You can read more information here:
https://support.google.com/a/answer/176600?hl=en
and here:
https://support.google.com/a/answer/2956491
Hope this helps!
Ive been reading all days different blog all around the web looking for a solution to my problem. For the first time in my life a used AWS VPS (with ubuntu 2.04.1 LTS) to host my Wordpress blog. My problem is I dont know how to send transactional mails (user suscription confirmation, password reset) through it. I set a AWS SES account and already verified a domain and have been granted production access. I dont know what to do next. How can i verify a sender email address using my Dreamhost domain and how can i start sending welcome emails to new users from a custom domain email address?
I found some wordpress plugins such as WP SES but all i get is an empty blank page when i try to access their settings.
Your help is much appreciated, thanks.
Since you are using Wordpress, you can easily use a plugin to send through Amazon SES.
Our AWS re:Invent presentation shows you how to configure Amazon SES and Wordpress to send using the service. We used the Configure SMTP plugin to connect Wordpress with Amazon SES. This plugin sends all email generated by Wordpress through Amazon SES.
Also, you don't need to verify an email address if you have production access and the domain you are sending from is already verified. Amazon SES will accept email from any email address at the verified domain.