Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game. |
Notices |
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
Are you new to LinuxQuestions.org? Visit the following links:
Site Howto |
Site FAQ |
Sitemap |
Register Now
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
|
 |
09-08-2003, 11:00 AM
|
#1
|
LQ Newbie
Registered: Sep 2003
Posts: 3
Rep:
|
Allowing an IP to send email using my email server...
I feel like such a newbie, but I gotta ask... I've got a Linux box acting as our work email server. I have a home user with a static IP address. This home user cannot open his email client and send email using my email server as the SMTP server because his connection to the Internet is an IP address that my server will not accept. I thought this was a hosts.allow issue, but cannot seem to get it working no matter what I do. I know it's got to be something simple, but I'm obviously missing it. Please give me some direction. Thx!
|
|
|
09-08-2003, 01:54 PM
|
#2
|
Moderator
Registered: Mar 2003
Location: Scotland
Distribution: Slackware, RedHat, Debian
Posts: 12,047
Rep:
|
Welcome to LQ.
It could be a firewall issue:
iptables -L
If the machine itself isn't connected to the net you amy need to forward port 25 from the device with the public ip to the address of the mail server.
|
|
|
09-08-2003, 02:48 PM
|
#3
|
Member
Registered: Jul 2001
Location: Earth
Posts: 164
Rep:
|
what you can do is in /etc/mail/access
put the ip, and relay, or accept
Then do makemap hash /etc/mail/access.db < /etc/mail/access
Then your mail server will know what to do when it gets mail from him..... THIS ONLY WORKS IF YOUR USERS EMAIL ADDRESS IS NOT FROM YOUR DOMAIN.....
I think you need to have your remote user go over his email settings.... as long as he has an account on your mail server, then sendmail really shouldn't care what IP he is connecting with, its the user name and authentication that'll let him in.
|
|
|
09-08-2003, 03:14 PM
|
#4
|
LQ Newbie
Registered: Sep 2003
Posts: 3
Original Poster
Rep:
|
Reading over the replies I discovered my original post was not a thourough description of the problem. My home user has an Internet connection through COMCAST.NET. He takes his work laptop home and checks his work email fine (ex. work email = WORKEMAIL.COM) and he can reply to anyone within that same domain (ex. joe@workemail.com & susan@workemail.com) using his normal work email settings. The problem arises when he recieves and email from someone outside of the work domain and tries to reply to them (ex. jim@somewhereelse.com) because our email server does not allow relaying. Hope that makes better sense. I've not quite worked through the first replies, but I hope I made the question clearer for future replies. Thx again!
|
|
|
09-08-2003, 03:18 PM
|
#5
|
Moderator
Registered: Mar 2003
Location: Scotland
Distribution: Slackware, RedHat, Debian
Posts: 12,047
Rep:
|
Take a look at:
/etc/mail/access
You can setup a relay for the users IP in there.
|
|
|
09-09-2003, 10:55 AM
|
#6
|
LQ Newbie
Registered: Sep 2003
Posts: 3
Original Poster
Rep:
|
Looks like /etc/mail/access was the fix. I did, however, run into another problem. His IP is not static, it's "persistent"... meaning it stays the same for a few months. So, rather than changing the relayed IP in the future can I just place his email address in the file with RELAY next to it? I planned to try this, but is that going to work?
|
|
|
09-09-2003, 11:08 AM
|
#7
|
Senior Member
Registered: Nov 2001
Location: Budapest, Hungary
Distribution: SuSE 6.4-11.3, Dsl linux, FreeBSD 4.3-6.2, Mandrake 8.2, Redhat, UHU, Debian Etch
Posts: 1,126
Rep:
|
We accidentally did the same, and it worked. We had a line:
foo.bar RELAY
in /etc/mail/access, and some notebooks configured to be in domain foo.bar can send mail from here and from home, too.
Strangely enough, so far no spammers tried to relay though our mail server pretending he sends his mail from our domain - though that would be a handy idea.
Based on my experiences, I think one can allow relaying based on domain name, but things may change...
I wonder if it is possible to specify an IP address range in /etc/mail/access? It would be still better.
Last edited by J_Szucs; 09-09-2003 at 11:12 AM.
|
|
|
09-09-2003, 01:24 PM
|
#8
|
Moderator
Registered: Mar 2003
Location: Scotland
Distribution: Slackware, RedHat, Debian
Posts: 12,047
Rep:
|
Yes you can use ip addresses. Although I haven't tried it I would anticipate dynamic dns addresess working equally well too.
|
|
|
All times are GMT -5. The time now is 09:44 AM.
|
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.
|
Latest Threads
LQ News
|
|