mox/smtpserver
Mechiel Lukkien fbc18d522d
smtpserver: when writing slow responses, don't take so long the remote smtp client regards it as timeout
when writing the 4xx temporary error line, we were taking 1s in between each
byte. the total line could take longer than 30 seconds, which is the timeout we
use for reading a whole line (regardless of individual bytes). so mox as
deliverer was timing out to mox as slow rejecter. this causes slow writes to
not take longer than the 30s timeout: if we are 2s before the 30s, we write the
remainder in one go.

based on a debug log from naturalethic, thanks!
2023-12-14 20:20:17 +01:00
..
alignment.go switch to slog.Logger for logging, for easier reuse of packages by external software 2023-12-14 13:45:52 +01:00
analyze.go wrap long lines with many logging parameters to multiple lines 2023-12-14 13:45:52 +01:00
dnsbl.go switch to slog.Logger for logging, for easier reuse of packages by external software 2023-12-14 13:45:52 +01:00
dsn.go expose fewer internals in packages, for easier software reuse 2023-12-14 15:39:36 +01:00
error.go for imap/smtp syntax errors, only echo the remaining buffer if the connection is authenticated 2023-03-10 11:32:34 +01:00
fuzz_test.go switch to slog.Logger for logging, for easier reuse of packages by external software 2023-12-14 13:45:52 +01:00
limitwriter.go mox! 2023-01-30 14:27:06 +01:00
mx.go implement dnssec-awareness throughout code, and dane for incoming/outgoing mail delivery 2023-10-10 12:09:35 +02:00
parse.go expose fewer internals in packages, for easier software reuse 2023-12-14 15:39:36 +01:00
parse_test.go mox! 2023-01-30 14:27:06 +01:00
rejects.go switch to slog.Logger for logging, for easier reuse of packages by external software 2023-12-14 13:45:52 +01:00
reputation.go wrap long lines with many logging parameters to multiple lines 2023-12-14 13:45:52 +01:00
reputation_test.go switch to slog.Logger for logging, for easier reuse of packages by external software 2023-12-14 13:45:52 +01:00
server.go smtpserver: when writing slow responses, don't take so long the remote smtp client regards it as timeout 2023-12-14 20:20:17 +01:00
server_test.go expose fewer internals in packages, for easier software reuse 2023-12-14 15:39:36 +01:00