home *** CD-ROM | disk | FTP | other *** search
/ ProfitPress Mega CDROM2 …eeware (MSDOS)(1992)(Eng) / ProfitPress-MegaCDROM2.B6I / UTILITY / VIRUS / PCV4RPT.ZIP / HOLO.RPT < prev    next >
Encoding:
Text File  |  1991-05-28  |  14.3 KB  |  285 lines

  1.  
  2.              *********************************************
  3.              ***   Reports collected and collated by   ***
  4.              ***            PC-Virus Index             ***
  5.              ***      with full acknowledgements       ***
  6.              ***            to the authors             ***
  7.              *********************************************
  8.  
  9.  
  10.   Report from Jim Bates - The Virus Information Service - 23rd
  11.   December 1990
  12.  
  13.   === Spanish Telecom Virus aka HOLOCAUST, TELEFONICA ===
  14.  
  15.   Another virus attempting to make a political (?) point has recently
  16.   come to hand from Spain.  This is being called the "Spanish Telecom"
  17.   virus for reasons which will become apparent as this analysis
  18.   progresses.
  19.  
  20.   This virus is a true multi-partite virus in that it functions both
  21.   as a parasitic virus infecting COM files, and as a Boot Sector Virus
  22.   which infects the Master Boot Record of the first fixed disk drive
  23.   as well as the boot record of any type of floppy disk.  The code
  24.   contains a particularly vicious trigger routine which will overwrite
  25.   all data on both the first AND SECOND fixed disk drives.  The
  26.   trigger routine is invoked from the boot code section of the virus
  27.   after the 400th infected boot cycle.  The parasitic code is
  28.   encrypted and contains plain text at the end of the code which reads
  29.   :
  30.  
  31.          Virus Anti - C.T.N.E. (c)1990 Grupo Holokausto.
  32.          Kampanya Anti-Telefonica. Menos tarifas y mas servicio.
  33.          Programmed in Barcelona (Spain). 23-8-90. - 666 -
  34.  
  35.   The final "666" may be a reference to the 666 (Number of the Beast)
  36.   virus since certain techniques first noticed there have been used
  37.   here!  The phrase translates roughly as "Lower tariffs, more
  38.   service."
  39.  
  40.   Another message which is separately encrypted is displayed during
  41.   the overwriting activity of the trigger routine :
  42.  
  43.          Campana Anti-TELEFONICA (Barcelona)
  44.  
  45.   Analysis of this code is best undertaken by considering the
  46.   Parasitic and Boot sections separately -
  47.  
  48.  
  49.   Parasitic Analysis
  50.  
  51.   This is undoubtedly one of the most untidy pieces of code that I
  52.   have examined.  There are many repetitions and several bugs which
  53.   will reveal the presence of the virus long before the trigger
  54.   routine is invoked. The virus code is attached at the end of COM
  55.   files between 128 and 60999 bytes in length (inclusive).
  56.   COMMAND.COM is specifically excluded from infection as is any file
  57.   beginning with the letters "IBM" (the IBM system files).  The
  58.   initial four bytes of the host file are saved within the virus code
  59.   and overwritten with an appropriate jump instruction to pass
  60.   processing to the virus code.  The infective length of the parasitic
  61.   code is 3,700 bytes (this includes the Boot code).  The virus code
  62.   begins with an 85 byte section which contains "armoured" coding to
  63.   detect the presence of debugging software and also several
  64.   randomised instructions which are presumably intended to prevent the
  65.   extraction of a reliable search string.  Within the code there are
  66.   two different versions of this 85 byte "header" routine, only one of
  67.   which is actually positioned for use during the file infection
  68.   process.  There are therefore two distinct search strings for the
  69.   parasitic code although each confirms the existence of the same
  70.   virus.
  71.  
  72.   Both "header" code routines perform the same functions: check for
  73.   debug presence, locate the position of the virus code within the
  74.   host segment and decrypt the remaining code.  Processing then checks
  75.   to see if the virus is resident in memory.  This is done by
  76.   collecting the byte at offset 1BCH of low memory and XORing it with
  77.   13H, the result is then checked against the next byte at offset
  78.   1BDH.  If they are the same then the virus is resident and
  79.   processing passes directly back to the host program.  The actual
  80.   values of these two bytes are changed regularly by the virus during
  81.   its intercept operations but by simply XORing them together,
  82.   regardless of their values, the result will be 13H if the virus is
  83.   resident in memory.
  84.  
  85.   If the virus is not resident, the current INT 21H vector is
  86.   collected and stored in memory.  Collection is via direct access to
  87.   page zero of memory where the interrupt vectors are stored.  All of
  88.   the virus code is then installed in high memory and 3984 bytes are
  89.   removed from system memory to accommodate it.  The next set of
  90.   instructions collects a pseudo-random number from the system clock
  91.   and uses it to index into a table of word addresses.  The selected
  92.   word is then inserted as the offset portion of the INT 21H vector in
  93.   low memory, the segment portion being set to the virus' own segment
  94.   in high memory.  This random process of selection ensures that the
  95.   actual offset stored in the interrupt table will vary from infection
  96.   to infection.  Each address, though different, points to a jump
  97.   instruction which takes processing to a single INT 21H handler
  98.   within the virus code.  There are 14 entries in the address table
  99.   although only 7 of them are used and this, together with other
  100.   sections of the code, suggests that other ideas may have been tried
  101.   (or are being prepared) within this code.  Once the interrupt
  102.   handler has been installed, a special call is made to it which
  103.   completes the installation process.  This call consists of putting
  104.   4B21H into AX and issuing an INT 21H request.
  105.  
  106.   The special call is routed by the virus' handler to an installation
  107.   routine which uses the single step INT 01 capability in the same way
  108.   as the Flip virus (VB Sept 90) to "strip" out any extraneous
  109.   handlers from the targeted interrupt chain.  Interrupts treated in
  110.   this way are 13H, 21H and 40H and the stripped vectors are
  111.   temporarily installed during file infection and repaired when the
  112.   process has completed.  Thus any monitoring software which uses
  113.   installed handlers will need to contain reliable self-testing
  114.   routines to guard against this type of subversion.
  115.  
  116.   The virus interrupt handler intercepts six different function
  117.   requests within the DOS services interrupt :  function 4B21H has
  118.   already been mentioned and there is another special call using a
  119.   value of 4B20H which does nothing.  This is another area which gives
  120.   rise to speculation that further developments may be in hand.  The
  121.   SEEK function (42H) is intercepted when accompanied by subfunction
  122.   02 (to End of File).  This checks to see if the file has been
  123.   infected and if so, modifies the pointer to subtract the length of
  124.   the virus code before returning the End of File position.  The two
  125.   alternative sets of Find First and Find Next functions (11H - 12H
  126.   and 4EH - 4FH) are similarly intercepted to return a modified file
  127.   size on infected files.
  128.  
  129.   The main intercept however, is that applied to the Load and Execute
  130.   function (4B00H).  This is used to select and infect files with a
  131.   COM extension (subject to the name and size exceptions mentioned
  132.   earlier).  Once a suitable file has been identified, the INT 13H and
  133.   INT 40H vectors are temporarily replaced with their stripped
  134.   equivalents and a simple handler for the critical error interrupt
  135.   (24H) is installed.  The usual process of file infection is then
  136.   invoked whereby the target file date, time and attributes are
  137.   collected and stored, and the file is opened for Read/Write access
  138.   (attributes are modified if necessary).  The correct initial jump is
  139.   calculated and the first four bytes of the target file copied and
  140.   stored before being overwritten by a jump to the virus code.
  141.   Certain sections of the virus code are then modified by the addition
  142.   of random data values generated from a system clock reading.  The
  143.   next stage involves using one of these data values as the new
  144.   encryption key into one of the two 85 bytes decryption headers
  145.   (chosen at random).  The header is written (unencrypted) to the end
  146.   of the host file and then the encryption routine is executed.  The
  147.   whole of the virus code is encrypted and written to the end of the
  148.   host file one byte at a time - each byte is collected, encrypted and
  149.   written on an individual basis.  This removes the need for either a
  150.   special buffer or a decrypt/recrypt cycle.  The final stage is to
  151.   close the file and reset the date, time and attributes to their
  152.   original settings.  As a marker to indicate that the file is
  153.   infected, the date setting is modified in a similar way to the 4K
  154.   (IDF or FRODO) virus by adding 100 to the year field.  Modified
  155.   interrupt vectors are then reset to their previous values before
  156.   processing returns to the calling routine.
  157.  
  158.   During the installation of the handlers, a check is made to see if
  159.   the Master Boot Record of the first hard drive is infected with the
  160.   virus' boot code.  If the disk is not infected then the boot section
  161.   of the virus code is installed in Sector 1, Head 0, Track 0.  The
  162.   second sector of virus code is stored in sector 6 of the same track
  163.   and the original boot sector is stored in sector 7.  This will cause
  164.   problems of access on some machines which use these sectors for
  165.   other purposes.
  166.  
  167.  
  168.   BOOT Analysis
  169.  
  170.   The boot section of this virus functions completely independently of
  171.   the parasitic portion and both sections will almost certainly be in
  172.   memory simultaneously.  This may explain the almost obsessive
  173.   concern with revectoring interrupts during the parasitic file
  174.   infection.  However, while the parasitic code contain all the virus
  175.   routines, the boot section is limited to two sectors of self
  176.   contained code.  Thus a machine infected with only the boot code
  177.   will not infect files, only other disks.
  178.  
  179.   The only items worthy of note in the boot code are the Trigger
  180.   routine, the floppy infection routine and the interrupt redirection.
  181.   The interrupt redirection intercepts requests to INT 13H for both
  182.   floppy and hard drives.  A Read or Write request to either the first
  183.   or second floppy drive will result in the disk being checked for
  184.   infection and infected if possible.  The routine is unusual in that
  185.   it will only complete the check and infection if the motors of both
  186.   of the first two floppy drives are NOT running.  INT 13H requests to
  187.   the first hard drive are intercepted and tested to see if they are
  188.   Read or Write.  A Write request to the Master Boot Record of the
  189.   first hard drive is changed into a Verify call so that the sector
  190.   will not be overwritten if the virus is resident.  Read requests are
  191.   tested to see which sector (on Head 0, Track 0) is wanted and
  192.   re-routed accordingly.  Requests for sector 1 are given sector 7
  193.   (where the original boot sector is stored) and requests for either
  194.   sector 6 or 7 are given sector 5.  Thus in a similar way to the
  195.   original Brain virus, it is not possible to examine the true boot
  196.   sector of an infected machine with ordinary utilities while the
  197.   virus is resident.
  198.  
  199.   Floppy Infection
  200.  
  201.   If an uninfected floppy is accessed, the virus will attempt to
  202.   infect it and the storage sectors used for the second sector of code
  203.   will vary according to a table maintained within the virus code.
  204.   Remember that both first and second (A:  and B:) drives are affected
  205.   - the table looks like this :-
  206.  
  207.       Floppy Type        Head and Sector of second part of virus
  208.       160K - 5.25"              0     6
  209.       180K - 5.25"              0     8
  210.       320K - 5.25"              1     1
  211.       360K - 5.25"              1     2
  212.       720K - 5.25" or 3.5"      1     4
  213.       1.2M - 5.25"              1    0DH  (decimal 13)
  214.       1.44M - 3.5"              1    0EH  (decimal 14)
  215.  
  216.   From this table it will be seen that infected disks may become
  217.   unreadable as virus code overwrites sections of the FAT or Root
  218.   Directory.  To complete this information you should note that the
  219.   virus code occupies sectors 1 and 6 of a hard disk, with a copy of
  220.   the original boot sector being stored in sector 7 (all on head 0,
  221.   track 0).
  222.  
  223.  
  224.   Trigger Routine
  225.  
  226.   When a machine is booted from an infected hard disk, a counter
  227.   within the boot code is incremented and tested to see if it has
  228.   passed 400 (190H).  If it hasn't, the code is rewritten back to the
  229.   boot sector and processing continues normally.  However, when the
  230.   counter does reach this number, processing immediately passes to the
  231.   Trigger routine.  This is one of the nastiest, most destructive
  232.   triggers that I have yet seen since it will overwrite all sectors of
  233.   both the first and (if there is one present) the second hard drive
  234.   with random information from boot-time low memory.  The overwriting
  235.   routine will be completed a number of times (for each drive)
  236.   depending upon the number of heads on the drive.  On each pass, the
  237.   encrypted message mentioned above will be displayed.
  238.  
  239.  
  240.   Recognition
  241.  
  242.   It has been necessary to extract a different recognition string for
  243.   each version of the parasitic code and these are as follows:-
  244.  
  245.   Header 1 - 8B1D B200 83FB 0074 18BF 5500 B2         Offset - 34H
  246.  
  247.   Header 2 - 83ED 09BE 2001 03F5 FCB6                 Offset - 24H
  248.  
  249.   It should be noted that the presence of either of these strings at
  250.   the appropriate offset (into the virus code) is an indication of
  251.   infection.  Infective length of the parasite is 3700 bytes (appended
  252.   on LOAD and EXECUTE).
  253.  
  254.   Recognition of the presence of the Boot virus code is simpler but
  255.   note should be taken of the interrupt redirection discussed above.
  256.   The code is not encrypted and the recognition string is as follows
  257.   :-
  258.  
  259.         8A0E EC00 BE70 0003 F18A 4C02 8A74 03C3     Offset - 0B3H
  260.  
  261.  
  262.   VIS Classification - BfmCARKD3700A
  263.  
  264.  
  265.   The information contained in this report is the direct result of
  266.   disassembling and analysing a specimen of the virus code.  I take
  267.   great pains to ensure the accuracy of these analyses but I cannot
  268.   accept responsibility for any loss or damage suffered as a result of
  269.   any errors or omissions.  If any errors of fact are noted, please
  270.   let me know at :-
  271.  
  272.     The Virus Information Service,
  273.     Treble Clef House,
  274.     64, Welford Road,
  275.     WIGSTON MAGNA,
  276.     Leicester  LE8 1SL
  277.  
  278.   or call +44 (0)533 883490
  279.  
  280.   Jim Bates
  281.  
  282.   ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
  283.   ++++++++++++++++++++++++++ end of reports ++++++++++++++++++++++++
  284.   ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
  285.