"John" <[EMAIL PROTECTED]> schreef in bericht news:[EMAIL PROTECTED] > > "Paul Cocker" <[EMAIL PROTECTED]> schreef in bericht > news:[EMAIL PROTECTED] > Does anyone have any experience with Altermime? The official mailing > list page appears to be dead, but it strikes me as likely that several > postfix users may have experience with the app. > > I know the postfix page discourages footers via the MTA, but alas the UK > has laws which require company numbers and registered addresses attached > to all communications, and managing a legal issue from the client side > is impractical, so here I go. > > Unfortunately, while I was able to dig up some information on linking > altermime to postfix, the script only detailed how to do this for > specific e-mail addresses, where as I (and I'm betting most people who > do this) need it for all outgoing e-mail. At the same time I don't want > altermime to attach the footer to incoming e-mail. > > Here's the instructions I found. > > http://www.howtoforge.com/add-disclaimers-to-outgoing-emails-with-alterm > ime-postfix-debian-etch > > I lack the scripting skills necessary to modify the setup. Help is much > appreciated. > > I am working on CentOS 5.2 and have installed altermime 3.7 from > rpmforge. > > Paul Cocker > > > st is the trading name for TNT Post UK Ltd (company number: 04417047), TNT > Post (Doordrop Media) Ltd (00613278), TNT Post Scotland Ltd (05695897), > TNT Post North Ltd (05701709), TNT Post South West Ltd (05983401), TNT > Post Midlands Limited (6458167)and TNT Post London Limited (6493826). > Emma's Diary and Lifecycle are trading names for Lifecycle Marketing > (Mother and Baby) Ltd (02556692). All companies are registered in England > and Wales; registered address: 1 Globeside Business Park, Fieldhouse Lane, > Marlow, Buckinghamshire, SL7 1HY. > > Hello Paul, > > Yes, we use Altermime of quite some time now, but it has some quirks. > Initially we started a similar way as described in the howto you > mentioned. But we encountered the following problems: > -Adding disclaimer in a formatted html page failed. > -In some webmail clients (like Hotmail) the inserted footer shows > incorrect line breaks. ( I 'm NOT tying to start a discussion on whois is > RFC compliant and who NOT), Just an observation... > > It looks that Altermine has problems correctly MIME encoding the message > again. > The solution for us, to use the already used Amavisd-new to call Altermime > in a Policy bank, letting Amavisd-new responsible for decoding / encoding > the message. From then it worked as expected. The Amavisd-new Policybank / > Altermine solution provides the possibility to uses different policy banks > (and different disclaimers) for different mail directions. Just create a > new policybank and a new Postfix filter. > For this to work, you should use a resonable new Amavisd-new. > > Create you /etc/altermime/disclaimer.htm and /etc/altermime/disclaimer.txt > file > > Amavisd-new config: > > --> amavisd.conf piece implematation sample > > [EMAIL PROTECTED] = ( [".$mydomain"] ); > [EMAIL PROTECTED] = ( [ ".$mydomain", '.domain1.com', '.domain2.com', > '.domain1.com' ], read_hash("/etc/postfix/maps/relay_domains") ); > @local_domains_maps = read_hash(\%local_domains, > '/etc/postfix/maps/relay_domains'); > > $altermime = '/usr/bin/altermime'; > @altermime_args_disclaimer = > qw(--verbose --disclaimer-html=/etc/altermime/disclaimer.htm > --disclaimer=/etc/altermime/disclaimer.txt); > $defang_maps_by_ccat{+CC_CATCHALL} = [ 'disclaimer' ]; > > > @mynetworks = qw( 127.0.0.0/8 [::1] [FE80::]/10 [FEC0::]/10 > 10.0.0.0/8 172.16.0.0/12 192.168.0.0/16 ); > > > $inet_socket_port = [10024, 10026]; # listen on this local TCP port(s) > (see $protocol) > $interface_policy{'10026'} = 'OUTGOING_FILTER'; > > $policy_bank{'OUTGOING_FILTER'} = { # mail originating from the Internal > network > originating => 1, # is true in MYNETS by default, but let's make it > explicit > bypass_spam_checks_maps => [1], # don't spam-check outgoing mail > bypass_banned_checks_maps => [1], # don't banned-check outgoing mail > allow_disclaimers => 1, # enables disclaimer insertion if available > os_fingerprint_method => undef, # don't query p0f for internal clients > virus_admin_maps => ["[EMAIL PROTECTED]"], > spam_admin_maps => ["[EMAIL PROTECTED]"], > warnbadhsender => 1, > # # forward to a smtpd service providing DKIM signing service > # forward_method => 'smtp:[127.0.0.1]:10027', > # force MTA conversion to 7-bit (e.g. before DKIM signing) > smtpd_discard_ehlo_keywords => ['8BITMIME'], > terminate_dsn_on_notify_success => 0, # don't remove NOTIFY=SUCCESS > option > forward_method => 'smtp:[127.0.0.1]:10025', # forward to 10027 > # Forward to 10027, and make smtpd instance in master.cf, if you want to > stack other non amavisd-new (policy) filters > }; > > In Postfix, you have to create a filter trigger, so forward mail coming > from your internal network to be redirected to the amavisd-new instance > created for your disclaimer. > > create a file /etc/postfix/outgoing_filter_check, and replace 192.168 with > your internal network > 192.168 FILTER smtp:[127.0.0.1]:10026 > create a map file of it: postmap hash:outgoing_filter_check > > main.cf: addon > add to the smtpd_recipient_restrictions just before permit_mynetworks: > check_client_access hash:/etc/postfix/maps/access_outgoing_filter_check, > > piece of main.cf > smtpd_recipient_restrictions = reject_non_fqdn_sender, > reject_non_fqdn_recipient, > reject_unknown_sender_domain, > reject_unknown_recipient_domain, > check_recipient_access > hash:/etc/postfix/access_recipient, > check_client_access > hash:/etc/postfix/access_outgoing_filter_check > permit_mynetworks, > reject_unauth_destination, > your_other_smtpd_restrictions > ...... > > > > Hope this get you started. > > > Regards, > > John > The Netherlands > > > Paul,
Warning: During post, serveral lines in my examples were broken in two lines.When copying and pasting, fix them before starting amavisd-new > > > > > > > > > > > >