Code Monkey home page Code Monkey logo

Comments (6)

andris9 avatar andris9 commented on July 20, 2024

Hi, this issue is not know. Could you set debug:true in SMPT settings and copy the console output here (replace real server names and e-mail addresses from the log before pasting, since these are not needed).

from nodemailer.

sirganya avatar sirganya commented on July 20, 2024

All it gives me is "error occurred,Timeout waiting for response from server"

The only difference between the config in the other package is it allows me to include a domain setting to identify itself to the server. Is it possible to add that to the SMTP config?

If I set SSL to false I get some more info.

CONNECTION (1): 220 SG108 - ServerGrove - www.servergrove.com ESMTP
Connection established! (1)
SEND (1):
└──"EHLO server.xxxxxxxxxxxk.com\r\n"
RECEIVE (1):
└──"250-sg107.xxxxxxxxxxx.com\r\n" ""
RECEIVE (1):
└──"250-AUTH LOGIN\r\n250-AUTH=LOGIN\r\n250-PIPELINING\r\n250 8BITMIME\r\n" "250-sg107.xxxxxxxxxxx.com\r\n"
Routing Data (1)
Mail.emit { '0': 'connection_stable' }
SEND (1):
└──"AUTH PLAIN xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx\r\n"
RECEIVE (1):
└──"504 Unsupported authorization type.\r\n" "250-sg107.xxxxxxxxxxxxxx.com\r\n"
Routing Data (1)
Error occured
504 Unsupported authorization type.

from nodemailer.

andris9 avatar andris9 commented on July 20, 2024

You can set the identifying domain with hostname

SMTP = {
    host:"smtp.example.com",
    hostname: "mydomain",
    ....
}

The default value is the machine name (os.hostname()) or if not set then [127.0.0.1]

from nodemailer.

sirganya avatar sirganya commented on July 20, 2024

I've been playing around with various setting but can't get it to work. Here's the settings that work for
https://github.com/Marak/node_mailer

email.send({
      host : "mail.mydomain.com",              // smtp server hostname
      port : "2525",                     // smtp server port
      ssl: true,                        // for SSL support - REQUIRES NODE v0.3.x OR HIGHER
      domain : "mydomain.com",            // domain used by client to identify itself to server
      to : "[email protected]",
      from : "'Godfrey' <[email protected]>",
      subject : "Godfrey added "+count+" contacts to consumers DB",
      template : "./templates/consumersadded.txt",
      data : {"cheesyquote" : message,
              "count" : count },

      authentication : "login",        // auth login is supported; anything else is no auth
      username : "dnJfYxxxxxxxxxxxxxxxxxEuY29t",       // Base64 encoded username
      password : "N2xxxxxxx=="       // Base64 encoded password
    },
    function(err, result){
      if(err){ console.log(err); }
    });


}

from nodemailer.

andris9 avatar andris9 commented on July 20, 2024

From the log I can see that that the server expects AUTH LOGIN as the login method but Nodemailer uses AUTH PLAIN which is a bit similar but not the same. Some servers don't advertise support for AUTH PLAIN but actually they do support it, so Nodemailer tries to use it anyway.

Maraks node_mailer on the contrary to Nodemailer uses AUTH LOGIN instead of AUTH PLAIN - that is why it works with this particular server. In a future release I'll add better AUTH handling for Nodemailer but this is probably not coming before June.

from nodemailer.

andris9 avatar andris9 commented on July 20, 2024

AUTH LOGIN turned out to be quite easy to implement, so didn't bother to wait until June :)

from nodemailer.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.