Regular Expressions 101

Library entries

artifactory-acess

Vote

0

Regular Expression
pcre2

/
^<[0-9]+>(?:[A-Z][a-z]{2}\s+[0-9]{1,2}\s[0-9]{1,2}:[0-9]{2}:[0-9]{2})\s*(?:[^\s]+)?\s*artifactory-access\s*(?P<Timestamp>[0-9]{4}-[0-9]{2}-[0-9]{2}\s*[0-9]{2}:[0-9]{2}:[0-9]{2},[0-9]{3})?\s*(?:\[(?P<ActionResponse>[A-Z]+)\s(?P<ActionType>[A-Z]+)\])?\s*(?:(?P<RepositoryPath>[^\s]+))?\s*(?P<Message>[^:]*)?\s*:\s*(?P<Username>\w+)\s\/\s(?P<IP>[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3})?.*$
/
gm

Description

Loading markdown...
Submitted by anonymous - 7 months ago