Skip to content

Commit

Permalink
All numeric host under certain option conditions
Browse files Browse the repository at this point in the history
  • Loading branch information
rfaircloth-splunk committed Mar 13, 2020
1 parent 82d4748 commit 5eb1d15
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions package/etc/conf.d/filters/cisco/cisco_syslog.conf
Original file line number Diff line number Diff line change
Expand Up @@ -41,12 +41,12 @@ parser cisco-parser-ex{
set(
"${4}",
value("HOST")
condition(match('..' value('4')))
condition(not match('^\d+$', value('4')) and match('^(([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\.){3}([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])$|^(([a-zA-Z0-9]|[a-zA-Z0-9][a-zA-Z0-9\-]*[a-zA-Z0-9])\.)*([A-Za-z0-9]|[A-Za-z0-9][A-Za-z0-9\-]*[A-Za-z0-9])$' value('4')))
);
set(
"${13}",
value("HOST")
condition(match('..' value('13')))
condition(not match('^\d+$', value('13')) and match('^(([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\.){3}([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])$|^(([a-zA-Z0-9]|[a-zA-Z0-9][a-zA-Z0-9\-]*[a-zA-Z0-9])\.)*([A-Za-z0-9]|[A-Za-z0-9][A-Za-z0-9\-]*[A-Za-z0-9])$' value('13')))
);
set(
"${15}",
Expand Down

0 comments on commit 5eb1d15

Please sign in to comment.