OSSEC文档——正则语法
发布时间:2020-12-14 06:38:02 所属栏目:百科 来源:网络整理
导读:翻译:http://ossec-docs.readthedocs.io/en/latest/syntax/regex.html 正则语法 目前,OSSEC支持正则表达式语法: OS_Regex或正则表达式 OS_Match或sregex OS_Regex或正则表达式 在c语言中,快速而简单的正则表达式库。 这个库的设计很简单,但是支持最常用
翻译:http://ossec-docs.readthedocs.io/en/latest/syntax/regex.html
正则语法 目前,OSSEC支持正则表达式语法: OS_Regex或正则表达式 OS_Match或sregex OS_Regex或正则表达式 在c语言中,快速而简单的正则表达式库。 这个库的设计很简单,但是支持最常用的正则表达式。它在设计时考虑了入侵检测系统, 支持表达式: w -> A-Z,a-z,0-9,'-','@' 字符 d -> 0-9 s -> For spaces " " t -> For tabs. p -> ()*+,-.:;<=>?[]!"'#$%&|{} (标点符号) W -> For anything not w D -> For anything not d S -> For anything not s . -> For anything修饰符 + -> To match one or more times (eg w+ or d+) * -> To match zero or more times (eg w* or p*)特殊字符 ^ -> To specify the beginning of the text. $ -> To specify the end of the text. | -> To create an "OR" between multiple patterns.转义字符 $ -> $ ( -> ( ) -> ) -> | -> | OS_Match或sregex 比osregex/regex更快,但是只支持简单的字符串匹配和以下特殊字符。 ^ -> To specify the beginning of the text. $ -> To specify the end of the text. | -> To create an "OR" between multiple patterns. (编辑:李大同) 【声明】本站内容均来自网络,其相关言论仅代表作者个人观点,不代表本站立场。若无意侵犯到您的权利,请及时与联系站长删除相关内容! |