skip to main content
10.1145/1323548.1323573acmconferencesArticle/Chapter ViewAbstractPublication PagesancsConference Proceedingsconference-collections
research-article

An improved algorithm to accelerate regular expression evaluation

Published:03 December 2007Publication History

ABSTRACT

Modern network intrusion detection systems need to perform regular expression matching at line rate in order to detect the occurrence of critical patterns in packet payloads. While deterministic finite automata (DFAs) allow this operation to be performed in linear time, they may exhibit prohibitive memory requirements. In [9], Kumar et al. propose Delayed Input DFAs (D2FAs), which provide a trade-off between the memory requirements of the compressed DFA and the number of states visited for each character processed, which corresponds directly to the memory bandwidth required to evaluate regular expressions.

In this paper we introduce a general compression technique that results in at most 2N state traversals when processing a string of length N. In comparison to the D2FA approach, our technique achieves comparable levels of compression, with lower provable bounds on memory bandwidth (or greater compression for a given bandwidth bound). Moreover, our proposed algorithm has lower complexity, is suitable for scenarios where a compressed DFA needs to be dynamically built or updated, and fosters locality in the traversal process. Finally, we also describe a novel alphabet reduction scheme for DFA-based structures that can yield further dramatic reductions in data structure size.

References

  1. A. V. Aho and M. J. Corasick, "Efficient String Matching: An Aid to Bibliographic Search," Communication of ACM, 1975. Google ScholarGoogle ScholarDigital LibraryDigital Library
  2. J. E. Hopcroft and J. D. Ullman, "Introduction to Automata Theory, Languages, and Computation," Addison Wesley, 1979. Google ScholarGoogle ScholarDigital LibraryDigital Library
  3. J. Hopcroft, "An nlogn algorithm for minimizing states in a finite automaton," in Theory of Machines and Computation, J. Kohavi, Ed. New York: Academic, 1971, pp. 189--196.Google ScholarGoogle Scholar
  4. R. Prim, "Shortest connection networks and some generalizations," Bell System Technical Journal, 1957.Google ScholarGoogle ScholarCross RefCross Ref
  5. J. B. Kruskal, "On the shortest spanning subtree of a graph and the traveling salesman problem," Proc. of the American Mathematical Society, Vol. 7, No. 1. (Feb., 1956), pp. 48--50.Google ScholarGoogle ScholarCross RefCross Ref
  6. Y. J. Chu and T. H. Liu, "On the shortest arborescence of a directed graph", Science Sinica, v.14, 1965, pp. 1396--1400.Google ScholarGoogle Scholar
  7. J. Edmonds, "Optimum branchings", J. Research of the National Bureau of Standards, 71B, 1967, pp.233--240.Google ScholarGoogle ScholarCross RefCross Ref
  8. R. E. Tarjan, "Data Structures and Network Algorithms," SIAM 1983. Google ScholarGoogle ScholarDigital LibraryDigital Library
  9. S. Kumar et alt., "Algorithms to Accelerate Multiple Regular Expressions Matching for Deep Packet Inspection," in ACM SIGCOMM, Sept 2006. Google ScholarGoogle ScholarDigital LibraryDigital Library
  10. M. Roesch, "SNORT: Lightweight Intrusion Detection for Networks," in 13th System Administration Conf., Nov 1999. Google ScholarGoogle ScholarDigital LibraryDigital Library
  11. SNORT: http://www.snort.orgGoogle ScholarGoogle Scholar
  12. Bro: A System for Detecting Network Intruders in Real-Time. http://www.icir.org/vern/bro-info.htmlGoogle ScholarGoogle Scholar
  13. Cisco Systems. Cisco Adaptive Security Appliance. http://www.cisco.com. 2007.Google ScholarGoogle Scholar
  14. Citrix Systems. Citrix Application Firewall. http://www.citrix.com. 2007.Google ScholarGoogle Scholar
  15. F. Yu et alt., "Fast and Memory-Efficient Regular Expression Matching for Deep Packet Inspection", in ANCS 2006. Google ScholarGoogle ScholarDigital LibraryDigital Library
  16. S. Kumar, J. Turner and J. Williams, "Advanced Algorithms for Fast and Scalable Deep Packet Inspection", in ANCS 2006. Google ScholarGoogle ScholarDigital LibraryDigital Library
  17. S. Sen et alt., "Accurate, Scalable In-network Identification of P2P Traffic Using Application Signatures", in Proc. of the XIII Intl. WWW Conf., New York City, May 2004. Google ScholarGoogle ScholarDigital LibraryDigital Library
  18. N. Tuck et alt., "Deterministic Memory-Efficient String Matching Algorithms for Intrusion Detection", in IEEE Infocom, pp. 333--340, Mar 2004.Google ScholarGoogle Scholar
  19. G. Varghese, "Network Algorithms: An Interdisciplinary Approach to Designing Fast Networked Devices", Morgan Kaufmann, 1st ed., 2004. Google ScholarGoogle ScholarDigital LibraryDigital Library
  20. R. Sommer and V. Paxson, "Enhancing byte-level network intrusion detection signatures with context.", in ACM CCS 2003. Google ScholarGoogle ScholarDigital LibraryDigital Library
  21. R. Sidhu and V. K. Prasanna, "Fast Regular Expression Matching using FPGAs", in FCCM 2001. Google ScholarGoogle ScholarDigital LibraryDigital Library
  22. C. R. Clark and D. E. Schimmel, "Efficient reconfigurable logic circuit for matching complex network intrusion detection patterns," In FPL 2003.Google ScholarGoogle Scholar
  23. J. Moscola, J. Lockwood, R. P. Loui, and M. Pachos, "Implementation of a content-scanning module for an internet firewall," in FCCM, Napa, CA, USA, April 2003. Google ScholarGoogle ScholarDigital LibraryDigital Library
  24. http://www.tensilica.comGoogle ScholarGoogle Scholar
  25. Cisco Systems. Silicon Packet Processor in the CRS-1 Router. http://www.cisco.com/en/US/products/ps5763/index.htmlGoogle ScholarGoogle Scholar
  26. M. Adiletta et al., "The Next Generation of Intel IXP Network Processors", in Intel Tech. Journal, Vol. 6, Iss 3, 2002.Google ScholarGoogle Scholar

Index Terms

  1. An improved algorithm to accelerate regular expression evaluation

    Recommendations

    Comments

    Login options

    Check if you have access through your login credentials or your institution to get full access on this article.

    Sign in
    • Published in

      cover image ACM Conferences
      ANCS '07: Proceedings of the 3rd ACM/IEEE Symposium on Architecture for networking and communications systems
      December 2007
      212 pages
      ISBN:9781595939456
      DOI:10.1145/1323548

      Copyright © 2007 ACM

      Permission to make digital or hard copies of all or part of this work for personal or classroom use is granted without fee provided that copies are not made or distributed for profit or commercial advantage and that copies bear this notice and the full citation on the first page. Copyrights for components of this work owned by others than ACM must be honored. Abstracting with credit is permitted. To copy otherwise, or republish, to post on servers or to redistribute to lists, requires prior specific permission and/or a fee. Request permissions from [email protected]

      Publisher

      Association for Computing Machinery

      New York, NY, United States

      Publication History

      • Published: 3 December 2007

      Permissions

      Request permissions about this article.

      Request Permissions

      Check for updates

      Qualifiers

      • research-article

      Acceptance Rates

      ANCS '07 Paper Acceptance Rate20of70submissions,29%Overall Acceptance Rate88of314submissions,28%

    PDF Format

    View or Download as a PDF file.

    PDF

    eReader

    View online with eReader.

    eReader