mirror of
https://github.com/mjl-/mox.git
synced 2025-07-12 12:24:38 +03:00
for submission over IPv6, allow missing "IPv6" tag in ip address (unless in pedantic mode)
an EHLO ipv4 address looks like this: "[1.2.3.4]". for ipv6, the syntax is: "[IPv6🔡:1]". mail user agents aren't as careful in compliance as smtp servers. for incoming messages from smtp servers, we want to be strict (we're eager to find a reason not to accept spam messages, and not adhering to the standards is usually a strong spam signal), but there is no reason to punish authenticated users. for the syntax requirements, see ABNF rule "address-literal" in rfc 5321. for issue #48 by @bobobo1618, thanks!
This commit is contained in:
@ -772,7 +772,7 @@ func (c *conn) cmdHello(p *parser, ehlo bool) {
|
||||
p.xspace()
|
||||
var remote dns.IPDomain
|
||||
if ehlo {
|
||||
remote = p.xipdomain()
|
||||
remote = p.xipdomain(true)
|
||||
} else {
|
||||
remote = dns.IPDomain{Domain: p.xdomain()}
|
||||
if !c.submission {
|
||||
|
Reference in New Issue
Block a user