Thomas Schürger
2008-10-22 21:31:24 UTC
Hi,
SpamProbe contains an optimization that skips MD5-digesting a mail when
an appropriate header (X-SpamProbe by default, see -g option) already
exists. This
code uses a regular expression for parsing ("^[a-z]+ +[0-9]\\.[0-9]+
+([0-9a-z]+)").
An example header value is "GOOD 0,0005146
17ada81378f7fdee8808e9fa492ea906".
However, the "score" command (and others) use a localized version of
printf()
to produce this kind of string. Depending on the selected locale, the
decimal dot
can be replaced by a comma in the output (e.g., when German locale
"de_DE" is used),
so that the regular expression above doesn't match when the result from
"score" is put
into the mail's header. In this case, the message is MD5-digested even
though the header
already exists the next time it is scanned by SpamProbe.
I would suggest that either the regular expression should allow a dot or
a comma or that
the commands produce a non-localized output (always using a decimal
dot). This is of course
not a big issue, but might be fixed anyway.
Greetings,
Thomas.
SpamProbe contains an optimization that skips MD5-digesting a mail when
an appropriate header (X-SpamProbe by default, see -g option) already
exists. This
code uses a regular expression for parsing ("^[a-z]+ +[0-9]\\.[0-9]+
+([0-9a-z]+)").
An example header value is "GOOD 0,0005146
17ada81378f7fdee8808e9fa492ea906".
However, the "score" command (and others) use a localized version of
printf()
to produce this kind of string. Depending on the selected locale, the
decimal dot
can be replaced by a comma in the output (e.g., when German locale
"de_DE" is used),
so that the regular expression above doesn't match when the result from
"score" is put
into the mail's header. In this case, the message is MD5-digested even
though the header
already exists the next time it is scanned by SpamProbe.
I would suggest that either the regular expression should allow a dot or
a comma or that
the commands produce a non-localized output (always using a decimal
dot). This is of course
not a big issue, but might be fixed anyway.
Greetings,
Thomas.