From 5f7d7fe25208567aed8bd04200c2746dd0873364 Mon Sep 17 00:00:00 2001 From: david Date: Tue, 7 Sep 2010 20:15:41 +0000 Subject: [PATCH] Add status code 553 (Relaying Denied) to the list of NOTPERMITTED codes in smtp-enum-users.nse. Martin Holst Swende reported this. --- scripts/smtp-enum-users.nse | 3 +++ 1 file changed, 3 insertions(+) diff --git a/scripts/smtp-enum-users.nse b/scripts/smtp-enum-users.nse index 11f61559b..d16af0428 100644 --- a/scripts/smtp-enum-users.nse +++ b/scripts/smtp-enum-users.nse @@ -288,6 +288,9 @@ function do_rcpt(socket, username, domain) if not status then return STATUS_CODES.ERROR, string.format("Failed to issue RCPT TO:<%s@%s> command (%s)", username, domain, response) + elseif string.match(response, "^553") then + -- 553 Relaying Denied + return STATUS_CODES.NOTPERMITTED elseif string.match(response, "^530") then -- If the command failed, check if authentication is needed because all the other attempts will fail. return STATUS_CODES.AUTHENTICATION