Last active
January 9, 2019 11:18
-
-
Save neu5ron/cbfca0dfc42b1d6c96cd321d687e5495 to your computer and use it in GitHub Desktop.
Add Additional HTTP Header fields to Bro http logs
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
module HTTP; | |
# Add additional HTTP Headers | |
redef record Info += { | |
#Origin "Origin" | |
origin: string &log &optional; | |
}; | |
event http_header(c: connection, is_orig: bool, name: string, value: string) &priority=5 | |
{ | |
if ( is_orig ) # client headers | |
{ | |
if ( name == "ORIGIN" ) | |
c$http$origin = value; | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment