Proxmox Mail Gateway

Deployment Guide

5/21/2010 MailGatewayDeploymentGuide-V1.8.docx

Proxmox Server Solutions GmbH
Kohlgasse 51/10

A-1050 Vienna  office@proxmox.com

www.proxmox.com

Proxmox Server Solutions GmbH reserves the right to make changes to this document and to the products described herein without notice. Before installing and using the software, please review the latest version of this document, which is available from http://www.proxmox.com. NOTE: A license to the Proxmox Software usually includes the right to product updates for one (1) year from the date of purchase. Maintenance can be renewed on an annual basis. All other product or company names different from Proxmox may be trademarks or registered trademarks of their owners. Copyright © 2010 Proxmox Server Solutions GmbH. All rights reserved. No part of this publication may be reproduced, photocopied, stored in a retrieval system, or transmitted without the express prior written consent of Proxmox.

© 21.05.2010 Proxmox Server Solutions GmbH

2

49

Proxmox Server Solutions GmbH
Kohlgasse 51/10

A-1050 Vienna  office@proxmox.com

www.proxmox.com

Table of Contents
1 2 Introduction .................................................................................................... 5 Proxmox Mail Gateway Integration ..................................................................... 6 2.1 E-mail system without Proxmox ................................................................... 6 2.2 E-mail system with Proxmox ........................................................................ 6 2.3 Proxmox in the Intranet .............................................................................. 8 2.3.1 Default port settings ............................................................................ 8 2.3.2 Alternative port settings (e.g. for MS Exchange) ..................................... 8 2.4 Proxmox in DMZ (demilitarized zone) ...........................................................10 2.5 Proxmox with multiple e-mail server and mail domains ..................................11 Performance Tuning ........................................................................................12 3.1 Hardware benchmarks ...............................................................................12 3.2 Backup MX ...............................................................................................12 3.3 Local DNS cache........................................................................................12 3.4 Blocking Emails on SMTP level ....................................................................13 3.4.1 Greylisting.........................................................................................13 3.4.2 Sender Policy Framework – SPF ...........................................................14 3.4.3 Real time Blacklists (RBL)....................................................................14 3.4.4 Local DNS RBL cache – Spamhaus Datafeed Service ...............................15 3.4.4.1 Configuring local DNS blacklist caches ............................................15 3.4.5 Receiver Verification ...........................................................................16 3.4.5.1 Proxmox Solutions .......................................................................16 3.4.5.2 Enabling Verify Receivers ..............................................................17 3.4.5.2.1 Settings for Exchange 2003 SP2 ..................................................18 3.4.5.2.2 Settings for Exchange 2007 SP1 ..................................................21 Rule System ...................................................................................................22 4.1 Default Rules ............................................................................................24 4.1.1 Block Viruses .....................................................................................24 4.1.2 Virus Alert .........................................................................................24 4.1.3 Block Dangerous Files .........................................................................25 4.1.4 Mark Spam ........................................................................................25 4.2 Custom Rules............................................................................................26 4.2.1 Enable Spam and Virus quarantine .......................................................26 4.2.2 Enable Spam quarantine for just a selection of users ..............................26 4.2.3 Enable Spam quarantine for existing LDAP users ....................................27 4.2.4 Block Spam e-mails with a score higher 10 ............................................29 4.2.5 BCC object – An simple archive solution ................................................33 4.2.6 Block Video and Audio Attachments ......................................................33 4.2.7 Add Admin Notification to Rules ...........................................................34 4.2.8 Preventing directory harvesting attacks with LDAP object ........................34 4.2.9 Block Video and Audio Attachments for LDAP Groups ..............................35 Proxmox HA Cluster – High availability ..............................................................37 5.1 Load Balancing with MX Records..................................................................38 5.2 Multiple Address Records ............................................................................39 5.3 Using third party Firewall features ...............................................................39 Hardware selection and Virtualization ................................................................40 6.1 Physical Hardware .....................................................................................40 6.1.1 Certified Hardware .............................................................................40 6.2 Proxmox VE (http://pve.proxmox.com) ........................................................40 6.3 VMware™ .................................................................................................40 6.3.1 Settings for VMware™ ESX, ESXi and vSphere .......................................41 6.3.1.1 Settings for the Proxmox Mail Gateway Virtual Machine ....................41 6.3.1.1.1 RAM settings .............................................................................41 6.3.1.1.2 VMware Tools............................................................................41 6.3.1.1.3 Enable VMI Paravirtualization ......................................................41 6.3.1.1.4 Enable time synchronization .......................................................42
3

3

4

5

6

© 21.05.2010 Proxmox Server Solutions GmbH

49

Proxmox Server Solutions GmbH
Kohlgasse 51/10

A-1050 Vienna  office@proxmox.com

www.proxmox.com

6.3.2 Settings for a VMware™ Server 2 .........................................................42 6.3.2.1 Host memory settings...................................................................42 6.3.2.2 Settings for Proxmox Mail Gateway Virtual Machine ..........................43 6.3.2.2.1 RAM settings .............................................................................43 6.3.2.2.2 VMware Tools............................................................................43 6.3.2.2.3 Enable VMI Paravirtualization ......................................................43 6.3.2.2.4 Enable time synchronization .......................................................44 6.4 OpenVZ....................................................................................................45 7 Troubleshooting and technical support ...............................................................47 8 Table of figures ...............................................................................................48 9 Appendix .......................................................................................................49

© 21.05.2010 Proxmox Server Solutions GmbH

4

49

or it could cause a public-relations problem that no organization would want. If the email server is not working. and professionally managed e-mail improves organizational workflow and customer satisfaction. Proxmox Mail Gateway temporarily stores the message in the e-mail queue for later transfer. © 21.Proxmox Server Solutions GmbH Kohlgasse 51/10  A-1050 Vienna  office@proxmox. Note: See also the Proxmox Mail Gateway Administration Guide for a detailed product description.com  www. How does Proxmox work? When an e-mail arrives at the Proxmox Mail Gateway. The process works similar for outgoing e-mails. it is analyzed and forwarded to your e-mail server which is responsible for sending the e-mail to the receiver. This document covers samples and deployment information how to integrate and customize Proxmox in your e-mail environment. this includes: performance.2010 Proxmox Server Solutions GmbH 5  49 . A missed e-mail could mean a lost opportunity. reliability.proxmox. regulation under public law and e-mail threads like viruses or Phishing attacks.com 1 Introduction The huge amount of e-mail traffic is a challenge for every e-mail environment. E-mail is an essential service for any organization.05. The daily e-mail routine brings along some major problems.

For high availability and maximum performance it is recommended to use a Proxmox HA Cluster. With the integrated Proxmox system all your e-mail traffic is forwarded to the Proxmox Mail Gateway which filters the whole e-mail traffic and removes unwanted e-mails. your e-mail traffic (SMTP) arrives on the firewall and will be forwarded directly to your e-mail server. Figure 2-1 System without Proxmox Mail Gateway 2.com 2 Proxmox Mail Gateway Integration 2.com  www.05. Proxmox Mail Gateway can process incoming AND outgoing SMTP traffic by using different ports.2 E-mail system with Proxmox A single Proxmox Mail Gateway Server can handle unlimited mail domains with multiple internal mail servers and millions of e-mails per day.Proxmox Server Solutions GmbH Kohlgasse 51/10  A-1050 Vienna  office@proxmox. One port is assigned to incoming. Figure 2-2 Incoming e-mail with Proxmox Mail Gateway © 21.2010 Proxmox Server Solutions GmbH 6  49 . You can manage incoming and outgoing e-mail traffic. one port for outgoing e-mails.proxmox. see chapter 5 Proxmox HA Cluster – High availability.1 E-mail system without Proxmox In a sample configuration.

Proxmox can gather statistics about outgoing e-mails too.com Many mail filter solutions do not scan outgoing mails. While user-2 receiver 5 mails from a customer and sent 5 mails back.2010 Proxmox Server Solutions GmbH 7  49 . but they are quite useless.com  www. user1 receives 10 mails from news portals and wrote 1 mail to a person you never heard from.Proxmox Server Solutions GmbH Kohlgasse 51/10  A-1050 Vienna  office@proxmox. Proxmox advanced address statistics can show you this important information. This has two major advantages: Figure 2-3 Outgoing with Proxmox Mail Gateway 1. Solution which does not scan outgoing mail can’t do that. I many countries you are liable for not sending viruses to other people. 2. Which user do you consider more active? I am sure its user-2.proxmox. Opposed to that Proxmox Mail Gateway is designed to scan both incoming and outgoing mails. Consider two users. Proxmox is able to detect viruses sent from an internal host. Statistics about incoming e-mails looks nice. © 21. because he communicates with your customers.05. Proxmox outgoing e-mail scanning feature is an additional protection to avoid that.

proxmox. Note: Proxmox receives the outgoing e-mails on port 26. for MS Exchange) Sometimes it is not possible to change the outgoing port due to third party software limitations or existing network configurations (e.Proxmox Server Solutions GmbH Kohlgasse 51/10  A-1050 Vienna  office@proxmox.3 Proxmox in the Intranet 2. port 26. so Proxmox knows its internal trusted e-mail. After processing. So that you’re external IP and port 25 shows to the Proxmox Mail Gateway IP and port 26.com  www.2 Alternative port settings (e. changing MS Exchange to another sending port will have impact on Exchange internals and it’s not recommend) To receive e-mails you have to do port forwarding at your Firewall. Figure 2-5 Outgoing default port settings (port 26) 2. using standard port 25.1 Default port settings The default configuration of the Proxmox Mail Gateway uses port 25 for incoming and port 26 for outgoing e-mails.05. Proxmox sends the e-mails to Internet.com 2.g. Figure 2-4 Incoming default port settings (port 25) Outgoing Mails: Configure your mail server to send all e-mails to the Proxmox Mail Gateway.3. © 21.3.g.2010 Proxmox Server Solutions GmbH 8  49 .

proxmox.com  www.05.com Figure 2-6 Incoming alternative port settings (port 26) With MS Exchange you should not use port 26 for outgoing so you have to switch these two values (25 and 26). In the end you have to use port 25 for outgoing and port 26 for incoming mails.Proxmox Server Solutions GmbH Kohlgasse 51/10  A-1050 Vienna  office@proxmox.2010 Proxmox Server Solutions GmbH 9  49 . Figure 2-7 Outgoing alternative port settings (port 25) © 21.

proxmox.05. for example: Interface eth0 eth1 eth2 Zone Local Internet DMZ IP Address 192.255.255.168.16.255. The intranet (Local) and DMZ needs to have different IP Networks.168.255.0.0 255.0 Figure 2-8 Proxmox in DMZ © 21.2 192.Proxmox Server Solutions GmbH Kohlgasse 51/10  A-1050 Vienna  office@proxmox.1 Net mask 255.1 10.2010 Proxmox Server Solutions GmbH 10  49 .0 255.4 Proxmox in DMZ (demilitarized zone) To run a DMZ Zone you have to adjust your Firewall settings.255.255.1.com 2.com  www.0.

com  www.proxmox. Figure 2-9 Multiple e-mail servers Note: you need for each domain an appropriate license. otherwise it will not work! © 21.2010 Proxmox Server Solutions GmbH 11  49 .5 Proxmox with multiple e-mail server and mail domains You can use Proxmox Mail Gateway sending e-mails to different internal e-mail servers.05. For example you can send e-mails addressed to domain.Proxmox Server Solutions GmbH Kohlgasse 51/10  A-1050 Vienna  office@proxmox.com to your first e-mail server.domain. In the e-mail proxy transport section add the IP addresses or hostname.com to a second one. SMTP ports and mail domains of your additional e-mail servers.com 2. and e-mails addressed to subdomain.

Figure 3-1 Use local DNS Cache © 21.com 3 Performance Tuning 3. it is recommended to run a second Proxmox server in HA Cluster mode to avoid lower spam detection rates 3.38 MB/sec AVERAGE SEEK TIME: 8. because many ISPs do not use advanced spam prevention techniques. And spammers know this and they use your ISP backup MX to work around your Proxmox spam filtering.spamhaus.Proxmox Server Solutions GmbH Kohlgasse 51/10  A-1050 Vienna  office@proxmox.com) DNSBL: 35.51 DNS EXT: 46.com  www. Additionally. you can never benefit of blocking spam messages on SMTP level.2010 Proxmox Server Solutions GmbH 12  49 . It is recommended to enable it if you do not have access to fast (internal) DNS servers. If you need redundancy.05 ms (domain.com.1 Hardware benchmarks Please use the command line tool “proxperf” to get an overview about your hardware and DNS performance.05. Note: Never run “proxperf” if the system is under load.proxmox.09 ms FSYNCS/SECOND: 1084.26 ms DNS INT: 1. 3.org) proxmox:~# Please compare your results against this reference. or if you want to reduce the load on those servers.3 Local DNS cache Proxmox includes a local DNS cache. Here is a sample output of “proxperf”: proxmox:~# proxperf CPU BOGOMIPS: 8489.47 ms (zen.64 REGEX/SECOND: 410814 HD SIZE: 6.2 Backup MX Using your ISPs mail server is not a good idea. If you get lower results please analyze your hardware and DNS setup – for comments email your results to support@proxmox.89 GB (/dev/sda2) BUFFERED READS: 116.

proxmox. just enter in the Mail proxy whitelist. Figure 3-2 Mail proxy whitelist 3.4. The e-mail is rejected with a temporary error. a legitimate server will attempt to connect again later on to deliver the e-mail. depends on your environment. Greylisted e-mails never reach your mail server and your mail server will stop sending useless "Non Delivery Reports" to spammers. If a sender has a valid SPF record. Greylisting is effective because many mass e-mail tools utilized by spammers are not set up to handle temporary failures (or any failures for that matter) so the Spam is never received. The assumption is that since temporary failures are built into the RFC specifications for e-mail delivery.Proxmox Server Solutions GmbH Kohlgasse 51/10  A-1050 Vienna  office@proxmox. Then. This feature can reduce e-mail traffic up to 50%. If you want to exclude some senders or receivers from getting blocked on the SMTP level.    The IP address of the connecting host The envelope sender address The envelope recipient address The client is checked against the mail server's internal whitelists (if any) first. a server that utilizes Greylisting will record the following three pieces of information (referred to as triplet) for all incoming e-mail. filling up the queue.com  www. he will never be greylisted.com 3. if the triplet has never been seen before.1 Greylisting Typically. it is greylisted for a period of time (how much time is dependent on the server configuration).4 Blocking Emails on SMTP level Blocking emails before they reach your network saves your internet bandwidth and reduces processing power. By doing the following.05. you can reduce your email traffic by more than 90 %. © 21.2010 Proxmox Server Solutions GmbH 13  49 .

org for setting up a SPF for your mail domain.org Figure 3-3 Enable RBL checks © 21. Proxmox use the following RBL providers by default: • Spamhaus.05.org • dsbl. SPF works by domains publishing "reverse MX" records to tell the world what machines send email for the domain. the recipient can check those records to make sure e-mail is coming from where it should be coming from.) to the machines that perform those services. When receiving a message from a domain.2010 Proxmox Server Solutions GmbH 14  49 . Note: see http://www. e-mail.com  www.openspf.2 Sender Policy Framework – SPF Domains use public records (DNS) to direct requests for different services (web.4.com 3. etc. Please make sure.Proxmox Server Solutions GmbH Kohlgasse 51/10  A-1050 Vienna  office@proxmox.3 Real time Blacklists (RBL) Proxmox can use RBL checks on SMTP level to reject e-mails. 3. Therefore Proxmox has to query the RBL server for every SMTP connection. All domains already publish e-mail (MX) records to tell the world what machines receive e-mail for the domain.proxmox.4. that you deploy a valid SPF record for your mail domain.

org:ip4tset:xbl \ zen. please replace these values with the one in your spamhaus datafeed license.org and dsbl. usually started via cron. Proxmox can synchronize these blacklists locally to provide quality of service and speed up the query time. Please log in to the console and configure the following: crontab –e 11.4.dsbl.spamhaus.spamhaus.org:ip4trie:pbl \ xbl.org.4 Local DNS RBL cache – Spamhaus Datafeed Service Each e-mail leads to a DNS query to the RBL server of spamhaus and dsbl.0.1' to disable it (default).spamhaus.05. configure the RBLDNS daemon configuration file: nano /etc/default/rbldnsd RBLDNSD=".2010 Proxmox Server Solutions GmbH 15  49 .org:ip4tset:xbl \ list.proxmox. You can locally mirror blacklist data making queries to remote DNS servers unnecessary.org --dsbl rsync.dsbl.spamhaus.org:ip4set:dsbl" © 21.Proxmox Server Solutions GmbH Kohlgasse 51/10  A-1050 Vienna  office@proxmox.0.org:ip4trie:pbl \ zen.com HowTo: Synchronize DNS blacklist to the Proxmox server Local sync is done via proxblsync.0. 3.-r/var/lib/rbldns -f -b127.org -mailto root Note: “11. If these servers are under heavy it cannot be guaranteed that you will get an answer – also if you are running a high traffic site it is recommended to locally cache both RBL´s.spamhaus.4.spamhaus.org:ip4set:sbl \ zen.proxmox.com  www. Note: Spamhaus data feed is a commercial service – additional license/account required. For details visit http://www.1 Configuring local DNS blacklist caches Some DNS blacklist providers offers data feed services. Next. or '127. Just set the IP address of your local mirror.41” stands for the minutes of each hour.spamhaus.41 * * * * proxblsync --spamhaus rsync1. You can use your Proxmox Server to download the blacklists. but you can also use any other server within your network.0.org:ip4set:sbl \ pbl.com 3. Proxmox can use local DNS blacklist caches of spamhaus.4.2 \ sbl.

Proxmox Server Solutions GmbH Kohlgasse 51/10  A-1050 Vienna  office@proxmox. up to 90 % Your internal e-mail server is now working for you again Reduced load on your scanners.05.2010 Proxmox Server Solutions GmbH 16  49 . which means BEFORE the e-mails are transferred to your networks.5 Receiver Verification Nowadays.org and Dsbl.1 Proxmox Solutions Proxmox can detect these e-mails to non-existing users on SMTP level.d/rbldnsd start Finally.5.com Start the RBLDNS service: /etc/init. In short.org 3.4.4. this means for your systems:     Increased traffic on your internet connection Your e-mail server is handling junk e-mails instead of working for you High load on your scanners Slow overall performance and high costs 3. 90 % less e-mails to analyze for spam and viruses Good performance and costs © 21. this means for your systems:     reduced traffic. In short. redirect query to local mirror: Figure 3-4 Enable local RLB cache – Spamhaus.proxmox. e-mail domains are receiving a lot of e-mails to non-existing users.com  www. This could be up to 95 % of junk messages.

5.com 3. Note: Your internal e-mail server has to be reconfigured to reject unknown user.4.2.05. see chapter 3.2 Enabling Verify Receivers You can enable this option on the admin interface (Configuration/Mail Proxy/Options) We recommend selecting yes (450).com  www. Proxmox is doing a short query to the internal e-mail server to check if the user is valid.1 Settings for Exchange 2003 SP2 Figure 3-5 Enable Verify Receivers © 21. For settings on Exchange 2003 SP2. that in the case of a short downtime of your internal mail server no messages are lost. 450 means.Proxmox Server Solutions GmbH Kohlgasse 51/10  A-1050 Vienna  office@proxmox.proxmox.2010 Proxmox Server Solutions GmbH 17  49 .4.5.

2010 Proxmox Server Solutions GmbH 18  49 .5.com  www.com 3. Figure 3-6 Exchange 2003: Filter recipients 1 © 21.2.05. please use the Exchange System Manager.proxmox.1 Settings for Exchange 2003 SP2 You have to enable Recipient Filtering.4.Proxmox Server Solutions GmbH Kohlgasse 51/10  A-1050 Vienna  office@proxmox.

com  www.2010 Proxmox Server Solutions GmbH 19  49 .com Figure 3-7 Exchange 2003: Filter recipients 2 © 21.proxmox.05.Proxmox Server Solutions GmbH Kohlgasse 51/10  A-1050 Vienna  office@proxmox.

Proxmox Server Solutions GmbH Kohlgasse 51/10  A-1050 Vienna  office@proxmox.com Figure 3-8 Exchange 2003: Filter recipients 3 Figure 3-9 Exchange 2003: Filter recipients 4 © 21.com  www.2010 Proxmox Server Solutions GmbH 20  49 .05.proxmox.

05.2.2010 Proxmox Server Solutions GmbH 21  49 . 4.Proxmox Server Solutions GmbH Kohlgasse 51/10  A-1050 Vienna  office@proxmox. Microsoft provides an install script to manually install the Anti-Spam agent: 1. Open the Exchange Management Shell cd “c:\program files\Microsoft\Exchange Server\Scripts” . 3.proxmox. If you installed a typical one server installation.5.4. make sure that you have the Exchange 2007 Anti-Spam agent.com  www.\install-AntispamAgents Restart the Microsoft Exchange Transport service Figure 3-10 Exchange 2007 SP1: Install Anti-Spam agent Now you can enable Recipient Filtering on the Anti-Spam agent. Figure 3-11 Exchange 2007 SP1: Filter recipients 1 © 21.com 3. this is NOT installed by default. please use the Exchange Management Console. 2.2 Settings for Exchange 2007 SP1 First.

object Example: Mark e-mail with "SPAM:" in the subject.2010 Proxmox Server Solutions GmbH 22  49 .object Example: Does the e-mail contain spam? Action .proxmox. content type and resulting action.     Who .Who is the sender or receiver of the e-mail? When . Every rule has got 5 categories (FROM. recipients not visible in the "To" field) to Mailbox or to a Public Folder      FROM: Anybody TO: Anybody WHEN: Always WHAT: Mail ACTION: BCC to Publicfolder In most of the countries worldwide a company has to forward all e-mails to there employees this includes spam e-mails as well.com Figure 3-12 Exchange 2007 SP1: Filter recipients 2 4 Rule System The object-oriented rule system enables custom rules for your domains. TO. WHAT.Proxmox Server Solutions GmbH Kohlgasse 51/10  A-1050 Vienna  office@proxmox.05. domains.object Example: When is the e-mail received by Proxmox Mail Gateway? What .object For TO and/or FROM Category Example: Mail object . time frame. For example enable Archive Solutions with BCC Object (Blind carbon copy. ACTION) which can contain several objects. © 21. WHEN. It’s an easy but very powerful way to define filter rules by user.com  www.

To increase the efficiency of e-mail communications the use of anti-spam. Microsoft Exchange. At present the usefulness of e-mail is being threatened by three phenomena: spamming. The combination of spam and worm programs results in users receiving a constant drizzle of junk e-mail. E-mail worms use e-mail as a way of replicating themselves into vulnerable computers. Lotus Domino. Spamming is unsolicited commercial e-mail. pishing and e-mail worms. With the deployment of Proxmox Mail Gateway you get the job done. Quarantine can be enabled just for existing LDAP groups or via BCC to Public Folders or Mailboxes. anti-pishing and antivirus software is essential. It’s compatible to every type of mail server or MTA (e.com  www. which reduces the usefulness of e-mail as a practical tool.g. Postfix …). Hundreds of active spammers sending this volume of mail results in information overload for many computer users who receive tens or even hundreds of junk messages each day. spammers can send hundreds of millions of e-mail messages each day over an inexpensive internet connection. highly customized configurations blocking certain types of e-mails and generating notifications.2010 Proxmox Server Solutions GmbH 23  49 . For example a virus protection looks like this:      FROM: Anybody TO: Anybody WHEN: Always WHAT: Virus ACTION: Block Options range from simple spam and virus filter setups to sophisticated. It can be easy integrated in existing E-mail architecture. Based on the design as software appliance one of the strengths of Proxmox Mail Gateway is its flexibility. © 21.Proxmox Server Solutions GmbH Kohlgasse 51/10  A-1050 Vienna  office@proxmox.com For example to send Spam mails in quarantine      FROM: Anybody TO: Anybody WHEN: Always WHAT: Spam ACTION: Quarantine With this kind of setup the receiver gets detailed Information about the Spam e-mails.05. Because of the very low cost of sending email.proxmox.

Figure 4-1 Rule: Block Viruses 4.com 4.1.Proxmox Server Solutions GmbH Kohlgasse 51/10  A-1050 Vienna  office@proxmox.2 Virus Alert This rule blocks all outgoing virus e-mail and informs the admin and sender via e-mail notification.05.proxmox.1.com  www.1 Block Viruses This rule blocks all incoming virus e-mail and informs the admin via e-mail notification. Figure 4-2 Rule: Virus Alert © 21.2010 Proxmox Server Solutions GmbH 24  49 .1 Default Rules 4.

05.com.bat.com  www. Figure 4-4 Rule: Mark Spam © 21.Proxmox Server Solutions GmbH Kohlgasse 51/10  A-1050 Vienna  office@proxmox.proxmox..vbs.4 Mark Spam This rule identifies spam and modifies the spam level and the e-mail subject.2010 Proxmox Server Solutions GmbH 25  49 ..com 4.3 Block Dangerous Files This rule removes dangerous attachments from incoming e-mails (. …) Figure 4-3 Rule: Block Dangerous Files 4.1.1.

1. give a name like “Quarantine Users” and add the users or domains to this object 2.g. Use the existing (inactive) rule “Spam Quarantine” and set higher priority than the “Mark Spam” rule (e. 4.proxmox. create a new WHO object containing these users or domains.com  www. For support or help configuring rules see the Proxmox support forum at: http://www. Activate the rule © 21.1 Enable Spam and Virus quarantine Activate or change the Spam and/or Virus rule with the existing action object “Quarantine”.05.2 Enable Spam quarantine for just a selection of users If you want to use the spam quarantine for specific users or a specific domain (and for the rest just “Mark Spam”).com 4.2 Custom Rules Proxmox provides samples for custom rules to show the functionality.2. Create a new WHO object.2. Add the WHO object “Quarantine Users” 4.2010 Proxmox Server Solutions GmbH 26  49 . 81) 3. Figure 4-5 Add “Quarantine” action to rule “Mark Spam” 4.Proxmox Server Solutions GmbH Kohlgasse 51/10  A-1050 Vienna  office@proxmox.com/forum/ or contact a Proxmox partner.proxmox.

give a name like “Existing LDAP address” and add the LDAP group “Existing LDAP address” 2. 81) 3. Add the WHO object “Existing LDAP address” 4.05. you can use the LDAP query “Existing LDAP”.proxmox. Activate the rule Figure 4-7 Create WHO object “Existing LDAP address” © 21. 1. Create a new WHO object.com  www.3 Enable Spam quarantine for existing LDAP users If you want to use the spam quarantine only for existing internal e-mail addresses.2010 Proxmox Server Solutions GmbH 27  49 .g.Proxmox Server Solutions GmbH Kohlgasse 51/10  A-1050 Vienna  office@proxmox.2.com Figure 4-6 Enable Spam quarantine for just a selection of users 4. Use the existing (inactive) rule “Spam Quarantine” and set higher priority than the “Mark Spam” rule (e.

com  www.2010 Proxmox Server Solutions GmbH 28  49 .com Figure 4-8 Enable Spam quarantine for existing LDAP addresses © 21.05.Proxmox Server Solutions GmbH Kohlgasse 51/10  A-1050 Vienna  office@proxmox.proxmox.

proxmox. give a name. Set Priority to 81 (higher than the “Mark Spam” rule!. you can block Spam with a score higher 10 to reduce the delivery of spam e-mails to the user. give a name. set Direction to “In” Figure 4-12 Add What Object “Spam Level 10” to the rule Figure 4-13 Add Action Object “Block” to the rule Figure 4-14 Final review (still inactive) Figure 4-15 Activate rule Figure 4-16 Figure 4-9 Add new What Object © 21. “Spam Level 10” Figure 4-9 Add “Spam Filter” to the Object Figure 4-10 Set the Set Spam Filter to Level 10 Figure 4-11 Add new Rule.2. Create a new “What Object”. 4.com 4. e. 7.05. 6. With this additional rule.com  www.g. 1. 3. 5. 8.Proxmox Server Solutions GmbH Kohlgasse 51/10  A-1050 Vienna  office@proxmox. e. “Delete Spamlevel 10”.4 Block Spam e-mails with a score higher 10 The default setting marks Spam with a score higher 5 and delivers the e-mail to the user. 2.2010 Proxmox Server Solutions GmbH 29  49 .g.

05.proxmox.com  www.Proxmox Server Solutions GmbH Kohlgasse 51/10  A-1050 Vienna  office@proxmox.com Figure 4-10 Add Spam Filter to a What Object Figure 4-11 Set Spam Filter to Level 10 © 21.2010 Proxmox Server Solutions GmbH 30  49 .

2010 Proxmox Server Solutions GmbH 31  49 .05.com  www.com Figure 4-12 Add new Rule Figure 4-13 Add What Object to a Rule © 21.proxmox.Proxmox Server Solutions GmbH Kohlgasse 51/10  A-1050 Vienna  office@proxmox.

proxmox.com  www.05.2010 Proxmox Server Solutions GmbH 32  49 .Proxmox Server Solutions GmbH Kohlgasse 51/10  A-1050 Vienna  office@proxmox.com Figure 4-14 Add Action Object to a Rule Figure 4-15 Final Review of Rule (still inactive) © 21.

Set appropriate client permission (note: anonymous must have the right to create items) 6. Optional: Set age limit: select “Limits” and set the age limit to 90 days (all messages older than 90 days will be automatically deleted) 4. Create a new rule. name it “BCC to Archive Public folder or Mailbox” 2.g. Under “Receiver”. Right click the folder an check the e-mail address (or change it. if you want).Proxmox Server Solutions GmbH Kohlgasse 51/10  A-1050 Vienna  office@proxmox. Add Action Object “BCC to Archive Public folder or Mailbox” to the rule How to create a Mail Enable Public Folder under Exchange 2000/2003? 1.6 Block Video and Audio Attachments 1. 1. Click on an already existing rule or create a new one 4.05. Wait a few minutes. e. define direction and set priority 2.com  www. Create an Action Object: “Add BCC Object”. If you have Microsoft Exchange.2. Create a public folder in Exchange (Exchange System Manager or via Outlook) 2. "Mail enable" the public folder via Exchange system manager – right click an select “Mail Enable” 3. Add What Object “Multimedia” to the rule © 21.5 BCC object – An simple archive solution If you need to archive e-mails it’s useful to send a copy to a special mailbox. “Block Multimedia Files”.com Figure 4-16 Activate Rule 4.proxmox. type the e-mail address of the public folder/Mailbox 3.2010 Proxmox Server Solutions GmbH 33  49 .2. Exchange creates the e-mail address 4. you can also send a copy to a mail enabled public folder. remember e-mail address 5.

g. Add the “notify Admin” action to the rule 4. select “Any profile” and “Unknown LDAP Address”. Activate the rule Note: Add always the “Spam” object – because most directory attacks are also spam.g. Final review (still inactive) 9. “Unknown LDAP”. just add a notify to see results – be careful with block action) 8. Add Action Object “Block” to the rule 4.8 Preventing directory harvesting attacks with LDAP object The LDAP group object “Unknown LDAP address” can be used to prevent directory harvesting attacks.2010 Proxmox Server Solutions GmbH 34  49 .7 Add Admin Notification to Rules If you block mails it’s useful to inform the Proxmox Admin. 1.Proxmox Server Solutions GmbH Kohlgasse 51/10  A-1050 Vienna  office@proxmox. Click on the desired rule 2. Create a new “WHO Object”. Add the WHO object “Unknown LDAP” from above to the rule (as “to”) 6. it should be member of the Unknown LDAP group. 1.com 3. set direction to “in” 5.05.proxmox. Activate the rule 4. e. © 21. then click save. “Unknown LDAP” 2. 4.2.com  www. If you type a valid e-mail address. Add new rule. it should not be member. Add the WHAT “Spam” to the rule 7. Final review (still inactive) 5. Add the ACTION object “block” (for testing. Now you can test your object against e-mail addresses. So you just block attacks from spammers and you still are able to send NDR to people just mistyping an e-mail address. give a name.2. The Mail Gateway can check incoming e-mail addresses against valid e-mail addresses in your organization. If you type an unknown e-mail address. e. 3. give a name. set priority to 85 (higher than the “Mark Spam” rule. Add an “LDAP Group” to the Object.

Proxmox Server Solutions GmbH Kohlgasse 51/10  A-1050 Vienna  office@proxmox. give a name.g.  Now you can test your object against e-mail addresses  Add new rule.05. “Block Multimedia for Staff”. set direction to “in”. you do not want to block these funny things for everybody.com  www. select “your LDAP Profile” and select “Staff” from the dropdown menu.  Create a new “WHO Object”. e. “Staff”  Add “LDAP Group” to the Object.g. click save  Add the WHO object “Staff” from above to the rule (as “to”)  Add the WHAT “Multimedia” to the rule  Add the ACTION object “Remove Attachments”  Final review (still inactive)  Activate the rule Note: Removed attachments from e-mails are replaced with a text file. click save. give a name.2010 Proxmox Server Solutions GmbH 35  49 . Most people like sending joke videos and audio files via e-mail – this grows up your users mailboxes. © 21.com Figure 4-17 Unknown LDAP address rule 4. We assume you have a LDAP group called “Staff”.2. On the other side. e. set priority to 70.proxmox.9 Block Video and Audio Attachments for LDAP Groups The LDAP groups can be used to apply special settings to groups.

2010 Proxmox Server Solutions GmbH 36  49 .com Figure 4-18 Block video and Audio attachment for LDAP group “Staff” © 21.Proxmox Server Solutions GmbH Kohlgasse 51/10  A-1050 Vienna  office@proxmox.com  www.05.proxmox.

Configuration is done on the master.com 5 Proxmox HA Cluster – High availability We are living in a world where e-mail becomes more and more important .failures in email systems are just not acceptable. Special considerations where taken to make management as easy as possible. and nodes automatically reintegrate after temporary failures without any operator interaction.Proxmox Server Solutions GmbH Kohlgasse 51/10  A-1050 Vienna  office@proxmox. Complete Cluster setup is done within minutes. Figure 5-1 Proxmox HA Cluster with load balanced MX records © 21. To meet these requirements we developed the Proxmox HA (High Availability) Cluster. This provides the following advantages:     centralized configuration management fully redundant data storage high availability high performance Proxmox uses a unique application level clustering scheme. The Proxmox HA Cluster consists of a master and several nodes (minimum one node).proxmox.05. Configuration and data is synchronized to all cluster nodes over a VPN tunnel.com  www.2010 Proxmox Server Solutions GmbH 37  49 . which provides extremely good performance.

com  www. You have to define two MX records with the same priority. This is all you need.05.proxmox.example.com 5. Many e-mail systems nowadays reject mails from hosts without valid PTR records.e. You need to have 2 working Proxmox Mail Gateways (mail1. more or less load-balanced (round-robin scheduling). You will receive mails on both hosts.2010 Proxmox Server Solutions GmbH 38  49 . i. We recommend adding reverse lookup entries (PTR records) for those hosts.com and mail2.Proxmox Server Solutions GmbH Kohlgasse 51/10  A-1050 Vienna  office@proxmox. you can use backup/restore to copy the rules).com). each having its own IP address (the rest of the setting should be more or less equal. If one host fails the other is used.example. Figure 5-2 Load balancing via MX Records © 21.1 Load Balancing with MX Records It’s quite simple to set up a high performance load balanced mail cluster using MX records.

3 Using third party Firewall features Many firewalls can do some kind of RR-Scheduling (round-robin) when using DNAT.Proxmox Server Solutions GmbH Kohlgasse 51/10  A-1050 Vienna  office@proxmox.05.com 5. It is also possible to use one MX record per domain. but multiple address records: Figure 5-3 Load balancing Multiple Address Records 5. See your firewall manual for more details.2 Multiple Address Records Using several DNS MX record is sometime clumsy if you have many domains.2010 Proxmox Server Solutions GmbH 39  49 .com  www.proxmox. © 21.

com for certified hardware.1 Certified Hardware The latest certified hardware list is published on http://www.com.com) The Mail Gateway is available as a certified Virtual Appliance for Proxmox VE.2010 Proxmox Server Solutions GmbH 40  49 . Installation from the ISO-Image is also fully supported and gives the possibility for custom settings.05.27) and we deliver a prebuilt VMware Tools package for installation (already included in the Appliance). For quick deployment Proxmox delivers a ready to run.proxmox. 6.Proxmox Server Solutions GmbH Kohlgasse 51/10  A-1050 Vienna  office@proxmox.000rpm). For all details see http://pve.proxmox.proxmox. Proxmox can be run under VMware™. Proxmox delivers prebuilt Virtual Appliances for:    Proxmox VE (http://pve.3 VMware™ Proxmox runs perfectly under VMware™. preconfigured and certified Virtual Appliance. optimized for the VMware™ Host.2 Proxmox VE (http://pve.6. OpenVZ and Proxmox VE.com) VMware™ OpenVZ Also known to work (Intel VT or AMD-V needed):       Virtualbox XEN (Full virtualized) Citrix XenServer (Full virtualized) Parallels Server Virtualbox Hyper-V For best performance please use physical hardware or OS virtualization like Proxmox VE (OpenVZ).proxmox. © 21. Hardware Raid with battery backup and cache enabled Two Quad Core Xeon (5xxx) 4 GB ECC 6.3 and later supports VMware™ para-virtualization (Kernel 2.1. Proxmox 2.com/wiki/Proxmox_Mail_Gateway 6. For maximum performance we recommend: Hard disks CPU RAM SAS Disk (15.proxmox.1 Physical Hardware See http://www. 6.proxmox. Alternative.com 6 Hardware selection and Virtualization Proxmox always needs a dedicated PC or server hardware.com  www.

3 Enable VMI Paravirtualization Figure 6-1 Enable VMI Paravirtualization for Proxmox Mail Gateway on ESX © 21.1.3.Proxmox Server Solutions GmbH Kohlgasse 51/10  A-1050 Vienna  office@proxmox.3.com. A VMware™ host can swap memory between guests and if configured.com/forum/.1. 6.1.com 6.com  www. if Proxmox runs on a machine with 1 GB memory it uses 1 GB of memory. for optimal operation you should never assign more memory to virtual machines than is available on the host. Please visit the support forum for detailed instructions and downloads. While memory overcommit is possible. the host can show more physical memory to the guest as available by swapping to disks.2 VMware Tools Proxmox precompiles the VMware Tools components for easy installation. ESXi and vSphere Proxmox dynamically adapts the number of processes referring to the given memory to maximize performance.3.05. This means.1.1 RAM settings The minimum memory for running Proxmox Mail Gateway is 512 MB RAM.1.1.vmware.2010 Proxmox Server Solutions GmbH 41  49 .3.3. 6. 6.1 Settings for VMware™ ESX.1 Settings for the Proxmox Mail Gateway Virtual Machine 6.proxmox. For more details see VMware documentation on http://www.1.proxmox. http://www. This leads to very poor performance.

if Proxmox runs on a machine with 1 GB memory it uses 1 GB of memory.3. This means.2 Settings for a VMware™ Server 2 Proxmox dynamically adapts the number of processes referring to the given memory to maximize performance.com 6. This setting imposes the tightest restrictions on the number and memory size of virtual machines that can run at a given time.vmware. This leads to very poor performance. 6. Because the virtual machines are running entirely in RAM.proxmox.4 Enable time synchronization Figure 6-2 Enable time synchronization on ESX/ESXi 6. While memory overcommit is possible.2010 Proxmox Server Solutions GmbH 42  49 .2.1.Proxmox Server Solutions GmbH Kohlgasse 51/10  A-1050 Vienna  office@proxmox. © 21.com. the host can show more physical memory to the guest as available by swapping to disks.05. they have the best possible performance.3.3. A VMware™ host can swap memory between guests and if configured.com  www.1.1 Host memory settings Always choose this option: “Fit all virtual machine memory into reserved host RAM” Strictly apply the reserved memory limit set in the top of the panel. For more details see VMware documentation on http://www. for optimal operation you should never assign more memory to virtual machines than is available on the host.

3.2.2 Settings for Proxmox Mail Gateway Virtual Machine 6.3 Enable VMI Paravirtualization © 21. 6.com  www.2.2.2010 Proxmox Server Solutions GmbH 43  49 .proxmox.Proxmox Server Solutions GmbH Kohlgasse 51/10  A-1050 Vienna  office@proxmox.3.3.2 VMware Tools Proxmox precompiles the VMware Tools components for easy installation. http://www.com Figure 6-3 Memory settings for VMware Server 2 Host 6.2. 6.1 RAM settings The minimum memory for running Proxmox Mail Gateway is 512 MB RAM.2.05.3. Please visit the support forum for detailed instructions and downloads.com/forum/.2.proxmox.2.

2010 Proxmox Server Solutions GmbH 44  49 .proxmox.2.com Figure 6-4 Enable VMI Paravirtualization for Proxmox Mail Gateway 6.05.3.2.com  www.4 Enable time synchronization © 21.Proxmox Server Solutions GmbH Kohlgasse 51/10  A-1050 Vienna  office@proxmox.

com Figure 6-5 Enable time synchronization on VMware Server 2 Host 6.com). For details about OpenVZ.com  www. we launched a wiki page on: © 21. please visit http://openvz. OpenVZ is also used in Proxmox VE (http://pve. Proxmox runs on OpenVZ quite as fast as on physical hardware with all advantages from virtualization.2010 Proxmox Server Solutions GmbH 45  49 .Proxmox Server Solutions GmbH Kohlgasse 51/10  A-1050 Vienna  office@proxmox.proxmox. Main advantage from Operating System-level server virtualization is minimum overhead which leads to maximum performance. For running Proxmox on OpenVZ.05.org/. OpenVZ supports online migration from a running Proxmox from one hardware node to another without downtime.4 OpenVZ OpenVZ is an Open Source Operating System-level server virtualization solution.proxmox. built on Linux.

proxmox. we developed vzdump: http://wiki.05.Proxmox Server Solutions GmbH Kohlgasse 51/10  A-1050 Vienna  office@proxmox.2010 Proxmox Server Solutions GmbH 46  49 .openvz.com http://wiki.org/Proxmox_Mail_Gateway_in_VE For online backups of a running OpenVZ.org/Backup_of_a_running_VE_with_vzdump © 21.com  www.openvz.

All information: http://www.com Email support: support@proxmox.com 7 Troubleshooting and technical support Use the moderated Proxmox support forum or contact a Proxmox partner for their support offerings.05.com © 21.Proxmox Server Solutions GmbH Kohlgasse 51/10  A-1050 Vienna  office@proxmox.proxmox.com  www.proxmox.2010 Proxmox Server Solutions GmbH 47  49 .

..................................................................14 3-4 Enable local RLB cache – Spamhaus.......................................12 3-2 Mail proxy whitelist ................................................................................13 3-3 Enable RBL checks ...................................................................17 3-6 Exchange 2003: Filter recipients 1 .......................27 4-7 Create WHO object “Existing LDAP address” ..............................................19 3-8 Exchange 2003: Filter recipients 3 .......39 6-1 Enable VMI Paravirtualization for Proxmox Mail Gateway on ESX ..... 9 2-8 Proxmox in DMZ ..............com 8 Table of figures Figure Figure Figure Figure Figure Figure Figure Figure Figure Figure Figure Figure Figure Figure Figure Figure Figure Figure Figure Figure Figure Figure Figure Figure Figure Figure Figure Figure Figure Figure Figure Figure Figure Figure Figure Figure Figure Figure Figure Figure Figure Figure Figure Figure Figure Figure Figure 2-1 System without Proxmox Mail Gateway .................................................................................................... 7 2-4 Incoming default port settings (port 25) ..........................................................................................45 © 21...............................Proxmox Server Solutions GmbH Kohlgasse 51/10  A-1050 Vienna  office@proxmox......32 4-15 Final Review of Rule (still inactive) .......................................................................................16 3-5 Enable Verify Receivers ...................... 9 2-7 Outgoing alternative port settings (port 25) ........... 6 2-3 Outgoing with Proxmox Mail Gateway ..............................................21 3-11 Exchange 2007 SP1: Filter recipients 1.41 6-2 Enable time synchronization on ESX/ESXi .....................................................38 5-3 Load balancing Multiple Address Records ...............................................................36 5-1 Proxmox HA Cluster with load balanced MX records .......25 4-5 Add “Quarantine” action to rule “Mark Spam” ....................................31 4-13 Add What Object to a Rule ...........................................proxmox......42 6-3 Memory settings for VMware Server 2 Host ..30 4-12 Add new Rule ....................44 6-5 Enable time synchronization on VMware Server 2 Host .........................com  www..................................................................................................................................................35 4-18 Block video and Audio attachment for LDAP group “Staff” ....................org ...................31 4-14 Add Action Object to a Rule ..............28 4-9 Add new What Object .......10 2-9 Multiple e-mail servers ...........................................25 4-4 Rule: Mark Spam .........................................................21 3-12 Exchange 2007 SP1: Filter recipients 2...........................................................................24 4-2 Rule: Virus Alert ....................33 4-17 Unknown LDAP address rule................................................................................................................................................. 8 2-5 Outgoing default port settings (port 26) ..........................20 3-10 Exchange 2007 SP1: Install Anti-Spam agent ........................................ 6 2-2 Incoming e-mail with Proxmox Mail Gateway......................................43 6-4 Enable VMI Paravirtualization for Proxmox Mail Gateway ........................................................18 3-7 Exchange 2003: Filter recipients 2 ........................2010 Proxmox Server Solutions GmbH 48  49 ............................................20 3-9 Exchange 2003: Filter recipients 4 ..............................32 4-16 Activate Rule ......05.....................................................................................................26 4-6 Enable Spam quarantine for just a selection of users ............................................24 4-3 Rule: Block Dangerous Files ..................................... 8 2-6 Incoming alternative port settings (port 26) .................22 4-1 Rule: Block Viruses .................................................37 5-2 Load balancing via MX Records.....30 4-11 Set Spam Filter to Level 10 .............................11 3-1 Use local DNS Cache ...............29 4-10 Add Spam Filter to a What Object ............................................................................................................org and Dsbl.............27 4-8 Enable Spam quarantine for existing LDAP addresses ..............................................

2010 Proxmox Server Solutions GmbH 49  49 .proxmox.05.End of document - © 21.com 9 Appendix Reference document: Mail Gateway AdminGuide You can download the latest version from www.Proxmox Server Solutions GmbH Kohlgasse 51/10  A-1050 Vienna  office@proxmox.com  www.proxmox.com .

Master your semester with Scribd & The New York Times

Special offer for students: Only $4.99/month.

Master your semester with Scribd & The New York Times

Cancel anytime.