Regular Expressions 101

Community Patterns

Apache Log Parser

1

Regular Expression
Python

r"
([\d.]+) - - \[(.*?)\] \"(.*?)\" (\d{3}\s\d{3}) \"(.*?)\" \"(.*?)\"
"

Description

Parse Apache web logs to be stored in python (most likely a tuple for manipulation, parsing, and correlation)

Submitted by hos - 8 years ago