Certopolis

Certified Information Systems Security Professional (CISSP)

IDS vs IPS: signature vs anomaly-based detection (CISSP)

NIST SP 800-94 defines intrusion detection as monitoring events and analyzing them for signs of possible incidents, and intrusion prevention as also attempting to stop them. Signature-based detection compares known-threat patterns with observed events. Anomaly-based detection compares activity with a learned profile of normal behavior. Stateful protocol analysis compares it with vendor-developed profiles of benign protocol use.

Signature-based vs anomaly-based detection

A signature is a pattern that corresponds to a known threat. Signature-based detection is the simplest method: it compares the current unit of activity, such as a packet or a log entry, with a list of signatures. It is very effective against known threats and largely ineffective against previously unknown threats, disguised threats and many variants of known threats. NIST's example is malware renamed from freepics.exe to freepics2.exe, which a signature for the first name does not match.

Anomaly-based detection builds profiles of the normal behavior of users, hosts, network connections or applications over a training period, then flags significant deviations. Its major benefit is that it can be very effective at detecting previously unknown threats.

Its cost is false positives. Benign activity that deviates from the profile raises alerts, such as a monthly maintenance job with large file transfers that never ran during training. A static profile becomes inaccurate as systems change and must be regenerated periodically. A dynamic profile adjusts constantly, but an attacker can raise malicious activity slowly enough for it to be absorbed into the profile.

What is stateful protocol analysis?

Stateful protocol analysis compares observed events with predetermined profiles of generally accepted benign protocol activity for each protocol state. Unlike anomaly-based detection, the profiles are universal and developed by the vendor, not learned from one host or network.

Stateful means the system tracks the state of the protocol and pairs requests with responses. In an FTP session, a user in the unauthenticated state should issue only a few commands. Issuing most other commands before authenticating is treated as suspicious.

IDS, IPS and the four IDPS types

SP 800-94 treats detection and prevention together as intrusion detection and prevention systems (IDPS). False positives and false negatives cannot both be eliminated, since reducing one increases the other. Many organizations choose to reduce false negatives at the cost of more false positives. Altering the configuration to improve detection accuracy is called tuning.

The four types are network-based, wireless, network behavior analysis and host-based. A wireless IDPS analyzes the wireless protocols themselves and cannot identify suspicious activity in the higher-layer protocols the wireless traffic carries. Network behavior analysis examines traffic to identify threats that generate unusual flows, such as distributed denial of service attacks and certain malware.

Where the exam catches people

  • Believing signature-based detection catches a renamed variant of known malware: a small change to the matched pattern defeats the signature.
  • Believing an alert on a rare but legitimate maintenance job is a false negative: it is an anomaly-based false positive.
  • Believing stateful protocol analysis learns each network's normal traffic: it uses vendor-developed universal profiles, and learned profiles are anomaly-based.
  • Believing tuning removes both false positives and false negatives: lowering one raises the other.
  • Believing a dynamic profile is always safer than a static one: it avoids going stale but can be trained by slow, gradual malicious activity.

Written from these sources

Try 3 questions on this

Pick an answer to see why each option is right or wrong.

  1. An organization's IDPS reliably alerts on catalogued malware, yet it missed a variant of the same malware whose only change was a new filename. Which detection method most likely explains the miss?

    Right. In the game that’s Renown for your Domain 7: Security Operations building.

    Not that one: D is right. In the game your Domain 7: Security Operations building would lose a little Renown, and this question would come back later.

    Show the full explanation and doc quotes

    It is very effective against known threats but largely ineffective against unknown threats, evasion and many variants of known threats, such as malware renamed so the signature no longer matches.

    Written from nvlpubs.nist.gov/nistpubs/Legacy/SP/nistspecialpublication800-94.pdf

  2. A new IDPS spent two weeks learning the typical activity of an organization's hosts. Weeks later, it raises an alert when a monthly maintenance job, never seen while it was learning, performs large file transfers. Which description fits this alert?

    Right. In the game that’s Renown for your Domain 7: Security Operations building.

    Not that one: B is right. In the game your Domain 7: Security Operations building would lose a little Renown, and this question would come back later.

    Show the full explanation and doc quotes

    An alert on benign activity is a false positive.

    Written from nvlpubs.nist.gov/nistpubs/Legacy/SP/nistspecialpublication800-94.pdf

  3. An IDPS alerts when an FTP client issues file-management commands before completing authentication. It reached that verdict by comparing the session with vendor-developed universal models of benign behavior for each session state, not with a profile built from this network's own traffic. Which detection method did it use?

    Right. In the game that’s Renown for your Domain 7: Security Operations building.

    Not that one: A is right. In the game your Domain 7: Security Operations building would lose a little Renown, and this question would come back later.

    Show the full explanation and doc quotes

    Unlike anomaly-based detection, which uses host- or network-specific profiles, it relies on vendor-developed universal profiles. FTP commands issued in the unauthenticated state are its own example.

    Written from nvlpubs.nist.gov/nistpubs/Legacy/SP/nistspecialpublication800-94.pdf

Ask for something