Talk:Ed's FreeBSD Virtual Mail How-To
From Wistful.net
This is the discussion page for the virtual mail how-to. Here you can add notes and comments. Please click on the + (plus symbol) next to the edit link along the top of the page so you can add an individual comment instead of editing the entire discussion page.
When pasteing code, try to make sure it starts with one or more blank lines (including those lines which otherwise contain no text) so that it is placed in a nice preformatted block. If you want to make an ordered list, make your lines start with a # (pound), and use a * (star) for unordered lists. Remember to use the preview function.
[edit] imapd.conf -- possible benign config error
I was fiddling around, trying to figure out how to get imapd to accept logins from remote hosts.
I went thru the /usr/local/etc/imapd.conf file and tried to mess with
loginrealm =
I commented it out and everything continued to work as before. In fact, the comment to it reads as follows:
# The list of remote realms whose users may log in using cross-realm # authentications. Seperate each realm name by a space. This option is # only used when the server is compiled with Kerberos authentication. # #loginrealms: obitori.net
Based on the above, it seems to me that this variable is only for use if you have kerberos, so I think it should be dropped from your How-To.
Thanks for the document. I am having a lot of fun using squirrelmail.
Bud
[edit] command line "mail" bypassing authentication?
Hey Ed,
This article of yours saved us days. Was wondering if you, or anyone else, after having done these steps found the command line "mail" program bypassing or achieving verification falsely?
mail bogususer@domain.com (etc)
The above generates an email that is handed off to cyrus and once cyrus has been handed to by the MTA it creates the mailbox for this user as it assumes the user is valid. Even though there is no entry in the SQL tables for this user.
So we did a review of the .cf files:
postmap -q validuser@domain.com mysql:/usr/local/etc/postfix/mysql_virtual_mailbox_maps.cf
and get a valid response back. (validuser@domain.com) . Checked the other conf files through similar commands.
So then we telnet'ed in to postfix on port 25 and create a mail header to bogususer2@domain.com. blam. It is refused and NOT passed off to cyrus. Which is what is supposed to happen. So our problem appears to only be when sending mail from the command line or using CGI/PHP.
PROBLEM DEFINED: It appears that postfix is behaving as designed. Sendmail does not validate users but leaves it to the delivery agent (cyrus) to verify users. But the patch installed creates mailboxes for any users that don't exist. Only SMTPD appears to validate users exists before accepting receipt.
FIX: We installed AMAVISD-NEW port and configured as specified in INSTALL directions from AMAVSID. Problem has been fixed. The mail is now handed off to amavisd which hands it back to SMTPD which validates local address before handing it off to CYRUS. And we get virus protection to boot with clamav! NOTE: We had to change the following code:
Amavisd recommends the following line in your master.cf
-o receive_override_options=no_header_body_checks,no_unknown_recipient_checks
We changed this to
-o receive_override_options=no_header_body_checks
And it's working great.
Sean Howard
sean_at_spinglobe.com
[edit] Relay Access Denied for External Delivery
I followed these instructions for setting up an email server, the best article on the net by the way. I have used these instructions to setup a few servers, but each time I get stuck at one point and give up. In this example, say the new server has the domain setup on it, and in this example I have 1234myaccount.com pointed to it.
If I use Outlook via Pop3, I can....
- receive emails from external accounts, example: pete@yahoo.com -to- joe@1234myaccount.com.
- download new emails to Outlook via pop3. Example: Receive the new email from pete@yahoo.com)
- Send emails to local accounts, example: sally@1234myaccount.com -to- joe@1234myaccount.com
But, I can not send emails to external accounts? Example: joe@1234myaccount.com -to- pete@yahoo.com
Here is a log sample:
Feb 4 00:06:50 mail1server postfix/smtpd[22919]: NOQUEUE: reject: RCPT from pool-11-111-444-11.lsanca.verizon.net[22.222.222.22]: 554 5.7.1 <myaccounttest_hh1@yahoo.com>: Relay access denied; from=<test@1234myaccount.com> to=<myaccounttest_hh1@yahoo.com> proto=ESMTP helo=<thecomp001>
Any help from anyone is greatly appreciated.
Possible solution / hint: It sounds like Outlook is not configured to authenticate with Postfix. Perhaps I should add a how-to on configuring Outlook, etc., for that, but there are many other how-to's out there for that already. -Ed