Skip to content

Commit

Permalink
Supports all keyword for the mode
Browse files Browse the repository at this point in the history
  • Loading branch information
nodauf committed Feb 5, 2022
1 parent 10118b8 commit 98da5e6
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion src/cmd/enum/smtp.go
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ var smtpCmd = &cobra.Command{
func init() {

smtpCmd.Flags().StringVarP(&smtpOptions.Domain, "domain", "d", "", "Targeted domain ")
smtpCmd.Flags().StringVarP(&smtpOptions.Mode, "mode", "m", "", "RCPT, VRFY, EXPN (default: all)")
smtpCmd.Flags().StringVarP(&smtpOptions.Mode, "mode", "m", "", "RCPT, VRFY, EXPN, ALL (default: all)")
smtpCmd.Flags().StringVarP(&smtpOptions.Users, "user", "u", "", "Username or file containing the usernames")
smtpCmd.Flags().StringVarP(&smtpOptions.Target, "target", "t", "", "Host pointing to the SMTP service. If not specified, the first SMTP server in the MX record will be targeted.")
smtpCmd.Flags().IntVar(&smtpOptions.Thread, "thread", 2, "Number of threads")
Expand Down
4 changes: 2 additions & 2 deletions src/modules/smtp/userEnum.go
Original file line number Diff line number Diff line change
Expand Up @@ -87,14 +87,14 @@ func UserEnum(optionsInterface *interface{}, username string) bool {
options.Log.Fatal("The command EXPN is not implemented. No need to pursue using this method.")
}
}
case "":
case "", "all":

optionsCopy := *options
options.connectionsPool <- smtpConnection
// Execute the 3 enumeration methods
optionsCopy.all = true
// RCPT request
options.Log.Debug("No enumeration method specify. Executing enumeration with RCPT, VRFY and EXPN")
options.Log.Debug("No enumeration method specify. Executing enumeration with RCPT, VRFY, EXPN and ALL")
options.Log.Debug("Enumerate with RCPT")
optionsCopy.Mode = "rcpt"
newOptionsInterface := reflect.ValueOf(&optionsCopy).Interface()
Expand Down

0 comments on commit 98da5e6

Please sign in to comment.