Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

related to mail servers, mta and mda

12 views
Skip to first unread message

H.S.

unread,
Apr 12, 2009, 9:00:19 PM4/12/09
to
Hello,

This is a beginner's (no experience with setting up mail servers) query
about MTA's and MUA's. I am trying to see if I can setup an mta or a
related application on my Debian machine which is being run as a router
for my home lan such that it can send email to an external email
address. It does not need to receive any public email at all.

I have already tried heirloom and I can send email to my gmail account
if I put my gmail log in info in my mail's conf file.

Now I am wondering if I can allow outgoing email (need to have port 25
open?) with no need nor requirement to receive any in coming email from
the WAN without having to use a particular email's log in info. The idea
is that email from that machine (and perhaps from lan machines) may be
sent to any valid email address with reply-to address changed to a fixed
email address.

Thanks.

--

Please reply to this list only. I read this list on its corresponding
newsgroup on gmane.org. Replies sent to my email address are just
filtered to a folder in my mailbox and get periodically deleted without
ever having been read.


--
To UNSUBSCRIBE, email to debian-us...@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listm...@lists.debian.org

Raquel

unread,
Apr 12, 2009, 10:20:10 PM4/12/09
to
On Sun, 12 Apr 2009 20:53:11 -0400
"H.S." <hs.s...@gmail.com> wrote:

> Hello,
>
> This is a beginner's (no experience with setting up mail servers)
> query about MTA's and MUA's. I am trying to see if I can setup an
> mta or a related application on my Debian machine which is being
> run as a router for my home lan such that it can send email to an
> external email address. It does not need to receive any public
> email at all.
>
> I have already tried heirloom and I can send email to my gmail
> account if I put my gmail log in info in my mail's conf file.
>
> Now I am wondering if I can allow outgoing email (need to have port
> 25 open?) with no need nor requirement to receive any in coming
> email from the WAN without having to use a particular email's log
> in info. The idea is that email from that machine (and perhaps from
> lan machines) may be sent to any valid email address with reply-to
> address changed to a fixed email address.
>
> Thanks.
>

I can give you a few suggestions, but email here won't be enough.
Read EVERYTHING you can find about mail servers. Think 3 or 4 times
about setting up your own mail server. The trouble is that if you
don't do things right, you can end up as an open relay. If you have
static IPs, you can end up having your server blacklisted. If you
have dynamic IPs, you may be blacklisted because of having dynamic
IPs, which may even happen for the same reason if you have static
IPs. Many ISPs won't let you run your own servers. Most "private
citizens" who set up servers, shouldn't.

Of course, you're free to do what you want.

--
Raquel
http://www.byraquel.com
============================================================
As nightfall does not come all at once, neither does oppression. In
both instances, there is a twilight. And it is in such twilight that
we all must be aware of change in the air ... however slight -lest we
become unwitting victims of the darkness.

--Justice William O. Douglas, US Supreme Court (-)

James Richardson

unread,
Apr 12, 2009, 11:50:08 PM4/12/09
to
H.S. wrote:
> Hello,
>
> This is a beginner's (no experience with setting up mail servers) query
> about MTA's and MUA's. I am trying to see if I can setup an mta or a
> related application on my Debian machine which is being run as a router
> for my home lan such that it can send email to an external email
> address. It does not need to receive any public email at all.
>
> I have already tried heirloom and I can send email to my gmail account
> if I put my gmail log in info in my mail's conf file.
>
> Now I am wondering if I can allow outgoing email (need to have port 25
> open?) with no need nor requirement to receive any in coming email from
> the WAN without having to use a particular email's log in info. The idea
> is that email from that machine (and perhaps from lan machines) may be
> sent to any valid email address with reply-to address changed to a fixed
> email address.
>
> Thanks.
>
>
I use Exim on my f/w on my router. It accepts email from all the nodes
on my home network and now forwards it to my mail server on my vps.
Previously, it forwarded mail through my isp. If I remember correctly
when sending mail through my isp the from header was always rewritten to
be from my isp email address.

If you have a static ip you may be able to send mail directly to
mailservers around the internet, however if you have a dynamic ip, it
will be blocked by most mailservers. Also your isp may block outbound
port 25 traffic. Mine just redirects all outbound port 25 traffic to
their mail servers. I get around this by having a vpn between my home
network and my vps.

I know you said you did not need to receive any incoming email, just be
sure to keep port 25 into your network closed.


--
James Richardson
Debian GNU/Linux Consultant
http://www.linkedin.com/in/jamesrichardsonconsulting
ja...@jamesr.biz

signature.asc

Tzafrir Cohen

unread,
Apr 13, 2009, 5:40:15 AM4/13/09
to
On Sun, Apr 12, 2009 at 11:20:13PM -0400, James Richardson wrote:

> I use Exim on my f/w on my router. It accepts email from all the nodes
> on my home network and now forwards it to my mail server on my vps.
> Previously, it forwarded mail through my isp. If I remember correctly
> when sending mail through my isp the from header was always rewritten to
> be from my isp email address.

That's what I do (though using postfix). I also connect to the vps
through an opnvpn tunnel. This means the configuration of the mail
server there remains simple. I likewise forward the mail from my laptop
through an openvpn tunnel to that server.

(Well, I already had that tunnel for other uses)

--
Tzafrir Cohen | tza...@jabber.org | VIM is
http://tzafrir.org.il | | a Mutt's
tza...@cohens.org.il | | best
ICQ# 16849754 | | friend

Douglas A. Tutty

unread,
Apr 13, 2009, 2:10:14 PM4/13/09
to
On Sun, Apr 12, 2009 at 08:53:11PM -0400, H.S. wrote:
> This is a beginner's (no experience with setting up mail servers) query
> about MTA's and MUA's. I am trying to see if I can setup an mta or a
> related application on my Debian machine which is being run as a router
> for my home lan such that it can send email to an external email
> address. It does not need to receive any public email at all.
>
> I have already tried heirloom and I can send email to my gmail account
> if I put my gmail log in info in my mail's conf file.
>
> Now I am wondering if I can allow outgoing email (need to have port 25
> open?) with no need nor requirement to receive any in coming email from
> the WAN without having to use a particular email's log in info. The idea
> is that email from that machine (and perhaps from lan machines) may be
> sent to any valid email address with reply-to address changed to a fixed
> email address.

I'd suggest that you use exim and use your isp's mail server as a
smarthost. When you install exim, the debconf questions will give you
this choice. You'll need the hostname of your isp's smarthost. Local
mail will be delivered locally, non-local mail will be sent to the
smarthost (with address rewriting so that it appears to the receiver as
coming from your public mail name (e.g. h...@example.com, rather than
hs@myhome). If you want to receive public mail, you'd use something
like fetchmail.

Unless you're running a firewall, you'll already have port 25 (all
ports) open. Installing an MTA will simply provide a server listening
to port 25. However, with the standard debconf smarthost, I don't think
it actually will be listening on your public IP, only on your localnet.

I'd further suggest that you install the doc-linux-howto (something like
that) package, probably in html format. You'll find lots of info,
including mail admin howto.

Doug.

H.S.

unread,
Apr 16, 2009, 3:20:11 PM4/16/09
to
H.S. wrote:
> Hello,
>
> This is a beginner's (no experience with setting up mail servers) query
> about MTA's and MUA's. I am trying to see if I can setup an mta or a
> related application on my Debian machine which is being run as a router
> for my home lan such that it can send email to an external email
> address. It does not need to receive any public email at all.
>
> I have already tried heirloom and I can send email to my gmail account
> if I put my gmail log in info in my mail's conf file.
>
> Now I am wondering if I can allow outgoing email (need to have port 25
> open?) with no need nor requirement to receive any in coming email from
> the WAN without having to use a particular email's log in info. The idea
> is that email from that machine (and perhaps from lan machines) may be
> sent to any valid email address with reply-to address changed to a fixed
> email address.
>
> Thanks.
>


Thanks everyone who responded.

I finally found a web page which answered all my questions, and then
some. The url is:
http://www.spencerstirling.com/computergeek/email.html

All I had to do was follow exim4's config prompts. I just had to specify
my ISP's smtp mail server as the smarthost I wanted to use. Apparently
my ISP does not require authentication on smtp to act as a smarthost. So
that was also quite convenient.

Since Exim4 uses encryption by default, I suppose I am okay in that
respect too.

I needed to make no changes in Exim4's config files. However, I did
need to make the changes to fix the From and Reply-To address for each
user (otherwise the sending domain would be localhost.localdomain)[].
But since I wanted only one user to use this email system (sending
emails to various users externally), it was not much of a problem. I
just put the right lines in .muttrc to fix it:
# Set your "From" information
set from="m...@some-email.com"
set use_from=yes
set use_envelope_from=yes


For mails sent out via scripts, I installed heirloom-mailx and used its
-r flag to fix the from address, like so:
$> echo "mail body" | mail -r m...@some-email.com -s "mail config with
exim4" toad...@some-email.com

Regards.

0 new messages