View previous topic :: View next topic |
Author |
Message |
Vieri l33t

Joined: 18 Dec 2005 Posts: 921
|
Posted: Wed Jan 18, 2012 1:59 pm Post subject: [SOLVED PARTIALLY] amavisd-new mimedefang and postfix |
|
|
Can amavisd-new do what mimedefang can (such as remove an attachment from the email, save the file to an HTTP directory and modify the e-mail so it displays a URL to the attachment instead of the attachment)?
If so, any quick guide or hints?
If not, what's the simplest way to use 2 content filters, first amavisd-new and then mimedefang, within postfix?
Thanks,
Vieri
Last edited by Vieri on Mon Jan 30, 2012 12:14 pm; edited 1 time in total |
|
Back to top |
|
 |
freke Veteran

Joined: 23 Jan 2003 Posts: 1093 Location: Somewhere in Denmark
|
Posted: Sun Jan 29, 2012 4:47 pm Post subject: |
|
|
I don't know mimedefang, but you chose where/which port amavisd-new should forward the message to after scanning - so I'd expect it could simply hand off the message to mimedefang?
Alternatively you could do something like:
Code: | main.cf
content_filter = smtp:127.0.0.1:20024
master.cf
localhost:20025 inet n - n - - smtpd -o content_filter=smtp:127.0.0.1:10026
127.0.0.1:10027 inet n - n - - smtpd
-o content_filter=
-o smtpd_delay_reject=no
-o smtpd_client_restrictions=permit_mynetworks,reject
-o smtpd_helo_restrictions= -o smtpd_sender_restrictions=
-o smtpd_recipient_restrictions=permit_mynetworks,reject
-o smtpd_data_restrictions=reject_unauth_pipelining
-o smtpd_end_of_data_restrictions=
-o smtpd_restriction_classes=
-o mynetworks=127.0.0.0/8
-o smtpd_error_sleep_time=0
-o smtpd_soft_error_limit=1001
-o smtpd_hard_error_limit=1000
-o smtpd_client_connection_count_limit=0
-o smtpd_client_connection_rate_limit=0
-o receive_override_options=no_header_body_checks,no_unknown_recipient_checks,no_milters
-o local_header_rewrite_clients=
|
To first have postfix send the message to the contentfilter at 20024 - the first filter send it back to postfix at port 20025 and postfix then sends it to the filter at port 10026 which return the message at port 10027
Edit:
On further reading it seems that mimedefang is a Sendmail milter - which you can use like this:
Code: | main.cf
smtpd_milters = inet:localhost:10025
milter_default_action = accept
milter_protocol = 3
|
Assuming you have mimedefang running - listening on port 10025.
You can have multiple milters like this:
Code: | main.cf
smtpd_milters = inet:localhost:9999 inet:localhost:8026
|
|
|
Back to top |
|
 |
Vieri l33t

Joined: 18 Dec 2005 Posts: 921
|
Posted: Mon Jan 30, 2012 12:10 pm Post subject: |
|
|
Thanks
I'm using mimedefang with postfix and it seems to be working great.
I think I can do just about everything I need with mimedefang; I don't seem to require amavisd. |
|
Back to top |
|
 |
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
|