Unix Formula - UNIX Pro

Get the latest news and get the most out of Unix.


Recent Stories...
Alfresco, MySQL and Red Hat Deliver First Open Source JSR-170 Benchmark

8 December 2006

OpenLogic Expert Community Successfully Brings Together Open Source Community and Enterprise Users

7 December 2006

Jive Software Launches IgniteRealtime.org Website in Response to Explosive Community Support for Its Open Source EIM Products

7 December 2006

CA Advances Virtual Platform Management With Newest Release of Unicenter ASM

5 December 2006

Vonage Selects EnterpriseDB

5 December 2006

Communications Platforms Trade Association Adds Three Members

5 December 2006

AccessIT's Christie/AIX Deployment Program Hits Average Monthly Screen Installs of 266

5 December 2006

Liberty Alliance Announces 'Open Source Identity for the Web 2.0 Era' Webcast November 29

5 December 2006

VA Software Reports First Quarter Fiscal 2007 Results

5 December 2006

Leading Telco Carriers Tout Versatility of Sun Microsystems' Java(TM) System Content Delivery Server

5 December 2006

XBRL Enhances Performance Management Applications and Offers Immediate External Benchmarking Business Benefits

5 December 2006

Azul Systems Gains Major Market Support for Its Approach to Delivering Business Critical Java Solutions

5 December 2006

DigitalFX International, Inc. Announces Q4 '06 and Full Year '06 Revenue Guidance, as Well as Initial 2007 Revenue and Margins Guidance

5 December 2006

$0 Net Cost Promotion With Sprint Activation for CDU-550 Mobile Broadband USB Modem Supporting Windows, Windows Mobile, Linux, Mac Systems

4 December 2006

Acronis Joins Red Hat ISV Partner Program; Becomes Red Hat Ready Partner

4 December 2006

Future Media Concepts Targets IT Professionals and Systems Administrators with New Mac OS X Training Options

2 December 2006

OSDL Mobile Linux Initiative Gains Another Heavy Hitter

2 December 2006

Trusted Computer Solutions' Cross Domain Linux Product Now Part of Accredited System at U.S. Coast Guard

29 November 2006

Xandros Desktop - Professional Spearheads New Line of Enterprise Linux Management Solutions

29 November 2006

AIX Group, Inc. Names Peter Soloway Vice President of Program Business Development

29 November 2006

Novell Launches First 'Desktop-to-Data Center' Management Solutions That Deliver on Interoperable, Cross-Platform Vision

29 November 2006

HPC4U Fault Tolerant Middleware - Open Source Version Released

29 November 2006

Unisys Predicts 2007 Open Source Trends: Architectural Approaches and Specialized Stacks Will Dominate

29 November 2006

MapGuide Open Source and Autodesk Mark Record Downloads in First Year

29 November 2006

Novell Launches First 'Desktop-to-Data Center' Management Solutions That Deliver on Interoperable, Cross-Platform Vision

29 November 2006

Report: IBM #1 in Global Server Revenue, Blades and UNIX in 3Q 2006

29 November 2006

University-Built Election System Raises Bar and Released Open Source

29 November 2006

Montilio and Open Source Systems to Provide Fastest File Servers Available on the Market

29 November 2006

IBM Open Source Application Server Gains Support of More Than 600 Partners in Six Months

29 November 2006

Report: IBM Open Source-Based Application Server Growing Nearly Three Times Faster Than JBoss

24 November 2006

Sun Open Sources Java Platform and Releases Source Code Under GPL License Via NetBeans and Java.net Communities

23 November 2006

IBM Introduces Linux and Grid Implementation Service Products

22 November 2006

Internet Systems Consortium Turns to Sun's Solaris(TM) 10 Operating System and Sun Fire(TM) x64 Servers to Power the Internet

18 November 2006

Novell Announces Amendment and Extension of Consent Solicitation

18 November 2006

Microsoft and Novell Announce Broad Collaboration on Windows and Linux Interoperability and Support

15 November 2006

Novell Releases Mono 1.2 With Enhanced Support for .NET on Linux

15 November 2006

The Sage Group plc Announces Global Partnership With MySQL AB

15 November 2006

Linux Networx Announces Performance Tuned Supercomputing

15 November 2006

XenSource Announces High Performance Virtualization of Microsoft Windows and Linux Based on the Xen(TM) Hypervisor

15 November 2006

vtiger Upgrades its Enterprise-class Open Source CRM Solution With New Features

15 November 2006


Archive
April 2007
February 2007
January 2007
December 2006
November 2006
October 2006
September 2006
August 2006
July 2006
June 2006
May 2006
April 2006
March 2006
February 2006
January 2006
December 2005
November 2005
October 2005
September 2005
August 2005
July 2005
June 2005
May 2005
April 2005
March 2005
February 2005
January 2005
December 2004
November 2004
October 2004
September 2004
August 2004


Unix Formula - UNIX Pro RSS Feed
RSS Feed

We support:

Linux Intrusion Detection System
Linux Gazette



 

Linux-Windows Single Sign-On

1 January 1970

A Modest Proposal
With this in mind, I set out to accomplish what I considered to be a fairly straightforward goal: Configure the Linux desktops and servers in my office to accept logins using accounts stored in AD. My metrics for success were relatively modest. I wanted to sit down at a Linux desktop, enter a set of Windows credentials, and get a KDE or Gnome desktop with a home directory that has appropriate access permissions.

Achieving this goal turned out to be a bit more challenging than anticipated. After spending lots of time reading through docs and chasing down hints and configuration snippets, I finally found the right combination of settings for all the different Linux flavors in my lab. The results were gratifying, though. I had seamless authentication with AD that could be used for initial login, file sharing, secure shell (ssh) and other network services.

To save you a little time in case you decide to give this interoperability experiment a try, I put together notes and screen shots that show how to configure AD authentication for Fedora Core 2 (and the Core 3 beta). To see examples and instructions for these other Linux flavors: SuSE Linux 9.1 Professional, Mandrake 10.1 and Xandros Desktop 2.5, visit my Web site at www.billboswellconsulting.com/linux-ad.html.

If you're a bottom-line kind of person, here's a quick summary. Xandros 2.5 has the slickest AD configuration of the bunch. Mandrakelinux and Fedora are fairly simple once you know where to add a few settings. SuSE required the most work, but Novell should have this corrected in Novell Linux Desktop.

In the examples here, I used a Windows Server 2003 domain called Company.com, flat name COMPANY. I retained the default Windows 2003 security settings, including SMB signing, LDAP signing and anonymous logon restrictions. I set the domain and forest functional level to Windows Server 2003 and left the Authentication Users group in Pre-Windows 2000 Compatible Access, the default Windows 2003 setting.

I installed Fedora Core 2 with the Workstation package options. During setup, I assigned a unique computer name of Fedora.company.com. Following the installation, I updated all packages using Yum, the Yellowdog Updater, Modified. (Other Linux flavors use different package managers.)

Initial Configuration
Regardless of Linux flavor, you'll work with the same elements when configuring AD authentication:

Name Service Switch (NSS): This is a set of capabilities built into the Linux C libraries that allow an application to select a source to validate authentication credentials.
Pluggable Authentication Modules (PAM): This extends the standard Unix password authentication mechanism to include central authentication databases such as LDAP, Kerberos, AD and so on.
Winbind with Samba: The winbind service uses Samba for configuration information. For AD interoperability, make sure your system is running a current version of Samba (3.05 or newer).
Kerberos: Winbind uses Kerberos to get tickets for accessing AD. A Windows domain controller acts as the Key Distribution Center (KDC).
To configure winbind in Fedora, launch the authconfig utility as superuser (root). Fedora has a GUI utility—system-config-authentication—but it doesn't make all the required configuration settings.
Check the Use Winbind option, then click Next. The Winbind Settings screen opens. Fill in the following settings (the entries you make in this screen aren't case sensitive):

Security Model: ADS
Domain: flat (NetBIOS) name for the domain (COMPANY)
Domain Controllers: Fully Qualified Domain Name (FQDN) for a domain controller (dc1.company.com)
ADS Realm: FQDN for the domain (company.com)
Template Shell: /bin/bash
There's a Join Domain option, but don't select it. It might not work, and you won't get sufficient feedback to help resolve problems. For now, just click OK to save the changes you just entered.

When the authconfig window closes, the console window should show that winbind starts. If this fails, try starting the service manually with the following command:

/etc/init.d/winbind start

If winbind starts, it will appear on a ps process list like this:

# ps -A | grep winbind
3132 ? 00:00:00 winbindd
3133 ? 00:00:00 winbindd

If you get an error, search the Internet with the error message. It may take a while, but nearly always someone with a similar error will have posted a solution.

Configuration Files
Authconfig makes changes to three configuration files. Listings 1-3 show their contents, with comments and irrelevant information removed.

nsswitch (/etc/nsswitch.conf): The critical entries are passwd and group. Other Linux flavors don't bother assigning winbind to other services.
system-auth (/etc/pam.d/system-auth): PAM uses a stackable authentication scheme, and each element in the stack must be separately configured. Thankfully, authconfig does a good job of setting up system-auth. Otherwise, you have to do quite a bit of experimenting.
smb.conf (/etc/samba/smb.conf): The idmap entries are important because winbind uses them to maintain a correspondence between AD account names and the User IDs and Group IDs used by Linux. Fedora assigns a large range of potential IDs. Typically, other Linux flavors assign a range of 10000-20000.
Also, in smb.conf, note the home directory path inserted by authconfig, /home/%D/%U. A user, call him winuser1, from an AD domain, call it company.com, would get a home directory path of /home/COMPANY/ winuser1. Authconfig does not create the domain folder under /home. You must create it manually.

Joining an AD Domain
You can now join the Linux workstation to the AD domain using the Linux net command. Here's the syntax, with everything after the first line generated by net:

# net ads join -U administrator
administrator's password:
Using short domain name -- COMPANY
Joined 'FEDORA' to realm 'COMPANY.COM'

You'll see many different syntax examples for net ads if you browse the Internet. My example shows the bare minimum, which is all you really need.

Configure PAM
At this point, a Windows user trying to authenticate at the Linux desktop would get a series of errors because a local home directory isn't present. A PAM module—mkhomedir.so—automatically creates a home directory. To include this module as part of the login process, change two configuration files under /etc/pam.d (see Listings 4 and 5):

login: This file controls authentication from a console prompt.
jgdm: This file controls login from a graphical screen.
Always make copies of the original files before changing PAM files. You can lock yourself out of a system if you aren't careful.

After changing the PAM files, restart the desktop. This is a quick way to ensure that authconfig made the correct boot settings for the required services.

At the login window following restart, Fedora prompts for a name. Enter the Windows account name in domain\user format, such as company\winuser1, then enter the password when prompted. (Other Linux flavors present a selection list of Windows accounts. The option to display a selection list is available in Fedora, but it is not the default setting.)

You can configure smb.conf so that you don't need to enter a domain name, which is fine if you have one AD domain but a little cumbersome if you have several.

At this point, when the login succeeds, you'll get an announcement about creating a home directory for the user. The permissions assigned to the home directory use the AD account of the user.

Rock On
If you can't get the steps to work, e-mail me with the particulars. This can be a finicky configuration, and you want to make sure you're in the right state of mind. During the testing I did for this column, I played Jeff Beck's album, You Had It Coming. I found track six, "Loose Cannon," especially good when setting PAM files.



Source: Redmond


All trademarks and copyrighted information contained herein are the property of their respective owners.


Related Articles


 
Telecom News
Voip News
Hardware News
Wireless News



A   B   C   D   E   F   G   H   I   J   K   L   M   N   O   P   Q   R   S   T   U   V   W   X   Y   Z