
Hi, On Wed, Feb 19, 2003 at 03:59:33PM +0100, Stefan Schmidt wrote:
Is the following procedure possible? (because of statistic reasons)
Email is coming into otrs -> pool x or y or z GenericAgent looks for: from, subject or header If from is xxxx@yyyy.zzz or subject contains "*** spam ***" then forward to queue SPAM
I know this is normally done by procmail (like in our system) but procmail is the fronttool and the mail never gets into otrs (which is normaly ok). But we would like to count such mails for statistic reasons.
Of course it can be done by procmail, you simply add an additional header to the mail, and OTRS sorts it directly into the SPAM-Queue: .procmail === # -- # presort mails if spamassassin marks the incoming mail as spam # -- :0 fhw : * ^X-Spam-Status: Yes | formail -I "X-OTRS-Queue: Spam" === (this or smth. the like should be in /opt/otrs/.procmail anyway, but commented out). The drwaback is, that yuou have to close them manually, which is terrible ;-)
Or you use: [...] :0 fhw : * ^X-Spam-Status: Yes | formail -I "X-OTRS-Queue: Spam" | formail -I "X-OTRS-State: closed successful" [...] to close also the ticket.
Stefan
Martin -- Martin Edenhofer - <martin at edenhofer.de> - http://martin.edenhofer.de/ -- "Security is a process, not a product." - Bruce Schneier