Content search mechanism
First Claim
1. A network services processor comprising:
- a processor; and
a memory, the memory storing a graph having a plurality of nodes, the processor executing a walker process having an associated walker state to walk the graph to search for a match defined by a regular expression in an input stream, at least one node in the graph associated with a command, upon reaching the at least one node, the processor executing the command to manage the state.
8 Assignments
0 Petitions
Accused Products
Abstract
An improved content search mechanism uses a graph that includes intelligent nodes avoids the overhead of post processing and improves the overall performance of a content processing application. An intelligent node is similar to a node in a DFA graph but includes a command. The command in the intelligent node allows additional state for the node to be generated and checked. This additional state allows the content search mechanism to traverse the same node with two different interpretations. By generating state for the node, the graph of nodes does not become exponential. It also allows a user function to be called upon reaching a node, which can perform any desired user tasks, including modifying the input data or position.
180 Citations
26 Claims
-
1. A network services processor comprising:
-
a processor; and
a memory, the memory storing a graph having a plurality of nodes, the processor executing a walker process having an associated walker state to walk the graph to search for a match defined by a regular expression in an input stream, at least one node in the graph associated with a command, upon reaching the at least one node, the processor executing the command to manage the state. - View Dependent Claims (2, 3, 4, 5, 6, 7, 8)
-
-
9. A content search mechanism comprising:
-
a compiler that generates a graph having a plurality of intelligent nodes;
and a walker process that executes a command associated with one of the intelligent nodes to manage a walker state while walking the graph stored in a memory to search for a match in an input stream based on a sequence of characters defined by an expression. - View Dependent Claims (10, 11, 12, 13)
-
-
14. A method for performing a search for a match for an expression in a string of characters comprising:
-
generating a graph for searching for the expression, the graph having a plurality of intelligent nodes;
walking the graph for each character in the string of characters to search for the match defined by the expression in the string; and
upon reaching at least one intelligent node in the graph associated with a command, executing the command to manage a walker state associated with the command.
-
-
15. A network services processor comprising:
-
a memory storing a graph having a plurality of intelligent nodes; and
a content search mechanism, the content search mechanism comprising a walker that walks the intelligent nodes in the graph to search for a match in an input stream by executing a command stored in one of the intelligent nodes to manage a walker state associated with the command. - View Dependent Claims (16, 17)
-
-
18. A computer implemented method for traversing a deterministic finite automata-based graph comprising:
-
traversing nodes in the graph to search for an expression in an input stream based on pointers to next nodes stored in a node; and
upon detecting a command associated with the node, executing a function identified by the command to manage a walker state. - View Dependent Claims (19, 20)
-
-
21. A computer implemented method for generating a deterministic finite automata-based graph comprising:
-
parsing expressions to determine locations for breaks;
building the graph by creating nodes and arcs to nodes; and
inserting intelligence in a node by storing a command in a node corresponding to a break location, the command being executed when the node is reached during a graph walk. - View Dependent Claims (22, 23, 24, 25)
-
-
26. A deterministic finite automata-based graph comprising:
-
at least one data node, the data node storing a command, the command executed while walking the graph to search for a match for a sequence of characters defined by a regular expression in an input stream; and
a state for storing status of a data node while walking the graph, the state including start offset, and end offset of an expression.
-
Specification