qmail | Brain Goo https://www.popmartian.com/tipsntricks Carpe Crap 'em Fri, 03 Oct 2008 16:32:00 +0000 en-US hourly 1 https://wordpress.org/?v=6.9.10 How to update qmail relay rules https://www.popmartian.com/tipsntricks/2008/08/20/how-to-update-qmail-relay-rules/ https://www.popmartian.com/tipsntricks/2008/08/20/how-to-update-qmail-relay-rules/#respond Wed, 20 Aug 2008 15:31:05 +0000 http://www.popmartian.com/tipsntricks/?p=27 D. J. Bernstein’s Qmail, now in the public domain, is a powerful yet clumsy SMTP messaging system. One of the most common problems is updating the rules for allowing SMTP relay, or denying the same. If you qmail-smtpd under tcpserver, … Continue reading →

The post How to update qmail relay rules first appeared on Brain Goo.

]]>
D. J. Bernstein’s Qmail, now in the public domain, is a powerful yet clumsy SMTP messaging system. One of the most common problems is updating the rules for allowing SMTP relay, or denying the same.

If you qmail-smtpd under tcpserver, the following will update relay allow and relay forbid rules.

Create a file called /etc/tcp.smtp and put in it:

127.:allow,RELAYCLIENT=""
1.1.1.1:allow,RELAYCLIENT=""
2.2.:allow,RELAYCLIENT=""
2.2.2.5:deny

Qmail uses simple pattern matching so only classful subnets are allowed. Sorry, no CIDR notation.

The example above will allow/deny:

  • Allow relaying from 127.* your localhost subnet of 127.0.0.0/8
  • Allow the /32 address of 1.1.1.1
  • Allow 2.2.* the /16 subnet of 2.2.0.0/16
  • Specifically forbid 2.2.2.5

In order to implement these rules you need to update the server tcp.smpt.cbd file and restart Qmail.

First, back up /etc/tcp.smtp, then run the command:
tcprules /etc/tcp.smtp.cdb /etc/tcp.smtp.tmp < /etc/tcp.smtp

If the rules don’t update, make sure -x /etc/tcp.smtp.cdb is after tcpserver in your start script, then restart Qmail.

Did you find this post useful or have questions or comments?  Please let me know!

The post How to update qmail relay rules first appeared on Brain Goo.

]]>
https://www.popmartian.com/tipsntricks/2008/08/20/how-to-update-qmail-relay-rules/feed/ 0
Qmail lacking features, view config https://www.popmartian.com/tipsntricks/2007/05/17/qmail-lacking-features-view-config/ https://www.popmartian.com/tipsntricks/2007/05/17/qmail-lacking-features-view-config/#respond Thu, 17 May 2007 18:10:07 +0000 http://www.popmartian.com/tipsntricks/2007/05/17/qmail-lacking-features-view-config/ /var/qmail/bin/qmail-showctl will show you the running config. Qmail does not allow you to restrict max recipients or max messages per session. I saw reference to a plugin to handle these controls, but do not know the name of it. You … Continue reading →

The post Qmail lacking features, view config first appeared on Brain Goo.

]]>
/var/qmail/bin/qmail-showctl will show you the running config.

Qmail does not allow you to restrict max recipients or max messages per session. I saw reference to a plugin to handle these controls, but do not know the name of it.

You can restrict max message size in /va/qmail/control/databytes

Example:

$ cat /var/qmail/control/databytes
10485760

That’s a 10MB limit

Adverts:
The qmail Handbook
qmail
Running qmail

The post Qmail lacking features, view config first appeared on Brain Goo.

]]>
https://www.popmartian.com/tipsntricks/2007/05/17/qmail-lacking-features-view-config/feed/ 0
Qmail SMTP routes, single route https://www.popmartian.com/tipsntricks/2007/05/16/qmail-smtp-routes-single-route/ https://www.popmartian.com/tipsntricks/2007/05/16/qmail-smtp-routes-single-route/#respond Wed, 16 May 2007 19:29:44 +0000 http://www.popmartian.com/tipsntricks/2007/05/16/qmail-smtp-routes-single-route/ Qmail smtproutes can only handle one route per egress domain name. Example: example1.com:10.0.0.1 example1.com:10.0.0.2 Will send mail only to 10.0.0.1 The second entry will be ignored. You are better off using round-robin DNS or submitting a patch to handle priority … Continue reading →

The post Qmail SMTP routes, single route first appeared on Brain Goo.

]]>
Qmail smtproutes can only handle one route per egress domain name.

Example:

example1.com:10.0.0.1
example1.com:10.0.0.2

Will send mail only to 10.0.0.1 The second entry will be ignored.

You are better off using round-robin DNS or submitting a patch to handle priority routing.

Adverts:
The qmail Handbook
qmail
Running qmail

The post Qmail SMTP routes, single route first appeared on Brain Goo.

]]>
https://www.popmartian.com/tipsntricks/2007/05/16/qmail-smtp-routes-single-route/feed/ 0