Table of Contents for
Practical UNIX and Internet Security, 3rd Edition

Version ebook / Retour

Cover image for bash Cookbook, 2nd Edition Practical UNIX and Internet Security, 3rd Edition by Alan Schwartz Published by O'Reilly Media, Inc., 2003
  1. Cover
  2. Practical Unix & Internet Security, 3rd Edition
  3. A Note Regarding Supplemental Files
  4. Preface
  5. Unix “Security”?
  6. Scope of This Book
  7. Which Unix System?
  8. Conventions Used in This Book
  9. Comments and Questions
  10. Acknowledgments
  11. A Note to Would-Be Attackers
  12. I. Computer Security Basics
  13. 1. Introduction: Some Fundamental Questions
  14. What Is Computer Security?
  15. What Is an Operating System?
  16. What Is a Deployment Environment?
  17. Summary
  18. 2. Unix History and Lineage
  19. History of Unix
  20. Security and Unix
  21. Role of This Book
  22. Summary
  23. 3. Policies and Guidelines
  24. Planning Your Security Needs
  25. Risk Assessment
  26. Cost-Benefit Analysis and Best Practices
  27. Policy
  28. Compliance Audits
  29. Outsourcing Options
  30. The Problem with Security Through Obscurity
  31. Summary
  32. II. Security Building Blocks
  33. 4. Users, Passwords, and Authentication
  34. Logging in with Usernames and Passwords
  35. The Care and Feeding of Passwords
  36. How Unix Implements Passwords
  37. Network Account and Authorization Systems
  38. Pluggable Authentication Modules (PAM)
  39. Summary
  40. 5. Users, Groups, and the Superuser
  41. Users and Groups
  42. The Superuser (root)
  43. The su Command: Changing Who You Claim to Be
  44. Restrictions on the Superuser
  45. Summary
  46. 6. Filesystems and Security
  47. Understanding Filesystems
  48. File Attributes and Permissions
  49. chmod: Changing a File’s Permissions
  50. The umask
  51. SUID and SGID
  52. Device Files
  53. Changing a File’s Owner or Group
  54. Summary
  55. 7. Cryptography Basics
  56. Understanding Cryptography
  57. Symmetric Key Algorithms
  58. Public Key Algorithms
  59. Message Digest Functions
  60. Summary
  61. 8. Physical Security for Servers
  62. Planning for the Forgotten Threats
  63. Protecting Computer Hardware
  64. Preventing Theft
  65. Protecting Your Data
  66. Story: A Failed Site Inspection
  67. Summary
  68. 9. Personnel Security
  69. Background Checks
  70. On the Job
  71. Departure
  72. Other People
  73. Summary
  74. III. Network and Internet Security
  75. 10. Modems and Dialup Security
  76. Modems: Theory of Operation
  77. Modems and Security
  78. Modems and Unix
  79. Additional Security for Modems
  80. Summary
  81. 11. TCP/IP Networks
  82. Networking
  83. IP: The Internet Protocol
  84. IP Security
  85. Summary
  86. 12. Securing TCP and UDP Services
  87. Understanding Unix Internet Servers and Services
  88. Controlling Access to Servers
  89. Primary Unix Network Services
  90. Managing Services Securely
  91. Putting It All Together: An Example
  92. Summary
  93. 13. Sun RPC
  94. Remote Procedure Call (RPC)
  95. Secure RPC (AUTH_DES)
  96. Summary
  97. 14. Network-Based Authentication Systems
  98. Sun’s Network Information Service (NIS)
  99. Sun’s NIS+
  100. Kerberos
  101. LDAP
  102. Other Network Authentication Systems
  103. Summary
  104. 15. Network Filesystems
  105. Understanding NFS
  106. Server-Side NFS Security
  107. Client-Side NFS Security
  108. Improving NFS Security
  109. Some Last Comments on NFS
  110. Understanding SMB
  111. Summary
  112. 16. Secure Programming Techniques
  113. One Bug Can Ruin Your Whole Day . . .
  114. Tips on Avoiding Security-Related Bugs
  115. Tips on Writing Network Programs
  116. Tips on Writing SUID/SGID Programs
  117. Using chroot( )
  118. Tips on Using Passwords
  119. Tips on Generating Random Numbers
  120. Summary
  121. IV. Secure Operations
  122. 17. Keeping Up to Date
  123. Software Management Systems
  124. Updating System Software
  125. Summary
  126. 18. Backups
  127. Why Make Backups?
  128. Backing Up System Files
  129. Software for Backups
  130. Summary
  131. 19. Defending Accounts
  132. Dangerous Accounts
  133. Monitoring File Format
  134. Restricting Logins
  135. Managing Dormant Accounts
  136. Protecting the root Account
  137. One-Time Passwords
  138. Administrative Techniques for Conventional Passwords
  139. Intrusion Detection Systems
  140. Summary
  141. 20. Integrity Management
  142. The Need for Integrity
  143. Protecting Integrity
  144. Detecting Changes After the Fact
  145. Integrity-Checking Tools
  146. Summary
  147. 21. Auditing, Logging, and Forensics
  148. Unix Log File Utilities
  149. Process Accounting: The acct/pacct File
  150. Program-Specific Log Files
  151. Designing a Site-Wide Log Policy
  152. Handwritten Logs
  153. Managing Log Files
  154. Unix Forensics
  155. Summary
  156. V. Handling Security Incidents
  157. 22. Discovering a Break-in
  158. Prelude
  159. Discovering an Intruder
  160. Cleaning Up After the Intruder
  161. Case Studies
  162. Summary
  163. 23. Protecting Against Programmed Threats
  164. Programmed Threats: Definitions
  165. Damage
  166. Authors
  167. Entry
  168. Protecting Yourself
  169. Preventing Attacks
  170. Summary
  171. 24. Denial of Service Attacks and Solutions
  172. Types of Attacks
  173. Destructive Attacks
  174. Overload Attacks
  175. Network Denial of Service Attacks
  176. Summary
  177. 25. Computer Crime
  178. Your Legal Options After a Break-in
  179. Criminal Hazards
  180. Criminal Subject Matter
  181. Summary
  182. 26. Who Do You Trust?
  183. Can You Trust Your Computer?
  184. Can You Trust Your Suppliers?
  185. Can You Trust People?
  186. Summary
  187. VI. Appendixes
  188. A. Unix Security Checklist
  189. Preface
  190. Chapter 1: Introduction: Some Fundamental Questions
  191. Chapter 2: Unix History and Lineage
  192. Chapter 3: Policies and Guidelines
  193. Chapter 4: Users, Passwords, and Authentication
  194. Chapter 5: Users, Groups, and the Superuser
  195. Chapter 6: Filesystems and Security
  196. Chapter 7: Cryptography Basics
  197. Chapter 8: Physical Security for Servers
  198. Chapter 9: Personnel Security
  199. Chapter 10: Modems and Dialup Security
  200. Chapter 11: TCP/IP Networks
  201. Chapter 12: Securing TCP and UDP Services
  202. Chapter 13: Sun RPC
  203. Chapter 14: Network-Based Authentication Systems
  204. Chapter 15: Network Filesystems
  205. Chapter 16: Secure Programming Techniques
  206. Chapter 17: Keeping Up to Date
  207. Chapter 18: Backups
  208. Chapter 19: Defending Accounts
  209. Chapter 20: Integrity Management
  210. Chapter 21: Auditing, Logging, and Forensics
  211. Chapter 22: Discovering a Break-In
  212. Chapter 23: Protecting Against Programmed Threats
  213. Chapter 24: Denial of Service Attacks and Solutions
  214. Chapter 25: Computer Crime
  215. Chapter 26: Who Do You Trust?
  216. Appendix A: Unix Security Checklist
  217. Appendix B: Unix Processes
  218. Appendixes C, D, and E: Paper Sources, Electronic Sources, and Organizations
  219. B. Unix Processes
  220. About Processes
  221. Signals
  222. Controlling and Examining Processes
  223. Starting Up Unix and Logging In
  224. C. Paper Sources
  225. Unix Security References
  226. Other Computer References
  227. D. Electronic Resources
  228. Mailing Lists
  229. Web Sites
  230. Usenet Groups
  231. Software Resources
  232. E. Organizations
  233. Professional Organizations
  234. U.S. Government Organizations
  235. Emergency Response Organizations
  236. Index
  237. Index
  238. Index
  239. Index
  240. Index
  241. Index
  242. Index
  243. Index
  244. Index
  245. Index
  246. Index
  247. Index
  248. Index
  249. Index
  250. Index
  251. Index
  252. Index
  253. Index
  254. Index
  255. Index
  256. Index
  257. Index
  258. Index
  259. Index
  260. Index
  261. Index
  262. Index
  263. About the Authors
  264. Colophon
  265. Copyright

B

Bace, Rebecca (Intrusion Detection), General Computer Security
Bach, Maurice (The Design of the UNIX Operating System), Unix Programming and System Administration
back doors, Keeping Secrets, Cryptographic Strength of Symmetric Algorithms, Communicating with MUDs, Internet Relay Chat (IRC), and Instant Messaging, Programmed Threats: Definitions, Back Doors and Trap DoorsBack Doors and Trap Doors, Protecting Yourself
as common threat, Protecting Yourself
in MUDs and IRCs, Communicating with MUDs, Internet Relay Chat (IRC), and Instant Messaging
strength of encryption and, Cryptographic Strength of Symmetric Algorithms
background checks, Background Checks, Other People
background processes, Abusing Automatic Mechanisms
backing out of upgrades, Upgrading Distributed Applications
backups, Standards, Guidelines, Defending Against Acts of War and Terrorism, Protecting Backups, Protecting Backups, Verify your backups, Protect your backups, Upgrading Distributed Applications, Why Make Backups?The Role of Backups, The Role of Backups, What Should You Back Up?, Types of Backups, Types of Backups, Types of Backups, Types of Backups, Guarding Against Media Failure, Replace tapes as needed, Verify the backup, How Long Should You Keep a Backup?, How Long Should You Keep a Backup?, Security for BackupsData security for backups, Physical security for backups, Physical security for backups, Write-protect your backups, Data security for backups, Data security for backups, Legal Issues, Legal Issues, Legal Issues, Deciding Upon a Backup StrategyRetention schedule, Individual Workstation, Small Network of Workstations and a ServerRetention schedule, Large Service-Based Networks with Large Budget, Backing Up System FilesBuilding an Automatic Backup System, Building an Automatic Backup System, Building an Automatic Backup System, Building an Automatic Backup System, Software for BackupsNetwork Backup Systems, Software for Backups, Simple Local Copies, Simple Archives, Specialized Backup Programs, Network Backup Systems, Network Backup Systems, Encrypting Your Backups, Read-Only Filesystems, Managing Log Files, Managing Log Files, World-readable backup devices, Hazards of Criminal Prosecution, The Responsibility to Report Crime, Criminal Hazards, Chapter 18: Backups
across network, Network Backup Systems
automatic system for, Building an Automatic Backup System
commercial systems for, Network Backup Systems
configuration files, paper copies of, Building an Automatic Backup System
criminal investigations and, Hazards of Criminal Prosecution, The Responsibility to Report Crime, Criminal Hazards
data security for, Data security for backups
dedicated programs for, Specialized Backup Programs
destruction of, Legal Issues
differential, Types of Backups
encryption of, Protecting Backups, Physical security for backups, Data security for backups, Encrypting Your Backups
file modification times and, Large Service-Based Networks with Large Budget
files with holes, Software for Backups
guidelines for, Guidelines
human error and, Replace tapes as needed
of individual workstations, Individual Workstation
legal issues concerning, Legal Issues
levels of, Types of Backups
location of, Protect your backups, Physical security for backups
of log files, Managing Log Files
media failure, protecting against, Guarding Against Media Failure
methods of, The Role of Backups
migrating, How Long Should You Keep a Backup?
of networks, Small Network of Workstations and a ServerRetention schedule
performing before upgrades, Upgrading Distributed Applications
public key encryption and PGP, Building an Automatic Backup System
purposes of, Why Make Backups?The Role of Backups
read-only partitions, Read-Only Filesystems
retention of, How Long Should You Keep a Backup?, Legal Issues
rotating media, Types of Backups
schedule for, Types of Backups
security checklist for, Chapter 18: Backups
security of, Security for BackupsData security for backups
simple archives, Simple Archives
simple local copies, Simple Local Copies
simultaneous, Defending Against Acts of War and Terrorism
software for, Software for BackupsNetwork Backup Systems
standards for, Standards
strategies for, Deciding Upon a Backup StrategyRetention schedule, Managing Log Files
of system-critical files, Backing Up System FilesBuilding an Automatic Backup System
theft of, Protecting Backups
verifying, Verify your backups, Verify the backup
what to back up, What Should You Back Up?
world-readable, World-readable backup devices
write-protecting, Write-protect your backups
bacteria, Programmed Threats: Definitions, Bacteria and Rabbits
BADSU attempts, logging, sulog Log File
Badulescu, Ion, The Virtual Filesystem Interface
banners, BannersBanners, Security concerns with SMTP banners and commands
modem, BannersBanners
SMTP, Security concerns with SMTP banners and commands
bash history file, Shell History
Basic Input/Output System (BIOS), Starting Up Unix and Logging In
batch command, CPU overload attacks
batch jobs, Sudden changes in time (see cron file)
baud, Baud and bps
Bellovin, Steve (Firewalls and Internet Security), Network Technology and Security
Berkeley BSD Unix, Which Unix System? (see BSD Unix)
Berkeley FTP server, restricting accounts with, Restricting FTP with the standard Berkeley FTP server
Berkeley Software Design, Inc. (BSDI), Second-Generation Commercial Unix Systems
Bernstein, Dan, SMTP: Simple Mail Transfer Protocol (TCP Port 25)
best practices, Best PracticesBest Practices
beverages, effects on hardware, Food and drink
bftpd server, Setting up an FTP server
bidirectionality of modems, Modems: Theory of Operation, One-Way Phone Lines
biff service, UDP
bigcrypt algorithm, crypt16( ), DES Extended, and Modular Crypt Format
/bin directory, Unix salt, Using NIS+, Setting up the chroot( ) environment, Viruses, Running the User’s Shell, Running the User’s Shell, Running the User’s Shell
/bin/csh, Running the User’s Shell (see csh)
/bin/ksh, Running the User’s Shell (see ksh)
/bin/login, Using NIS+ (see login program)
/bin/passwd, Unix salt (see passwd command)
/bin/sh, Running the User’s Shell (see sh)
in restricted filesystems, Setting up the chroot( ) environment
binary code, downloading, Programmed Threats: Definitions, Viruses
binary owner, Users and Groups
BIND name server, Users and Groups, DNS under Unix
bind() system call, The inetd Program
BIOS (Basic Input/Output System), Starting Up Unix and Logging In
Bishop, Matt, Protecting Integrity
Blaze, Matt, The Virtual Filesystem Interface
block algorithms, Symmetric Key Algorithms
block devices, Device Files, Device Files, Device Files
block/send commands, Trojan horses and, Terminal-based Trojan horses
Blowfish algorithm, Common Symmetric Key Algorithms
bogus nameserver cache poisoning, Authentication and DNS
bogusns directive, DNS best practices
Bolsky, Morris I. (The New Kornshell Command and Programmang Language), Unix Programming and System Administration
bombs, as destructive attack, Destructive Attacks
books, security, Paper SourcesSecurity Periodicals
boot disks, viruses on, Viruses
BOOTP protocol, BOOTP: Bootstrap Protocol, and DHCP: Dynamic Host Configuration Protocol (UDP Ports 67 and 68)
Bootparams table (NIS+), NIS+ Tables and Other Objects
Bostic, Keith (The Design and Implementation of the 4.4 BSD UNIX Operating System), Unix Programming and System Administration
Bosworth, S. (Computer Security Handbook), General Computer Security
bounds checking, Coding Standards
Bourne shell, Conventions Used in This Book (see sh)
bps (bits per second), Baud and bps
brackets ([]), indicating optional syntax, Conventions Used in This Book
Brand, Russell, Worms
break-ins, PreludeRule #3: Plan Ahead, Rule #2: Document, Rule #3: Plan AheadRule #3: Plan Ahead, Rule #3: Plan Ahead, Discovering an IntruderOther tip-offs, Discovering an Intruder, Monitoring commands, What to Do When You Catch SomebodyGetting Rid of the Intruder, Monitoring the Intruder, How to Contact the System Administrator of a Computer You Don’t KnowAlternative contact strategies, Cleaning Up After the IntruderDamage Control, Preserving the EvidencePreserving the Evidence, Resuming OperationDamage Control, Case Studiesfaxsurvey, Your Legal Options After a Break-inThe Responsibility to Report Crime, What the Superuser Can and Cannot Do, Chapter 22: Discovering a Break-In
case studies of, Case Studiesfaxsurvey
commands used to discover, Discovering an Intruder
commands used to monitor, Monitoring commands, Monitoring the Intruder
contacting a remote system administrator, How to Contact the System Administrator of a Computer You Don’t KnowAlternative contact strategies
detecting and discovering, Discovering an IntruderOther tip-offs, What the Superuser Can and Cannot Do
documenting, Rule #2: Document
legal recourses after, Your Legal Options After a Break-inThe Responsibility to Report Crime
planning for, Rule #3: Plan AheadRule #3: Plan Ahead
preserving evidence from, Preserving the EvidencePreserving the Evidence
recovering from, Cleaning Up After the IntruderDamage Control
responding to, PreludeRule #3: Plan Ahead, What to Do When You Catch SomebodyGetting Rid of the Intruder
resuming operation after, Resuming OperationDamage Control
security checklist for, Chapter 22: Discovering a Break-In
software toolkit for, Rule #3: Plan Ahead
A Brief History of Time: From the Big Bang to Black Holes (Hawking, Stephen W.), Miscellaneous References
broadcast storms, Message Flooding
Brunner, John (Shockwave Rider), Understanding the Computer Security “Culture”
brute force attacks, A Cryptographic Example, Key Length with Symmetric Key Algorithms, Key Length with Symmetric Key Algorithms, Key search (brute force) attacks
BSD 4.2, Unix goes commercial
BSD 4.4 Lite, Versions Covered in This Book, Second-Generation Commercial Unix Systems
BSD Unix, Which Unix System?, Which Unix System?, Versions Covered in This Book, Versions Covered in This Book, Unix escapes AT&TThe Unix Wars: Why Berkeley 4.2 over System V, What the Superuser Can’t Do, Secure Terminals: Limiting Where the Superuser Can Log In, BSD Kernel Security Levels, chmod: Changing a File’s Permissions, SGID and Sticky Bits on Directories, Connecting a Modem to Your Computer, Startup on different Unix systems, The inetd Program, Access Control Lists with TCP Wrappers, Using a Host-Based Packet Firewall, The ipfw host-based firewall, Sun RPC’s portmapper (UDP and TCP Ports 111), Hard, soft, and spongy mounts, /etc/exports/usr/etc/exportfs, Samba Client Security, The Lesson of the Internet Worm, Using chroot( ), Package-Based Systems, Specialized Backup Programs, Setting up the chroot( ) environment, Setting up the chroot( ) environment, Disabling an Account by Changing the Account’s Password, Secure Terminals, Shadow Password Files, Immutable and Append-Only Files, Immutable and Append-Only Files, BSD’s mtree and Periodic Security Scans, BSD’s mtree and Periodic Security Scans, BSD’s mtree and Periodic Security Scans, Packaging Tools, Integrity checking with the BSD pkg_info command, utmp and wtmp Files, Accounting with BSD and Linux, Writable system files and directories, Reserved space, Listing processes with versions of Unix derived from BSD, including Linux, Unix Programming and System Administration
(see also FreeBSD; Mac OS X; NetBSD; OpenBSD)
append-only files, Immutable and Append-Only Files
chroot wrapper, Setting up the chroot( ) environment
exporting filesystems read-only, Writable system files and directories
exporting NFS directories, /etc/exports/usr/etc/exportfs
Fast File System (FFS) reserved space, Reserved space
forcible unmounts with, What the Superuser Can’t Do
history of, Unix escapes AT&TThe Unix Wars: Why Berkeley 4.2 over System V
host-based firewall for, Using a Host-Based Packet Firewall, The ipfw host-based firewall
immutable files, Immutable and Append-Only Files
inetd program and, The inetd Program
integrity-checking tools, BSD’s mtree and Periodic Security Scans
jail() system call, Using chroot( ), Setting up the chroot( ) environment
kernel security levels on, BSD Kernel Security Levels
modems and, Connecting a Modem to Your Computer
mtree program, BSD’s mtree and Periodic Security Scans
nonexecutable stack, The Lesson of the Internet Worm
package management commands, Package-Based Systems
packaging tools, Packaging Tools
periodic security scans, BSD’s mtree and Periodic Security Scans
permission options for, chmod: Changing a File’s Permissions
pkg (package) system, Integrity checking with the BSD pkg_info command
portmapper program, Sun RPC’s portmapper (UDP and TCP Ports 111)
process accounting with, Accounting with BSD and Linux
ps command, Listing processes with versions of Unix derived from BSD, including Linux
published resources on, Unix Programming and System Administration
secure terminals, Secure Terminals
server startup on, Startup on different Unix systems
SGID and sticky bits for directories, SGID and Sticky Bits on Directories
shadow password file, Shadow Password Files
SMB kernel support, Samba Client Security
spongy mounts, Hard, soft, and spongy mounts
TCP Wrappers support, Access Control Lists with TCP Wrappers
terminal security on, Secure Terminals: Limiting Where the Superuser Can Log In
utmp and wtmp log files, utmp and wtmp Files
vipw command, Disabling an Account by Changing the Account’s Password
“no dump” file attribute, Specialized Backup Programs
BSD/OS, Businesses adopt Unix, Second-Generation Commercial Unix Systems, Second-Generation Commercial Unix Systems
BSDI (Berkeley Software Design, Inc.), Second-Generation Commercial Unix Systems
buffers, Software Quality, The Lesson of the Internet Worm, Things to Avoid
checking boundaries, Things to Avoid
overflow attack, The Lesson of the Internet Worm
overruns, Software Quality
bugs, What Is Computer Security?, Software Quality, Keeping Secrets, Bugs (biological), Well-Known Bugs, An Empirical Study of the Reliability of Unix UtilitiesWhere’s the beef?, Tips on Avoiding Security-Related BugsBefore You Finish, Before You Finish, Programmed Threats: Definitions, Hardware Bugs, Buggy SoftwareBuggy Software, Hacker Challenges, Security Bugs That Never Get Fixed, Bugtraq
(see also insects, effects on hardware)
Bugtraq mailing list, Bugtraq
hacker challenges and, Hacker Challenges
hardware, Hardware Bugs
in Unix utilities, An Empirical Study of the Reliability of Unix UtilitiesWhere’s the beef?
keeping secret, Keeping Secrets
in NFS, Well-Known Bugs
security, Security Bugs That Never Get Fixed
software, Buggy SoftwareBuggy Software
testing for, Software Quality, Before You Finish
tips on avoiding, Tips on Avoiding Security-Related BugsBefore You Finish
Bugtraq mailing list, Bugtraq
Building a Secure Computer System (Gasser, Morrie), General Computer Security
Building in Big Brother: The Cryptographic Policy Debate (Hoffman, Lance J.), Cryptography Books
Building Internet Firewalls (Zwicky, Elizabeth D.; Chapman, D. Bren; Cooper, Simon), Network Technology and Security
Building Secure Software (Viega, John and McGraw, Gary), General Computer Security
bulk erasers, Sanitizing Media Before Disposal
Burning Chrome (Gibson, William), Understanding the Computer Security “Culture”
byte-by-byte comparisons, Comparison Copiesrdist