hMail server not sending mails to external domain

Use this forum if you have installed hMailServer and want to ask a question related to a production release of hMailServer. Before posting, please read the troubleshooting guide. A large part of all reported issues are already described in detail here.
Post Reply
divyapoornam
New user
New user
Posts: 2
Joined: 2019-11-06 13:53

hMail server not sending mails to external domain

Post by divyapoornam » 2019-11-13 14:48

Hi Team,


I'm getting emails successfully from Gmail, but Im not able to send mail to Gmail

Please help me out with the below log:

"SMTPC" 19896 17848 "2019-11-13 18:14:20.540" "183.82.250.38" "SENT: [nl]."
"SMTPD" 7724 17847 "2019-11-13 18:14:20.578" "192.168.16.63" "SENT: 250 Queued (0.864 seconds)"
"SMTPC" 19896 17848 "2019-11-13 18:14:20.579" "183.82.250.38" "RECEIVED: 250 Queued (0.864 seconds)"
"SMTPC" 19896 17848 "2019-11-13 18:14:20.580" "183.82.250.38" "SENT: QUIT"
"SMTPD" 1484 17847 "2019-11-13 18:14:20.581" "192.168.16.63" "RECEIVED: QUIT"
"SMTPD" 1484 17847 "2019-11-13 18:14:20.581" "192.168.16.63" "SENT: 221 goodbye"
"SMTPC" 7664 17848 "2019-11-13 18:14:20.583" "183.82.250.38" "RECEIVED: 221 goodbye"
"SMTPD" 17628 17851 "2019-11-13 18:14:20.584" "192.168.16.63" "SENT: 220 mail.sternasecurity.com ESMTP"
"SMTPC" 17628 17852 "2019-11-13 18:14:20.585" "183.82.250.38" "RECEIVED: 220 mail.sternasecurity.com ESMTP"
"SMTPC" 17628 17852 "2019-11-13 18:14:20.585" "183.82.250.38" "SENT: HELO mail.sternasecurity.com"
"SMTPD" 19896 17851 "2019-11-13 18:14:20.587" "192.168.16.63" "RECEIVED: HELO mail.sternasecurity.com"
"SMTPD" 19896 17851 "2019-11-13 18:14:20.587" "192.168.16.63" "SENT: 250 Hello."
"SMTPC" 17628 17852 "2019-11-13 18:14:20.588" "183.82.250.38" "RECEIVED: 250 Hello."
"SMTPC" 17628 17852 "2019-11-13 18:14:20.589" "183.82.250.38" "SENT: MAIL FROM:<update@sternasecurity.com>"
"SMTPD" 7664 17851 "2019-11-13 18:14:20.590" "192.168.16.63" "RECEIVED: MAIL FROM:<update@sternasecurity.com>"
"SMTPD" 7664 17851 "2019-11-13 18:14:20.591" "192.168.16.63" "SENT: 250 OK"
"SMTPC" 19896 17852 "2019-11-13 18:14:20.592" "183.82.250.38" "RECEIVED: 250 OK"
"SMTPC" 19896 17852 "2019-11-13 18:14:20.593" "183.82.250.38" "SENT: RCPT TO:<divya@sterna.in>"
"SMTPD" 17628 17851 "2019-11-13 18:14:20.594" "192.168.16.63" "RECEIVED: RCPT TO:<divya@sterna.in>"
"SMTPD" 17628 17851 "2019-11-13 18:14:20.595" "192.168.16.63" "SENT: 250 OK"
"SMTPC" 7664 17852 "2019-11-13 18:14:20.596" "183.82.250.38" "RECEIVED: 250 OK"
"SMTPC" 7664 17852 "2019-11-13 18:14:20.596" "183.82.250.38" "SENT: DATA"
"SMTPD" 19896 17851 "2019-11-13 18:14:20.598" "192.168.16.63" "RECEIVED: DATA"
"SMTPD" 19896 17851 "2019-11-13 18:14:20.598" "192.168.16.63" "SENT: 354 OK, send."
"SMTPC" 17628 17852 "2019-11-13 18:14:20.599" "183.82.250.38" "RECEIVED: 354 OK, send."

User avatar
mattg
Moderator
Moderator
Posts: 20837
Joined: 2007-06-14 05:12
Location: 'The Outback' Australia

Re: hMail server not sending mails to external domain

Post by mattg » 2019-11-13 17:19

Remove the SMTP Relayer (leave it blank) then try again

If you still have issues please run this and post the results

viewtopic.php?f=20&t=30914
Just 'cause I link to a page and say little else doesn't mean I am not being nice.
https://www.hmailserver.com/documentation

divyapoornam
New user
New user
Posts: 2
Joined: 2019-11-06 13:53

Re: hMail server not sending mails to external domain

Post by divyapoornam » 2019-11-14 06:24

Tried removing the relayer but getting error in the SMTP log.
SMTPC" 2680 26226 "2019-11-14 09:50:50.684" "172.217.194.26" "SENT: HELO mail.sternasecurity.com"
"SMTPC" 7828 26226 "2019-11-14 09:50:50.952" "172.217.194.26" "RECEIVED: 250 mx.google.com at your service"
"SMTPC" 7828 26226 "2019-11-14 09:50:50.952" "172.217.194.26" "SENT: MAIL FROM:<narayan@sternasecurity.com>"
"SMTPC" 2680 26226 "2019-11-14 09:50:51.218" "172.217.194.26" "RECEIVED: 250 2.1.0 OK n14si5536156pfq.242 - gsmtp"
"SMTPC" 2680 26226 "2019-11-14 09:50:51.219" "172.217.194.26" "SENT: RCPT TO:<divya@sterna.in>"
"SMTPC" 7828 26226 "2019-11-14 09:50:51.642" "172.217.194.26" "RECEIVED: 250 2.1.5 OK n14si5536156pfq.242 - gsmtp"
"SMTPC" 7828 26226 "2019-11-14 09:50:51.642" "172.217.194.26" "SENT: DATA"
"SMTPC" 7828 26226 "2019-11-14 09:50:51.908" "172.217.194.26" "RECEIVED: 354 Go ahead n14si5536156pfq.242 - gsmtp"
"SMTPC" 7828 26226 "2019-11-14 09:50:51.908" "172.217.194.26" "SENT: [nl]."
"SMTPC" 7828 26226 "2019-11-14 09:50:52.342" "172.217.194.26" "RECEIVED: 550-5.7.1 [183.82.250.38] The IP you're using to send mail is not authorized to[nl]550-5.7.1 send email directly to our servers. Please use the SMTP relay at your[nl]550-5.7.1 service provider instead. Learn more at[nl]550 5.7.1 https://support.google.com/mail/?p=NotAuthorizedError n14si5536156pfq.242 - gsmtp"
"SMTPC" 7828 26226 "2019-11-14 09:50:52.342" "172.217.194.26" "SENT: QUIT"
"ERROR" 14276 "2019-11-14 09:50:52.345" "Severity: 3 (Medium), Code: HM4404, Source: SMTPDeliverer::_ApplyForwarding, Description: Did not submit bounce message for message 21912 from narayan@sternasecurity.com since rule loop count was reached or Auto-Submitted header."
"SMTPD" 7828 26219 "2019-11-14 09:50:52.806" "192.168.16.171" "RECEIVED: QUIT"
"SMTPD" 7828 26219 "2019-11-14 09:50:52.806" "192.168.16.171" "SENT: 221 goodbye"




---------------------------------------------------------------------------------------------------------------------------------------------------------

Diag :

Code: Select all

2019-11-14   Hmailserver: 5.6.7-B2425

DOMAINS

   "Domain1.com" - stxxxxxxxxxxxx.com             Enabled: True

SIGNATURE         LIMITS                       DKIM               ADVANCED
  Enabled: False   Max size:                2   Enabled: False   
                   Max message size:      500                      Plus addressing: False
                   Max size of accounts:    0                    
                                                                   Greylisting:     False
-----------------------------------------------------------------------------------------------

IP RANGES

IP: 127.0.0.1 - 127.0.0.1     Priority: 15     Name: My Computer

  Allow connections                         Other
     SMTP:   True                              Antispam :   True !! 'Spam tests' not enabled !!
     POP3:   True                              Antivirus:   True !! ANTIVIRUS NOT CONFIGURED !!
     IMAP:   True                              SSL/TLS:     True

  Allow Deliveries from                     Require Authentication from
     Local To Local       -  True              Local To Local       -  True
     Local To External    -  True              Local To External    - False
     External To Local    -  True              External To Local    - False
     External To External -  True              External To External -  True


IP: 0.0.0.0 - 255.255.255.255     Priority: 10     Name: Internet

  Allow connections                         Other
     SMTP:   True                              Antispam :   True !! 'Spam tests' not enabled !!
     POP3:   True                              Antivirus:   True !! ANTIVIRUS NOT CONFIGURED !!
     IMAP:   True                              SSL/TLS:    False

  Allow Deliveries from                     Require Authentication from
     Local To Local       -  True              Local To Local       - False
     Local To External    -  True              Local To External    - False
     External To Local    -  True              External To Local    - False
     External To External -  True              External To External -  True


   !!  Warning:  DEFAULT DOMAIN is SET  !! - "Domain1.com"
------------------------------------------------------
AUTOBANNED Local Addresses:
    No entries

-----------------------------------------------------------------------------------------------

AUTOBAN
  Autoban Enabled: False

No problems were found in the IP range configuration.
-----------------------------------------------------------------------------------------------

INCOMING RELAYS
                    192.168.16.93    -   192.168.16.93
-----------------------------------------------------------------------------------------------

MIRRORING         Disabled
-----------------------------------------------------------------------------------------------

PROTOCOLS

SMTP
GENERAL             DELIVERY                  RFC COMPLIANCE            ADVANCED
No. Connections:  0  No Retries:  1 Mins:  1   Plain Text:         True  Bind: 192.168.16.93
                     Host: EXTERNAL.TLD        Empty sender:       True  Batch recipients:   100
Max Msg Size: 30480  Relay:-                   Incorrect endings:  True  Use STARTTLS:     False
                     (none entered)            Disc. on invalid:  False  Delivered-To hdr: False
                                                                         Loop limit:           0
                                                                         Recipient hosts:      0
  Routes:
     No routes defined.

POP3
  No. Connections: 100

IMAP
 GENERAL                   PUBLIC FOLDERS                    ADVANCED
  No. Connections:   0      Public folder name: #Public       IMAP sort:  True
                                                              IMAP Quota: True
                                                              IMAP Idle:  True
                                                              IMAP ACL:   True
                                                              Delim: "."
-----------------------------------------------------------------------------------------------

ANTISPAM

GENERAL                              SPAM TESTS              Score   SPAMASSASSIN
  Spam Mark:                  5       Use SPF:           False        Use Spamassassin:   False
  Add X-HmailServer-Spam:     True    Check HELO host:   False    
  Add X-HmailServer-Reason:   True    Check MX records:  False    
  Add X-HmailServer-Subject: False    Verify DKIM:       False    

  Spam delete threshold: 20         Maximum message size: 1024

DNSBL ENTRIES:
   No 'enabled' entries

SURBL ENTRIES:
   No 'enabled' entries

GREYLISTING:
  Greylisting:  False

WHITELISTING
   No entries
-----------------------------------------------------------------------------------------------

ANTIVIRUS:  No application configured.

  Block Attachments: False
-----------------------------------------------------------------------------------------------

SSL CERTIFICATES
   No entries
-----------------------------------------------------------------------------------------------

SSL/TLS
             SSL 3.0 :  False
             TLS 1.0 :   True
             TLS 1.1 :   True
             TLS 1.2 :   True                Verify Remote SSL/TLS Certs:   True
SslCipherList  :

ECDHE-RSA-AES128-GCM-SHA256     - ECDHE-ECDSA-AES128-GCM-SHA256   - ECDHE-RSA-AES256-GCM-SHA384     
ECDHE-ECDSA-AES256-GCM-SHA384   - DHE-RSA-AES128-GCM-SHA256       - DHE-DSS-AES128-GCM-SHA256       
kEDH+AESGCM                     - ECDHE-RSA-AES128-SHA256         - ECDHE-ECDSA-AES128-SHA256       
ECDHE-RSA-AES128-SHA            - ECDHE-ECDSA-AES128-SHA          - ECDHE-RSA-AES256-SHA384         
ECDHE-ECDSA-AES256-SHA384       - ECDHE-RSA-AES256-SHA            - ECDHE-ECDSA-AES256-SHA          
DHE-RSA-AES128-SHA256           - DHE-RSA-AES128-SHA              - DHE-DSS-AES128-SHA256           
DHE-RSA-AES256-SHA256           - DHE-DSS-AES256-SHA              - DHE-RSA-AES256-SHA              
AES128-GCM-SHA256               - AES256-GCM-SHA384               - ECDHE-RSA-RC4-SHA               
ECDHE-ECDSA-RC4-SHA             - AES128                          - AES256                          
RC4-SHA                         - HIGH                            - !aNULL                          
!eNULL                          - !EXPORT                         - !DES                            
!3DES                           - !MD5                            - !PSK;                           
-----------------------------------------------------------------------------------------------

TCPIP PORTS                                         Connection Sec
               0.0.0.0         / 25    / SMTP   -   None                
               0.0.0.0         / 110   / POP3   -   None                
               0.0.0.0         / 143   / IMAP   -   None                
               0.0.0.0         / 587   / SMTP   -   None                
-----------------------------------------------------------------------------------------------

LOGGING      Logging Enabled: True

  Paths:-
    Current:  C:\Program Files (x86)\hMailServer\Logs\hmailserver_2019-11-14.log
    Error:    C:\Program Files (x86)\hMailServer\Logs\ERROR_hmailserver_2019-11-14.log - !! ERRORS PRESENT !!
    Event:    C:\Program Files (x86)\hMailServer\Logs\hmailserver_events.log - Not present
    Awstats:  C:\Program Files (x86)\hMailServer\Logs\hmailserver_awstats.log
                        APPLICATION -      .
                        SMTP        -    True
                        POP3        -      .
                        IMAP        -      .
                        TCPIP       -      .
                        DEBUG       -      .
                        AWSTATS     -      .
-----------------------------------------------------------------------------------------------

SYSTEM TESTS

Database type: MSSQL

IPv6 support is available in operating system.

Backup directory E:\mail is writable.

Relative message paths are stored in the database for all messages.

-----------------------------------------------------------------------------------------------

HMAILSERVER.INI

[Directories]
Program folder:  C:\Program Files (x86)\hMailServer\
Database folder: 
Data folder:     C:\Program Files (x86)\hMailServer\Data
Log folder:      C:\Program Files (x86)\hMailServer\Logs
Temp folder:     C:\Program Files (x86)\hMailServer\Temp
Event folder:    C:\Program Files (x86)\hMailServer\Events

[Database]
Type=              MSSQL
Username=          sa
PasswordEncryption=1
Port=              0
Server=            192.168.16.93
Internal=          0
-----------------------------------------------------------------------------------------------

Generated by HMSSettingsDiagnostics v1.98, Hmailserver Forum.

Virinum
Normal user
Normal user
Posts: 88
Joined: 2018-11-23 14:42
Location: Germany

Re: hMail server not sending mails to external domain

Post by Virinum » 2019-11-14 07:45

Your IP is not allowed to send mails „direct-to-mx“: https://www.spamhaus.org/pbl/query/PBL505694

You have to use a relay server. But don’t enter your own server. That doesn’t make sense. Google for „mail relay server“. Or you could try a delisting at Spamhaus. But I think there are good reasons why your IP is listed.

User avatar
mattg
Moderator
Moderator
Posts: 20837
Joined: 2007-06-14 05:12
Location: 'The Outback' Australia

Re: hMail server not sending mails to external domain

Post by mattg » 2019-11-14 08:38

Yep you are an open relay

on IP ranges press the default button, or at least require AUTH from local to external on the internet range

Also, you have a default domains set.
If you don't know why it is set, then remove it.

Those two things combined means that anyone can send email even from a made up account
No wonder that you've been listed
Just 'cause I link to a page and say little else doesn't mean I am not being nice.
https://www.hmailserver.com/documentation

Virinum
Normal user
Normal user
Posts: 88
Joined: 2018-11-23 14:42
Location: Germany

Re: hMail server not sending mails to external domain

Post by Virinum » 2019-11-14 09:46

mattg wrote:
2019-11-14 08:38
No wonder that you've been listed
No, that's not the reason. See the description about Spamhaus PBL:
The Spamhaus Policy Block List ("PBL") is an international anti-spam system maintained by The Spamhaus Project in conjunction with Internet Service Providers and is used by Internet networks to enforce inbound email policies. The PBL database lists end-user IP address ranges which should not be delivering unauthenticated email to any mail server except those provided for specifically for that customer's use. The PBL lists only IP addresses (not domains or email addresses).
But you're right. It's only a matter of time before the IP gets listed on other blacklists.

Post Reply