Docsity

Computer Security and Rootkits, Study notes of Computer Networks

Partial preview of the text

Download Computer Security and Rootkits and more Study notes Computer Networks in PDF only on Docsity!

Computer Security and Rootkits

by Jameel Alsalam, Somnath Banerjee, Grant Musick and Rares Saftoiu

Table of Contents

    1. Introduction.....................................................................................................................
    1. What is a rootkit?
    1. Current vulnerability assessment
    • 3.1. Windows vulnerabilities (2k/2k3/XP/64-bit)...........................................................
    • 3.2 Linux/Unix/OS X vulnerabilities..............................................................................
    1. Estimated Attack Damage.............................................................................................
    • 4.1 Home users..............................................................................................................
      • 4.1.1 Identity and private information theft
      • 4.1.2 Turning home user’s computers into zombies for unethical/criminal activity
      • 4.1.3 Loss of time/money/confidence.......................................................................
    • 4.2 Enterprise and Governmental Systems
      • 4.2.1 Direct costs.......................................................................................................
      • 4.2.2 Indirect costs
      • 4.2.3 Failure Costs
    1. Preventative and Responsive measures
    • 5.1 Technical Responses...............................................................................................
    • 5.2 Policy Responses
      • 5.2.1 Existing Policy.................................................................................................
      • 5.2.2 Policy Recommendations.................................................................................
    1. Cost analysis of proposed measures
    • 6.1 Technical Perspective
    • 6.2 Policy Perspective...................................................................................................
    1. Conclusion
    1. Glossary
    1. Endnotes........................................................................................................................

2. What is a rootkit?

A rootkit is a suite of one or more programs that allows a third party to hide files and activities from the administrator of a computer system. An intruder takes advantage of one or more known vulnerabilities on a particular computing platform to deliver and install the rootkit. Once the rootkit is in place, the intruder can use the infected system while remaining undetected. The original intent of rootkits (circa 1996) appears to have centered simply on hiding programs that would allow an attacker to “sniff” or spy on traffic going to and from a computer system. They earned the name “rootkits” because they were mainly used on Unix derived computer systems where the top-level administrative account is called “root”. Thus to “root” a system is to obtain top-level administrative privileges and hence obtain full control of the system.^1 In the last few years however, attacks have grown in sophistication and the targets have changed. Home users (especially users of Microsoft Windows family of operating systems) are now the primary targets. Not only are attackers trying to harvest information from the targeted computer systems, they also take over the systems and use them as building blocks for “bot-nets”. These bot-nets can then be used in a variety of ways, including spam forwarding and extortion. While performing the latter, an attacker demands money from a corporation, threatening a DDOS attack against their corporate website(s) as a consequence of non-payment. Even well-known and respected companies have been known to use rootkits as a way to enforce their own DRM policies or keep end-users from eliminating adware.

Rootkits of varying levels of sophistication are known to exist for all major operating system platforms, although all types can be dangerous if a system administrator is not wary^2 : The earliest type of rootkit consists of replacement programs for commonly used administrative programs on the computer system. The replacement programs hide the activity of the actual payload from the system administrator. These kits are almost exclusive the Unix/Linux family of operating systems. These will be referred to as first generation rootkits. The second generation rootkits use “hooks” to redirect application calls to operating system (kernel) functions. The hook is used to intercept such legitimate function calls and reroute them to the rootkit’s own version of the function. They are more difficult to detect because they have moved a level closer to the kernel. A cousin to this type of rootkit is a library kit that subverts non-system calls from standard applications, such as a word processor, thereby controlling the application’s interaction with the underlying operating system. Attackers then began to employ even more sophisticated techniques. Third generation rootkits use techniques that go deeper into the system and modify dynamic data structures in the kernel itself. This type of modification is very difficult to detect and, for the most part, can only be spotted by using heuristics that analyze statistical patterns of memory usage. The latest and greatest of rootkits are now aiming to subvert the memory of other applications running on the system, presenting the applications with a false view of the underlying system. This would effectively hide the rootkit from any antivirus scanning

link, the rootkit and payload are installed on the computer just like any other installable piece of software. Windows also has tight integration of many of its subsystems, providing many venues for potential exploitation. For example, the image processing subsystem can be exploited to run arbitrary code with top-level permissions. Such was the case with a vulnerability found last year (2004), where a user could exploit a buffer overrun in the Windows image handling software to execute arbitrary code on a user’s system. This vulnerability made it trivial to compromise systems. All a malicious website would have to do is redirect the user to a web page with a bad image on it. Once the user reached the malicious web page, the system was automatically compromised.^3 Another attack vector is through system level applications such as SQL Server

  1. The so-called SQL Slammer worm caused a lot of mayhem in 2003 by exploiting a buffer-overflow vulnerability to turn each system into a virus generating machine. Although this particular exploit was easily detectable, a more delicate use of this vulnerability would have been to surreptitiously install a payload to monitor information on the system. As recent as several months ago, in October 2005, the first rootkit infections through instant messaging (IM) software were reported. The rootkits are installed when the attacker convinces the IM target to click on a link in their IM client to launch the install program^4. As if all the illegal vectors were not enough, rootkits can also come from organizations you would expect to be upstanding citizens. Earlier year Sony used a rootkit to enforce their own DRM scheme on home users’ computer systems. The

software was bundled with certain music CDs. When a user listened to a CD on his or her computer, the software was installed and hid several pieces of code intended to stop people from abusively copying the music they purchased. However, it only took a couple of days before people started realizing they could use this “benign” rootkit for other activities, such as hiding their malware, spyware, or as in a more unusual example, hiding cheat programs for the popular online role-playing game World of Warcraft 5 . 3.2 Linux/Unix/OS X vulnerabilities The other major family of operating systems consists of Linux, Unix and OSX. Together they form an extended family which share the same basic heritage and kernel design. These systems will collectively be referred to as *Nix systems hereafter. *Nix systems tend to be less vulnerable than Windows systems for several reasons. They are not as widely deployed, which means less exposure to attacks. Where they are deployed, they are often (with the exception of OS X) deployed by people with superior knowledge of computers. Their users are encouraged by the system to not logon as “root”, making it more difficult for software to be installed by a tricked user. Moreover, these systems may not support dynamically loaded device driver modules for the kernel, which removes an entire class of vulnerabilities.^6 On the other hand, *Nix systems are often used for mission-critical roles and can be much more valuable targets for an attacker to subvert. Another potential problem lies in the fact that the underlying system source code for some of these systems (e.g. Linux, Mac OS) is freely available. Attackers can examine such code for vulnerabilities and devise new attacks.

system kernel. However, this vulnerability can be mostly mitigated by compiling the *Nix kernel with LKM turned off. 8 One last note about vulnerabilities in the *Nix systems: there appear to be no known rootkits for OSX systems, at least not in the wild. A rootkit was recently made for OSX as a proof-of-concept, but it could not practically be spread from system to system. It should be noted, though, that OSX is based on a Unix variant called FreeBSD and any rootkit written for that system could potentially affect OSX. 9

4. Estimated Attack Damage

As can be seen in the previous section, all modern computer systems contain multiple vulnerabilities which can be exploited by a rootkit. But what are the consequences of having your computer system “rooted”? The effects range from the traumatizing, but relatively harmless identity theft for individual home users, to a coordinated cyber assault on critical governmental or enterprise computer systems. In this section we will discuss the losses for home and enterprise users separately since they each have different uses for computer systems and different stakes to lose when they get compromised.

4.1 Home users

4.1.1 Identity and private information theft This includes stealing of credit card information, bank account information, social security numbers, software license activation keys, etc., and using the stolen identity for profit or clandestine activities.

A rootkit can be used to hide several common surveillance techniques, such as a key-logger that captures input from the keyboard or a packet sniffer that monitors traffic to and from a server. According to some estimates, 80 to 90 percent of computers are infected with spyware. Assuming that fifteen percent of these users transfer identity related information, there are over twenty six million people that are likely victims of identity theft^10. Another estimate by UW professor Steven Gribble states that between 75 and 80 percent of computers were infected with spyware one time or another 11 . With no way to detect the spyware, an attacker can easily monitor computers and harvest credit card information. Although major credit cards provide zero liability in the event credit cards are compromised, recovering from identity theft can still be a hassle for the consumer. Consumers could spend a lot of time trying to pursue the issue with the credit card company, have to wait for a week or two for a new card, reset their automatic payments, and have their credit history wiped out^12. Less commonly, harvesting information could be used for identity theft to enable illegal immigration, terrorism, espionage, or changing identity permanently. It may also be a means of blackmail, especially if medical privacy or political privacy has been breached and revealing the activities undertaken by the thief under the name of the victim might have serious consequences such as loss of job or marriage. Stolen social security numbers can be used by illegal immigrants to find jobs and obtain other services, which may cause serious problems for the victim^13. Identity theft can be a source of funding for terrorist groups. Terrorists can use stolen information to pay for their operations as well as create false identities 14 .

organization’s type of business. Information corruption or theft from rootkits could threaten life, property, goodwill, and revenue, amongst a host of things. For safety critical information systems, such as those that control nuclear power plants and air traffic control systems, failure to respond at an optimum level could endanger lives, a particularly desirable outcome for terrorist organizations. The results of failure in non-safety related systems include the possibility that data will be corrupted or stolen, or services will be unavailable. These are serious outcomes are not perceived to be as serious as those associated with safety critical systems. Financial consequences can also be grave. Some possibilities are quantified below and their impact on the bottom line calculated. Losses can be divided into direct costs, indirect costs, and failure costs. 4.2.1 Direct costs Direct costs include purchasing, installing, and administering security measures that can be unambiguously associated with loss prevention. These include purchase of products such as firewalls and anti virus software, rootkit detection kits etc. Another direct cost is the maintenance of hot sites. Direct costs vary widely depending on the requirements of the corporation or governmental entity. Specialized groups, such as the U.S. military, usually have the most demanding requirements. However, other institutions such as banking, nuclear facilities, and air traffic control systems also have stringent security requirements. Some sources put the federal information security spending at $6.1 billion this year and projected to grow by 20 percent over the next five years^18. Studies also indicate that information security in the Air Traffic Control Systems is weak and vulnerable^19. About 8 percent of all crashes have resulted from Other Human

Error, which includes Air Traffic Controller error^20. An active series of attacks could push that number up significantly and/or paralyze the U.S. transportation infrastructure. There is rising trend of cyber attacks on corporations.^21 Financial institutions understandably are the number one targets of these attacks. Profits from cyber crimes have surpassed those from drug trafficking, with a turnover of $105 billion in 2004.^22 Corporations are also increasing their security budget to counter an increased threat from cyber attacks 23

. A Deloitte survey in 2003 shows financial services companies are spending approximately 6% of their corporate IT budget on security^24. Of those surveyed 47% percent hired extra security staff compared to 2001. According to another report companies spend from 5.5% (for large companies) to nearly 20% (for small companies) of their IT budget on security. 25 If we assume that the IT budget for a small company is a hundred thousand dollars a year, then twenty thousand dollars are spend on security. Similarly, if a very large company spent $100 million on IT a year, $5.5 million is being spent on security. A substantial portion of the security budget is being spent on web intrusion protection services, the market for which is expected to be $700 million in 2006^26. As mentioned above, spam zombies are also an ever-present problem. One estimate placed the per-worker cost of spam at $1,934 in 2004^27. This cost more than doubled from 2003 where the estimated cost per-worker was $874. 4.2.2 Indirect costs These are less obvious costs associated with loss prevention. Additional security measures can affect system performance, employee morale, or retraining requirements.

of security concerns^32. Cyber crimes in which confidentiality is violated cause a measurable negative impact on stock market value to the tune of 5% 33 . 4.2.3 Failure Costs Failure costs arise when an attack occurs with a consequent loss or impairment of service. These include loss of confidential information, theft of intellectual property, increase in spam, degraded performance, network congestion and instability, drains on productivity, increased help desk costs, and inability to ensure regulatory compliance. Complaints from employees about slow computers, program crashes, or slow network connections may be the first signs of infection. These problems can signal that programs are working in the background, connecting to remote servers to upload or download information. The results are a productivity drain for employees and a computing resource/bandwidth drain for the company. Some estimates put the boot times of a computer with spyware to be 4 to 8 times higher than a computer without spyware^34. According to Microsoft's Jeffrey Friedberg, spyware causes half of the computer crashes reported by customers, at a cost of millions of dollars^35. The same article states that spyware accounts for more than 12 percent of Dell’s technical support calls. Failure is of particular challenge to organizations trying to demonstrate compliance with government regulations for information security. These regulations include the HIPAA, established to ensure privacy of patient information, the Sarbanes- Oxley Act, established to ensure that financial statements are resistant to fraud, the Gramm-Leach-Bliley Act, established to safeguard customer information, and the California Data Privacy Law (California SB 1386), established to protect the confidential information of state residents. Simple non-compliance under HIPAA can bring fines up

to $50,000 36. Similarly compliance with Sarbanes-Oxley Act is very important to an organization because failure can bring senior management up to twenty years of jail time and $5 million in fines 37.

5. Preventative and Responsive measures

Although rootkits can be used for a number of malicious purposes, it is important to note that rootkits themselves pose no inherent threat. They are merely tools used to compromise a computer system, allowing hackers use of the system for further attacks. Rootkits are used to disguise programs running on a computer system, allowing the attacker to escape detection while using the system.

5.1 Technical Responses

Unfortunately, there is no easy way to combat rootkits. Rootkits are designed by nature to be stealthy and undetectable. Unlike viruses or previous breeds of spyware, rootkits alter the structure of the underlying operating system itself, rendering most current techniques for virus and spyware detection ineffective. In a computer system, the operating system is the interface between the hardware and the software. An application running on a particular operating system is a client of that system, and, in order to operate correctly, relies on information provided by the underlying system. After the installation of a rootkit, the underlying operating system can no longer be trusted. Unfortunately, any anti-virus or spyware detection software running on a particular system is also a client of the operating system and is inherently dependent on it. Current virus scanning software examines each file on a computer

query files and programs. If two different methods for obtaining a list of files yield different results, the system is likely to be infected. One way to obtain the two different file lists is by using the system’s standard way to report information, and in addition, using a method that is less likely to be compromised. The non-compromised list can be constructed in a variety of ways – through known good backups, lower level and less commonly used API’s which are less likely to be infected, or through the examination of resources from a known good operating system, which could be deployed from a different machine or a clean boot CD. F-Secure Blacklight and RootKitRevealer from SysInternals are programs which use this technique to detect rootkits. Although this approach is able to detect a wide variety of rootkits, even the low-level scan could be intercepted by a well-designed rootkit, necessitating an external viewpoint to accurately detect file and process-hiding. VICE is a program designed by Jamie Butler, designer of the FU rootkit, which catalogues the API hooks which may be potentially used by a rootkit. It could not detect rootkits that use other techniques, such those that directly modify kernel data structures. Although effective, this method cannot guarantee 100% coverage. A rootkit may hook into API’s that are not being monitored. Moreover, it is difficult to automatically distinguish legitimate from malicious API hooks. Another way to keep track of changes potentially made by a rootkit is by using a “cross-time diff” comparison to catalog changes as they are being made to the system. To use this method effectively, the rootkit detection software must be installed in a known clean state. From this point forward, the detection software can compare the present state to the known clean state, and allow the user to merge desired system

changes into the known-clean state. If any suspect changes appear, the user can revert to the last known clean state. Tripwire and Strider Ghostbuster are two software implementations of this approach. The advantage of this method is that it can detect a wide variety of malware. The major disadvantage is that a system incurs many benign changes during its lifetime, changes that must be recognized by the user as not being malicious.^39 Responding to a rootkit threat involves both the detection of the rootkit and its removal. Since rootkits alter the operating system itself, they are often difficult to remove without destabilizing a system. Moreover, it is very hard, if not impossible to know when and if a system is clean. The methods surveyed above are all detection only or preventative measures. In most cases, users are advised to perform a clean install once a system has been deemed compromised.

5.2 Policy Responses

5.2.1 Existing Policy Although rootkits have been around since the mid 1990’s, the average computer user has not been aware of their existence until just recently, and only due to the media attention generated by Sony’s use of a rootkit to enforce copy protection of its music CDs. Although consumer awareness of spyware in general has been on the rise, rootkits still remain relatively unknown. It is then not surprising that legislation pertaining to rootkits specifically does not exist. A survey of existing computer security legislation shows attempts to tackle spyware and the means by which spyware propagates. The lack of rootkit specific legislation can also be attributed to the use of rootkits as tools to propagate spyware or