What's Milter ?

 
 
 
Sendmail is one of the most popular SMTP MTAs. It is very configurable through some defines, features and rulesets. However for quite a long time for content analysis/messages modifications of SMTP messages and complex needs (spam & attachment filtering, custom logging, disclaimer addition, virus scanning ....) you had to either :
  • call some external programs (through pipes in aliases or special mailers : perl script, procmail, maildrop, ....). Such solution could handle only local delivery or messages to local addresses..
  • or use sendmail in queuing mode and parse the qf and df files with some program triggered on a regular basis (MailScanner approach)
  • or use some special forwarding scheme : sandwitch architecture with several sendmail's instances : amavisd-new dual-sendmail set-up & first commercial antivirus approach)
  • or alter sendmail's source code (use of the check_compat function) to add some extensions requiring recompiling sendmail. It was not dynamic and smooth. Furthermore adjustments for each new sendmail releases could be needed (sendmail's internal code change)..

Some better and easier solutions were really needed.
In order to make it easy to write some Sendmail filters, the Sendmail team has developed some API called Milter (Mail Filtering API) which was first implemented in versions on 8.10.x, then improved in 8.11.x as some FFR (For Future Release) code and officially supported since 8.12.x.
This content Management API can be used on on any OS that supports threads and was devised with the following goals :
  • safety/security
  • reliabilty
  • simplicity
  • performance