On June 11, 2003 the Gartner
Intrusion detection has had its problems, such as false positives, operational issues in high-speed environments, and the difficulty of detecting unknown threats. In addition, intrusion prevention is still in its infancy. Most of the problems with intrusion detection are caused by improper implementation and misunderstanding of what the technology can and cannot do.
This book focuses on what intrusion detection and prevention can and cannot do. We will examine ways to get the most from this technology, and look at how it can be managed to benefit your organization.
This chapter will introduce intrusion-detection system (IDS) and intrusion-prevention system (IPS) technologies, explaining what they are, as well as pointing out their differences. We will examine why these systems may be important to your organization, and look at the general types of analysis processes used by both IDSs and IPSs. Finally, we will review the pros and cons of both IDS and IPS technologies and clear up some of the myths about them.
Any dictionary will provide a definition of
intrusion
, but its meaning in the computer security context has been debated. Many people consider intrusions to include
Security professionals may want to have IDS systems record information about both successful and unsuccessful attempts so that security professionals will have a more comprehensive understanding of the events on their networks. One way this can be done is by placing devices that examine network traffic, called
sensors
, both in front of the firewall (the
An intrusion-detection system (IDS) can be defined as the tools,
You can loosely compare firewalls to locked doors, intrusion detection to alarm systems, and intrusion prevention to guard dogs. Let’s say that you have a warehouse full of secret documents that you want to protect with a fence around the perimeter, an alarm system, locked doors, and security
As you can see, the door locks, alarm system, and guard dog play separate but complementary roles in the protection of this warehouse. This is also true of firewalls and IDSs and IPSs. All of these are different technologies that can work together to alert you and can prevent intrusions into a network. In addition, how these technologies are implemented determines whether or not they increase security. For instance, in the warehouse example, the most effective strategy may be to place alarms and locks on all the
It is also important to note that IDSs and IPSs are just two of many methods that should be employed in a strong security program. Using a layered approach, or defense in depth, based on careful risk analysis is critical in any information protection program because a network is only as secure as its weakest link. This means that a network should have multiple
Figure 1-1:
Defense in depth
IDSs work at the network layer of the OSI model (see Table 1-1), and passive network sensors are typically positioned at
|
Layer |
Function |
Protocols |
|---|---|---|
|
Application (
|
This layer is used for applications, such as HTTP,
|
DNS, FTP, TFTP, BOOTP, SNMP, RLOGIN, SMTP, MIME, NFS, FINGER, TELNET, APPC, AFP, |
|
Presentation (translation) |
The presentation layer helps to translate between the application and the network formats. This is also where protocol conversion takes place. |
Named Pipes, Mail Slots, RPC, NCP, SMB |
|
Session |
The session layer helps to establish, maintain, and end sessions across the network. |
NetBios |
|
Transport (packets; flow control and error-handling) |
The transport layer
|
TCP, ARP, RARP, SPX, NWLink, ATP, NetBEUI |
|
Network (addressing; routing) |
The network layer
|
IP, ARP, RARP,
|
|
Data link (data
|
The data-link layer turns packets into raw bits on the sending end, and at the receiving end turns bits into packets. It handles data frames between the network and physical layers. |
|
|
Physical (hardware; raw bit stream) |
The physical layer transmits the raw bit stream over the physical cable or airwaves (when dealing with wireless). It defines cables, cards, and other physical aspects. |
IEEE 802, IEEE 802.2, ISO 2110, ISDN |
IDSs fall into one of three categories: host-based intrusion-detection system (HIDS), network-based intrusion-detection system (NIDS), and hybrids of the two.
A HIDS system will require some software that resides on the system and can scan all host resources for activity; some just scan syslog and event logs for activity. It will log any activities it discovers to a secure database and check to see whether the events match any malicious event record listed in the knowledge base.
A NIDS system is usually inline on the network, and it analyzes network packets looking for attacks. A NIDS receives all packets on a particular network segment, including switched networks (where this is not the default behavior) via one of several methods, such as taps or port mirroring. It
A hybrid IDS combines a HIDS, which monitors events occurring on the host system, with a NIDS, which
|
NIDS |
HIDS |
|---|---|
|
Broad in scope (
|
Narrow in scope (watches only specific host activities) |
|
Easier setup |
More complex setup |
|
Better for detecting attacks from the outside |
Better for detecting attacks from the inside |
|
Less expensive to implement |
More expensive to implement |
|
Detection is based on what can be recorded on the entire network |
Detection is based on what any single host can record |
|
Examines packet headers |
Does not see packet headers |
|
Near real-time response |
Usually only responds after a suspicious log entry has been made |
|
OS-independent |
OS-specific |
|
Detects network attacks as payload is
|
Detects local attacks before they hit the network |
|
Detects unsuccessful attack attempts |
Verifies success or failure of attacks |
The basic process for an IDS is that a NIDS or HIDS
Figure 1-2:
Standard IDS system
It is still early in the development of intrusion-prevention systems (IPSs), but
|
|
There are two primary ways to collect data on a switched network: port mirroring and network taps. Port mirroring , also referred to as spanning , is when copies of incoming and outgoing packets are forwarded from one port of a network switch to another port where the packets can be analyzed. Network taps are put directly in-line of the network traffic, and they copy the incoming and outgoing packets and retransmit them back out on the network. Both methods have advantages and disadvantages that should be explored when making implementation decisions.
|
|
IPS systems are similar in setup to IDS systems—an IPS can be a host-based IPS (HIPS), which work best at protecting applications, or a network-based IPS (NIPS). User actions should
An IPS will typically consist of four main
Traffic normalizer
Service scanner
Detection engine
Traffic shaper
The traffic normalizer will interpret the network traffic and do packet analysis and packet reassembly, as well as performing basic blocking functions. The traffic is then fed into the detection engine and the service scanner. The service scanner builds a reference table that classifies the information and helps the traffic shaper manage the flow of the information. The detection engine does pattern matching against the reference table, and the appropriate response is determined. Figure 1-3 outlines this process.
Figure 1-3:
Standard IPS system
IDS and IPS technology each have their own place in a security program because they perform separate functions. Table 1-3 clarifies some of the differences between them.
|
IDS |
IPS |
|---|---|
|
Installed on network segments (NIDS) and on
|
Installed on network segments (NIPS) and on hosts (HIPS) |
|
Sits on network passively |
Sits inline (not passive) |
|
Cannot parse encrypted traffic |
Better at protecting applications |
|
Central management control |
Central management control |
|
Better at detecting hacking attacks |
Ideal for blocking web defacement |
|
Alerting product (reactive) |
Blocking product (proactive) |