Bonobo-Git-Server icon indicating copy to clipboard operation
Bonobo-Git-Server copied to clipboard

Unable to send email. Validate SMTP settings.

Open matousek-martin opened this issue 6 years ago • 2 comments

Bonobo returns 'Unable to send email. Validate SMTP settings.' even tho I set up web.config with smtp mail settings, e.g.:

  <system.net>
    <mailSettings>
      <smtp deliveryMethod="Network" deliveryFormat="SevenBit"  from="[email protected]">
        <network
          host="smtp.gmail.com"
          password="mypw"
          userName="[email protected]"
          port="587"
        />
      </smtp>
    </mailSettings>
  </system.net>

When I tried these settings with python's smtplib with the same port, mail and password, it worked. Any idea?

matousek-martin avatar Dec 13 '18 15:12 matousek-martin

Any insights to this issue? I have the same phenomenon.

mirkomaty avatar Mar 20 '19 08:03 mirkomaty

I got it. You need a from-Address:

<smtp from="[email protected]">
…
</smtp>

The SendForgotPasswordEmail method in the MembershipHelper class doesn't provide a "from" address. It makes sense to provide this information in the web.config. But there should be a better error message, "Please define a from address in your web.config file."

mirkomaty avatar Mar 20 '19 08:03 mirkomaty