“This standard specifies a syntax for text messages that are sent
between computer users, within the framework of 'electronic mail’ messages. This standard supersedes the one specified in Request For
Comments (RFC) 822, “Standard for the Format of ARPA Internet Text
Messages”, updating it to reflect current practice and incorporating
incremental changes that were specified in other RFCs…”
7231 obsoleted 2616 but that’s not the point. Esi uses 2822 - this in fact is correct with 7231 which de facto allows any format, but prefers a subset of 5322. You just need to deal with it.
I also believe it was a bug, but please, next time you get such problem, you’d better report it on github instead of the forum, it will be fixed faster
I think what you state is wrong: rfc 7231 allows format from rfc5322 (what they call the “prefered format”) and obsolete format from RFC 850 and from asctime, but that’s all.
It doesn’t allow “any” format, actually it says the contrary:
A recipient that parses a timestamp value in an HTTP header field
MUST accept all three HTTP-date formats. When a sender generates a
header field that contains one or more timestamps defined as
HTTP-date, the sender MUST generate those timestamps in the
IMF-fixdate format.
But anyway, it’s looks like it’s fixed, so it doesn’t matter
Well, if you want a full investigation then here you go
5322 is a newer version of 2822, but the date/time format is the same. If we then get to 7231, we can see:
Recipients of timestamp values are encouraged to be robust in parsing
timestamps unless otherwise restricted by the field definition. For
example, messages are occasionally forwarded over HTTP from a
non-HTTP source that might generate any of the date and time
specifications defined by the Internet Message Format.
Translation: the format can be anything than the preferred one - deal with it.