Sudoers Meryll Larkin - that's me Why you are here:

Slides:



Advertisements
Similar presentations
Establishing an OU Hierarchy for Managing and Securing Clients Base design on business and IT needs Split hierarchy Separate user and computer OUs Simplifies.
Advertisements

CIS 193A – Lesson2CIS 193A - Lesson2 Authorization & Authentication Sudo and PAM.
Linux Users and Groups Management
When you combine NTFS permissions and share permissions the most restrictive effective permission applies. For example, if you share a folder and assign.
1 CSE 390a Lecture 4 Persistent shell settings; users/groups; permissions slides created by Marty Stepp, modified by Jessica Miller
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.
User Accounts and Permissions Chapter IV / Part II.
Sudo Access with Beowulf Clusters Chris Feehan CS Senior Capstone 12/18/06.
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.
© 2003 By Default! A Free sample background from Slide 1 Week 2  Free PHP Hosting Setup  PHP Backend  Backend Security 
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.
CSC 386 – Computer Security Scott Heggen. Agenda A last look at OS Security Comparing Windows to Linux.
CMSBrownBag,05/29/2007 B.Mangano How to “use” CMSSW on own Linux Box and be happy In this context “use” means: - check-out pre-compiled CMSSW code - run.
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 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.
Linux Security. Authors:- Advanced Linux Programming by Mark Mitchell, Jeffrey Oldham, and Alex Samuel, of CodeSourcery LLC published by New Riders Publishing.
Introduction to System Admin Sirak Kaewjamnong. 2 The system administration’s job  Adding a new user  Doing backup and restoring files from backups.
1 Day 2 Logging in, Passwords, Man, talk, write. 2 Logging in Unix is a multi user system –Many people can be using it at the same time. –Connections.
SCSC 455 Computer Security Chapter 3 User Security.
Self Control: Do you have a grip on it?
Managing Users CSCI N321 – System and Network Administration Copyright © 2000, 2011 by Scott Orr and the Trustees of Indiana University.
Lecture 14 Page 1 CS 236 Online Secure Programming CS 236 On-Line MS Program Networks and Systems Security Peter Reiher.
Linux Permissions ● Meryll Larkin - that's me ● Why you are here: – You do this at work or want to – General curiosity - want to learn – Your first choice.
Server Security Sudo Lars Noodén March – April 2009.
Using Linux Kaya Oğuz Room: 310.
UNIX Command RTFM: sudo(8)
Security Risk Assessment Determine how important your computer is to your group ● Mission critical? ● Sensitive information? ● Expensive hardware? ● Service.
System Administration II
Operating System Kernel Compilation
Unit 7 Learning Objectives
SYSTEM ADMINISTRATION PART I by İlker Korkmaz and Kaya Oğuz
Protecting Memory What is there to protect in memory?
Security+ All-In-One Edition Chapter 1 – General Security Concepts
Overview – SOE Sudo SEP 2014.
Protecting Memory What is there to protect in memory?
Overview – SOE Sudo Dec 2013.
Protecting Memory What is there to protect in memory?
Rootly Powers and Controlling Processes
Installation and Configuration
Chapter 11: Managing Users
User Management.
Overview – SOE Sudo September 2016.
Overview – SOE Sudo November 2015.
Part 3 – Remote Connection, File Transfer, Remote Environments
Chapter 3 Rootly Powers.
Users and Accounts Lab 0.1. Users and Accounts Lab 0.1.
Linux Users and Groups Management
IS3440 Linux Security Unit 3 User Account Management
DevOps Database Administration
Operating System Kernel Compilation
Principles of report writing
By Les Cottrell for UltraLight meeting, Caltech October 2005
DevOps Database Administration
Data Visualizations and Graphs: From Excel Defaults to Excellence
COP 4343 Unix System Administration
OPS235 Lab4: Investigations 5 – 9
The Linux Command Line Chapter 9
User Management lctseng.
Linux Security.
User Management.
Persistent shell settings; users/groups; permissions
Chapter Introduction 3.2 The UNIX Model of Ownership
Operating System Hardening
Rootly Powers Chapter 3.
Preventing Privilege Escalation
Fix Hotmail Account Hacked Problems with Hotmail Support Phone Number
Microsoft AZ-500 Dumps Pdf – Latest And Authentic Material
Presentation transcript:

Sudoers Meryll Larkin - that's me Why you are here: You do this at work or want to General curiosity - want to learn Your first choice workshop was full To heckle Any burning questions you need answered? I'll make sure to get to them.

Sudoers Examples and discussion style workshop I've seen some bad sudoers files and I know how to do better, but I'm not an “expert” - ok for you to help/suggest Why do we need to write good sudoers files? Your ideas, Examples and analysis/critiques

Why Sudoers What do we do if we don't use sudoers? What role does sudoers play in security? Most common form of bad sudoers?

Sudo Aptonym Linux developers knew commands were hard to remember so they tried to make them memorable. Pseudo - masquerading as someone else SU - do = What the SuperUser does

Wheel Group What is the wheel group and how is it used? What is the gid of the wheel group? Does it have to be the “wheel” group?

How to think about Sudo Specify what a user or group CAN do Set limits as to what a user or group CAN'T do (trickier): Because there are so many way to accomplish something in Linux. CLI examples here. Why we would want to do those things

Discuss Assorted Sudo Strategies Per-administrator, additional admin accounts: nuhura, nuhura_adm Shared accounts for shared work root does not have ssh permission, but you need to run remote scripts with root authority difference between su and su - if you can become root, you can become any login.

Writing Sudoers Rules Permissions on /etc/sudoers file aliases & privilege specs in sudoers 4 types of aliases User_Alias, Runas_Alias, Host_Alias, Cmnd_Alias. Default for each alias type what is /etc/sudoers.d/ ?

Writing Sudoer Rules, More principle of least privilege: This is a User Spec (privilege) template: User Host = Command(s) [: Hosts = Cmnd_Spec_List *] Commands (and command Cmnd_Spec_Lists) can be single commands (absolute path is best) or a comma separated list. Cmnd_Spec ::= Runas_Spec? SELinux_Spec? Tag_Spec* Cmnd Runas_Spec ::= '(' Runas_List? (':' Runas_List)? ')'

Writing Sudoer Rules, More 2 SELinux_Spec ::= ('ROLE=role' | 'TYPE=type') Tag_Spec ::= ('NOPASSWD:' | 'PASSWD:' | 'NOEXEC:' | 'EXEC:' | 'SETENV:' | 'NOSETENV:' | 'LOG_INPUT:' | 'NOLOG_INPUT:' | 'LOG_OUTPUT:' | 'NOLOG_OUTPUT:') Cmnd_Spec_List ::= Cmnd_Spec | Cmnd_Spec ',' Cmnd_Spec_List Cmnd_Spec ::= Runas_Spec? SELinux_Spec? Tag_Spec* Cmnd

Developing Rules & Testing TRY IT!!!! Become an unprivileged user, see if you can do your work. Deputize a dev to show you exactly the steps she takes. Don't test on production machines! Test what you DON'T want to happen as well as what you do!

sudo dangers “elevation of privileges” show them unintentional file deletion or alteration one strategy: greatly restrict who has sudo on Production systems. Allow more sudo access on Dev, Test, and/or Staging hosts.

Sudoers, End Thanks for your attention and especially your participation! I created a few scripts so to give you a “sample set” of users so you can try out permissions and how they work on your own laptop or test machine. They should found in the same place where you downloaded this presentation. Happy hacking!