mirror of
https://github.com/axllent/mailpit.git
synced 2025-02-03 13:12:03 +02:00
Commands in the POP3 are case-insensitive (see RFC1939)
This commit is contained in:
parent
a32237e14f
commit
7773c6b04c
@ -23,9 +23,12 @@ import (
|
||||
)
|
||||
|
||||
const (
|
||||
// AUTHORIZATION is the initial state
|
||||
AUTHORIZATION = 1
|
||||
TRANSACTION = 2
|
||||
UPDATE = 3
|
||||
// TRANSACTION is the state after login
|
||||
TRANSACTION = 2
|
||||
// UPDATE is the state before closing
|
||||
UPDATE = 3
|
||||
)
|
||||
|
||||
// Run will start the POP3 server if enabled
|
||||
@ -134,6 +137,7 @@ func handleClient(conn net.Conn) {
|
||||
|
||||
// Parses the command
|
||||
cmd, args := getCommand(rawLine)
|
||||
cmd = strings.ToUpper(cmd) // Commands in the POP3 are case-insensitive
|
||||
|
||||
logger.Log().Debugf("[pop3] received: %s (%s)", strings.TrimSpace(rawLine), conn.RemoteAddr().String())
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user