smtp-server
smtp-server copied to clipboard
If server is closing, then HELO etc commands should not be accepted
Here we have https://github.com/nodemailer/smtp-server/blob/2bd0975292208f1cf77d7a93cb3d8b3c4d48acb8/lib/smtp-connection.js#L406 commands being parsed. However if the server is shutting down, commands such as HELO will still be accepted. Is there a way to add this feature, similar to how we can process onData, onRcptTo, etc? Then we could add if (this._closeTimeout) return setImmediate(() => callback(new Error('Server is shutting down'));
.
Title updated