body_digest in SQL?

Patrick Ben Koetter p at state-of-mind.de
Fri Apr 6 08:52:46 CEST 2012


Mark,

* Mark Martinec <Mark.Martinec+amavis at ijs.si>:
> You are right, the body digest is available as $msginfo->body_digest,
> and also as a macro 'b'. Currently it is stored as a hex-encoded
> string of a digest (MD5, but could also be a SHA-1 or SHA-256),
> although it may be sensible to change the internal representation
> in $msginfo->body_digest to binary and do the encoding to hex or
> to base64 or to whatever encoding when externalizing it.
> 
> The body_digest is not written to an SQL table msgs, although
> it should be fairly easy to do so, just need to add an argument
> to the $conn_h->execute($upd_msg...) call in sub save_info_final
> and update the SQL clause in $sql_clause{'upd_msg'} accordingly.
> And adjust the SQL schema by adding a field to the table.
> 
> I can prepare a small patch, although it probably won't find
> its way into the release because it would require people to
> adjust their schema by adding a field, and currently there is
> no change in SQL schema planned between 2.7.0 and a would-be 2.8.0.

I don't need it right now, as I can work around it. Having it in the long run
(2.8.0+) would be nice.

>From a more general point of view I think information available in a
notification template should also be available in e.g. a SQL storage so we can
look it up and therefore can create linkable references.

p at rick

-- 
All technical questions asked privately will be automatically answered on the
list and archived for public access unless privacy is explicitely required and
justified.

saslfinger (debugging SMTP AUTH):
<http://postfix.state-of-mind.de/patrick.koetter/saslfinger/>


More information about the amavis-users mailing list