This works for me:
var transporter = nodemailer.createTransport({
host: 'smtp.office365.com', // Office 365 server
port: 587, // secure SMTP
secure: false, // false for TLS - as a boolean not string - but the default is false so just remove this completely
auth: {
user: username,
pass: password
},
tls: {
ciphers: 'SSLv3'
}
});
You may like to add:
requireTLS: true