Sending email with Joomla and Google Apps - joomla

I have the next settings in the Joomla Global Configuration panel.
**Mail Settings**
Mailer: SMTP Server
Mail from: email#mydomain.com
From Name: John Smith
Sendmail Path:
SMTP Authentication: Yes
SMTP Security: SSL
SMTP Port: 465
SMTP Username: email#mydomain.com
SMTP Password: ******
SMTP Host: gmail-smtp-in.l.google.com
I am running Joomla 1.5.14.
I have in my google apps domain both IMAP and POP enabled.
When I try to send an email with an article link by clicking the small envelope icon I get the next feedback. "The e-mail cold not be send correctly". The SMTP validation seems to work because I do not get any SMTP error but the email is not sent. Any idea would be really appreciated!
I have tested with SMTP Host as smtp.gmail.com without success.
I have tried with sendmail defined as /usr/sbin/postfix but without success.
Solution
Set sendmail path to the sendmail command or point sendmail to postfix if you have postfix installed.
Set SMTP Host to smtp.gmail.com. I would look like:
**Mail Settings**
Mailer: SMTP Server
Mail from: email#mydomain.com
From Name: John Smith
Sendmail Path: /usr/sbin/sendmail
SMTP Authentication: Yes
SMTP Security: SSL
SMTP Port: 465
SMTP Username: email#mydomain.com
SMTP Password: ******
SMTP Host: smtp.gmail.com

Mail Settings
Mailer: SMTP Server Mail from: emailmydomain.com
From Name: John Smith
Sendmail Path: /usr/sbin/sendmail
SMTP Authentication: Yes
SMTP Security: None
SMTP Port: 25
SMTP Username: emailmydomain.com
SMTP Password: **
SMTP Host: ssl://smtp.gmail.com:465

I have Virtuemart 1.1.4 with Joomla! 1.5.15.
The configuration that works for me was (both for virtuemart and joomla contacts):
Mail Settings
Mailer: SMTP Server
Mail from: email#mydomain.com
From Name: John Smith
Sendmail Path: /usr/sbin/sendmail
SMTP Authentication: Yes
SMTP Security: None
SMTP Port: 25
SMTP Username: email#mydomain.com
SMTP Password: ******
SMTP Host: ssl://smtp.gmail.com:465

Related

"Couldn't connect to host" occurs when trying to send mail from Gmail with Spring-Boot mail in Admin Server

I want to send mail as a reminder in Admin Server
But get this error:
com.sun.mail.util.MailConnectException: Couldn't connect to host, port: smtp.gmail.com, 587; timeout 20000
...
I have searched a lot online but still don't work
My Admin Server Application YAML configuration file:
spring:
security:
user:
name: admin
password: 123456
boot:
admin:
notify:
mail:
enabled: true
# receivers
to: xxx#outlook.com
ignore-changes: {"UNKNOWN:UP"}
# copy-to list
cc:
from: Spring Boot Admin<xxx#gmail.com>
# mail sender
mail:
host: smtp.gmail.com
port: 587
username: xxx#gmail.com
# with 2-factor authentication, we should get app password from Google
password: my-app-password
default-encoding: UTF-8
properties:
mail:
smtp:
connectiontimeout: 20000
timeout: 20000
writetimeout: 20000
starttls:
enable: true
required: true
auth: true
ssl:
enable: true
required: true
debug: true
server:
port: 8081
I config the settings with the help of this instruction
btw, 2-factor authentication is enabled with my Google account, so I followed this instruction to get my "app password"
But after I start my Admin Server application, and wait 20 second, the error appears
I have tried change port to 465, not working
I have tried spring.mail.properties.mail.smtp.socketFactory.port and configure it to 465, not working
I'm using Windows 11 and windows firewall has no Outbound rule against java, java platform, intelliJ idea, there're Inbound rules that block java and java(TM) platform, not working
With my config above, Admin Server should send a mail to xxx#outlook.com from xxx#gmail.com.

Connection could not be established with host smtp.sendgrid.net :stream_socket_client(): unable to connect to tcp://smtp.sendgrid.net:587

Some eamils sent successfully at start. But After that I face same issue again and again.
That's my .env variables.
Mail User Name: "apikey"
Mail Password: "Secrect API key"
Mail Host: "smtp.sendgrid.net"
Mail Encryption: "tls"
Mail Port: "587"
Mail Mailer: "smtp"
Mail From Name: "Demo"
Mail Mailer: "Demo#demo.com"
I have been apply this solution but not working.
MAIL_MAILER=sendmail
MAIL_PORT=587
MAIL_ENCRYPTION=ssl

Easy Redmine SMTP configuration error: An error occurred while sending mail (SSL_connect returned=1 errno=0 state=error: certificate verify failed)

I have following smtp configuration (/redmine_path/config/configuration.yml)
default:
email_delivery:
delivery_method: :smtp
smtp_settings:
address: mail.example.com
port: 465
authentication: :plain
domain: mail.example.com
user_name: "redmine#example.com"
password: "xxxxxxxx"
tls: true
enable_starttls_auto: false
openssl_verify_mode: 'peer'
You would expect that this is a correct configuration for TLS/SMTP mail server configuration.
But when you try to send test email. You get the following error:
An error occurred while sending mail (SSL_connect returned=1 errno=0 state=error: certificate verify failed)
Correct configuration requires additional parameter (Tested on Debian):
ca_file: "/etc/ssl/certs/ca-certificates.crt"
or
ca_path: "/etc/ssl/certs/"
After that change Redmine correctly finds CA Root Certificates.
Fully working configuration:
default:
email_delivery:
delivery_method: :smtp
smtp_settings:
address: mail.example.com
port: 465
authentication: :plain
domain: mail.example.com
user_name: "redmine#example.com"
password: "xxxxxxxx"
tls: true
enable_starttls_auto: false
openssl_verify_mode: 'peer'
ca_file: "/etc/ssl/certs/ca-certificates.crt"
Also make sure you have updated ca-certificates:
Exchange "package-manager" for yum, apt-get or zypper
<package-manager> install ca-certificates
I wonder how many people gave up and just set openssl_verify_mode to 'none'. Scary to think about with possible man-in-the-middle attack.
More information about Ruby ActionMailer::Base configuration: ActionMailer SMTP "certificate verify failed"

Exchange on Office 365 - need protocol, protocolport and serveradress

I need this for documentcapture, but I'm unable to locate this information.
From the Microsoft Support Document: POP and IMAP settings for Outlook Office 365 for business
Incoming Mail (IMAP) Server:
Host: outlook.office365.com
Port: 993
Requires SSL (TLS): Yes
Incoming Mail (POP) Server:
Host: outlook.office365.com
Port: 995
Requires SSL (TLS): Yes
Outgoing Mail (SMTP) Server:
Host: smtp.office365.com
Port: 587
Requires SSL (TLS): Yes

unable to send email via smtp over ssl

i am writing a ruby script to send email using 'mail' gem.
and my smtp settings on my local machine:
mailer_options:
address: smtp.gmail.com
port: 587
domain: gmail.com
user_name: example#gmail.com
password: example_password
authentication: :login
enable_starttls_auto: true
ssl: true
when i try to send the email with the above smtp settings i get the following exception:---
/opt/rbenv/versions/2.0.0-p247/lib/ruby/2.0.0/net/smtp.rb:585:in 'connect': SSL_connect returned=1 errno=0 state=SSLv2/v3 read server hello A: unknown protocol (OpenSSL::SSL::SSLError)
i tried installing ssl certificate by command
openssl s_client -connect gmail.com:443
but it does not help, thanks for any comments and answer.
Port 587 starts out plain text, and then "upgrades" to ssl via starttls if you want smtp from the start to use ssl, then you need to use port 465.
so either of these should fix your issue.
Remove enable_starttls_auto and set the port to 465
or
Remove ssl: true and rely on starttls to upgrade your connection to ssl

Resources