diff options
author | Stan Hu <stanhu@gmail.com> | 2019-07-09 03:58:50 +0000 |
---|---|---|
committer | Stan Hu <stanhu@gmail.com> | 2019-07-09 03:58:50 +0000 |
commit | 8ca710668f64d535ef5f0a7751fcf8ef815def90 (patch) | |
tree | 83fe697d765c50730120fab889c5ab2b5e90b134 | |
parent | 735f360cb4d11c9640d66fd8f76dbaf41dd340b7 (diff) | |
parent | bcd813c0958b10a9b87e162a85a434255002e027 (diff) | |
download | gitlab-ce-8ca710668f64d535ef5f0a7751fcf8ef815def90.tar.gz |
Merge branch '62756-follow-up-user-info-in-auth-log' into 'master'
Limit user information to RackAttack throttles
See merge request gitlab-org/gitlab-ce!30467
-rw-r--r-- | config/initializers/rack_attack_logging.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/config/initializers/rack_attack_logging.rb b/config/initializers/rack_attack_logging.rb index 338e968cc6c..7eb34bd69e5 100644 --- a/config/initializers/rack_attack_logging.rb +++ b/config/initializers/rack_attack_logging.rb @@ -12,7 +12,7 @@ ActiveSupport::Notifications.subscribe('rack.attack') do |name, start, finish, r fullpath: req.fullpath } - if req.env['rack.attack.matched'] != 'throttle_unauthenticated' + if %w(throttle_authenticated_api throttle_authenticated_web).include? req.env['rack.attack.matched'] user_id = req.env['rack.attack.match_discriminator'] user = User.find_by(id: user_id) |