News About Features Documentation FAQ ChangeLog Mailinglist Download GIT Screenshots RRDtool MRTG WebQ Logwatch Reporter Latest stable: 2.0.2-1 Latest devel: 2.0.3-0.beta5 |
sql_find() Recipient email address to index scanner, operating on SQL database. This scanner is an reimplementation of e2i_sql lmtpd() service from older sagator 0.7.2. It is useful only as lmtpd() scanner, because it operates on email recipients. Usage: sql_find(key, dbc, query, scanners) Where: key is an string, which defines which variable to compare. Currently only "recipient" or "sender" can be used here. dbc is an database connection query is an SQL condition to use scanners is an dictionary of scanners, each returned key from database must have coresponding key in this dictionary Example: sql_find( 'recipient', db.sqlite(), "SELECT key FROM userpref WHERE email=%s", { 'AV': b2f(libclam()), 'AS': spamassassind(), '': s2f(libclam())+spamassassind() # default } ) Limitations: It is not possible to include one sql_find() into another. New in version 0.9.0. |