diff --git a/lib/server.js b/lib/server.js index e0f18d6..a1b6b1d 100644 --- a/lib/server.js +++ b/lib/server.js @@ -301,6 +301,11 @@ SMTPServerConnection.prototype._onCommand = function(command, payload){ this._onCommandSTARTTLS(); break; + // No operation + case "NOOP": + this._onCommandNOOP(); + break; + // Display an error on anything else default: this.client.send("502 5.5.2 Error: command not recognized"); @@ -607,6 +612,13 @@ SMTPServerConnection.prototype._onCommandEHLO = function(host){ }).join("\r\n")); }; +/** + *

No operation. Just returns OK.

+ */ +SMTPServerConnection.prototype._onCommandNOOP = function(){ + this.client.send("250 OK"); +} + /** *

Detect login information from the payload and initiate authentication * by emitting 'authorizeUser' and waiting for its callback