CIT 470: Advanced Network and System Administration

Slides:



Advertisements
Similar presentations
Managing User, Computer and Group Accounts
Advertisements

6. Adding New Users Xiang Sha Cmsc 691x. 6.1 The /etc/passwd File The /etc/passwd File is a list of users recognized by the system. Login name Encrypted.
Chapter One The Essence of UNIX.
Active Directory: Final Solution to Enterprise System Integration
IST346:  Namespaces  Directories  Documentation.
Chapter 4 Chapter 4: Planning the Active Directory and Security.
User Account Management WeeSan Lee. Roadmap Add An Account Delete An Account /etc/{passwd,shadow} /etc/group How To Disable An Account? Root Account Q&A.
70-290: MCSE Guide to Managing a Microsoft Windows Server 2003 Environment Chapter 1: Introduction to Windows Server 2003.
Linux+ Guide to Linux Certification, Second Edition
LDAP LIGHT WEIGHT DIRECTORY ACCESS PROTOCOL PRESENTATION BY ALAKESH APURVA DHAN AND ASH.
CIT 470: Advanced Network and System Administration
Chapter 11: Directory Services. Directory Services A directory service is a database that contains information about all objects on the network. Directory.
Directory services Unit objectives
SPARCS 10 이대근 (harry). Contents  Directory Service  What is LDAP?  Installation  Configuration  ldap-utils  User authentication with LDAP.
Guide to Linux Installation and Administration, 2e1 Chapter 8 Basic Administration Tasks.
Managing User Accounts. Module 2 – Creating and Managing Users ♦ Overview ► One should log into a Linux system with a valid user name and password granted.
Linux+ Guide to Linux Certification, Second Edition
Adding New Users User as an entity - username(UID), GID. UID - typically a number for system to identify the user. GID – a number that recognizes a set.
IT2204: Systems Administration I 1 6b). Introduction to Linux.
Scis.regis.edu ● CS 468: Advanced UNIX Class 2 Dr. Jesús Borrego Regis University 1.
DIT314 ~ Client Operating System & Administration CHAPTER 5 MANAGING USER ACCOUNTS AND GROUPS Prepared By : Suraya Alias.
Chapter 13 Users, Groups Profiles and Policies. Learning Objectives Understand Windows XP Professional user accounts Understand the different types of.
Unix System Administration Chapter 6 Adding New Users.
Active Directory Administration Lesson 5. Skills Matrix Technology SkillObjective DomainObjective # Creating Users, Computers, and Groups Automate creation.
Linux+ Guide to Linux Certification, Third Edition
Module 7 Active Directory and Account Management.
CIT 470: Advanced Network and System AdministrationSlide #1 CIT 470: Advanced Network and System Administration Accounts and Namespaces.
Implementing LDAP Client/Server System for Directory Service By Maochun Sun Project Advisor: Dr. Chung-E Wang Department of Computer Science California.
Managing Users  Each system has two kinds of users:  Superuser (root)  Regular user  Each user has his own username, password, and permissions that.
LDAP (Lightweight Directory Access Protocol ) Speaker: Chang-Yu Wu Adviser: Quincy Wu Date:2007/08/22.
Page 1 Active Directory and DNS Lecture 2 Hassan Shuja 09/14/2004.
Chapter 10: Rights, User, and Group Administration.
Chapter 3 & 6 Root Status and users File Ownership Every file has a owner and group –These give read,write, and execute priv’s to the owner, group, and.
Free Powerpoint Templates Page 1 Free Powerpoint Templates Users and Documents.
The Saigon CTT Chapter 10 Managing Users. The Saigon CTT  Objectives  Define the requirements for user accounts  Explain group and group accounts 
LDAP (Lightweight Directory Access Protocol)
Lecture – Users and groups
Linux Operations and Administration
Introduction to Active Directory
CSC414 “Introduction to UNIX/ Linux” Lecture 6. Schedule 1. Introduction to Unix/ Linux 2. Kernel Structure and Device Drivers. 3. System and Storage.
MCSE Guide to Microsoft Exchange Server 2003 Administration Chapter One Introduction to Exchange Server 2003.
Hussain Ali Department of Computer Engineering KFUPM, Dhahran, Saudi Arabia Active Directory.
Active Directory. Computers in organizations Computers are linked together for communication and sharing of resources There is always a need to administer.
CEG 2400 Fall 2012 Directory Services Active Directory Tree Domain.
Directory Services CS5493/7493. Directory Services Directory services represent a technological breakthrough by integrating into a single management tool:
1 Introduction to Active Directory Directory Services Uniquely identify users and resources on a network Provide a single point of network management.
Managing Users CSCI N321 – System and Network Administration Copyright © 2000, 2011 by Scott Orr and the Trustees of Indiana University.
Lightweight Directory Access Protocol Objectives –This chapter will first show you how to install and use LDAP Contents –The LDAP Database Structure –Scenario.
1 Directory Services  What is a Directory Service?  Directory Services model  Directory Services naming model  X.500 and LDAP  Implementations of.
LDAP Overview Kevin Moseley Server Team Manager Walgreen Co.
Chapter 17: Sharing System Files Stephen Workman.
Migrating to LDAP What is LDAP? Fedora Directory Server LdapImport
File System Implementation
Active Directory Replication (Part 1) Paige Verwolf Support Professional Microsoft Corporation © 1999 Microsoft Corporation. All rights reserved.
CIT 470: Advanced Network and System Administration
Introduction to LDAP Frank A. Kuse.
Introduction to Operating Systems
Chapter 11: Managing Users
Active Directory Administration
(ITI310) SESSIONS 6-7-8: Active Directory.
Active Directory Administration
Chapter 2 User Management
Implementation and configuration of LDAP
IS3440 Linux Security Unit 3 User Account Management
Adding New Users, Storage, File System
CIT 470: Advanced Network and System Administration
Introduction to Active Directory Directory Services
Adding New Users Chapter 6.
CIT 470: Advanced Network and System Administration
Adding New Users.
Presentation transcript:

CIT 470: Advanced Network and System Administration Accounts and Namespaces CIT 470: Advanced Network and System Administration

CIT 470: Advanced Network and System Administration Topics Namespaces Policies: selection, lifetime, scope, security User Accounts Directories LDAP CIT 470: Advanced Network and System Administration

CIT 470: Advanced Network and System Administration Namespaces A namespace consists of A set of unique keys A set of attributes associated with each key Example Key = Username Attributes GECOS Homedir Shell Password CIT 470: Advanced Network and System Administration

CIT 470: Advanced Network and System Administration Namespaces Systems include many namespaces User account names. E-mail addresses. Filesystem pathnames. Hostnames. IP addresses. Printer names. Service names. CIT 470: Advanced Network and System Administration

CIT 470: Advanced Network and System Administration Types of Namespaces Flat No duplicates may exist. Ex: usernames in /etc/passwd. Hierarchical Tree-structured namespace like DNS. Duplicates can exist. Ex: www.nku.edu and www.google.com CIT 470: Advanced Network and System Administration

CIT 470: Advanced Network and System Administration Namespace Problems How to select names? How to avoid name collisions? How to ensure consistency? How to distribute names? CIT 470: Advanced Network and System Administration

CIT 470: Advanced Network and System Administration Name Selection Functional Names mail hostname, /cit/470, student account Descriptive names geographic, print type, customer type Formula-based Names cvg0141 hostname, student0148 account Themed Names constellations (orion, ursa, etc.) No Standard CIT 470: Advanced Network and System Administration

CIT 470: Advanced Network and System Administration Name Lifetime When are names removed? Immediately after PC, user leaves org. Set time after resource is no longer in use. When are names re-used? Immediately: functional names. Never. After a set time: usernames, email addresses. CIT 470: Advanced Network and System Administration

CIT 470: Advanced Network and System Administration Namespace Scope Geographical scopes Local machine. (e.g., /etc/passwd.) Local network. Organization. Global (e.g., DNS.) Service scopes Single username for UNIX, NT, RADIUS, e-mail, VPN? Transferring scopes Difficult without advance planning. Some names may have to change. CIT 470: Advanced Network and System Administration

CIT 470: Advanced Network and System Administration Namespace Security What are you trying to protect names from and why? Do the names need to be protected or just the attributes? Who can add, change, or delete records? Can the owner of a record change fields within the record? CIT 470: Advanced Network and System Administration

Example Namespace: Usernames Selection policies Descriptive: waldenj, jwalden Decriptive + formulaic: waldenj1, jwalden0002 Scope Use for every campus (avoids collisions.) Use for every service (avoids collisions.) Lifetime Do not reuse until 1 year has passed since email addresses derive from usernames. CIT 470: Advanced Network and System Administration

CIT 470: Advanced Network and System Administration One Big Database Centralize namespace in one big database. Use SQL or LDAP to store entire namespace. Derive other namespaces from database. Program to generate UNIX accounts. Program to generate NT accounts. etc. Advantages Consistency Ease of making changes, additions, deletions. CIT 470: Advanced Network and System Administration

CIT 470: Advanced Network and System Administration User Account Types OS files UNIX /etc/{passwd,shadow} Windows SAM Network service NIS LDAP Kerberos Active Directory RADIUS CIT 470: Advanced Network and System Administration

CIT 470: Advanced Network and System Administration UNIX Accounts Account Components Username UID Password Home directory Account Files /etc/passwd /etc/shadow /etc/group Account Management Adding users Removing and disabling users Account/password policies CIT 470: Advanced Network and System Administration

CIT 470: Advanced Network and System Administration /etc/{passwd,shadow} Central file(s) describing UNIX user accounts. /etc/passwd Username UID Default GID GCOS Home directory Login shell /etc/shadow Username Encrypted password Date of last pw change. Days ‘til change allowed. Days `til change required. Expiration warning time. Expiration date. student:x:1000:1000:Example User,,555-1212,:/home/student:/bin/bash student:$1$w/UuKtLF$otSSvXtSN/xJzUOGFElNz0:13226:0:99999:7::: CIT 470: Advanced Network and System Administration

CIT 470: Advanced Network and System Administration Username Syntax Each username must be unique. Length limits (8 chars on old systems) Any character except : or \n. Issues Naming standards. How to ensure that usernames are unique? System uses UIDs internally. CIT 470: Advanced Network and System Administration

CIT 470: Advanced Network and System Administration UIDs UIDs are 32-bit non-negative integers. Standards Root is UID 0. System accounts have low UIDs (<= 500) Uniqueness Multiple usernames can have same UID! Re-using UIDs may give away files to new user. Distributed systems may require unique UIDs across organizational boundaries. CIT 470: Advanced Network and System Administration

CIT 470: Advanced Network and System Administration Password Syntax Length: unlimited (MD5,SHA1), 8 chars (crypt) Chars: anything except \n, though certain control chars may be interpreted by system. Stored in “encrypted” format. Hashed: crypt, MD5, SHA1 Salted: 12-bit salt means 4096 different hashes for each password CIT 470: Advanced Network and System Administration

CIT 470: Advanced Network and System Administration GID GIDs are 32-bit non-negative integers. Each user has a default GID. File group ownership set to default GID. Temporarily change default GID: newgrp. Groups are described in /etc/group Users may belong to multiple groups. Format: group name, pw, GID, user list. wheel:x:10:root,waldenj,bergs CIT 470: Advanced Network and System Administration

CIT 470: Advanced Network and System Administration GECOS Original use Data for General Electric Comprehensive OS Current use User information. Full name, location, phone number, e-mail. CIT 470: Advanced Network and System Administration

CIT 470: Advanced Network and System Administration Home Directory User’s CWD at login time. Typically where user stores all files. CIT 470: Advanced Network and System Administration

CIT 470: Advanced Network and System Administration Login Shell Process started when user logs in. Typically a shell like bash, tcsh, ksh, or zsh. System users may be different. Disabled accounts have a noshell program. CIT 470: Advanced Network and System Administration

CIT 470: Advanced Network and System Administration Adding a User Create account with adduser. Lock account until user arrives. User signs account agreement. Set passwd with passwd. CIT 470: Advanced Network and System Administration

CIT 470: Advanced Network and System Administration Adding a User Edit /etc/{passwd,shadow} with vipw. Set passwd with passwd command. Edit /etc/group to add groups. Create user home directory. mkdir /home/studenta chown studenta.student /home/studenta chmod 755 /home/studenta Copy default files from /etc/skel .bashrc, .Xdefaults, .xsession, etc. Set e-mail aliases, disk quotas, etc. Verify that the account works. CIT 470: Advanced Network and System Administration

CIT 470: Advanced Network and System Administration Disabling an Account Edit account configuration: Place * in front of encrypted password. Replace shell with nologin program. Kill active logins and processes. CIT 470: Advanced Network and System Administration

CIT 470: Advanced Network and System Administration Removing a User Disable account. Change shared passwords (root, etc.) Kill active logins and processes. Remove from local databases/files. Remove from e-mail aliases. Remove mail spool (backup first.) Remove crontabs and pending jobs. Remove temporary files. Remove home directory (backup first.) Remove from passwd, shadow, and group. CIT 470: Advanced Network and System Administration

CIT 470: Advanced Network and System Administration What is a Directory? Directory: A collection of information that is primarily searched and read, rarely modified. Directory Service: Provides access to directory information. Directory Server: Application that provides a directory service. CIT 470: Advanced Network and System Administration

Directories vs. Databases Directories are optimized for reading. Databases balanced for read and write. Directories are tree-structured. Databases typically have relational structure. Directories are usually replicated. Databases can be replicated too. Both are extensible data storage systems. Both have advanced search capabilities. CIT 470: Advanced Network and System Administration

System Administration Directories Types of directory data Accounts Mail aliases and lists (address book) Cryptographic keys IP addresses Hostnames Printers Common directory services DNS, LDAP, NIS CIT 470: Advanced Network and System Administration

Advantages of Directories Make administration easier. Change data only once: people, accounts, hosts. Unify access to network resources. Single sign on. Single place for users to search (address book) Improve data management Improve consistency (one location vs many) Secure data through only one server. CIT 470: Advanced Network and System Administration

NIS: Network Information Service Originally called Sun Yellow Pages Clients run ypbind Servers run ypserv Data stored under /var/yp on server. Server shares NIS maps with clients Each UNIX file may provide multiple maps passwd: passwd.byname, passwd.byuid Slave servers replicate master server content. Easy to use, but insecure, difficult to extend. CIT 470: Advanced Network and System Administration

CIT 470: Advanced Network and System Administration LDAP Lightweight Directory Access Protocol Lightweight compared to X.500 directories. Directory, not a database, service. Access Protocol, not a directory itself. CIT 470: Advanced Network and System Administration

LDAP Clients and Servers Standalone directory browsers. Embedded clients (mail clients, logins, etc.) Cfg /etc/nsswitch.conf on UNIX to use LDAP. Common LDAP servers OpenLDAP Fedora Directory Server (formerly Sun, Netscape) Mac Open Directory Microsoft ActiveDirectory Novell eDirectory (NDS) CIT 470: Advanced Network and System Administration

CIT 470: Advanced Network and System Administration LDAP Structure An LDAP directory is made of entries. Entries may be employee records, hosts, etc. Each entries consists of attributes. Attributes can be names, phone numbers, etc. objectClass attribute identifies entry type. Each attribute is a type / value pair. Type is a label for the information stored (name) Value is value for the attribute in this entry. Attributes can be multi-valued. CIT 470: Advanced Network and System Administration

Tree-structure of LDAP Directories CIT 470: Advanced Network and System Administration

CIT 470: Advanced Network and System Administration LDAP Schemas Schemas specify allowed objectClasses and attributes. CIT 470: Advanced Network and System Administration

CIT 470: Advanced Network and System Administration LDIF LDAP Interchange Format. Standard text format for storing LDAP configuration data and directory contents. LDIF Files Collection of entries separated by blank lines. Mapping of attribute names to values. Uses Import new data into directory. Export directory to LDIF files for backups. CIT 470: Advanced Network and System Administration

CIT 470: Advanced Network and System Administration LDIF Output Example CIT 470: Advanced Network and System Administration

CIT 470: Advanced Network and System Administration Distinguished Names Distinguished Names (DNs) Uniquely identify an LDAP entry. Provides path from LDAP root to the named entry. Similar to an absolute pathname. dn:cn=Jeff Foo,ou=Sales,dc=plainjoe,dc=org Relative DNs (RDNs) Any unique attribute pair in directory’s container. ex: cn=Jeff Foo OR username=fooj Similar to a relative pathname. Except may have multiple components. cn=Jane Smith+ou=Sales cn=Jane Smith+ou=Engineering CIT 470: Advanced Network and System Administration

LDAP Client/Server Interaction Client requests to bind to server. Server accepts/denies bind request. Client sends search request. Server returns zero or more dir entries. Server sends result code with any errors. Client sends an unbind request. Server sends result code and closes socket. CIT 470: Advanced Network and System Administration

CIT 470: Advanced Network and System Administration LDAP Operations Client Session Operations Bind, unbind, and abandon Query and Retrieval Operations Search and compare Modification Operations Add, modify, modifyRDN, and delete CIT 470: Advanced Network and System Administration

CIT 470: Advanced Network and System Administration Authentication Anonymous Authentication Binds with empty DN and password. Simple Authentication Binds with DN and password. Cleartext. Simple Authentication over SSL/TLS Use SSL to encrypt simple authentication. Simple Authentication and Security Layer SASL is an extensible security scheme. SASL mechanisms: Kerberos, GSSAPI, SKEY CIT 470: Advanced Network and System Administration

Distributed Directories Use multiple LDAP servers. Why distribute? Throughput More servers can reduce load on any single server. Latency Have local server serve local data to LAN. Only use WAN for non-local data on other servers. Administrative Boundaries Let each side administrate their own directory. CIT 470: Advanced Network and System Administration

CIT 470: Advanced Network and System Administration OpenLDAP Open source LDAPv3 server. LDAP server: slapd Client commands: ldapadd, ldapsearch Backend storage: BerkeleyDB Backend commands: slapadd, slapcat Schemas: /etc/openldap/schema Data: /var/lib/ldap Configuration files Client: /etc/openldap/ldap.conf Server: /etc/openldap/slapd.conf CIT 470: Advanced Network and System Administration

Building an OpenLDAP Server Install OpenLDAP. Configure LDAP for your domain. Change suffix, rootdn, rootpw options. vim /etc/openldap/slapd.conf Start server Immediate: /sbin/service ldap start Permanent: /sbin/chkconfig --level 35 ldap on Add data with ldapadd Verify functionality with ldapsearch CIT 470: Advanced Network and System Administration

CIT 470: Advanced Network and System Administration LDAP Authentication Configure server with schema + user data. Point clients to hostname and rootDN of svr. /etc/ldap.conf and /etc/openldap/ldap.conf Verify server access with ldapsearch Configure clients to use LDAP auth /etc/nsswitch.conf passwd: files ldap shadow: files ldap group: files ldap CIT 470: Advanced Network and System Administration

CIT 470: Advanced Network and System Administration References Brian Arkills, LDAP Directories Explained: An Introduction and Analysis, Addison-Wesley, 2003. Gerald Carter, LDAP System Administration, O’Reilly, 2003. J. Heiss, “Replacing NIS with Kerberos and LDAP,” http://www.ofb.net/~jheiss/krbldap/, 2004. LDAP Howtos, Links, and Whitepapers, http://www.bind9.net/ldap/, 2005. http://www.ldapman.org/, 2005. Luiz Malere, “Linux LDAP HOWTO,” http://www.tldp.org/HOWTO/LDAP-HOWTO/, 2004. OpenLDAP, OpenLDAP Administrator’s Guide, http://www.openldap.org/devel/admin/, 2005. RedHat, Red Hat Enterprise Linux 4 Reference Guide, Chapter 13, http://www.redhat.com/docs/manuals/enterprise/RHEL-4-Manual/ref-guide/, 2005. CIT 470: Advanced Network and System Administration