Home > Store

UNIX System Security: A Guide for Users and System Administrators

Register your product to gain access to bonus material or receive a coupon.

UNIX System Security: A Guide for Users and System Administrators


  • Your Price: $31.99
  • List Price: $39.99
  • We're temporarily out of stock, but order now and we'll send it to you later.


  • Copyright 1992
  • Edition: 1st
  • Book
  • ISBN-10: 0-201-56327-4
  • ISBN-13: 978-0-201-56327-6

Because the UNIX system was originally designed by programmers for use by other programmers, it was used in an environment of open cooperation where security was of minimal concern. Now that its use has spread to universities, businesses, and government, the confidential and sensitive nature of the data stored on UNIX systems has made the security of these systems of paramount importance.

Despite all the technical papers and workshops on UNIX security, this book is unique. UNIX System Security is the first up-to-date source to provide the UNIX system user or administrator with the information needed to protect the data and system from unauthorized use. By following the procedures described in this book and making use of the C programs and shell scripts provided as examples, you can protect your UNIX system from most attackers.

The author begins by examining four high-profile breaches of UNIX security as illustrations of how a UNIX system can be attacked. He then provides the information necessary to protect against these forms of attack, and offers the tools that can be used to do so. Focusing on the most recent release of Berkeley and System V UNIX, and such vendor derivatives as SunOS and ULTRIX, the book gives information that can be applied to any version of UNIX since Seventh Edition.

Issues discussed include account and password security, securing the file system, encryption and authentication systems, TCP/IP network security, the Network Information Service (NIS), NFS, RFS, workstation security, terminals and modems, and UUCP. Other chapters describe how to respond if your system is attacked and how to develop a comprehensive security policy for your organization. The book also gives comprehensive lists of freely available security software, and publications and mailing lists dealing with UNIX security.

"UNIX System Security should become popular among site administrators struggling to get a handle on security needs - especially since most vendor-specific manuals don't cover those well-known security 'holes' which can cause grief."
-Dr. Dobb's Journal

"David A. Curry's UNIX System Security: A Guide for Users and Administrators is highly recommended. This should end the morbid joke that UNIX Security books belong to the 'thin-book' category that includes The Dan Quayle Spell Checker and The Woody Allen Family Values Guide."
-Stan Kelly-Bootle, UNIX Review

"UNIX System Security: A Guide for Users and Administrators by David Curry, provides a comprehensive overview of key issues and offers practical advice for making UNIX systems more secure."
-UniForum Monthly

"UNIX System Security: A Guide for Users and Administrators by David A. Curry, presents a rigorous look at security issues on BDS 4 and Systme V Release 4, enlivened by references to four well-known security breakdowns from real life."

"UNIX System Security is so clearly written that even some of the more complex topics become easy to understand, and there are sections that even the most inexperienced user will comprehend. Curry has provided an essential text in security for both the beginning and experienced user."
-Sys Admin


Sample Content

Table of Contents

1. UNIX Security Stories.
The Internet Worm.
The Wily Hacker.
A True UNIX Trojan Horse.
Attacking UNIX with Viruses.

2. Account Security.
Expiration Dates.
Guest Accounts.
Well-known Accounts.
Group Accounts vs. Groups.
Protecting an Account.
Monitoring Account Security.

3. File System Security.
File Permissions.
The umask Value.
The write System Call.
The Sticky Bit on Directories.
The Set-Group-Id Bit on Directories.
Set-User-Id and Set-Group-Id Shell Scripts.
Monitoring File System Security.

4. Network Security.
Trusted Hosts.
The inetd Program.
The File Transfer Protocol (FTP).
Electronic Mail.
Forgery and Spoofing.
Network Configuration.
Sophisticated Network Attacks.
Monitoring Network Security.

5. NIS, NFS, and RFS.
The Network Information Service (NIS).
The Network File System (NFS).
The Remote File Sharing Service (RFS).

6. Workstations.
Single-User Mode.
Super-User Access.
Network Access.
The PROM Monitor.
Screen Access.

7. Terminals, Modems, and UUCP.
Dial-Up Modems.
Terminal Servers.
The UNIX-to-UNIX Copy Program (UUCP).

8. Responding to Attacks.

9. Encryption and Authentication.
Encrypting and Authenticating Electronic Mail.

10. Security Policies.
Establishing Policies and Why.
Access to the System.
Password Policies.
Proper Use.
System Staff Rights and Responsibilities.
Copyrights and Licenses.
Guidelines for the Secure Operation of the Internet.

11. Security Software.
Obtaining Fixes and New Versions.
Publicly Available Software.
RSA Privacy-Enhanced Mail.
The National Computer Security Center.

12. Obtaining Security Information.
Computer Security Incident Response Capabilities.
Forming a CSIRC.
Vendor Security Notification.
Mailing Lists.
USENET Newsgroups.
Suggested Reading.

A Password Cracker.
A File System Checker.
Kerberos Dialogue.
A Complete Security Policy.
UNIX Security Checklist.

Index. 0201563274T04062001


The UNIX operating system, although now in widespread use in environments concerned about security, was not really designed with security in mind (Ritchie, 1975). This does not mean that UNIX does not provide any security mechanisms; indeed, several very good ones are available. However, most "out of the box" installation procedures from companies such as Sun Microsystems, Digital Equipment Corporation, and AT&T still set up the system in much the same way as it was originally shipped 15 years ago: with little or no security enabled.

The reasons for this state of affairs are largely historical. UNIX was originally designed by programmers for use by other programmers. The environment in which it was used was one of open cooperation, not one of privacy. Programmers typically collaborated with each other on projects, and hence preferred to be able to share their files with each other without having to jump over security hurdles. Because the first sites outside of Bell Laboratories to install UNIX were university research laboratories, where a similar environment existed, no real need for greater security was seen until some time later.

In the early 1980s, many universities began to move their UNIX systems out of the laboratories and into the computer centers, allowing (or forcing) the user population as a whole to use this new and wonderful system. Many businesses and government sites began to install UNIX systems as well, particularly as desktop workstations became more powerful and affordable. Thus, the UNIX operating system is no longer being used only in environments where open collaboration is the primary goal. Universities require their students to use the system for class assignments, yet they do not want the students to be able to copy from each other. Businesses use their UNIX systems for confidential tasks such as bookkeeping and payroll. And the government uses UNIX for numerous unclassified yet sensitive purposes.

To complicate matters, new features have been added to UNIX over the years, making security even more difficult to control. Perhaps the most problematic features are those relating to networking: remote login, remote command execution, file transfer, network file systems, and electronic mail. All of these features have increased the utility and usability of UNIX by untold amounts. However, these same features, along with the widespread connection of UNIX systems to the Internet (Quarterman and Hoskins, 1986) and other networks, have opened up many new areas of vulnerability to unauthorized abuse of the system.

Purpose of the Book

Over the years, a great deal has been written about UNIX system security. Papers are presented at almost every USENIX and Uniforum conference as well as others, and the USENIX Association sponsors an annual workshop on UNIX security. Electronic mailing lists exist for the purposes of reporting security problems and receiving fixes for them. Freely available software exists to analyze UNIX systems for security problems and report or correct them. But, in spite of all the work being done in this area, the results of this work have never been collected in one place, and average users or system administrators of UNIX system still do not have the information necessary to protect their data and their systems from unauthorized use.

This book provides the information necessary to protect a UNIX system from unauthorized access. The methods an attacker can use to gain access to a UNIX system are described, as well as how to defend against them. In describing the bugs and loopholes used by attackers, it is sometimes necessary to provide information on how they are used. However, we try to strike a midway point between providing enough information so that the reader can understand the problem, while not providing enough information for an attacker to use the text as a cookbook for breaking into systems.

The primary focus of the book is on the most recent versions of UNIX (4.2BSD and 4.3BSD from Berkeley) and their most recent vendor derivatives (SunOS4.x, ULTRIX 4.x, etc.), and System V Release 4 from AT&T . However, most of the information presented can be applied, with minor changes, to any version of UNIX since Seventh Edition. An attempt has been made to make the shell scripts and C programs used in the examples as portable as possible by avoiding many of the "convenience" features added in some versions of the operating system. While this means that some of the examples are not as efficient or "clean" as they could be, it also means that they will work on more systems. Industrious readers may feel free to recode any of the examples to use whatever new features are desired.

By following the procedures described in the text, and making use of the programs and shell scripts provided as examples, it is possible to secure a UNIX system against most attackers, even if it is connected to wide-area networks such as the Internet.

Organization of the Book

The book is divided into five parts.

In Chapter 1, we begin our discussion by considering four well-known cases of UNIX security being broken. This serves to make the reader aware of some possible types of attack on UNIX systems, as well as to provide a framework for later discussion.

Most of the information required to protect a single UNIX system is presented in the next three chapters. Chapter 2 discusses account and password security. File system security is covered in Chapter 3. Chapter 4 describes network security.

The third part of the book discusses some topics in more detail. These topics pertain primarily to networks of UNIX systems and systems that provide remote access. Chapter 5 describes the Network Information Service (NIS) (formerly called Sun Yellow Pages, or YP), the Network File System (NFS), and the Remote File Sharing (RFS) service. Workstations and the particular security problems they present are covered in Chapter 6.Terminals, modems, and the UNIX-to-UNIX copy program (UUCP) are discussed in Chapter 7. Chapter 8 describes methods for detecting and responding to break-ins, and serves to separate the discussion of specific UNIX security issues from the material in the last part of the book.

The last chapters of the book cover topics that are directly related to UNIX system security, but are not part of the UNIX system itself. Chapter 9 discusses encryption and authentication, and the software and hardware devices used to implement them. Security policies are discussed in Chapter 10. Chapters 11 and 12 discuss publicly available security-related software and how to obtain information about current threats to UNIX security.


This book assumes that the reader is familiar with the UNIX system, its commands, and its terminology. Readers who are unfamiliar with UNIX should consult A Practical Guide to the UNIX System, Third Edition by Mark G. Sobell, published by Addison-Wesley. Readers who wish to learn more about UNIX system administration (which will be helpful, but not necessary, in understanding some parts of this book) should consult the UNIX System Administration Handbook by Evi Nemeth, Garth Snyder, and Scott Seebass, published by Prentice Hall. Readers who would like to learn more about the history and "culture" of UNIX may wish to consult Life With UNIX by Don Libes and Sandy Ressler, published by Prentice Hall.


First and foremost, I am grateful to my wife, Cathy, and our sons, Trevor and Sean. Their love, patience, and encouragement helped make this book a reality.

Many thanks to the people who reviewed the book and provided technical and editorial critiques: Ralph Droms (Bucknell University), Tom Duff (AT&T Bell Laboratories), Fred Grampp (AT&T Bell Laboratories), Dan Farmer (Sun Microsystems), Brian Kernighan (AT&T Bell Laboratories), Rich Kulawiec (Hospital of the University of Pennsylvania), Doug McIlroy (AT&T Bell Laboratories), Michael Merritt (AT&T Bell Laboratories), Jim Reeds (AT&T Bell Laboratories), Jeff Schwab (Purdue University), and Steve Simmons (Industrial Technology Institute). Thanks also to John Wait and Alan Apt, my editors at Addison-Wesley, for their support and assistance while writing the book.

A good portion of the information about UNIX security presented in this book has come from discussions with friends and colleagues, and from suggestions received from the readers of an earlier paper I wrote on UNIX security (Curry, 1990). Thanks to all of you, especially Matt Bishop, Dan Farmer, Phil Klimbal, Doug Moran, Donn Parker, Peter Neumann, and Jeff Schwab. Finally, special thanks go to Rich Lynn of Digital Equipment Corporation, who obtained a copy of the ULTRIX Security Guide for Administrators for me, to Ken van Wyk of the CERT/CC, who answered my several requests for information, and to John Wack of NIST, who provided a wealth of information about how to form a response team, and about the FIRST.

This book was produced using AT&T's Documenter's Workbench, Release 2.0 (eqn, tbl, troff) with the -ms macro package on a Sun Microsystems SPARC station 1 running SunOS 4.1.1. PostScript output was produced by the TransScript package from Adobe Systems. The index was generated using a set of awk and sh programs described in (Bentley and Kernighan, 1988).

The author would like to hear from any readers with comments, suggestions, or bug reports: davy@ecn.purdue.edu.



Submit Errata

More Information

InformIT Promotional Mailings & Special Offers

I would like to receive exclusive offers and hear about products from InformIT and its family of brands. I can unsubscribe at any time.


Pearson Education, Inc., 221 River Street, Hoboken, New Jersey 07030, (Pearson) presents this site to provide information about products and services that can be purchased through this site.

This privacy notice provides an overview of our commitment to privacy and describes how we collect, protect, use and share personal information collected through this site. Please note that other Pearson websites and online products and services have their own separate privacy policies.

Collection and Use of Information

To conduct business and deliver products and services, Pearson collects and uses personal information in several ways in connection with this site, including:

Questions and Inquiries

For inquiries and questions, we collect the inquiry or question, together with name, contact details (email address, phone number and mailing address) and any other additional information voluntarily submitted to us through a Contact Us form or an email. We use this information to address the inquiry and respond to the question.

Online Store

For orders and purchases placed through our online store on this site, we collect order details, name, institution name and address (if applicable), email address, phone number, shipping and billing addresses, credit/debit card information, shipping options and any instructions. We use this information to complete transactions, fulfill orders, communicate with individuals placing orders or visiting the online store, and for related purposes.


Pearson may offer opportunities to provide feedback or participate in surveys, including surveys evaluating Pearson products, services or sites. Participation is voluntary. Pearson collects information requested in the survey questions and uses the information to evaluate, support, maintain and improve products, services or sites, develop new products and services, conduct educational research and for other purposes specified in the survey.

Contests and Drawings

Occasionally, we may sponsor a contest or drawing. Participation is optional. Pearson collects name, contact information and other information specified on the entry form for the contest or drawing to conduct the contest or drawing. Pearson may collect additional personal information from the winners of a contest or drawing in order to award the prize and for tax reporting purposes, as required by law.


If you have elected to receive email newsletters or promotional mailings and special offers but want to unsubscribe, simply email information@informit.com.

Service Announcements

On rare occasions it is necessary to send out a strictly service related announcement. For instance, if our service is temporarily suspended for maintenance we might send users an email. Generally, users may not opt-out of these communications, though they can deactivate their account information. However, these communications are not promotional in nature.

Customer Service

We communicate with users on a regular basis to provide requested services and in regard to issues relating to their account we reply via email or phone in accordance with the users' wishes when a user submits their information through our Contact Us form.

Other Collection and Use of Information

Application and System Logs

Pearson automatically collects log data to help ensure the delivery, availability and security of this site. Log data may include technical information about how a user or visitor connected to this site, such as browser type, type of computer/device, operating system, internet service provider and IP address. We use this information for support purposes and to monitor the health of the site, identify problems, improve service, detect unauthorized access and fraudulent activity, prevent and respond to security incidents and appropriately scale computing resources.

Web Analytics

Pearson may use third party web trend analytical services, including Google Analytics, to collect visitor information, such as IP addresses, browser types, referring pages, pages visited and time spent on a particular site. While these analytical services collect and report information on an anonymous basis, they may use cookies to gather web trend information. The information gathered may enable Pearson (but not the third party web trend services) to link information with application and system log data. Pearson uses this information for system administration and to identify problems, improve service, detect unauthorized access and fraudulent activity, prevent and respond to security incidents, appropriately scale computing resources and otherwise support and deliver this site and its services.

Cookies and Related Technologies

This site uses cookies and similar technologies to personalize content, measure traffic patterns, control security, track use and access of information on this site, and provide interest-based messages and advertising. Users can manage and block the use of cookies through their browser. Disabling or blocking certain cookies may limit the functionality of this site.

Do Not Track

This site currently does not respond to Do Not Track signals.


Pearson uses appropriate physical, administrative and technical security measures to protect personal information from unauthorized access, use and disclosure.


This site is not directed to children under the age of 13.


Pearson may send or direct marketing communications to users, provided that

  • Pearson will not use personal information collected or processed as a K-12 school service provider for the purpose of directed or targeted advertising.
  • Such marketing is consistent with applicable law and Pearson's legal obligations.
  • Pearson will not knowingly direct or send marketing communications to an individual who has expressed a preference not to receive marketing.
  • Where required by applicable law, express or implied consent to marketing exists and has not been withdrawn.

Pearson may provide personal information to a third party service provider on a restricted basis to provide marketing solely on behalf of Pearson or an affiliate or customer for whom Pearson is a service provider. Marketing preferences may be changed at any time.

Correcting/Updating Personal Information

If a user's personally identifiable information changes (such as your postal address or email address), we provide a way to correct or update that user's personal data provided to us. This can be done on the Account page. If a user no longer desires our service and desires to delete his or her account, please contact us at customer-service@informit.com and we will process the deletion of a user's account.


Users can always make an informed choice as to whether they should proceed with certain services offered by InformIT. If you choose to remove yourself from our mailing list(s) simply visit the following page and uncheck any communication you no longer want to receive: www.informit.com/u.aspx.

Sale of Personal Information

Pearson does not rent or sell personal information in exchange for any payment of money.

While Pearson does not sell personal information, as defined in Nevada law, Nevada residents may email a request for no sale of their personal information to NevadaDesignatedRequest@pearson.com.

Supplemental Privacy Statement for California Residents

California residents should read our Supplemental privacy statement for California residents in conjunction with this Privacy Notice. The Supplemental privacy statement for California residents explains Pearson's commitment to comply with California law and applies to personal information of California residents collected in connection with this site and the Services.

Sharing and Disclosure

Pearson may disclose personal information, as follows:

  • As required by law.
  • With the consent of the individual (or their parent, if the individual is a minor)
  • In response to a subpoena, court order or legal process, to the extent permitted or required by law
  • To protect the security and safety of individuals, data, assets and systems, consistent with applicable law
  • In connection the sale, joint venture or other transfer of some or all of its company or assets, subject to the provisions of this Privacy Notice
  • To investigate or address actual or suspected fraud or other illegal activities
  • To exercise its legal rights, including enforcement of the Terms of Use for this site or another contract
  • To affiliated Pearson companies and other companies and organizations who perform work for Pearson and are obligated to protect the privacy of personal information consistent with this Privacy Notice
  • To a school, organization, company or government agency, where Pearson collects or processes the personal information in a school setting or on behalf of such organization, company or government agency.


This web site contains links to other sites. Please be aware that we are not responsible for the privacy practices of such other sites. We encourage our users to be aware when they leave our site and to read the privacy statements of each and every web site that collects Personal Information. This privacy statement applies solely to information collected by this web site.

Requests and Contact

Please contact us about this Privacy Notice or if you have any requests or questions relating to the privacy of your personal information.

Changes to this Privacy Notice

We may revise this Privacy Notice through an updated posting. We will identify the effective date of the revision in the posting. Often, updates are made to provide greater clarity or to comply with changes in regulatory requirements. If the updates involve material changes to the collection, protection, use or disclosure of Personal Information, Pearson will provide notice of the change through a conspicuous notice on this site or other appropriate way. Continued use of the site after the effective date of a posted revision evidences acceptance. Please contact us if you have questions or concerns about the Privacy Notice or any objection to any revisions.

Last Update: November 17, 2020