Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

apache log format json

log_format le_json '{ "time": "$time_iso8601", ' '"remote_addr": "$remote_addr", ' '"remote_user": "$remote_user", ' '"body_bytes_sent": "$body_bytes_sent", ' '"request_time": "$request_time", ' '"status": "$status", ' '"request": "$request", ' '"request_method": "$request_method", ' '"http_referrer": "$http_referer", ' '"http_user_agent": "$http_user_agent" }'; access_log /var/log/nginx/access.log le_json;
Source by blog.rapid7.com #
 
PREVIOUS NEXT
Tagged: #apache #log #format #json
ADD COMMENT
Topic
Name
1+7 =