Amihood Amir, Avivit Levy, Ely Porat and B. Riva Shalom
Online Recognition of Dictionary with One Gap
We formalize and examine the online Dictionary Recognition with One Gap problem (DROG) which is the following.
Preprocess a dictionary D of d patterns, where each pattern contains a special gap symbol that can match any string, so that given a text that arrives online, a character at a time, we can report all the patterns from D that have not been reported yet and are suffixes of the text that has arrived so far, before the next character arrives. The gap symbols are associated with bounds determining the possible lengths of matching strings. Online DROG captures the difficulty in a bottleneck procedure for cyber-security, as many digital signatures of viruses manifest themselves as patterns with a single gap.
Following the work of Amir et al. (2016) on the closely related online Dictionary Matching with One Gap problem (DMOG), we provide algorithms whose time cost depends linearly on δ(G_D), where G_D is a bipartite graph that captures the structure of D and δ(G_D) is the degeneracy of this graph. These algorithms are of practical interest since although δ(G_D) can be as large as √d , and even larger if G_D is a multi-graph, it is typically a very small constant in practice. Finally, when δ(G_D) is large we describe other efficient solutions. 1