home *** CD-ROM | disk | FTP | other *** search
/ Simtel MSDOS 1992 June / SIMTEL_0692.cdr / msdos / trojanpr / ibmpaper.arc / IBMPAPER.TXT
Encoding:
Internet Message Format  |  1989-06-09  |  84.3 KB

  1. Date: Mon, 27 Mar 89 15:56:48 EST
  2. From: CHESS@IBM.COM
  3.  
  4.  
  5.  
  6.           Coping with Computer Viruses and Related Problems
  7.  
  8.           Steve R. White
  9.           David M. Chess
  10.           IBM Thomas J. Watson Research Center
  11.           Yorktown Heights, NY
  12.  
  13.           Chengi Jimmy Kuo
  14.           IBM Los Angeles Scientific Center
  15.           Los Angeles, CA
  16.  
  17.           Research Report (RC 14405)
  18.           January 30, 1989
  19.  
  20.  
  21.  
  22.           This research report is provided without restriction;
  23.           we encourage its redistribution.
  24.  
  25.  
  26.  
  27.  
  28.  
  29.           Copies may be requested from:
  30.  
  31.           IBM Thomas J. Watson Research Center
  32.           Distribution Services F-11 Stormytown
  33.           Post Office Box 218
  34.           Yorktown Heights, New York 10598
  35.  
  36.           (This report will be available from this address up to
  37.            one year after the IBM publication date (up to Jan 1990))
  38.  
  39.  
  40.           This online version differs from the hardcopy report only
  41.           in pagination, and in using *asterisks* for emphasis.  It
  42.           is formatted to print at 66 lines per page, and 80 or so
  43.           characters per line (including a 10 character margin on
  44.           either side).
  45.  
  46.  
  47.  
  48.  
  49.  
  50.  
  51.  
  52.  
  53.  
  54.  
  55.  
  56.  
  57.  
  58.  
  59.  
  60.  
  61.  
  62.  
  63.  
  64.  
  65.  
  66.  
  67.  
  68.  
  69.  
  70.  
  71.  
  72.  
  73.  
  74.  
  75.  
  76.  
  77.  
  78.  
  79.  
  80.  
  81.                      Coping with Computer Viruses and Related Problems
  82.  
  83.  
  84.  
  85.  
  86.  
  87.  
  88.  
  89.  
  90.  
  91.  
  92.                                                         Steve R. White
  93.                                                         David M. Chess
  94.                                   IBM Thomas J. Watson Research Center
  95.                                                   Yorktown Heights, NY
  96.  
  97.                                                       Chengi Jimmy Kuo
  98.                                      IBM Los Angeles Scientific Center
  99.                                                        Los Angeles, CA
  100.  
  101.  
  102.  
  103.  
  104.  
  105.                                        Research Report Number RC 14405
  106.  
  107.                                                       January 30, 1989
  108.  
  109.  
  110.  
  111.  
  112.  
  113.  
  114.  
  115.  
  116.  
  117.  
  118.  
  119.  
  120.  
  121.  
  122.  
  123.  
  124.  
  125.  
  126.  
  127.  
  128.  
  129.  
  130.  
  131.  
  132.  
  133.  
  134.  
  135.  
  136.  
  137.  
  138.           ABSTRACT
  139.  
  140.  
  141.  
  142.           We discuss computer viruses and related problems.  Our
  143.           intent is to help both executive and technical managers
  144.           understand the problems that viruses pose, and to suggest
  145.           practical steps they can take to help protect their
  146.           computing systems.
  147.  
  148.  
  149.  
  150.  
  151.  
  152.  
  153.  
  154.  
  155.  
  156.  
  157.  
  158.  
  159.  
  160.  
  161.  
  162.  
  163.  
  164.  
  165.  
  166.  
  167.  
  168.  
  169.  
  170.  
  171.  
  172.  
  173.  
  174.  
  175.  
  176.  
  177.  
  178.  
  179.  
  180.  
  181.  
  182.  
  183.  
  184.  
  185.  
  186.  
  187.  
  188.  
  189.  
  190.  
  191.  
  192.  
  193.  
  194.           Abstract                                                  ii
  195.  
  196.  
  197.  
  198.  
  199.  
  200.  
  201.  
  202.  
  203.  
  204.           CONTENTS
  205.  
  206.  
  207.  
  208.           1.0  Executive Summary   . . . . . . . . . . . . . . . . . 1
  209.           1.1  What Is a Computer Virus?   . . . . . . . . . . . . . 1
  210.           1.2  How Can Computer Viruses Affect an Organization?  . . 2
  211.           1.3  How Serious Is The Problem?   . . . . . . . . . . . . 2
  212.           1.4  Summary and Recommendations   . . . . . . . . . . . . 3
  213.  
  214.           2.0  Coping with Computer Viruses: A Guide for Technical
  215.            Management  . . . . . . . . . . . . . . . . . . . . . . . 5
  216.           2.1  How Viruses Infect Computing Systems  . . . . . . . . 5
  217.           2.2  How Viruses Differ From Other Security Threats  . . . 6
  218.           2.3  General Security Policies   . . . . . . . . . . . . . 7
  219.             2.3.1  User Education  . . . . . . . . . . . . . . . . . 7
  220.             2.3.2  Backups   . . . . . . . . . . . . . . . . . . . . 7
  221.           2.4  Decreasing the Risk of Viral Infection  . . . . . . . 8
  222.             2.4.1  Isolated Systems  . . . . . . . . . . . . . . . . 8
  223.             2.4.2  Limited-Function Systems  . . . . . . . . . . . . 9
  224.             2.4.3  Policies for Software Repositories  . . . . . .  10
  225.             2.4.4  Policies for Production Systems   . . . . . . .  11
  226.           2.5  Detecting Viral Infections  . . . . . . . . . . . .  12
  227.             2.5.1  Watching for Unexpected Things Happening  . . .  13
  228.             2.5.2  Some Symptoms of Known Viruses  . . . . . . . .  13
  229.             2.5.3  Watching for Changes to Executable Objects  . .  15
  230.             2.5.4  Using External Information Sources  . . . . . .  17
  231.           2.6  Containing Viral Infections   . . . . . . . . . . .  17
  232.             2.6.1  The Importance of Early Detection   . . . . . .  17
  233.             2.6.2  The Importance of Rapid Action  . . . . . . . .  18
  234.           2.7  Recovering from Viral Infections  . . . . . . . . .  19
  235.             2.7.1  Restoration and Backups   . . . . . . . . . . .  19
  236.             2.7.2  Virus-Removing Programs   . . . . . . . . . . .  20
  237.             2.7.3  Watching for Re-Infection   . . . . . . . . . .  20
  238.           2.8  Summary and Recommendations   . . . . . . . . . . .  21
  239.  
  240.           For Further Reading  . . . . . . . . . . . . . . . . . .  23
  241.  
  242.           Glossary   . . . . . . . . . . . . . . . . . . . . . . .  24
  243.  
  244.           Appendix: Viral Infections in PC-DOS   . . . . . . . . .  27
  245.  
  246.  
  247.  
  248.  
  249.  
  250.  
  251.  
  252.  
  253.  
  254.  
  255.  
  256.  
  257.  
  258.  
  259.  
  260.           Contents                                                 iii
  261.  
  262.  
  263.  
  264.  
  265.  
  266.  
  267.  
  268.  
  269.  
  270.           PREFACE
  271.  
  272.  
  273.  
  274.           While this document has been widely reviewed, and many
  275.           helpful suggestions have been incorporated, the authors are
  276.           entirely responsible for its present content.  It does not
  277.           represent the opinions, policies, or recommendations of IBM
  278.           or any other organization.
  279.  
  280.  
  281.  
  282.  
  283.  
  284.  
  285.  
  286.  
  287.  
  288.  
  289.  
  290.  
  291.  
  292.  
  293.  
  294.  
  295.  
  296.  
  297.  
  298.  
  299.  
  300.  
  301.  
  302.  
  303.  
  304.  
  305.  
  306.  
  307.  
  308.  
  309.  
  310.  
  311.  
  312.  
  313.  
  314.  
  315.  
  316.  
  317.  
  318.  
  319.  
  320.  
  321.  
  322.  
  323.  
  324.  
  325.  
  326.           Preface                                                   iv
  327.  
  328.  
  329.  
  330.  
  331.  
  332.  
  333.  
  334.  
  335.  
  336.           1.0  EXECUTIVE SUMMARY
  337.  
  338.  
  339.  
  340.           Computer viruses present a relatively new kind of security
  341.           problem in computing systems.  The purpose of this section
  342.           is to acquaint the senior management of an organization with
  343.           the nature of the problem.  It also outlines some of the
  344.           steps that can be taken to reduce the organization's risk
  345.           from computer viruses and other, similar, problems.
  346.  
  347.           Traditional computer security measures are helpful, but new
  348.           measures are needed to deal with the problems effectively.
  349.           The computer security management of the organization will
  350.           play a key role in reducing the risk.  But education and
  351.           ongoing participation of the users are also vital.
  352.  
  353.  
  354.  
  355.  
  356.           1.1  WHAT IS A COMPUTER VIRUS?
  357.  
  358.  
  359.           A computer virus is one kind of threat to the security and
  360.           integrity of computer systems.  Like other threats, a
  361.           computer virus can cause the loss or alteration of programs
  362.           or data, and can compromise their confidentiality.  Unlike
  363.           many other threats, a computer virus can spread from program
  364.           to program, and from system to system, without direct human
  365.           intervention.
  366.  
  367.           The essential component of a virus is a set of instructions
  368.           which, when executed, spreads itself to other, previously
  369.           unaffected, programs or files.  A typical computer virus
  370.           performs two functions.  First, it copies itself into
  371.           previously-uninfected programs or files.  Second, (perhaps
  372.           after a specific number of executions, or on a specific
  373.           date) it executes whatever other instructions the virus
  374.           author included in it.  Depending on the motives of the
  375.           virus author, these instructions can do anything at all,
  376.           including displaying a message, erasing files or subtly
  377.           altering stored data.  In some cases, a virus may contain no
  378.           intentionally harmful or disruptive instructions at all.
  379.           Instead, it may cause damage by replicating itself and
  380.           taking up scarce resources, such as disk space, CPU time, or
  381.           network connections.
  382.  
  383.           There are several problems similar to computer viruses.
  384.           They too have colorful names:  worms, bacteria, rabbits, and
  385.           so on.  Definitions of them are given in the glossary.  Each
  386.           shares the property of replicating itself within the
  387.           computing system.  This is the property on which we will
  388.           focus, using viruses as an example.  There are also a
  389.           variety of security issues other than viruses.  Here, we
  390.  
  391.  
  392.           Executive Summary                                          1
  393.  
  394.  
  395.  
  396.  
  397.  
  398.  
  399.  
  400.  
  401.  
  402.           will deal only with viruses and related problems, since new
  403.           measures are required to deal with them effectively.
  404.  
  405.  
  406.  
  407.           1.2  HOW CAN COMPUTER VIRUSES AFFECT AN ORGANIZATION?
  408.  
  409.  
  410.           Let us examine a particular sequence of events, by which a
  411.           virus could enter an organization and spread within it.
  412.           Suppose that the organization hires an outside person to
  413.           come in and perform some work.  Part of that person's work
  414.           involves working on one of the organization's personal
  415.           computers.  The person brings in a few programs to aid in
  416.           this work, such as a favorite text editor.
  417.  
  418.           Without the person having realized it, the text editor may
  419.           be infected with a virus.  Using that editor on one of the
  420.           organization's machines causes the virus to spread from the
  421.           editor to one of the programs stored on the organization's
  422.           machine, perhaps to a spreadsheet program.  The virus has
  423.           now entered the organization.
  424.  
  425.           Even when the outside person leaves, the virus remains on
  426.           the machine that it infected, in the spreadsheet program.
  427.           When an employee uses that spreadsheet subsequently, the
  428.           virus can spread to another program, perhaps to a directory
  429.           listing program that the employee keeps on the same floppy
  430.           disk as the spreadsheet data files.  The listing program is
  431.           then infected, and the infection can be spread to other
  432.           computers to which this floppy disk is taken.  If the
  433.           employee's personal computer is connected to the
  434.           organization's network, the employee may send the listing
  435.           program to another user over the network.  In either case,
  436.           the virus can spread to more users, and more machines, via
  437.           floppy disks or networks.  Each copy of the virus can make
  438.           multiple copies of itself, and can infect any program to
  439.           which it has access.  As a result, the virus may be able to
  440.           spread throughout the organization in a relatively short
  441.           time.
  442.  
  443.           Each of the infected programs in each of the infected
  444.           machines can execute whatever other instructions the virus
  445.           author intended.  If these instructions are harmful or
  446.           disruptive, the pervasiveness of the virus may cause the
  447.           harm to be widespread.
  448.  
  449.  
  450.  
  451.           1.3  HOW SERIOUS IS THE PROBLEM?
  452.  
  453.  
  454.           Traditional security measures have attempted to limit the
  455.           number of security incidents to an acceptable level.  A
  456.  
  457.  
  458.           Executive Summary                                          2
  459.  
  460.  
  461.  
  462.  
  463.  
  464.  
  465.  
  466.  
  467.  
  468.           single incident of lost files in a year may be an acceptable
  469.           loss, for instance.  While this is important, it only
  470.           addresses part of the problem of viruses.  Since a single
  471.           virus may be able to  spread throughout an organization, the
  472.           damage that it could cause may be much greater than what
  473.           could be caused by any individual computer user.
  474.  
  475.           Limiting the number of initial viral infections of an
  476.           organization is important, but it is often not feasible to
  477.           prevent them entirely.  As a result, it is important to be
  478.           able to deal with them when they occur.
  479.  
  480.           Most actual viruses discovered to date have either been
  481.           relatively benign, or spread rather slowly.  The actual
  482.           damage that they have caused has been limited accordingly.
  483.           In some cases, though, thousands of machines have been
  484.           affected.  Viruses can easily be created which are much less
  485.           benign.  Their *potential* damage is indeed large.
  486.           Organizations should evaluate their vulnerability to this
  487.           new threat, and take actions to limit their risks.
  488.  
  489.  
  490.  
  491.  
  492.           1.4  SUMMARY AND RECOMMENDATIONS
  493.  
  494.  
  495.           o   A computer virus is a program that can infect other
  496.               programs by modifying them to include a copy of itself.
  497.               When the infected programs are executed, the virus
  498.               spreads itself to still other programs.
  499.  
  500.           o   Viruses can spread rapidly in a network or computing
  501.               system and can cause widespread damage.
  502.  
  503.           o   Unlike many other security threats, viruses can enter a
  504.               given computing system without anyone intending them to.
  505.  
  506.  
  507.           o   There are no known ways to make a general computing
  508.               system completely immune from viral attacks, but there
  509.               are steps you can take to decrease the risks:
  510.  
  511.               -   Use good general security practices.  (For a more
  512.                   complete discussion of these points, and some
  513.                   examples of others, see reference (6).)
  514.  
  515.                   --  Keep good backups of critical data and programs.
  516.                   --  Periodically review overall controls to
  517.                       determine weaknesses.
  518.                   --  Use access control facilities to limit access to
  519.                       information by users, consistent with their job
  520.                       duties and management policies.  Audit accesses
  521.                       that do occur.
  522.  
  523.  
  524.           Executive Summary                                          3
  525.  
  526.  
  527.  
  528.  
  529.  
  530.  
  531.  
  532.  
  533.  
  534.                   --  Do not use network connections to outside
  535.                       organizations without a mutual review of
  536.                       security practices.
  537.                   --  Consider limiting electronic mail communications
  538.                       to non-executable files.  Separate
  539.                       communications that must move executable files
  540.                       from electronic mail, so that they can be
  541.                       separately controlled.
  542.                   --  Make security education a prerequisite to any
  543.                       computer use.
  544.  
  545.               -   Put a knowledgeable group in place to deal with
  546.                   virus incidents.
  547.  
  548.                   --  The group may be a formal part of the
  549.                       organization, or may be an informal collection
  550.                       of knowledgeable people.
  551.  
  552.                   --  The group should be responsible for educating
  553.                       users about the threat of viruses, providing
  554.                       accurate information about viruses, responding
  555.                       to reports of viruses, and dealing with viral
  556.                       infections when they occur.
  557.  
  558.                   --  Make sure each employee who works with a
  559.                       computer knows how to contact this group if they
  560.                       suspect a viral infection.
  561.  
  562.               -   Develop a plan to deal with viruses *before* there is
  563.                   a problem.
  564.  
  565.                   --  Decrease the risks of an initial infection, from
  566.                       internal and external sources.
  567.                   --  Put mechanisms in place to detect viral
  568.                       infections quickly.
  569.                   --  Develop procedures to contain an infection once
  570.                       one is detected.
  571.                   --  Know how to recover from a viral infection.
  572.  
  573.               -   Test the plan periodically, as you would test a fire
  574.                   evacuation plan.
  575.  
  576.                   --  But *do not* use a real virus to test the plan!
  577.  
  578.  
  579.  
  580.  
  581.  
  582.  
  583.  
  584.  
  585.  
  586.  
  587.  
  588.  
  589.  
  590.           Executive Summary                                          4
  591.  
  592.  
  593.  
  594.  
  595.  
  596.  
  597.  
  598.  
  599.  
  600.           2.0  COPING WITH COMPUTER VIRUSES: A GUIDE FOR TECHNICAL
  601.           MANAGEMENT
  602.  
  603.  
  604.  
  605.           Once an organization makes a commitment to deal with the
  606.           problems of computer viruses, there are specific areas which
  607.           should receive attention.  The purpose of this section is to
  608.           acquaint technical management with the problems and to
  609.           indicate the actions that can be taken to limit the risks
  610.           posed by viruses.
  611.  
  612.  
  613.  
  614.           2.1  HOW VIRUSES INFECT COMPUTING SYSTEMS
  615.  
  616.  
  617.           There are many ways in which a system can become infected
  618.           with a virus.  Any time a program is run which can alter one
  619.           or more other programs, there is the possibility of viral
  620.           infection.  Any time a user executes a program which is
  621.           written by anyone else, compiled by a compiler, or linked
  622.           with run time libraries, all the resources to which that
  623.           program has access are in the hands of every person who
  624.           contributed to that program, that compiler, or those
  625.           libraries.
  626.  
  627.           The initial introduction of an infected program can occur
  628.           through a large variety of channels, including:
  629.  
  630.           o   Software introduced into or used on the system by an
  631.               outsider who had access to the system,
  632.  
  633.           o   Software used at home by an employee whose home computer
  634.               system is, unknown to the employee, itself infected,
  635.  
  636.           o   Software purchased from a commercial software company
  637.               whose production facilities are infected,
  638.  
  639.           o   Software that turns out to be infected that has been
  640.               down-loaded from public bulletin boards for business
  641.               use, or by employees,
  642.  
  643.           o   Software intentionally infected by a malicious or
  644.               disgruntled employee,
  645.  
  646.           o   *Any* other time that a piece of software (including
  647.               programs, operating systems, and so on) is created
  648.               within the organization, or brought in from *any*
  649.               outside source.
  650.  
  651.           See the appendix for an example of sources and locations of
  652.           possible infection for one operating system.
  653.  
  654.  
  655.           Coping with Computer Viruses: A Guide for Technical
  656.           Management                                                 5
  657.  
  658.  
  659.  
  660.  
  661.  
  662.  
  663.  
  664.  
  665.  
  666.           2.2  HOW VIRUSES DIFFER FROM OTHER SECURITY THREATS
  667.  
  668.  
  669.  
  670.           There are many kinds of threats to security.  Threats
  671.           traceable to dial-in systems are greatly reduced with the
  672.           use of call-back systems.  Simple threats created by
  673.           disgruntled employees can often be traced to the person
  674.           responsible.  One important thing that makes the virus
  675.           different from all the rest is its untraceability.  Except
  676.           in rare cases, the only way a virus' author becomes known is
  677.           if the author admits to ownership.  As a result, an author
  678.           can create a virus with reasonable certainty that he will
  679.           not be discovered.  This allows great latitude in the design
  680.           of the destructive portion of the virus.
  681.  
  682.           The only perfect ways to protect against viral infection are
  683.           isolation and reduced functionality.  A computer system
  684.           cannot be infected if it runs only one fixed program, and
  685.           cannot have new programs either loaded or created on it.
  686.           But this is clearly not very useful in many circumstances.
  687.           So there is almost always some exposure.  As with other
  688.           security concerns, it is a matter of weighing benefits,
  689.           practicality, and potential risks, and then taking
  690.           cost-effective action to help control those risks.
  691.  
  692.           Viruses exhibit elements of many other security threats.
  693.           (See the Glossary for a summary of some of these threats.)
  694.           There are important differences, though.  Dr. Fred Cohen,
  695.           who has done much of the original research on computer
  696.           viruses, defines a virus as:
  697.  
  698.               a program that can "infect" other programs by modifying
  699.               them to include a possibly evolved copy of itself.  (See
  700.               reference (1).)
  701.  
  702.           But a virus is more than the part that replicates itself.
  703.           There is usually also a potentially damaging portion.  This
  704.           portion could be a "time bomb" (on November 11th, display a
  705.           political message), a "logic bomb" (when it sees a certain
  706.           write to disk, it also corrupts the file structure), or
  707.           anything else the virus author can design.  The variety of
  708.           possible effects is part of the reason why the notion of a
  709.           virus is so confusing to many people.  The term "virus" is
  710.           sometimes misused to refer to anything undesirable that can
  711.           happen to a computer.  This is incorrect.  The thing that
  712.           makes viruses and related threats different from other
  713.           problems is that they spread.
  714.  
  715.  
  716.  
  717.  
  718.  
  719.  
  720.  
  721.           Coping with Computer Viruses: A Guide for Technical
  722.           Management                                                 6
  723.  
  724.  
  725.  
  726.  
  727.  
  728.  
  729.  
  730.  
  731.  
  732.           2.3  GENERAL SECURITY POLICIES
  733.  
  734.  
  735.  
  736.           2.3.1  User Education
  737.  
  738.  
  739.           Good security policies depend on the knowledge and
  740.           cooperation of the users.  This is just as true of security
  741.           against viruses as it is of policies about password
  742.           management.  Users should be aware of the dangers that
  743.           exist, should know what to do if they suspect they have
  744.           found a security problem.  In particular, they should know
  745.           whom to call if they have questions or suspicions, and
  746.           should know what to do, and what not to do, to minimize
  747.           security risks.  Users should be encouraged to feel that
  748.           security measures are things that they want to do for their
  749.           own benefit, rather than things that are required for no
  750.           rational reason.
  751.  
  752.           A strategy to detect and contain viruses is described below.
  753.           An important part of that strategy is for users to know whom
  754.           to call if they see a system problem that may be the result
  755.           of a virus.  Someone should always be available to work with
  756.           the user in determining if a problem exists, and to report
  757.           the problem to a central source of information if it is
  758.           serious.  This central source must have the ability to
  759.           inform the necessary people of the problem quickly and
  760.           reliably, and to set in motion the process of containing and
  761.           solving the problem.  More detailed suggestions for this
  762.           mechanism will be given below, but each stage depends on
  763.           education.  It is important to educate the end users, the
  764.           first-level support people, and management involved at all
  765.           levels, since they must take the necessary actions quickly
  766.           when a viral infection is detected.
  767.  
  768.  
  769.  
  770.           2.3.2  Backups
  771.  
  772.  
  773.           Even without the threat of viruses, good backups are an
  774.           important part of system management.  When a program or a
  775.           data file is lost, a good set of backups can save many days
  776.           or months of work.  The potential harm caused by computer
  777.           viruses only increases the need for backups.
  778.  
  779.           Although they are necessary for recovery, backups can also
  780.           present a place for a virus to hide.  When a virus attack
  781.           has been stopped, and the virus removed from all software on
  782.           the system, the obvious way to recover altered or lost files
  783.           is by restoring them from backups.  Great care must be taken
  784.           not to reintroduce the virus into the system in the process!
  785.  
  786.  
  787.           Coping with Computer Viruses: A Guide for Technical
  788.           Management                                                 7
  789.  
  790.  
  791.  
  792.  
  793.  
  794.  
  795.  
  796.  
  797.  
  798.           All backups should be inspected to ensure that the virus is
  799.           not present in any file on any backup.  Until a backup has
  800.           been certified "clean," it should not be used, unless
  801.           certain files on it are not recoverable through other means.
  802.           Even in this case, it is necessary to be very careful to
  803.           restore only objects which the virus did not infect or
  804.           otherwise change.  The behavior of the virus should be well
  805.           understood before any restoration from backup is attempted.
  806.  
  807.  
  808.  
  809.           2.4  DECREASING THE RISK OF VIRAL INFECTION
  810.  
  811.  
  812.           Viruses can spread from one user to another on a single
  813.           system, and from one system to another.  A virus can enter a
  814.           company either by being written within the company, or by
  815.           being brought in from the outside.  Although a virus cannot
  816.           be written accidentally, a virus may be brought in from the
  817.           outside either intentionally or unintentionally.  Viruses
  818.           can enter a company because a program is brought in from
  819.           outside which is infected, even though the person who brings
  820.           it in does not know it.
  821.  
  822.           Because sharing of programs between people is so
  823.           commonplace, it is difficult to prevent an initial infection
  824.           from "outside." An employee may take a program home to use
  825.           it for business purposes on his or her home computer, where
  826.           it becomes infected.  When the program is returned to the
  827.           workplace, the infection can spread to the workplace.
  828.           Similarly, an outside person can bring a set of programs
  829.           into a company in order to perform work desired by the
  830.           company.  If these programs are infected, and they are
  831.           executed on the company's systems, these systems may also
  832.           become infected.
  833.  
  834.           There are two major ways to prevent infection in the first
  835.           place, and to limit the spread of an existing infection:
  836.           isolating systems, and limiting their function.
  837.  
  838.  
  839.  
  840.           2.4.1  Isolated Systems
  841.  
  842.  
  843.           Since viruses spread to new users and systems only when
  844.           information is shared or communicated, you can prevent
  845.           viruses from spreading by isolating users and systems.
  846.           Systems that are connected to other systems by a network can
  847.           spread a virus across that network.  Isolating systems from
  848.           the network will prevent their being infected by that
  849.           network.  If a company maintains connections with other
  850.           companies (or universities, or other institutions) by a
  851.  
  852.  
  853.           Coping with Computer Viruses: A Guide for Technical
  854.           Management                                                 8
  855.  
  856.  
  857.  
  858.  
  859.  
  860.  
  861.  
  862.  
  863.  
  864.           network, a virus may be able to enter the company through
  865.           that network.  By isolating the company from such external
  866.           networks, it cannot be infected by these networks.
  867.  
  868.           This is a reasonable policy to follow when possible,
  869.           especially for those systems which contain especially
  870.           sensitive programs and data.  It is impractical in many
  871.           cases, though.  Networks are valuable components of a
  872.           computing system.  The easy sharing of programs and data
  873.           that they make possible can add substantially to the
  874.           productivity of a company.  You should be aware, however,
  875.           that this sharing also increases the risk of viral infection
  876.           to these systems.  This is especially true if the network
  877.           security measures have not been designed with viruses and
  878.           related threats in mind.
  879.  
  880.           Your organization may wish to limit the kinds of access to
  881.           systems afforded to those outside the organization.  In many
  882.           cases, users of external systems may be less motivated to be
  883.           benevolent to your systems than internal users are.  This
  884.           may make it worthwhile to limit the ability of external
  885.           users to transmit executable files, or have full interactive
  886.           access, to internal systems.
  887.  
  888.           Similarly, movement of programs between personal computers
  889.           on floppy disks can result in one system infecting another.
  890.           If an employee's home computer is infected, for instance,
  891.           bringing a program (or even a bootable disk) from home to
  892.           work could result in the work computer becoming infected.
  893.           You may want to have a policy that employees should not
  894.           bring programs or bootable disks between work and home.  Or,
  895.           you may want to have a policy that employees should use
  896.           virus-detection tools on their home computers as well as
  897.           their work computers.
  898.  
  899.  
  900.  
  901.  
  902.           2.4.2  Limited-Function Systems
  903.  
  904.  
  905.           Since viruses must be able to infect other executable
  906.           objects in order to spread, you can help prevent viruses
  907.           from spreading by eliminating this ability from a computing
  908.           system.  This can be done in some circumstances by
  909.           restricting the ability to add or change programs on a
  910.           system.
  911.  
  912.           If general-purpose programming must be done on a system, as
  913.           is the case with development systems, it is not possible to
  914.           prevent users from creating or adding new programs.  On
  915.           these systems, it is not possible to prevent the
  916.           introduction of viruses under every possible condition.
  917.  
  918.  
  919.           Coping with Computer Viruses: A Guide for Technical
  920.           Management                                                 9
  921.  
  922.  
  923.  
  924.  
  925.  
  926.  
  927.  
  928.  
  929.  
  930.           Many companies have computing systems, including
  931.           workstations and personal computers, that are not used for
  932.           general-purpose programming.  A bank, for instance, may use
  933.           personal computers as teller stations, to handle a fixed set
  934.           of teller transactions.  Since the tellers need not program
  935.           these systems, it may be possible to strictly limit the
  936.           introduction of new programs and thus greatly limit the
  937.           introduction of viruses onto them.
  938.  
  939.           This is a prudent policy.  Whenever practical, limit the
  940.           ability of users to add or change programs on the systems
  941.           they use.  This ability should be restricted to authorized
  942.           personnel, and these personnel should use every means
  943.           available to them to check any new programs for viruses
  944.           before they are installed in the limited-function systems.
  945.           As long as no new programs are introduced, no new viruses
  946.           can be introduced onto these systems.
  947.  
  948.           Remember, though, that the trend in personal workstations
  949.           has been toward the empowerment of the individual user,
  950.           including giving the user the ability to create programs to
  951.           suit his or her own needs.  Thus, it may not be practical
  952.           and competitive in the long run to impose restrictions on
  953.           many systems.  The risk of viral infection must be weighed
  954.           against the benefits of providing power and flexibility to
  955.           the individual user.
  956.  
  957.  
  958.  
  959.  
  960.           2.4.3  Policies for Software Repositories
  961.  
  962.  
  963.  
  964.           Software repositories are places in which programs reside
  965.           which may be used by a number of people.  These may be disks
  966.           on a mainframe, which can be accessed from a number of
  967.           different users' accounts.  They may also be disks on a
  968.           local area network file server, from which many users get
  969.           common programs.
  970.  
  971.           These repositories can pose more of a risk in the spread of
  972.           viruses than most "private" program storage locations.  If a
  973.           commonly-accessed program becomes infected, such as a text
  974.           editor used by an entire department, the entire department
  975.           can become infected very quickly.  So, extra care is
  976.           required to prevent infection of repositories.
  977.  
  978.           A policy can be put into place that requires each program
  979.           added to a repository to be checked thoroughly for possible
  980.           infection.  It is helpful, for instance, to use tools to
  981.           ensure that it is not infected with any of the already-known
  982.           viruses.
  983.  
  984.  
  985.           Coping with Computer Viruses: A Guide for Technical
  986.           Management                                                10
  987.  
  988.  
  989.  
  990.  
  991.  
  992.  
  993.  
  994.  
  995.  
  996.           In cases in which users who access the repository deal with
  997.           especially sensitive programs and data, it may be prudent to
  998.           enforce even more stringent policies.  Programs to be added
  999.           may be tested first on isolated systems, to see if they show
  1000.           any signs of infecting other programs.  Or, a repository
  1001.           team may inspect the source code of the program for viral
  1002.           code.  If no viral code is found, the repository team can
  1003.           compile the program on an isolated system that has been
  1004.           certified to be free of viruses.  In such a case, the only
  1005.           object code allowed on the repository would come directly
  1006.           from the team's compilation on its isolated system.
  1007.  
  1008.           Repositories can also be helpful in detecting and
  1009.           controlling viruses.  Consider the situation in which most
  1010.           users run a significant amount of the software that they
  1011.           execute from a central server to which they do not have
  1012.           write access, rather than from individual writeable disks.
  1013.           Since the users do not regularly update this software,
  1014.           viruses will not be able to spread as quickly between these
  1015.           users.  If a program on a central repository becomes
  1016.           infected, it may be comparatively simple to replace it with
  1017.           an uninfected version (or remove it entirely).  It may be
  1018.           more difficult to screen all programs on hundreds of
  1019.           individual systems.  It may also be easier to audit the
  1020.           usage of, and updates to, a single software repository, as
  1021.           opposed to a large number of individual systems.
  1022.  
  1023.           There are a variety of other areas in many organizations
  1024.           which could spread viruses rapidly, and hence which should
  1025.           be carefully controlled.  Internal software distribution
  1026.           centers, for instance, could spread a virus widely if they
  1027.           were infected.  Similarly, a software lending library, if
  1028.           infected, may transmit a virus to many other users before it
  1029.           is detected.  Walk-in demo rooms and educational centers are
  1030.           also potential problems.  In general, any place from which
  1031.           software is widely distributed, and which has uncontrolled
  1032.           software importation, needs special attention.
  1033.  
  1034.  
  1035.  
  1036.  
  1037.           2.4.4  Policies for Production Systems
  1038.  
  1039.  
  1040.           Production systems are those systems which are used to
  1041.           prepare internally-developed programs for distribution
  1042.           either within a company, or for sale to external customers.
  1043.           If these systems were infected with a virus, the virus could
  1044.           spread to programs used widely within the company, or to
  1045.           programs used by the company's customers.  In the former
  1046.           case, this could spread the virus widely throughout the
  1047.           company.  In the latter case, it could damage the reputation
  1048.           of the company with its customers.  There has been
  1049.  
  1050.  
  1051.           Coping with Computer Viruses: A Guide for Technical
  1052.           Management                                                11
  1053.  
  1054.  
  1055.  
  1056.  
  1057.  
  1058.  
  1059.  
  1060.  
  1061.  
  1062.           documented cases of companies accidentally shipping
  1063.           virus-infected program products to customers.
  1064.  
  1065.           Since the infection of production systems could have serious
  1066.           consequences, you should be especially careful about
  1067.           protecting them.  The key to this is the institution of
  1068.           stringent change control policies on production systems.
  1069.  
  1070.           They should be strongly isolated from non-production
  1071.           systems, so that only known, authorized files can be put
  1072.           onto the system.  Each file should be checked for infection,
  1073.           to whatever extent possible.  Installing object code on
  1074.           these systems should be avoided whenever possible.  Rather,
  1075.           source code should be installed, and compiled locally with a
  1076.           trusted compiler.  Where the impact of a viral infection
  1077.           would be particularly large, it may be important to inspect
  1078.           the source code before it is compiled, to avoid the
  1079.           introduction of a virus through the source code.  If object
  1080.           code must be installed, its origin should be verified
  1081.           beforehand.  For instance, object code for a personal
  1082.           computer could be installed only from an original,
  1083.           write-protected distribution disk, which has been found to
  1084.           be free of viruses.
  1085.  
  1086.           In addition, virus-checking programs (see below) should be
  1087.           run frequently on production systems.  On a multitasking
  1088.           system, it may be possible to run a virus detector
  1089.           continuously in the background.  Further, a policy can be
  1090.           instituted which ensures that a virus detector will be
  1091.           executed at least once between the time that new files are
  1092.           installed on the system, and the time that any files are
  1093.           exported from the system.
  1094.  
  1095.  
  1096.  
  1097.           2.5  DETECTING VIRAL INFECTIONS
  1098.  
  1099.  
  1100.           With the possible exception of isolation, all of the methods
  1101.           outlined above for preventing viral infections are only
  1102.           somewhat reliable.  Viruses can still reach some systems
  1103.           despite the implementation of preventative measures.
  1104.           Indeed, no perfect defense exists that still allows
  1105.           programming, and sharing of executable information.  There
  1106.           is no "one time fix," as there is for many other computer
  1107.           security problems.  This is a hole that cannot be plugged
  1108.           completely.  Defenses will have to be improved with time to
  1109.           deal with new classes of viruses.  Because of this, virus
  1110.           *detection* is an important component of system security.
  1111.  
  1112.           The two most important resources available for the detection
  1113.           of viruses are watchful users and watchful programs.  The
  1114.           best approaches to virus detection include both.  The users
  1115.  
  1116.  
  1117.           Coping with Computer Viruses: A Guide for Technical
  1118.           Management                                                12
  1119.  
  1120.  
  1121.  
  1122.  
  1123.  
  1124.  
  1125.  
  1126.  
  1127.  
  1128.           should be aware of the possibility of viruses, just as they
  1129.           are aware of the need for backups, and to know what kinds of
  1130.           things to watch for.  System programs and utilities should
  1131.           be available to help the users, and the computer center
  1132.           staff, to take advantage of this awareness.
  1133.  
  1134.  
  1135.  
  1136.           2.5.1  Watching for Unexpected Things Happening
  1137.  
  1138.  
  1139.           If users are aware of the kinds of visible things that are
  1140.           known to happen in systems that are virus-infected, these
  1141.           users can serve as an important line of defense.  Users
  1142.           should know that odd behavior in a computer system may be a
  1143.           symptom of penetration by a virus, and they should know to
  1144.           whom such odd behavior should be reported.
  1145.  
  1146.           On the other hand, it is a fact that odd behavior is usually
  1147.           *not* caused by viral penetration.  Software bugs, user
  1148.           errors, and hardware failures are much more common.  It is
  1149.           important to avoid unfounded rumors of viral infections, as
  1150.           dealing with such "false alarms" can be costly.  An actual
  1151.           infection, however, may require rapid action.  So the group
  1152.           to which users report oddities must have the skill to
  1153.           determine which reports are almost certainly due to one of
  1154.           these more common causes, and which merit closer
  1155.           investigation for possible viral infection.  One obvious
  1156.           choice for such a group is within the computing center or
  1157.           "help desk," since the computing center staff probably
  1158.           already has a good idea of what sorts of oddities are
  1159.           "business as usual."
  1160.  
  1161.  
  1162.  
  1163.           2.5.2  Some Symptoms of Known Viruses
  1164.  
  1165.  
  1166.  
  1167.  
  1168.           2.5.2.1  Workstation Viruses
  1169.  
  1170.  
  1171.           This section lists specific oddities that are known to occur
  1172.           in workstations infected with particular viruses that have
  1173.           already occurred.  Some of the things in these examples only
  1174.           occur once the virus is in place, and is triggered to
  1175.           perform its particular function.  Others occur while the
  1176.           virus is still spreading.  Some things users should know to
  1177.           watch for include:
  1178.  
  1179.           o   Unexpected changes in the time stamps or length of
  1180.               files, particularly executable files,
  1181.  
  1182.  
  1183.           Coping with Computer Viruses: A Guide for Technical
  1184.           Management                                                13
  1185.  
  1186.  
  1187.  
  1188.  
  1189.  
  1190.  
  1191.  
  1192.  
  1193.  
  1194.           o   Programs taking longer to start, or running more slowly
  1195.               than usual,
  1196.           o   Programs attempting to write to write-protected media
  1197.               for no apparent reason,
  1198.           o   Unexplained decreases in the amount of available
  1199.               workstation memory, or increases in areas marked as
  1200.               "bad" on magnetic media,
  1201.           o   Executable files unexpectedly vanishing,
  1202.           o   Workstations unexpectedly "rebooting" when certain
  1203.               previously-correct programs are run, or a relatively
  1204.               constant amount of time after being turned on,
  1205.           o   Unusual things appearing on displays, including
  1206.               "scrolling" of odd parts of the screen, or the
  1207.               unexpected appearance of "bouncing balls" or odd
  1208.               messages,
  1209.           o   Unexpected changes to volume labels on disks and other
  1210.               media,
  1211.           o   An unusual load on local networks or other communication
  1212.               links, especially when multiple copies of the same data
  1213.               are being sent at once.
  1214.  
  1215.           It is important to remember, though, that future viruses may
  1216.           do none of these things.  Users should be alert to oddities
  1217.           in general and should have a place to report them, as
  1218.           recommended above.
  1219.  
  1220.  
  1221.  
  1222.  
  1223.           2.5.2.2  Mainframe Viruses
  1224.  
  1225.  
  1226.  
  1227.           Viruses in multi-user computer systems share some of the
  1228.           typical behaviors of viruses in single-user workstations.
  1229.           In particular, lengths or time stamps of executable files
  1230.           may change, programs may load or execute more slowly,
  1231.           unusual errors (especially relating to disk-writes) may
  1232.           occur, files may vanish or proliferate, and odd things may
  1233.           appear on displays.  If the virus is attempting to spread
  1234.           between users, users may also notice "outgoing mail" that
  1235.           they did not intend to send, "links" to other user's
  1236.           information that they did not intentionally establish, and
  1237.           similar phenomena.
  1238.  
  1239.           Generally, the same comments apply in this environment as in
  1240.           the single-user workstation environment.  Future viruses may
  1241.           do none of these things, and users should be sensitive to
  1242.           suspicious oddities in general, and have a place to which to
  1243.           report them.
  1244.  
  1245.  
  1246.  
  1247.  
  1248.  
  1249.           Coping with Computer Viruses: A Guide for Technical
  1250.           Management                                                14
  1251.  
  1252.  
  1253.  
  1254.  
  1255.  
  1256.  
  1257.  
  1258.  
  1259.  
  1260.           2.5.3  Watching for Changes to Executable Objects
  1261.  
  1262.  
  1263.  
  1264.           Users are not the only line of defense in the detection of
  1265.           viruses.  It is comparatively simple to create programs that
  1266.           will detect the presence and the spread of the simpler
  1267.           classes of viruses.  Such programs can go a long way in
  1268.           "raising the bar" against computer viruses.
  1269.  
  1270.           One effective approach to detecting simple viruses involves
  1271.           notifying the user of changes to the contents of executable
  1272.           objects (program files, "boot records" on magnetic media,
  1273.           and so forth).  Users can be provided with a program to be
  1274.           run once a day which will examine the executable objects to
  1275.           be checked, and compare their characteristics with those
  1276.           found the last time the program was run.  (This could be run
  1277.           at the same time as the backup program, for instance.)  The
  1278.           user can then be presented with a list of objects that have
  1279.           changed.  If things have changed that should not have, the
  1280.           user can contact the appropriate people to investigate.  If
  1281.           certain objects that should seldom or never change (such as
  1282.           the operating system files themselves) are different, the
  1283.           user can be specially warned, and urged to contact the
  1284.           appropriate people.
  1285.  
  1286.           Often, a central system programming group has control over a
  1287.           large multi-user computing system.  That group can execute
  1288.           this sort of program periodically, to check for changes to
  1289.           common operating system utilities, and to the operating
  1290.           system itself.  Because viruses can often spread to
  1291.           privileged users, they are quite capable of infecting even
  1292.           those parts of the system that require the highest authority
  1293.           to access.
  1294.  
  1295.           The frequency with which virus detectors should be used
  1296.           depends upon the rate at which executables are transmitted,
  1297.           and the value of the information assets on the systems.
  1298.           Workstations that are not connected to networks can exchange
  1299.           information via floppy disks.  The known computer viruses
  1300.           that propagate by way of floppy disks do so relatively
  1301.           slowly.  It may take days, or weeks, or even months for such
  1302.           a virus to propagate across a large organization.  In this
  1303.           case, running virus detectors once a day, or once a week,
  1304.           may be sufficient.  For systems connected to networks,
  1305.           especially large-scale networks, the situation is much
  1306.           different.  Experience has shown network viruses to be
  1307.           capable of spreading very rapidly across the network.  In
  1308.           some cases, replicating programs have spread across
  1309.           nationwide networks in a matter of hours or days.  In these
  1310.           cases, it may be important to run virus detectors hourly or
  1311.           daily.
  1312.  
  1313.  
  1314.  
  1315.           Coping with Computer Viruses: A Guide for Technical
  1316.           Management                                                15
  1317.  
  1318.  
  1319.  
  1320.  
  1321.  
  1322.  
  1323.  
  1324.  
  1325.  
  1326.           Below is an outline of one possible implementation of a
  1327.           virus detecting program.  It is for illustration only; many
  1328.           different structures would do the job as well or better.
  1329.  
  1330.           1.  The program obtains a list of files to be checked.  For
  1331.               PC-DOS, for instance, this should include .COM and .EXE
  1332.               files, any files that are listed as device drivers in
  1333.               the CONFIG.SYS file, the CONFIG.SYS file itself, and any
  1334.               other executables such as batch files or BASIC programs.
  1335.           2.  For each of these files, the program
  1336.               o   Determines the time/date and length of the file from
  1337.                   the operating system.
  1338.               o   If desired, actually reads the data in the file, and
  1339.                   performs a calculation such as a CRC (cyclic
  1340.                   redundancy check) on the data.  (The number of files
  1341.                   checked in such detail depends on the importance of
  1342.                   the file, the speed of the program, and the amount
  1343.                   of time the user is willing to spend.)
  1344.               o   Compares this file information (time/date, length,
  1345.                   and perhaps CRC or other code) with the database
  1346.                   generated last time the program was run.
  1347.               o   If the file was not present the last time the
  1348.                   program was run, or if the information in the
  1349.                   previous database was different from the information
  1350.                   just obtained, the program records that the file is
  1351.                   new or changed.
  1352.           3.  After checking all relevant files, the program reads all
  1353.               other known executable objects in the system(1), and
  1354.               compares their CRC or other codes with the values in the
  1355.               database, and records any changes.
  1356.           4.  When all the existing objects have been checked in this
  1357.               way, the program updates the database for next time and
  1358.               presents all its findings to the user.
  1359.           5.  On the basis of this information, the user can decide
  1360.               whether any of the reported changes are suspicious, and
  1361.               worth reporting.
  1362.  
  1363.           This method is by no means foolproof.  A sophisticated virus
  1364.           could do a variety of things.  It could change an executable
  1365.           object without altering the time, date, length, or CRC code.
  1366.           It could only alter objects that had been legitimately
  1367.           changed recently.  It could act directly on the database
  1368.           itself and thus escape detection.  More sophisticated
  1369.           versions of the program outlined here can provide
  1370.           significantly more foolproof detection.  It is advantageous
  1371.           to have many different virus detectors in place at the same
  1372.  
  1373.           ----------------
  1374.           (1) For PC-DOS, this would typically include the boot record
  1375.               on a floppy diskette, and the master and partition boot
  1376.               records on hard disks.  For multi-user operating
  1377.               systems, this might include "shared system images," or
  1378.               "IPL datasets" or equivalent objects.
  1379.  
  1380.  
  1381.           Coping with Computer Viruses: A Guide for Technical
  1382.           Management                                                16
  1383.  
  1384.  
  1385.  
  1386.  
  1387.  
  1388.  
  1389.  
  1390.  
  1391.  
  1392.           time.  That way, a virus that can evade one detector may be
  1393.           caught by another.  Nevertheless, user awareness, and
  1394.           procedures for recovery in the event of an infection that is
  1395.           not detected until too late, are both still vital.
  1396.  
  1397.  
  1398.  
  1399.           2.5.4  Using External Information Sources
  1400.  
  1401.  
  1402.           Software viruses are able to spread because information
  1403.           flows so quickly in the modern world.  That same information
  1404.           flow can help in the detection of viruses.  Newspapers,
  1405.           magazines, journals, and network discussion groups have
  1406.           carried significant amounts of material dealing with
  1407.           computer viruses and other forms of malicious software.
  1408.           These sources of information can be valuable in maintaining
  1409.           awareness of what hazards exist, and what measures are
  1410.           available to detect or prevent specific viruses.  This kind
  1411.           of information can be invaluable to the people in your
  1412.           organization charged with investigating suspicious events
  1413.           reported by users, and deciding which ones to follow up on.
  1414.           On the other hand, these channels also carry a certain
  1415.           amount of inevitable misinformation, and care should be
  1416.           taken not to react to, or spread, rumors that seem to have
  1417.           no likely basis in fact.
  1418.  
  1419.  
  1420.  
  1421.           2.6  CONTAINING VIRAL INFECTIONS
  1422.  
  1423.  
  1424.           Having procedures in place to detect viral infection is very
  1425.           important.  By itself, however, it is of little use.  The
  1426.           individual who makes the first detection must have a
  1427.           procedure to follow to verify the problem and to make sure
  1428.           that appropriate action occurs.  If the information supplied
  1429.           in the detection phase is allowed to "fall between the
  1430.           cracks," even for a relatively short time, the benefit of
  1431.           detection can easily be lost.
  1432.  
  1433.  
  1434.  
  1435.  
  1436.           2.6.1  The Importance of Early Detection
  1437.  
  1438.  
  1439.           Computer viruses generally spread exponentially.  If a virus
  1440.           has infected only one system in a network on Monday, and
  1441.           spread to four by Tuesday, sixteen systems could easily be
  1442.           infected by Wednesday, and over five hundred by Friday.
  1443.           (These numbers are just samples, of course, but they give an
  1444.           idea of the potential speed of spread.  See reference (1)
  1445.  
  1446.  
  1447.           Coping with Computer Viruses: A Guide for Technical
  1448.           Management                                                17
  1449.  
  1450.  
  1451.  
  1452.  
  1453.  
  1454.  
  1455.  
  1456.  
  1457.  
  1458.           for some experiments in which much faster spread was
  1459.           observed.)
  1460.  
  1461.           Because viruses can spread so fast, it is very important to
  1462.           detect them as early as possible after the first infection.
  1463.           The surest way of doing this is to have every vulnerable
  1464.           user run the best available virus-detection software as
  1465.           often as feasible.  This solution may be too expensive and
  1466.           time-consuming for most environments.
  1467.  
  1468.           In most groups of users, it is possible to identify a number
  1469.           of "star" users who do a disproportionately large amount of
  1470.           information-exchange, who generally run new software before
  1471.           most people do, and who are the first to try out new things
  1472.           in general.  In multi-user systems, some of these people
  1473.           often have special authorities and privileges.  When a virus
  1474.           reaches one of these people, it can spread very rapidly to
  1475.           the rest of the community.  In making cost/benefit decisions
  1476.           about which users should spend the most time or effort on
  1477.           virus-detection, these are the people to concentrate on.
  1478.  
  1479.  
  1480.  
  1481.  
  1482.           2.6.2  The Importance of Rapid Action
  1483.  
  1484.  
  1485.           When a virus is detected, every moment spent deciding what
  1486.           to do next may give the virus another chance to spread.  It
  1487.           is vital, therefore, to have action plans in place *before* an
  1488.           infection occurs.  Such plans should include, for instance:
  1489.  
  1490.           o   Designation of one particular group (whether formal or
  1491.               informal) as the "crisis team,"
  1492.           o   Procedures for identifying infected systems, by
  1493.               determining how and from where the infection reached
  1494.               each system known to be infected,
  1495.           o   Procedures for isolating those systems until they can be
  1496.               rendered free of the virus,
  1497.           o   Procedures for informing vulnerable users about the
  1498.               virus, and about how to avoid spreading it themselves,
  1499.           o   Procedures for removing the virus from infected systems,
  1500.           o   Procedures for identifying the virus involved, and for
  1501.               developing or obtaining specific software or procedures
  1502.               to combat the virus.  These may remove the virus from
  1503.               infected systems and files, determine whether or not
  1504.               backups are infected, and so on.
  1505.           o   Procedures for recording the characteristics of the
  1506.               virus and the effectiveness of the steps taken against
  1507.               it, in case of later re-infection with the same or a
  1508.               similar virus.
  1509.  
  1510.           Some suggestions for recovery are given in the next section.
  1511.  
  1512.  
  1513.           Coping with Computer Viruses: A Guide for Technical
  1514.           Management                                                18
  1515.  
  1516.  
  1517.  
  1518.  
  1519.  
  1520.  
  1521.  
  1522.  
  1523.  
  1524.           2.7  RECOVERING FROM VIRAL INFECTIONS
  1525.  
  1526.  
  1527.           Once a virus has been detected and identified, and measures
  1528.           have been taken to stop it from spreading further, it is
  1529.           necessary to recover from the infection, and get back to
  1530.           business as usual.  The main objective of this activity is
  1531.           to provide each affected user with a normal, uninfected
  1532.           computing environment.  For individual workstations, this
  1533.           means ensuring that no infected objects remain on the
  1534.           workstation.  For more complex environments, it means
  1535.           ensuring that no infected objects remain anywhere on the
  1536.           system where they might inadvertently be executed.
  1537.  
  1538.           The basic recovery activities are:
  1539.  
  1540.           o   Replacing every infected object in the system with an
  1541.               uninfected version, and
  1542.           o   Restoring any other objects that the virus' actions may
  1543.               have damaged.
  1544.  
  1545.           It is of critical importance during these activities to
  1546.           avoid re-introducing the virus into the system.  This could
  1547.           be done, for instance, by restoring an infected executable
  1548.           file from a backup tape.
  1549.  
  1550.  
  1551.  
  1552.  
  1553.           2.7.1  Restoration and Backups
  1554.  
  1555.  
  1556.  
  1557.           An obvious but incorrect approach to removing the infection
  1558.           from a system is simply to restore the infected objects from
  1559.           backups.  This is *not* a wise thing to do, however, since
  1560.           the backups themselves may be infected.  If the virus first
  1561.           entered the system sufficiently long ago, infected objects
  1562.           may well have been backed up in infected form.
  1563.  
  1564.           Once the virus has been well understood, in terms of what
  1565.           types of objects it spreads itself to, three different
  1566.           categories of objects may be considered for restoration:
  1567.  
  1568.           o   Objects of the type that the virus infects.  These
  1569.               should only be restored from backups if the backed-up
  1570.               versions are thoroughly and individually checked for
  1571.               infection by the virus.  If it is possible, it is
  1572.               preferable to restore the objects from more "trusted"
  1573.               sources, such as original, unwriteable, copies supplied
  1574.               by the manufacturer, or by recompiling source code.
  1575.               Even in these cases, it is worthwhile to check once
  1576.               again for infection after restoration has been done.
  1577.  
  1578.  
  1579.           Coping with Computer Viruses: A Guide for Technical
  1580.           Management                                                19
  1581.  
  1582.  
  1583.  
  1584.  
  1585.  
  1586.  
  1587.  
  1588.  
  1589.  
  1590.           o   Objects of types that the virus does not infect, but
  1591.               which have been destroyed or altered by the virus'
  1592.               actions.  These can generally be restored from backups
  1593.               safely, although again it is worth checking the
  1594.               integrity of the backed-up copies.  If the virus has
  1595.               been in the system long enough, it may have damaged
  1596.               objects that were later backed up.
  1597.  
  1598.           o   Objects of types that the virus neither infects, nor
  1599.               damages.  If you are very sure that the virus does not
  1600.               infect or alter certain types of files, there may be no
  1601.               need to restore those files during the recovery process.
  1602.  
  1603.  
  1604.  
  1605.           2.7.2  Virus-Removing Programs
  1606.  
  1607.  
  1608.           Once a virus has been studied, you can write or obtain
  1609.           programs to help remove that particular virus.  One type of
  1610.           these programs checks for the presence of the virus in a
  1611.           executable objects.  Another type tries to remove the
  1612.           infection by restoring the object to its previous uninfected
  1613.           form.  "Checking" programs can be extremely valuable during
  1614.           the recovery process, to ensure that files that are being
  1615.           restored after infection or damage by the virus are now
  1616.           "clean." "Removal" programs are somewhat less useful, and
  1617.           should usually only be used when there is no other practical
  1618.           way to obtain an uninfected version of the object.  Removing
  1619.           a virus from an executable object can be a complex and
  1620.           difficult process, and even a well-written program may fail
  1621.           to restore the object correctly.
  1622.  
  1623.  
  1624.  
  1625.           2.7.3  Watching for Re-Infection
  1626.  
  1627.  
  1628.           Once recovery is complete, and all known infected and
  1629.           damaged objects have been restored to uninfected and correct
  1630.           states, it is necessary to remain watchful for some time.  A
  1631.           system that has recently been infected by a certain virus
  1632.           runs an increased risk of re-infection by that same virus.
  1633.           The re-infection can occur through some obscure, infected
  1634.           object that was missed in the recovery process.  It can also
  1635.           occur from the same outside source as the original
  1636.           infection.  This is especially true if the original source
  1637.           of infection is not known.
  1638.  
  1639.           Vigilance in the use of general virus-detection programs,
  1640.           like those described above, continues to be important.  In
  1641.           addition, it will often be possible to obtain or write
  1642.           programs designed to detect the specific virus from which
  1643.  
  1644.  
  1645.           Coping with Computer Viruses: A Guide for Technical
  1646.           Management                                                20
  1647.  
  1648.  
  1649.  
  1650.  
  1651.  
  1652.  
  1653.  
  1654.  
  1655.  
  1656.           the system has just recovered.  Specific virus-detection
  1657.           programs of this kind are particularly useful at this time.
  1658.           The same users who use the general virus-detection programs,
  1659.           and any users who would be specifically vulnerable to the
  1660.           virus just recovered from, can be given such programs to
  1661.           run.  This increases the probability of detection, should an
  1662.           infection recur.  The programs might also be incorporated
  1663.           into the backup system for a time, to scan files being
  1664.           backed up for infection, and even into appropriate places in
  1665.           networks and file-sharing systems.  Because such checks will
  1666.           introduce extra overhead, there will be a trade-off between
  1667.           performance and added security in considering how long to
  1668.           leave them in place.
  1669.  
  1670.  
  1671.  
  1672.           2.8  SUMMARY AND RECOMMENDATIONS
  1673.  
  1674.  
  1675.           Computer viruses can pose a threat to the security of
  1676.           programs and data on computing systems.  We have suggested
  1677.           several means of limiting this threat.  They are summarized
  1678.           below.
  1679.  
  1680.  
  1681.           o   Viruses represent a new kind of threat to the security
  1682.               of computing systems.
  1683.  
  1684.               -   They can be spread without the intent of the people
  1685.                   who spread them.
  1686.               -   They can spread widely and quickly within an
  1687.                   organization, reaching systems and users well beyond
  1688.                   the initial infection point.
  1689.               -   They can perform virtually any action that their
  1690.                   designer intends.
  1691.  
  1692.  
  1693.           o   The risks posed by viruses can be limited by proper
  1694.               action.
  1695.  
  1696.               -   Follow good security practices in general.
  1697.  
  1698.                   --  Educate your users about security threats,
  1699.                       including computer viruses.
  1700.                   --  Make sure that good backups are kept of all
  1701.                       important data.
  1702.  
  1703.               -   Take steps to reduce the possibility of being
  1704.                   infected.
  1705.  
  1706.                   --  Where practical, isolate critical systems from
  1707.                       sources of infection, such as networks and
  1708.                       outside programs.
  1709.  
  1710.  
  1711.           Coping with Computer Viruses: A Guide for Technical
  1712.           Management                                                21
  1713.  
  1714.  
  1715.  
  1716.  
  1717.  
  1718.  
  1719.  
  1720.  
  1721.  
  1722.                   --  Where practical, limit the ability to create or
  1723.                       install new programs on those systems which do
  1724.                       not require this ability.
  1725.                   --  Ensure that adequate controls exist on software
  1726.                       repositories, production systems, and other
  1727.                       important areas of your organization.  These
  1728.                       include careful change management and the use of
  1729.                       virus detectors.
  1730.  
  1731.               -   Take steps to ensure that virus infections will be
  1732.                   detected quickly.
  1733.  
  1734.                   --  Educate your users about possible warning signs.
  1735.                   --  Use virus detectors, which will inform users of
  1736.                       the unintended modification of programs and
  1737.                       data.
  1738.                   --  Make sure your users know to whom they can
  1739.                       report a potential problem.
  1740.  
  1741.               -   Take steps to contain virus infections that are
  1742.                   detected.
  1743.  
  1744.                   --  A plan to deal with an infection should be put
  1745.                       into place *before* an infection occurs.
  1746.                   --  A "crisis team" should be put into place, which
  1747.                       can respond quickly to a potential problem.
  1748.                   --  Isolate infected systems until they can be
  1749.                       cleaned up, to avoid them infecting other
  1750.                       systems, and to avoid their becoming reinfected.
  1751.  
  1752.               -   Take steps to recover from viral infections that are
  1753.                   contained.
  1754.  
  1755.                   --  Be able to restore critical programs and data
  1756.                       from virus-free backups.
  1757.                   --  Know how to remove viruses from programs if
  1758.                       virus-free backups are unavailable.
  1759.                   --  Watch for a reinfection from that particular
  1760.                       virus.
  1761.  
  1762.  
  1763.  
  1764.  
  1765.  
  1766.  
  1767.  
  1768.  
  1769.  
  1770.  
  1771.  
  1772.  
  1773.  
  1774.  
  1775.  
  1776.  
  1777.           Coping with Computer Viruses: A Guide for Technical
  1778.           Management                                                22
  1779.  
  1780.  
  1781.  
  1782.  
  1783.  
  1784.  
  1785.  
  1786.  
  1787.  
  1788.           FOR FURTHER READING
  1789.  
  1790.  
  1791.  
  1792.           (1)  Fred Cohen, "Computer Viruses: Theory and Experiment,"
  1793.                 Computers & Security, Vol. 6 (1987), pp. 22-35
  1794.  
  1795.           (2)  Fred Cohen, "On the Implications of Computer Viruses
  1796.                 and Methods of Defense," Computers & Security, Vol. 7
  1797.                 (1988), pp. 167-184
  1798.  
  1799.           (3)  W.H. Murray, "Security Considerations for Personal
  1800.                 Computers," IBM System Journal, Vol. 23, No. 3 (1984),
  1801.                 pp. 297-304
  1802.  
  1803.           (4)  --, "Security Risk Assessment in Electronic Data
  1804.                 Processing Systems," IBM Publication Number
  1805.                 G320-9256-0 (1984)
  1806.  
  1807.           (5)  --, "Good Security Practices for Information Systems
  1808.                 Networks," IBM Publication Number G360-2715-0 (1987)
  1809.  
  1810.           (6)  --, "An Executive Guide to Data Security," IBM
  1811.                 Publication Number G320-5647-0 (1975)
  1812.  
  1813.           (7)  --, "Security, Auditability, System Control
  1814.                 Publications Bibliography," IBM Publication Number
  1815.                 G320-9279-2 (1987)
  1816.  
  1817.  
  1818.  
  1819.  
  1820.  
  1821.  
  1822.  
  1823.  
  1824.  
  1825.  
  1826.  
  1827.  
  1828.  
  1829.  
  1830.  
  1831.  
  1832.  
  1833.  
  1834.  
  1835.  
  1836.  
  1837.  
  1838.  
  1839.  
  1840.  
  1841.  
  1842.  
  1843.  
  1844.           For Further Reading                                       23
  1845.  
  1846.  
  1847.  
  1848.  
  1849.  
  1850.  
  1851.  
  1852.  
  1853.  
  1854.                 GLOSSARY
  1855.  
  1856.  
  1857.  
  1858.                 Computer viruses and the like are relatively new
  1859.                 phenomena.  The terms used to describe them do not
  1860.                 have definitions that are universally agreed upon.  In
  1861.                 this glossary, we give definitions that try to clarify
  1862.                 the differences between the various concepts.  These
  1863.                 terms may be used differently elsewhere.
  1864.  
  1865.  
  1866.  
  1867.                 Availability:  That aspect of security that deals with
  1868.                 the timely delivery of information and services to the
  1869.                 user.  An attack on availability would seek to sever
  1870.                 network connections, tie up accounts or systems, etc.
  1871.  
  1872.                 Back Door:  A feature built into a program by its
  1873.                 designer, which allows the designer special privileges
  1874.                 that are denied to the normal users of the program.  A
  1875.                 back door in a logon program, for instance, could
  1876.                 enable the designer to log on to a system, even though
  1877.                 he or she did not have an authorized account on that
  1878.                 system.
  1879.  
  1880.                 Bacterium (informal):  A program which, when executed,
  1881.                 spreads to other users and systems by sending copies
  1882.                 of itself.  (Though, since it does "infect" other
  1883.                 programs, it may be thought of as a "system virus" as
  1884.                 opposed to a "program virus.") It differs from a
  1885.                 "rabbit" (see below) in that it is not necessarily
  1886.                 designed to exhaust system resources.
  1887.  
  1888.                 Bug:  An error in the design or implementation of a
  1889.                 program that causes it to do something that neither
  1890.                 the user nor the program author had intended to be
  1891.                 done.
  1892.  
  1893.                 Confidentiality:  That aspect of security which deals
  1894.                 with the restriction of information to those who are
  1895.                 authorized to use it.  An attack on confidentiality
  1896.                 would seek to view databases, print files, discover a
  1897.                 password, etc., to which the attacker was not
  1898.                 entitled.
  1899.  
  1900.                 Integrity:  That aspect of security that deals with
  1901.                 the correctness of information or its processing.  An
  1902.                 attack on integrity would seek to erase a file that
  1903.                 should not be erased, alter an element of a database
  1904.                 improperly, corrupt the audit trail for a series of
  1905.                 events, propagate a virus, etc.
  1906.  
  1907.  
  1908.  
  1909.  
  1910.           Glossary                                                  24
  1911.  
  1912.  
  1913.  
  1914.  
  1915.  
  1916.  
  1917.  
  1918.  
  1919.  
  1920.                 Logic Bomb:  A Trojan Horse (see below), which is left
  1921.                 within a computing system with the intent of it
  1922.                 executing when some condition occurs.  The logic bomb
  1923.                 could be triggered by a change in a file (e.g. the
  1924.                 removal of the designer's userid from the list of
  1925.                 employees of the organization), by a particular input
  1926.                 sequence to the program, or at a particular time or
  1927.                 date (see "Time Bomb" below).  Logic bombs get their
  1928.                 name from malicious actions that they can take when
  1929.                 triggered.
  1930.  
  1931.                 Rabbit (informal):  A program is designed to exhaust
  1932.                 some resource of a system (CPU time, disk space, spool
  1933.                 space, etc.) by replicating itself without limit.  It
  1934.                 differs from a "bacterium" (see above) in that a
  1935.                 rabbit is specifically designed to exhaust resources.
  1936.                 It differs from a "virus" (see below) in that it is a
  1937.                 complete program in itself; it does not "infect" other
  1938.                 programs.
  1939.  
  1940.                 Rogue Program:  This term has been used in the popular
  1941.                 press to denote any program intended to damage
  1942.                 programs or data, or to breach the security of
  1943.                 systems.  As such, it encompasses malicious Trojan
  1944.                 Horses, logic bombs, viruses, and so on.
  1945.  
  1946.                 Security:  When applied to computing systems, this
  1947.                 denotes the authorized, correct, timely performance of
  1948.                 computing tasks.  It encompasses the areas of
  1949.                 confidentiality, integrity, and availability.
  1950.  
  1951.                 Time Bomb:  A "logic bomb" (see above) activated at a
  1952.                 certain time or date.
  1953.  
  1954.                 Trojan Horse:  Any program designed to do things that
  1955.                 the user of the program did not intend to do.  An
  1956.                 example of this would be a program which simulates the
  1957.                 logon sequence for a computer and, rather than logging
  1958.                 the user on, simply records the user's userid and
  1959.                 password in a file for later collection.  Rather than
  1960.                 logging the user on (which the user intended), it
  1961.                 steals the user's password so that the Trojan Horse's
  1962.                 designer can log on as the user (which the user did
  1963.                 not intend).
  1964.  
  1965.                 Virus (pl. viruses):  a program that can "infect"
  1966.                 other programs by modifying them to include a possibly
  1967.                 evolved copy of itself.  Note that a program need not
  1968.                 perform malicious actions to be a virus; it need only
  1969.                 "infect" other programs.  Many viruses that have been
  1970.                 encountered, however, do perform malicious actions.
  1971.  
  1972.                 Worm:  A program that spreads copies of itself through
  1973.                 network-attached computers.  The first use of the term
  1974.  
  1975.  
  1976.           Glossary                                                  25
  1977.  
  1978.  
  1979.  
  1980.  
  1981.  
  1982.  
  1983.  
  1984.  
  1985.  
  1986.                 described a program that copied itself benignly around
  1987.                 a network, using otherwise-unused resources on
  1988.                 networked machines to perform distributed computation.
  1989.                 Some worms are security threats, using networks to
  1990.                 spread themselves against the wishes of the system
  1991.                 owners, and disrupting networks by overloading them.
  1992.  
  1993.  
  1994.  
  1995.  
  1996.  
  1997.  
  1998.  
  1999.  
  2000.  
  2001.  
  2002.  
  2003.  
  2004.  
  2005.  
  2006.  
  2007.  
  2008.  
  2009.  
  2010.  
  2011.  
  2012.  
  2013.  
  2014.  
  2015.  
  2016.  
  2017.  
  2018.  
  2019.  
  2020.  
  2021.  
  2022.  
  2023.  
  2024.  
  2025.  
  2026.  
  2027.  
  2028.  
  2029.  
  2030.  
  2031.  
  2032.  
  2033.  
  2034.  
  2035.  
  2036.  
  2037.  
  2038.  
  2039.  
  2040.  
  2041.  
  2042.           Glossary                                                  26
  2043.  
  2044.  
  2045.  
  2046.  
  2047.  
  2048.  
  2049.  
  2050.  
  2051.  
  2052.                 APPENDIX: VIRAL INFECTIONS IN PC-DOS
  2053.  
  2054.  
  2055.  
  2056.                 This section is intended to give an example of the
  2057.                 places in a typical computer system where a virus
  2058.                 might enter.  It is intended for a reader with some
  2059.                 knowledge of the workings of PC-DOS, although it may
  2060.                 be instructive to others as well.  PC-DOS was chosen
  2061.                 for convenience; many computer systems have similar
  2062.                 vulnerabilities.
  2063.  
  2064.                 Consider the process that is required for you to run a
  2065.                 single program.  What is happening?  Which parts do
  2066.                 you not bother checking since you have seen it a
  2067.                 million times?
  2068.  
  2069.                 For example, you turn on the power switch and then ...
  2070.  
  2071.                 o   You boot off the disk.  What code ran to enable
  2072.                     you to boot off the disk?
  2073.  
  2074.                 o   You boot off a diskette drive.  Again ...
  2075.  
  2076.                 o   You run a program.  It reads off a disk.  What was
  2077.                     actually read in?  How was it read in?  What did
  2078.                     the reading?
  2079.  
  2080.                 o   You compile a program.  Are you using any library
  2081.                     files?  What is in them?
  2082.  
  2083.                 o   When was the last time you looked at your
  2084.                     CONFIG.SYS?  AUTOEXEC.BAT?
  2085.  
  2086.                 o   You just bought a brand new program.  You just
  2087.                     brought it home from the store.  What do you know
  2088.                     about the program?  About the company that
  2089.                     produced it?
  2090.  
  2091.                 This list is not meant to be all-inclusive nor
  2092.                 thorough.  It is meant to be a spark to start
  2093.                 education.  Let us continue by examining each of these
  2094.                 cases.  (Where found, the symbol "(!)" is used to
  2095.                 designate a potential point of attack for viruses.)
  2096.  
  2097.  
  2098.  
  2099.  
  2100.                 When you turn on the power switch
  2101.  
  2102.  
  2103.                 Before we investigate the different cases above, we
  2104.                 examine the steps that occur when you first flip the
  2105.                 power switch of your IBM PC to the ON position.
  2106.  
  2107.  
  2108.           Appendix: Viral Infections in PC-DOS                      27
  2109.  
  2110.  
  2111.  
  2112.  
  2113.  
  2114.  
  2115.  
  2116.  
  2117.  
  2118.                 Power is given to the system.  A section of code known
  2119.                 as POST (Power On Self Test) residing in ROM (Read
  2120.                 Only Memory) starts running.  It checks memory,
  2121.                 devices, peripherals, and then transfers control to
  2122.                 any "properly signatured" ROMs found in the I/O
  2123.                 channels.  Assuming those pieces run smoothly, control
  2124.                 returns to POST.  When POST completes, it searches for
  2125.                 a diskette in the diskette drive.  If unsuccessful, it
  2126.                 tries to boot off a hard file.  And finally, if
  2127.                 neither works, it starts running the BASIC interpreter
  2128.                 which is found in its ROM.
  2129.  
  2130.                 The first place where programs are read into system
  2131.                 RAM (Random Access Memory) is the hard file or
  2132.                 diskette boot up process.  Until then, all the code
  2133.                 that is run has come from ROM.  Since these ROMs are
  2134.                 from trusted sources, we must assume that they have
  2135.                 not been created with viruses installed.  ROMs, by
  2136.                 their nature, can only be written by special
  2137.                 equipment, not found in your PC.  Thus to tamper with
  2138.                 them, they must be removed and/or replaced without
  2139.                 your knowledge.  For the purposes of this discussion,
  2140.                 we will assume that this has not happened.
  2141.  
  2142.  
  2143.  
  2144.                 Boot from hard file
  2145.  
  2146.  
  2147.                 When the computer boots off the hard file, it relies
  2148.                 on code which has been placed in two areas on the hard
  2149.                 file.  The first location is the master boot
  2150.                 record(!).  The master boot record contains code and
  2151.                 information to designate which "system boot record"(!)
  2152.                 to read and run.  This is the "active partition."
  2153.                 There are potentially many system boot records, one
  2154.                 for each partition, while there is only one master
  2155.                 boot record.
  2156.  
  2157.                 Boot records on a fixed disk vary.  But usually, up to
  2158.                 a whole track is reserved.  This is a large amount of
  2159.                 space, most of which is not normally used.  The large
  2160.                 empty space provides a potential area for viruses to
  2161.                 hide.
  2162.  
  2163.  
  2164.  
  2165.                 Boot from diskette
  2166.  
  2167.  
  2168.                 For a floppy disk, the boot record is a properly
  2169.                 "signatured" sector at head 0 track 0 sector 1 of the
  2170.                 disk(!).  If the machine finds a proper signature, it
  2171.                 takes the bytes stored in that sector and begins
  2172.  
  2173.  
  2174.           Appendix: Viral Infections in PC-DOS                      28
  2175.  
  2176.  
  2177.  
  2178.  
  2179.  
  2180.  
  2181.  
  2182.  
  2183.  
  2184.                 executing them.  This code is usually very short.
  2185.                 Usually, one of the first things it does is to tell
  2186.                 the machine where to get other sectors to form a
  2187.                 complete boot up program.
  2188.  
  2189.                 Viruses can hide parts of themselves on either hard or
  2190.                 floppy disks, in sectors that they mark as "bad."(!)
  2191.                 These sectors would require special commands to be
  2192.                 read.  This prevents the code from being accidentally
  2193.                 overwritten.  They also provide an obvious sign,
  2194.                 should you be looking for them (CHKDSK will report bad
  2195.                 sectors).
  2196.  
  2197.  
  2198.  
  2199.                 PC-DOS, the operating system
  2200.  
  2201.  
  2202.                 The purpose of the boot records is to load the
  2203.                 operating system.  This is done by loading files with
  2204.                 the names IBMBIO.COM(!), IBMDOS.COM(!), and
  2205.                 COMMAND.COM(!).  These files contain the operating
  2206.                 system.
  2207.  
  2208.                 After the operating system is loaded, it becomes the
  2209.                 integral portion of all system activities.  This
  2210.                 includes activities such as reading and writing
  2211.                 files(!), allocating memory(!), and allocating all
  2212.                 other system resources(!).  Few applications exist
  2213.                 that do not use the operating system to take advantage
  2214.                 of the system resources.  Thus, some viruses change
  2215.                 COMMAND.COM or intercept attempts to request a system
  2216.                 resource.
  2217.  
  2218.                 The purpose of such action would be two-fold.  The
  2219.                 first purpose is to place the virus in a common code
  2220.                 path, so that it is executed frequently so that it may
  2221.                 have ample opportunity to spread.  The second is to
  2222.                 cause damage, intercepting the proper request and
  2223.                 altering the request.
  2224.  
  2225.  
  2226.  
  2227.  
  2228.                 Running a program
  2229.  
  2230.  
  2231.                 What code runs when you run a program? (!)  (The
  2232.                 following list is not meant to be complete.  It is to
  2233.                 show you that any link could be a potential point of
  2234.                 attack for a virus.  Since the virus' purpose is to be
  2235.                 executed frequently, it would find itself executed
  2236.                 frequently enough if it resided in any of the
  2237.                 following areas.)
  2238.  
  2239.  
  2240.           Appendix: Viral Infections in PC-DOS                      29
  2241.  
  2242.  
  2243.  
  2244.  
  2245.  
  2246.  
  2247.  
  2248.  
  2249.  
  2250.                 o   DOS accepts your keystrokes.
  2251.  
  2252.                     -   BIOS INT 9H, INT 16H, INT 15H, INT 1BH
  2253.                     -   DOS INT 21H keyboard functions, INT 28H
  2254.                     -   Any keyboard device driver or TSR (Terminate
  2255.                         and Stay Resident) program.
  2256.  
  2257.                 o   DOS loads your program
  2258.  
  2259.                     -   BIOS INT 13H, INT 40H, INT 15H
  2260.                     -   DOS INT 21H file search functions, memory
  2261.                         allocation, set DTA, disk read, CTRL-BREAK
  2262.                         check, etc.
  2263.                     -   Any DOS extension driver or TSR (Terminate and
  2264.                         Stay Resident) program.
  2265.  
  2266.                 o   General background functions
  2267.  
  2268.                     -   BIOS INT 8 (timer), INT 0FH (printer), INT 1CH
  2269.                         (timer)
  2270.                     -   Any system driver or TSR (Terminate and Stay
  2271.                         Resident) program.
  2272.  
  2273.                 All these things happen and more, each time you run a
  2274.                 program.
  2275.  
  2276.  
  2277.  
  2278.                 CONFIG and AUTOEXEC
  2279.  
  2280.  
  2281.                 Every time you boot your system, CONFIG.SYS(!)  and
  2282.                 AUTOEXEC.BAT(!) tell the system to load many files and
  2283.                 options before you can start working on the computer.
  2284.                 If a virus decided to attach an extra line of
  2285.                 instruction to one of these files, it would result in
  2286.                 the program being loaded each day.  When was the last
  2287.                 time you looked at CONFIG.SYS?  AUTOEXEC.BAT?  Do you
  2288.                 remember the reason for the existence of each line in
  2289.                 the two files?
  2290.  
  2291.  
  2292.  
  2293.                 Compiling programs, using libraries
  2294.  
  2295.  
  2296.                 When you compile a program, you use several programs.
  2297.                 One is the compiler itself (!).  If the compiler is
  2298.                 infected with a virus, the virus may spread to other,
  2299.                 unrelated programs.  But it could also spread to the
  2300.                 program being compiled.
  2301.  
  2302.                 When a compiled program is linked to form an
  2303.                 executable program, it is common to link in programs
  2304.  
  2305.  
  2306.           Appendix: Viral Infections in PC-DOS                      30
  2307.  
  2308.  
  2309.  
  2310.  
  2311.  
  2312.  
  2313.  
  2314.  
  2315.  
  2316.                 from libraries(!).  These library programs provide
  2317.                 standard operating system interfaces, perform input
  2318.                 and output, and so on.  If one or more of the library
  2319.                 programs are infected with a virus, then every program
  2320.                 which is linked with it will be infected.
  2321.  
  2322.  
  2323.  
  2324.  
  2325.  
  2326.  
  2327.  
  2328.  
  2329.  
  2330.  
  2331.  
  2332.  
  2333.  
  2334.  
  2335.  
  2336.  
  2337.  
  2338.  
  2339.  
  2340.  
  2341.  
  2342.  
  2343.  
  2344.  
  2345.  
  2346.  
  2347.  
  2348.  
  2349.  
  2350.  
  2351.  
  2352.  
  2353.  
  2354.  
  2355.  
  2356.  
  2357.  
  2358.  
  2359.  
  2360.  
  2361.  
  2362.  
  2363.  
  2364.  
  2365.  
  2366.  
  2367.  
  2368.  
  2369.  
  2370.  
  2371.  
  2372.           Appendix: Viral Infections in PC-DOS                      31
  2373.  
  2374.  
  2375.  
  2376.