Unix Operating Systems Module 7. Unix Operating System Versions Basic Information User and Group Settings File Permissions Local Firewall Local Security.

Slides:



Advertisements
Similar presentations
1 Chapter 8 Fundamentals of System Security. 2 Objectives In this chapter, you will: Understand the trade-offs among security, performance, and ease of.
Advertisements

Race Condition Zutao Zhu 10/09/09. Outline Race Condition –Some functions –File format of /etc/passwd and /etc/shadow –Input Redirection Format-string.
Chapter 2 Accessing Your System and the Common Desktop Environment.
Security SIG: Introduction to Tripwire Chris Harwood John Ives.
SUSE Linux Enterprise Server Administration (Course 3037) Chapter 2 Manage User Access and Security.
Resource Sharing Over a Network
Linux+ Guide to Linux Certification, Second Edition
UNIT - III. Installing Samba Windows uses Sever Message Block(SMB) to communicate with each other using sharing services like file and printer. Samba.
Linux System Administration LINUX SYSTEM ADMINISTRATION.
1. This presentation covers :  User Interface Administration  Files System and Services Management 2.
Principles of Computer Security: CompTIA Security + ® and Beyond, Second Edition © 2010 Baselines Chapter 14.
Introduction to Linux Installing Linux User accounts and management Linux’s file system.
Guide to Operating System Security Chapter 4 Account-based Security.
Guide to Linux Installation and Administration, 2e1 Chapter 8 Basic Administration Tasks.
Unix System Administration Rootly Powers Chapter 3.
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.
Section 1: Introducing Group Policy What Is Group Policy? Group Policy Scenarios New Group Policy Features Introduced with Windows Server 2008 and Windows.
Working with Ubuntu Linux Track 2 Workshop June 2010 Pago Pago, American Samoa.
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.
ITI-481: Unix Administration Meeting 3. Today’s Agenda Hands-on exercises with booting and software installation. Account Management Basic Network Configuration.
IT2204: Systems Administration I 1 6b). Introduction to Linux.
Linux Services Muhammad Amer. 2 xinetd Programs  In computer networking, xinetd, the eXtended InterNET Daemon, is an open-source super-server daemon.
Linux+ Guide to Linux Certification, Third Edition
Managing Users Objectives Contents Practicals Summary
ITI-481: Unix Administration Meeting 3 Christopher Uriarte, Instructor Rutgers University Center for Applied Computing Technologies.
Users Greg Porter V1.0, 26 Jan 09. What is a user? Users “own” files and directories Permission based on “ownership” Every user has a User ID (UID) 
There are three types of users in linux  System users: ?  Super user: ?  Normal users: ?
Managing Users  Each system has two kinds of users:  Superuser (root)  Regular user  Each user has his own username, password, and permissions that.
CHAPTER Creating and Managing Users and Groups. Chapter Objectives Explain the use of Local Users and Groups Tool in the Systems Tools Option to create.
System Administration 1.  system administration  user and group management 2.
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.
A Practical Guide to Fedora and Red Hat Enterprise Linux Unit 9: Basic Linux Administration Chapter 11: System Administration: Core Concepts Chapter 16:
Introduction to System Admin Sirak Kaewjamnong. 2 The system administration’s job  Adding a new user  Doing backup and restoring files from backups.
Core System Services. INIT Daemon The init process is the patron of all processes. first process that gets started in any Linux/ UNIX -based system.
1 Linux Security. 2 Linux is not secure No computer system can ever be "completely secure". –make it increasingly difficult for someone to compromise.
Managing Users Objectives –to be able to add, modify and remove Unix user accounts Contents –requirements for a user account –configuration files (passwd,
1 LINUX SECURITY. 2 Outline Introduction Introduction - UNIX file permission - UNIX file permission - SUID / SGID - SUID / SGID - File attributes - File.
Fall 2011 Nassau Community College ITE153 – Operating Systems Session 21 Administering User Accounts and Groups 1.
Principles of Computer Security: CompTIA Security + ® and Beyond, Third Edition © 2012 Principles of Computer Security: CompTIA Security+ ® and Beyond,
The Saigon CTT Chapter 10 Managing Users. The Saigon CTT  Objectives  Define the requirements for user accounts  Explain group and group accounts 
Manually Creating a New User Account Presented by Carl South.
© 2006 ITT Educational Services Inc. Linux Operating System :: Unit 3 :: Slide 1 Downloading and Installing Software yum pirut Bit Torrent rmp.
ITI-481: Unix Administration Meeting 3 Christopher Uriarte, Instructor Rutgers University Center for Applied Computing Technologies.
CSCI 330 UNIX and Network Programming Unit XX: Linux Administration.
SCSC 455 Computer Security Chapter 3 User Security.
Lecture – Users and groups
Working with users and Groups. 1. Manage users and group 2. Manage ownership, permissions, and quotas.
Linux Use the Command-Line Interface to Administer the System.
CSC414 “Introduction to UNIX/ Linux” Lecture 6. Schedule 1. Introduction to Unix/ Linux 2. Kernel Structure and Device Drivers. 3. System and Storage.
SUSE Linux Enterprise Desktop Administration Chapter 9 Manage Users, Groups, and Permissions.
Password Security Module 8. Objectives Explain Authentication and Authorization Provide familiarity with how passwords are used Identify the importance.
Chapter 6 Adding New Users. Computer Center, CS, NCTU 2 Steps to add a new user 1.Edit the password and group files >vipw, pw 2.Set an initial password.
LINUX Presented By Parvathy Subramanian. April 23, 2008LINUX, By Parvathy Subramanian2 Agenda ► Introduction ► Standard design for security systems ►
Managing Users CSCI N321 – System and Network Administration Copyright © 2000, 2011 by Scott Orr and the Trustees of Indiana University.
This slide deck is for LPI Academy instructors to use for lectures for LPI Academy courses. ©Copyright Network Development Group Module 14 Managing.
Linux Security 2016 GenCyber JMU Bootcamp for High School Teachers.
AFA CyberCamp Module 4. Day One Cyber Safety Day Two Windows System Administration Day Three Intermediate Windows Security Day Four Intro to Linux and.
LINUX SYSTEM ADMINISTRATION
Chapter 11: Managing Users
FTP - File Transfer Protocol
9 Linux on the Desktop.
Ubuntu Working in Terminal
Linux Users and Groups Management
IS3440 Linux Security Unit 3 User Account Management
Adding New Users, Storage, File System
Unix Access Control Basic CE 2
LINUX SYSTEM ADMINISTRATION
Module 13 System and User Security
Adding New Users.
Presentation transcript:

Unix Operating Systems Module 7

Unix Operating System Versions Basic Information User and Group Settings File Permissions Local Firewall Local Security Policies Permissions and Rights Tools Checklist

History of Versions

Current Versions Linux (Red Hat, Fedora, SUSE, Ubuntu) BSD (OpenBSD, FreeBSD, NetBSD) Mac OS X Sun OS AIX HP/UX Solaris OpenServer

Linux Different flavors of Linux may be used for the competition like: Ubuntu Fedora Core Many flavors have GUIs for ease of use Command line interface GUIs may not always be available For consistency purposes, we will focus on command line rather than GUIs All flavors built around a “Kernel” Main component of the OS Made up of CPU, memory, and I/O (Input/Output) devices

Linux 101 Root The ‘administrator’ of the system Password files Encrypt passwords Located at /etc/passwd and /etc/shadow System Logs (syslog) Configure the Syslog daemon to log messages and events Located at the /etc/syslog.conf Daemon A process that runs in the background Editor VI is a text editor used on most Unix operating systems Cheat sheet for commands at content/uploads/2010/05/VI-Help-Sheet-011.pdfhttp://media.smashingmagazine.com/wp- content/uploads/2010/05/VI-Help-Sheet-011.pdf

Password Files Each user has an entry in the password file 1. Username: It is used when user logs in. It should be between 1 and 32 characters in length. 2. Password: An x character indicates that encrypted password is stored in /etc/shadow file. 3. User ID (UID): Each user must be assigned a user ID (UID). UID 0 (zero) is reserved for root and UIDs 1-99 are reserved for other predefined accounts. Further UID are reserved by system for administrative and system accounts/groups. 4. Group ID (GID): The primary group ID (stored in /etc/group file) 5. User ID Info: The comment field. It allows you to add extra information about the users such as user's full name, phone number etc. This field is used by the finger command. 6. Home directory: The absolute path to the directory the user will be in when they log in. If this directory does not exists then users directory often becomes / 7. Command/shell: The absolute path of a command or shell (/bin/bash). Typically, this is a shell. Please note that it does not have to be a shell.

Password Files Passwords are usually not stored in the /etc/passwd file, but rather in the /etc/shadow file Passwords are encrypted in the /etc/shadow file File permissions /etc/passwd Owned by Root Read only to users /etc/shadow Owned by Root Users should not have access to this file To crack Linux passwords you need the shadow file and sometimes have to merge the passwd and shadow file

User and Group Security Defaults Users and Groups Permissions and privilege tips Disable login for well known accounts (bin,sys,uucp) Disable all account(s) with no password and lock them down passwd -l {user-name} Root Disable direct login Limit number of users with access Regularly change password For Ubuntu, the root account must be enabled by giving it a password using the sudo command Sudo allows an authorized user to temporarily elevate their privileges using their own password instead of having to know the password belonging to the root account Locking a user account may not prevent a user access. They may still be able to gain shell access, without the need for any password.

File Permissions File Type Directory – d File – ‘-’ File Permissions Read - r Write (modify) - w Execute – x The first segment defines permissions set for the user, or creator, of the file. The second segment of three bits defines permissions set for the group that can access the file. The last segment defines permission for other Use the chmod command to change user and group permissions

File System Security Network File System (NFS) Security Method of sharing access to a filesystem between Unix systems Only run NFS as needed, apply latest patches (including nfsd, mountd, statd, lockd) Careful use of /etc/exports Read-only if possible No suid if possible Fully qualified hostnames Device Security Device files /dev/null, /dev/tty & /dev/console should be world writeable but NEVER executable Most other device files should be unreadable and unwriteable by regular users

Services Disable unnecessary services (daemons) If your system is configured with inetd, look at /etc/inetd.conf and prefix a line with a "#" character to make it a comment; then restart the inetd service or reboot If you are using xinetd, its configuration will be in the directory /etc/xinetd.d. Each file in the directory defines a service, and add disable = yes to any that you want to disable Disable daemons not normally used such as Telnet Anonymous FTP Remote processes (Rexec.Rlogin,Rsh) Rstatd Finger Talk, Ntalk

Other Security Tips Monitor your processes Use tools such as Snort, Nessus Monitor syslog Monitor run levels (0 to 6) Runlevels define what services or processes should be running on the system Make sure all processes are operating on the appropriate runlevel Encrypt network traffic Install ssh Utilize access control Configure hosts.allow and hosts.deny files for tcpd and sshd

Local Security Policies User profile The adduser utility creates a brand new home directory named /home/username /etc/default/useradd By default, user home directories in Ubuntu are created with world read/execute permissions

Local Security Policies Password Policy Minimum Password Length Add the ‘minlen = ’ parameter to the pam_unix configuration in the /etc/pam.d/common-password file – Set to 8 password required pam_cracklib.so retry=3 minlen=8 difok=3 By default, Ubuntu requires a minimum password length of 4 characters Password Expiration Needs a minimum and maximum password age forcing users to change their passwords when they expire PASS_MIN_DAYS – Set to 7 days Minimum number of days allowed between password changes PASS_MAX_DAYS – Set from 30 to 90 days Maximum number of days a password may be used PASS_WARN_AGE – Set to 14 days Number of days warning given before a password expires Parameters can be set in /etc/login.defs

Local Security Policies Password History (reuse) Create an empty /etc/security/opasswd file for storing old user passwords Set permissions to opasswd to the same as the /etc/shawdow file Enable password history by adding the “remember= ” to the pam_unix configuration in the /etc/pam.d/common-password file password required pam_unix.so md5 remember=12 use_authtok The value of the "remember" parameter is the number of old passwords to store for a user More explanation can be found at

Local Security Policies Account Lockout Set to a high enough number that authorized users are not locked out of their user accounts simply because they mistype a password Usually set to 5 Add the following two lines highlighted in blue to the /etc/pam.d/system- auth file auth required /lib/security/$ISA/pam_tally.so onerr=fail no_magic_root account required /lib/security/$ISA/pam_tally.so per_user deny=5 no_magic_root reset The first added line counts failed login and failed su attempts for each user. The default location for attempted accesses is recorded in /var/log/faillog The second added line specifies to lock accounts automatically after 5 failed login or su attempts (deny=5)

Local Firewall Use a local firewall UFW (Uncomplicated Firewall) Default Ubuntu firewall; but not activated by default Command line interface (frontend for iptables) Configure and enable Set default policies such as drop all connections (deny), then add (allow) rules for specific services Enable logging ntuFirewall Gufw Gui for ufw Type “sudo apt-get install gufw” at the command line Screenshots for Gufw at

Local Firewall Firestarter Shows active connections and who they belong to Controls inbound and outbound traffic Displays intrusion attempts as they occur Configure firewall to behave in a specific manner for certain types of connections Create security policies Screenshots can be found at Download at Installation directions can be found at on-ubuntu-linux/ on-ubuntu-linux/

Package Management Package A compressed program or piece of software Package Managers All software on a linux system is divided into RPM packages, which can be installed, upgraded, or uninstalled Contain a list of software repositories You will be prompted to enter the superuser (root) password before changes are made to the system RPM Package Manager.rpm is the file format for the software package files System administrators must manually install with dependencies Instead, a front end can be used to automate this process

Package Managers Common Package Managers (front end) YUM – automatic update and package installer PackageKit (GUI) Open Software Updates by clicking Applications → System Tools → Software Update from the Activities menu within the GNOME desktop apt-get Command line tool Aptitude Menu driven text based tool ( Synaptic Package Manager (GUI)

Checklist Disable unnecessary services Disable remote login Disable dangerous features Employ security practices Install and maintain malware protection software Patch more than just the OS Research and test updates Use a desktop/local firewall Look for alternatives to default applications

List of References Videos: Securing Ubuntu