LinuxQuestions.org
Help answer threads with 0 replies.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Server
User Name
Password
Linux - Server This forum is for the discussion of Linux Software used in a server related context.

Notices


Reply
  Search this Thread
Old 08-11-2010, 05:22 AM   #1
alanoco79
LQ Newbie
 
Registered: Feb 2010
Posts: 21

Rep: Reputation: 0
Question How to set Sendmail to allow authenticated relay


I have a CentOS server, and am using Sendmail to relay for various domains. However, I also need to have users send their outgoing mail via this server. I want to have them enter a username and password in Outlook, Thunderbird, etc in their smtp server settings. I currently have this set up via an Exchange server, but I cannot get it to work with Sendmail. I know little about Sendmail, and have done all the config via Webmin, which has worked fine as far as relaying domains. But even though I have added the CentOS user account for the smtp relaying, the clients mail apps give an error saying relaying denied.
Anyone know what I might have missed?
 
Old 08-11-2010, 05:32 AM   #2
linuxlover.chaitanya
Senior Member
 
Registered: Apr 2008
Location: Gurgaon, India
Distribution: Cent OS 6/7
Posts: 4,638

Rep: Reputation: Disabled
If I can understand correctly, I think you want SMTP authentication in Sendmail. You can do that here via smtp_auth.
Here:
http://www.madboa.com/geek/sendmail-auth/
 
Old 08-11-2010, 05:40 AM   #3
alanoco79
LQ Newbie
 
Registered: Feb 2010
Posts: 21

Original Poster
Rep: Reputation: 0
I'm not sure if that is what I need. I only need authentication for individual users who are sending mail. But, if that article is what I need, it is too technical for me. I need to be able to set it up from Webmin. Also, I do not need ssl connections enabled, just smtp authentication for users. Is there an EASY way to do this?
 
Old 08-11-2010, 05:47 AM   #4
linuxlover.chaitanya
Senior Member
 
Registered: Apr 2008
Location: Gurgaon, India
Distribution: Cent OS 6/7
Posts: 4,638

Rep: Reputation: Disabled
I do not know. Will need to install webmin and test it.
 
Old 08-11-2010, 05:52 AM   #5
linuxlover.chaitanya
Senior Member
 
Registered: Apr 2008
Location: Gurgaon, India
Distribution: Cent OS 6/7
Posts: 4,638

Rep: Reputation: Disabled
You can do that. In webmin option for sendmail, there is this option called Network Ports or something. There is an option Require authentication. You can tick the check box and restart the sendmail service.
 
Old 08-11-2010, 06:11 AM   #6
alanoco79
LQ Newbie
 
Registered: Feb 2010
Posts: 21

Original Poster
Rep: Reputation: 0
I have tried that, but it doesn't solve the problem. Mail client still gets error 530 5.7.0 authentication required.

In any case, with this enabled, surly ALL incoming mail connections would need authentication, including ail being delivered from other servers?
 
Old 08-11-2010, 06:15 AM   #7
linuxlover.chaitanya
Senior Member
 
Registered: Apr 2008
Location: Gurgaon, India
Distribution: Cent OS 6/7
Posts: 4,638

Rep: Reputation: Disabled
Is this not what you want? You need to authenticate to send and receive mails. And this is what you want? Or am I missing something?
 
Old 08-11-2010, 07:12 AM   #8
alanoco79
LQ Newbie
 
Registered: Feb 2010
Posts: 21

Original Poster
Rep: Reputation: 0
The server is the MTA for several mail domains, so it needs to accept email from any domain when the destination email is to one of my mail domains. but it also is the relay for my mail clients, so has to accept mail from those users (i.e. from Outlook) going to any domain. I have already configured the incoming mail: it accepts any mail for my mail domains and sends them to the internal mail server. But it does not accept mails from my cleints trying, for example, to reply to the mails they receive. I need sendmail to process these emails and send them to their destinations. But I do not want to make it an open relay, for obvious reasons, so I want the users mail client to authenticate with Sendmail to send mails. That is the part that is not working.
 
Old 08-11-2010, 07:17 AM   #9
linuxlover.chaitanya
Senior Member
 
Registered: Apr 2008
Location: Gurgaon, India
Distribution: Cent OS 6/7
Posts: 4,638

Rep: Reputation: Disabled
Quote:
Mail client still gets error 530 5.7.0 authentication required.
This means authentication part is working? Is not it? And if authentication is enabled, it will be enabled for the server so for every domain it hosts. And every user on every domain. And the error that you posted says that authentication is working.
Or am I still missing something.
 
Old 08-11-2010, 07:53 AM   #10
alanoco79
LQ Newbie
 
Registered: Feb 2010
Posts: 21

Original Poster
Rep: Reputation: 0
If I select 'require authentication' in network ports, then external mail servers cannot send mail to my domains. But even with this option on, the Outlook users still get the 'authentication required' error, even though authentication is configured in Outlook.
I need sendmail to accept mail destined for my domains (specified in 'relay domains'), and require authentication for all other domains. All this is do-able with a couple of mouse clicks in MS Exchange; I need to do the same with Sendmail.
 
Old 08-11-2010, 08:30 AM   #11
linuxlover.chaitanya
Senior Member
 
Registered: Apr 2008
Location: Gurgaon, India
Distribution: Cent OS 6/7
Posts: 4,638

Rep: Reputation: Disabled
Require authentication option will only be used if your server is used as a relay. Other servers should not be asked for authentication. Did not see much of webmin. Will see if I can help you further tomorrow.
 
Old 08-12-2010, 04:31 AM   #12
alanoco79
LQ Newbie
 
Registered: Feb 2010
Posts: 21

Original Poster
Rep: Reputation: 0
Yes, but this server IS a relay. Mails from the Outlook clients need to be relayed to the external mails servers of the recipients, and incoming user mails are to be relayed to the internal server (MS-Exchange). This could all be done by the Exchange server on its own, the reason I have the Sendmail server is to provide security by not having Exchange exposed directly to the internet, and to use SpamAssassin to filter the incoming mail.
 
Old 08-12-2010, 04:58 AM   #13
linuxlover.chaitanya
Senior Member
 
Registered: Apr 2008
Location: Gurgaon, India
Distribution: Cent OS 6/7
Posts: 4,638

Rep: Reputation: Disabled
What you suggest you are trying to do is quite different from what I assumed you were trying. If you enable authentication, then obviously every relay will need to be authenticated. But this scenario of yours is different from what I thought. Are your internal clients directly relaying from your sendmail? Else you could disable authentication on external sendmail and keep authentication on exchange and let your clients connect to exchange rather than sendmail. And then relay all the outgoing emails to sendmail from exchange.
 
Old 08-12-2010, 05:47 AM   #14
alanoco79
LQ Newbie
 
Registered: Feb 2010
Posts: 21

Original Poster
Rep: Reputation: 0
Yes, I could use Exchange for the relay of internal clients email, but as many are often roaming, I would need to open Exchange to the outside to allow this for those cleints. I'd prefer to use Sendmail for this purpose, for better security.
 
Old 08-12-2010, 06:21 AM   #15
linuxlover.chaitanya
Senior Member
 
Registered: Apr 2008
Location: Gurgaon, India
Distribution: Cent OS 6/7
Posts: 4,638

Rep: Reputation: Disabled
Okay. Will have to read about it. And wait for more experienced people to put light on it. Because I always thought, relaying is done by the server and if you want authentication it would be server wide.
And if you are looking for smtp authentication, then why do you even want to have Excahnge server in there. Let sendmail do that. So all your clients will go through sendmail and will have their mail boxes right there. That would simplify it. Then authentication will not be an issue.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Need to set up Sendmail Relay for a remote IP net-wolf Solaris / OpenSolaris 1 07-10-2009 07:21 AM
postfix: only accept relay mail from authenticated users eantoranz Linux - Server 3 10-04-2008 04:02 AM
Sendmail authenticated relay lynx81191 Linux - Server 2 06-07-2008 09:54 AM
disable sendmail relay check for authenticated users sunethj Linux - Server 0 08-14-2007 11:05 PM
Configure sendmail to *use* authenticated SNMP relay? TotalDefiance Linux - Software 1 11-22-2005 09:37 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Server

All times are GMT -5. The time now is 08:09 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration