DHSWM_一种改进WM多模式匹配算法.pdfVIP

  • 2
  • 0
  • 约2.52万字
  • 约 7页
  • 2017-07-05 发布于湖北
  • 举报
第 42 卷第 12 期 中南大学学报( 自然科学版) Vol.42 No.12 2011 年 12 月 Journal of Central South University (Science and Technology) Dec. 2011 DHSWM :一种改进的WM 多模式匹配算法 刘卫国,胡勇刚 ( 中南大学 信息科学与工程学院,湖南 长沙,410083) 摘要:针对 WM 算法的查找效率随着模式集规模的增大而降低的问题,提出一种改进算法。在预处理阶段,改变 原有 Hash 表中的链表结构,采用双哈希法将模式串存放在 Hash1 表中指定的区间,Hash 表中存放该存储区间的 起始位置与区间长度;Prefix 表用于判断模式集中是否存在与当前匹配窗口中文本前缀相同的模式;当 Shift 表中 出现移动值为0 时,根据后缀出现在模式串其他位置的信息计算匹配窗口可滑动的最大距离并存于 Shift1 表中。 在查找阶段,采用双哈希法在 Hash1 表的某一区间中查找模式串,避免在大规模模式集情况下查找过长的模式链 表,扩大匹配操作后匹配窗口滑动的距离,减少冗余的匹配操作,缩短查找时间。研究结果表明:在模式集规模 较大时,改进后的算法显著地提高了匹配速度;当模式串数目超过 5 000 条时,改进算法的查找时间要比 WM 算 法缩短 40%~47% 。 关键词:入侵检测;模式匹配;Wu-Manber 算法;双哈希查找 中图分类号:TP393 文献标志码:A 文章编号:1672−7207(2011)12−3765−07 DHSWM: An improved multi-pattern matching algorithm based on WM algorithm LIU Wei-guo, HU Yong-gang (School of Information Science and Engineering, Central South University, Changsha 410083, China) Abstract: To resolve the problem that with the constant increase of the number of rules, the performance of Wu-Manber algorithm will become less efficient, an improved Wu-Manber algorithm named double Hash searching Wu-Manber algorithm (DHSWM) was proposed. In the pre-processing stage, the patterns were stored in specified intervals in Hash1 table by double Hash method while Hash table was used to store the parameters which indicate the start address of the interval and its length. Prefix table was used to determine whether the patterns in set and the text of current matching window had the same prefix. When the shifting distance was 0 in

文档评论(0)

1亿VIP精品文档

相关文档