Skip to main content

Mailgun rejects logins

Comments

6 comments

  • owlight
    Also, I have opened mailgun support ticket and they provided, this - The only information we have on Exim is the below snippet from our docs. As the link mentioned, you will need to configure a smart host. For more information outside of the below, please see Exim"s documentation for authenticated outgoing SMTP. # In your exim.conf: # In routes configuration: mailgun: driver = manualroute domains = ! +local_domains transport = mailgun_transport route_list = * smtp.mailgun.org byname # In transports configuration: mailgun_transport: driver=smtp hosts_try_auth = smtp.mailgun.org
    Also make sure to configure login credentials (in your /etc/exim/passwd.client): *.mailgun.org:username:password
    0
  • cPanelLauren
    Based on what you're providing it appears to connect to mailgun without issue, right up until authentication when it fails with the following: mailgun_login authenticator failed H=smtp.mailgun.org [52.45.160.225] 535 5.7.0 Mailgun is not loving your login or password
    Furthermore, if the instructions in the resource were followed you should have matching entries to what mailgun sent you added to your exim configuration. With a couple of exceptions: They note: hosts_try_auth = smtp.mailgun.org
    where our resource which was tested in May notes: hosts = smtp.mailgun.org hosts_require_auth = smtp.mailgun.org hosts_require_tls = smtp.mailgun.org
    We also don't recommend putting the user/password in the same location - instead this should go in the AUTH section as noted in the example. Can you show me what you have in /etc/exim.conf.local currently and what the output when you attempt to connect to mailgun is per the exim logs at /var/log/exim_mainlog
    as well as confirm the username:password are correct for mailgun
    0
  • owlight
    Thank you for the response! I was writing a reply with my Exim config and log and while doing it, I figured it out. So basically, in Mailgun I went to domains -> my domain -> SMTP and there were proper credentials with a different SMTP server. I have tried them before, but it didn't work, because I haven't changed the SMTP servers. So after changing everything, my Exim config looks like this. %RETRYBLOCK% +secondarymx * F,4h,5m; G,16h,1h,1.5; F,4d,8h * * F,2h,15m; G,16h,1h,1.5; F,4d,8h @AUTH@ mailgun_login: driver = plaintext public_name = LOGIN hide client_send = : postmaster@[[mydomain]] : [[SMTPpass]] @BEGINACL@ @CONFIG@ @DIRECTOREND@ @DIRECTORMIDDLE@ @DIRECTORSTART@ @ENDACL@ @POSTMAILCOUNT@ @PREDOTFORWARD@ @PREFILTER@ @PRELOCALUSER@ @PRENOALIASDISCARD@ @PREROUTERS@ @PREVALIASNOSTAR@ @PREVALIASSTAR@ @PREVIRTUALUSER@ @RETRYEND@ @RETRYSTART@ @REWRITE@ @ROUTEREND@ @ROUTERMIDDLE@ @ROUTERSTART@ mailgun: driver = manualroute domains = ! +local_domains transport = mailgun_transport route_list = "* smtp.eu.mailgun.org::587 byname" host_find_failed = defer no_more @TRANSPORTEND@ @TRANSPORTMIDDLE@ @TRANSPORTSTART@ mailgun_transport: driver = smtp hosts = smtp.eu.mailgun.org hosts_require_auth = smtp.eu.mailgun.org hosts_require_tls = smtp.eu.mailgun.org
    It would be awesome if you could amend the
    0
  • cPanelLauren
    Hello, It looks like you still have the hide client_send in the config - was it removed? I can definitely update the tutorial to reflect that the domain needs to be verified and you'll have to log in to the dashboard to get your SMTP Credentials though. Thanks for that!
    0
  • owlight
    Hi, This is the exim.config.local that works. What mailgun sent, it couldn't even contact their server (I was getting timed out error) Thank you!
    0
  • cPanelLauren
    Hi, This is the exim.config.local that works. What mailgun sent, it couldn't even contact their server (I was getting timed out error) Thank you!

    Great! Thanks! I'll update the documentation to reflect your suggestions as well
    0

Please sign in to leave a comment.