From 32483a7f2617742efc466bae3f03fb6afbf0190a Mon Sep 17 00:00:00 2001 From: Konstantin Grachev Date: Sun, 25 Nov 2018 16:24:28 +0300 Subject: [PATCH] [Bugfix] Nginx Parser: http_x_forwarded_for can contain multiple IP divided by comma Signed-off-by: Konstantin Grachev --- lib/fluent/plugin/parser_nginx.rb | 2 +- test/plugin/test_parser_nginx.rb | 20 ++++++++++++++++++++ 2 files changed, 21 insertions(+), 1 deletion(-) diff --git a/lib/fluent/plugin/parser_nginx.rb b/lib/fluent/plugin/parser_nginx.rb index 9717e1bcbe..e9090ef06d 100644 --- a/lib/fluent/plugin/parser_nginx.rb +++ b/lib/fluent/plugin/parser_nginx.rb @@ -21,7 +21,7 @@ module Plugin class NginxParser < RegexpParser Plugin.register_parser("nginx", self) - config_set_default :expression, /^(?[^ ]*) (?[^ ]*) (?[^ ]*) \[(?