ietf-mta-filters
[Top] [All Lists]

Re: Filtering on raw (non-decoded) headers?

2008-02-14 08:37:23

I've been thinking about a langtest extension for a good long while. Like this: langtest <language> returns true if the message does or may use that language, and returns false if it certainly does not.

This is a fairly easy language test to implement, and I think it could be useful in scripts. Language detection in general is very hard, but this particular version is easy. And it can be used easily in scripts. For me, discarding russian safely would be something like:

  If allof( langtest "ru", not langtest ["no","de","en"] ) ...

Perhaps it ought to take two arguments, and return true if the language may be in the first list and is definitely not in the second list.

Comments?

Arnt