LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Home Forums Tutorials Articles Register
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 03-18-2011, 05:47 PM   #1
kungfur@mone
Member
 
Registered: Jul 2010
Location: California, USA
Distribution: Debian.
Posts: 35

Rep: Reputation: 1
SSH, Radius, Passwords, and PAM


At my workplace, we're running freeradius on a Ubuntu server to authenticate our Cisco equipment (which works great.) We're now trying to use the same server to authenticate our other Linux servers as well, so that we can use the radius server as a centralized user repository and log access attempts.

I have a test server which is setup as a radius client. In other words: client SSH's to test server, which sends a radius authentication request to the radius server, which sends approval, and the client logs on to the test server.

The problem has to do with passwords: this only works if there is a local user account on the test server with the same password as exists on the radius server.

What I want to do here is have it set up so that if the radius server approves the connection, the user is logged in on the target system, even if the passwords don't match.

The references I've found online suggest having the local user account setup with a blank password, but I manually edited /etc/shadow and deleted the (encrypted) password for a test user and it didn't make a difference.

/etc/pam.d/sshd contains:

Code:
auth	required	pam_radius_auth.so
auth       required     pam_env.so
I haven't changed anything in /etc/pam.d/

To sum up: does anyone know how to set it up so that any user approved by radius to complete the ssh session can log in, regardless of the local user password?

Any suggestions are most appreciated! TIA.
 
Old 03-22-2011, 11:38 AM   #2
kungfur@mone
Member
 
Registered: Jul 2010
Location: California, USA
Distribution: Debian.
Posts: 35

Original Poster
Rep: Reputation: 1
Well, I figured this out over the weekend, so I thought I'd post for the benefit of anyone else trying to do this.

The trick is commenting out "@include common-auth" in /etc/pam.d/sshd:

Code:
#@include common-auth
That means that the system will not check against the local password database; if radius says the user is in, he or she is in.

Hopefully that's helpful to someone else down the road....
 
  


Reply



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
pam radius authentication danieldinu Linux - Security 2 07-17-2009 01:56 PM
Radius PAM.D Module interpol Linux - Security 5 02-27-2007 03:29 AM
PAM Radius Module interpol Linux - Networking 1 02-23-2007 09:37 AM
PAM Radius Module interpol Linux - Security 1 02-23-2007 09:29 AM
pam radius auth in slackware ?? Barx Slackware 1 04-30-2005 08:06 AM

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

All times are GMT -5. The time now is 10:15 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