Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

qmail rcpthosts and ip addresses

Status
Not open for further replies.

cgonan

MIS
Feb 23, 2005
39
US
We use an outside spam service to filter spam, which our MX record points to. For inbound mail, we do not have that restriction. The Spam company wants us to specify which IP addresses to accept mail from. I belive this is to be done in the rcpthosts file, although it looks like the format only accepts host.domain name.

Can IP addresses be used in that file? If not, can wildcard entries be used because all their mail servers end with .something.com.

Thanks
 
Typically the outside service would named by IP(s) in your tcp.smtp file as allowed to relay mail coming from the outside world through them and into your server.

rcpthosts is used to specify domains for which your server is the mail host (final destination or authorized pass-through).

D.E.R. Management - IT Project Management Consulting
 
I don't know if I explained correctly. I only want to accept mail on port 25 from the IP address for their servers.

If I put IPs in that file, do I have to rebuild a DB or something, and if so, how.

Thanks so much.
Christine
 
Your tcp.smtp file is recompiled by issuing

"qmailctl cdb"

tcp.smtp contains a few kinds of entries:

# replace ip.ip.ip.ip to forbid this host from attaching to port 25
ip.ip.ip.ip:allow,RBLSMTPD="-Connections from this IP have been banned."

# replace ip.ip.ip.ip to allow the trusted host (your spam service) to relay mail into your server without authentication for subsequent delivery either locally or to another server
ip.ip.ip.ip:allow,RELAYCLIENT="",RBLSMTPD=""

# typically you always allow localhost to relay without authentication
127.0.0.1:allow,RELAYCLIENT="",RBLSMTPD=""


The RBLSMTP references exist because I have applied a patch that enables that test and response. You need to focus upon the RELAYCLIENT value.


D.E.R. Management - IT Project Management Consulting
 
Thanks for the info.

You mention a patch, but how do I know I have the version with the patch? The installation (performed by my coworker) was a qmailrocks installation.

Does anything need to be put between the "" in RELAYCLIENT or is that left as ""?

Can I put as many lines as I want into this file? The service provider has many servers so there will be many different IPs.

You have been very helpful.
 
qmailrocks DOES implement the needed patch

Yes, leave quote-quote as "" to ALLOW unauthorized relaying.

Yes, I've heard of tcp.smtp containing a few thousand lines.

D.E.R. Management - IT Project Management Consulting
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top