Skip to content

Commit

Permalink
v3.5.0
Browse files Browse the repository at this point in the history
  • Loading branch information
andris9 committed Dec 4, 2022
1 parent 5ec65ce commit f29d809
Show file tree
Hide file tree
Showing 6 changed files with 22 additions and 17 deletions.
5 changes: 5 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,10 @@
# CHANGELOG

- v3.5.0 2022-12-04

- Bumped Restify to v10 to support Node 18
- Added new plugin hook `smtp:init`

- v3.3.0 2022-02-23

- Bumped deps (fixes issue with 334 response)
Expand Down
2 changes: 1 addition & 1 deletion app.js
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ startSMTPInterfaces(err => {
log.error('API', err);
return process.exit(2);
}
log.info('API', 'API server started');
log.info('API', 'API server started listening on port %s', config.api.port);

// downgrade user if needed
if (config.group) {
Expand Down
3 changes: 1 addition & 2 deletions lib/api-server.js
Original file line number Diff line number Diff line change
Expand Up @@ -684,7 +684,7 @@ class APIServer {
);
});

this.server.get('/metrics', async (req, res, next) => {
this.server.get('/metrics', async (req, res) => {
res.setHeader('Content-Type', promClient.register.contentType);
await promClient.register
.metrics()
Expand All @@ -698,7 +698,6 @@ class APIServer {
// ignore
}
});
next();
});
}
}
Expand Down
2 changes: 1 addition & 1 deletion lib/smtp-interface.js
Original file line number Diff line number Diff line change
Expand Up @@ -353,7 +353,7 @@ class SMTPInterface {
log.error(this.logName, 'SERVERR error=%s', err.message);
});

return callback();
plugins.handler.runHooks('smtp:init', [this], () => callback());
});
});
}
Expand Down
26 changes: 13 additions & 13 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "zone-mta",
"private": false,
"version": "3.4.2",
"version": "3.5.0",
"description": "Tiny outbound MTA",
"main": "app.js",
"scripts": {
Expand All @@ -16,37 +16,37 @@
"crc-32": "1.2.2",
"dnscache": "1.0.2",
"gelf": "2.0.1",
"ioredis": "5.1.0",
"ioredis": "5.2.4",
"isemail": "3.2.0",
"js-yaml": "4.1.0",
"libmime": "5.1.0",
"mailsplit": "5.3.2",
"minimist": "1.2.6",
"mongodb": "4.7.0",
"minimist": "1.2.7",
"mongodb": "4.12.1",
"msgpack-js": "0.3.0",
"mx-connect": "1.2.0",
"nodemailer": "6.7.6",
"npmlog": "6.0.2",
"prom-client": "14.0.1",
"nodemailer": "6.8.0",
"npmlog": "7.0.1",
"prom-client": "14.1.0",
"punycode": "2.1.1",
"request": "2.88.2",
"restify": "8.6.1",
"restify": "10.0.0",
"seq-index": "1.1.0",
"smtp-server": "3.11.0",
"srs.js": "0.1.0",
"uuid": "8.3.2",
"wild-config": "1.6.1"
"uuid": "9.0.0",
"wild-config": "1.7.0"
},
"devDependencies": {
"ajv": "8.11.0",
"eslint": "8.19.0",
"ajv": "8.11.2",
"eslint": "8.29.0",
"eslint-config-nodemailer": "1.2.0",
"eslint-config-prettier": "8.5.0",
"grunt": "1.5.3",
"grunt-cli": "1.4.3",
"grunt-contrib-nodeunit": "4.0.0",
"grunt-eslint": "24.0.0",
"moment": "2.29.3",
"moment": "2.29.4",
"random-message": "1.1.0",
"zip-stream": "4.1.0"
},
Expand Down
1 change: 1 addition & 0 deletions plugins/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -119,6 +119,7 @@ To use these hooks you need to set `enabled` `'main'` or `['main',...]`

To use these hooks you need to set `enabled` to `true` or `'receiver'` or `['receiver',...]`

- **'smtp:init'** with arguments `server`, called when the SMTP interface has been initialized
- **'smtp:sni'** with arguments `servername`, `data`, called when the client tries to establish a SNI session. Set `data.secureContext` value if you want to override hostname specific secure context
- **'smtp:connect'** with argument `session`, called when the client connects to the interface
- **'smtp:auth'** with arguments `auth`, `session`, called when AUTH command is issued by the client
Expand Down

0 comments on commit f29d809

Please sign in to comment.