mirror of
https://github.com/axllent/mailpit.git
synced 2025-02-03 13:12:03 +02:00
Ensure a user has been set first before a password can be issued
This commit is contained in:
parent
7773c6b04c
commit
7991c49312
@ -163,6 +163,10 @@ func handleClient(conn net.Conn) {
|
||||
}
|
||||
case "PASS":
|
||||
if state == AUTHORIZATION {
|
||||
if user == "" {
|
||||
sendResponse(conn, "-ERR must supply a user")
|
||||
return
|
||||
}
|
||||
if len(args) != 1 {
|
||||
sendResponse(conn, "-ERR must supply a password")
|
||||
return
|
||||
|
Loading…
x
Reference in New Issue
Block a user