You're Invited: Meet the Socket team at BSidesSF and RSAC - April 27 - May 1.RSVP
Socket
Sign inDemoInstall
Socket

nodemailer-smtp-transport

Package Overview
Dependencies
Maintainers
1
Versions
40
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

nodemailer-smtp-transport - npm Package Compare versions

Comparing version

to
0.1.4

src/smtp-transport.js

4

package.json
{
"name": "nodemailer-smtp-transport",
"version": "0.1.3",
"version": "0.1.4",
"description": "SMTP transport for Nodemailer",
"main": "lib/smtp-transport.js",
"main": "src/smtp-transport.js",
"scripts": {

@@ -7,0 +7,0 @@ "test": "grunt"

@@ -21,2 +21,24 @@ # SMTP transport module for Nodemailer

```javascript
var transporter = nodemailer.createTransport(smtpTransport(options))
```
Where
* **options** defines connection data
* **options.port** is the port to connect to (defaults to 25 or 465)
* **options.host** is the hostname or IP address to connect to (defaults to 'localhost')
* **options.secure** defines if the connection should use SSL (if `true`) or not (if `false`)
* **options.ignoreTLS** turns off STARTTLS support if true
* **options.name** optional hostname of the client, used for identifying to the server
* **options.localAddress** is the local interface to bind to for network connections
* **options.connectionTimeout** how many milliseconds to wait for the connection to establish
* **options.greetingTimeout** how many milliseconds to wait for the greeting after connection is established
* **options.socketTimeout** how many milliseconds of inactivity to allow
* **options.debug** if true, the connection emits all traffic between client and server as 'log' events
* **options.authMethod** defines preferred authentication method, eg. 'PLAIN'
* **options.tls** defines additional options to be passed to the socket constructor, eg. *{rejectUnauthorized: true}*
**Example**
```javascript
var transport = nodemailer.createTransport(smtpTransport({

@@ -28,3 +50,5 @@ host: 'localhost',

pass: 'password'
}
},
maxConnections: 5,
maxMessages: 10
}));

@@ -44,4 +68,7 @@ ```

See the list of all supported services [here](https://github.com/andris9/nodemailer-wellknown#supported-services).
## License
**MIT**