mirror of
https://github.com/vdukhovni/postfix
synced 2025-08-21 17:37:24 +00:00
postfix-3.11-20250818
This commit is contained in:
parent
5c253cc5c9
commit
8d1e60ee70
@ -29568,3 +29568,10 @@ Apologies for any names omitted.
|
||||
documentation. This will be back-ported to Postfix 3.10.
|
||||
Files: Makefile.in, smtp/smtp.h smtp/smtp_connect.c,
|
||||
smtp/smtp_tls_policy.c, proto/postconf.proto.
|
||||
|
||||
20250816
|
||||
|
||||
Bugfix (defect introduced: Postfix 3.0, date 20140731): the
|
||||
smtpd 'disconnect' command counts did not count malformed
|
||||
commands with "bad syntax" and "bad UTF-8 syntax" errors.
|
||||
File: smtpd/smtpd.c.
|
||||
|
@ -20,7 +20,7 @@
|
||||
* Patches change both the patchlevel and the release date. Snapshots have no
|
||||
* patchlevel; they change the release date only.
|
||||
*/
|
||||
#define MAIL_RELEASE_DATE "20250808"
|
||||
#define MAIL_RELEASE_DATE "20250818"
|
||||
#define MAIL_VERSION_NUMBER "3.11"
|
||||
|
||||
#ifdef SNAPSHOT
|
||||
|
@ -5639,6 +5639,13 @@ static SMTPD_CMD smtpd_cmd_table[] = {
|
||||
{0,},
|
||||
};
|
||||
|
||||
/*
|
||||
* In addition to counting unknown commands, the last table element also
|
||||
* counts malformed commands (which aren't looked up in the command table).
|
||||
*/
|
||||
#define LAST_TABLE_PTR(table) ((table) + sizeof(table)/sizeof(*(table)) - 1)
|
||||
static SMTPD_CMD *smtpd_cmdp_unknown = LAST_TABLE_PTR(smtpd_cmd_table);
|
||||
|
||||
static STRING_LIST *smtpd_noop_cmds;
|
||||
static STRING_LIST *smtpd_forbid_cmds;
|
||||
|
||||
@ -6007,6 +6014,8 @@ static void smtpd_proto(SMTPD_STATE *state)
|
||||
state->error_mask |= MAIL_ERROR_PROTOCOL;
|
||||
smtpd_chat_reply(state, "500 5.5.2 Error: bad UTF-8 syntax");
|
||||
state->error_count++;
|
||||
state->where = SMTPD_CMD_UNKNOWN;
|
||||
smtpd_cmdp_unknown->total_count += 1;
|
||||
continue;
|
||||
}
|
||||
/* Move into smtpd_chat_query() and update session transcript. */
|
||||
@ -6028,6 +6037,8 @@ static void smtpd_proto(SMTPD_STATE *state)
|
||||
state->error_mask |= MAIL_ERROR_PROTOCOL;
|
||||
smtpd_chat_reply(state, "500 5.5.2 Error: bad syntax");
|
||||
state->error_count++;
|
||||
state->where = SMTPD_CMD_UNKNOWN;
|
||||
smtpd_cmdp_unknown->total_count += 1;
|
||||
continue;
|
||||
}
|
||||
/* Ignore smtpd_noop_cmds lookup errors. Non-critical feature. */
|
||||
@ -6036,6 +6047,7 @@ static void smtpd_proto(SMTPD_STATE *state)
|
||||
smtpd_chat_reply(state, "250 2.0.0 Ok");
|
||||
if (state->junk_cmds++ > var_smtpd_junk_cmd_limit)
|
||||
state->error_count++;
|
||||
/* XXX We can't count these. */
|
||||
continue;
|
||||
}
|
||||
for (cmdp = smtpd_cmd_table; cmdp->name != 0; cmdp++)
|
||||
|
Loading…
x
Reference in New Issue
Block a user