diff options
author | Robert Speicher <robert@gitlab.com> | 2017-08-31 15:18:09 +0000 |
---|---|---|
committer | Robert Speicher <robert@gitlab.com> | 2017-08-31 15:18:09 +0000 |
commit | 019b18f3267f341e8d6847c7c969bb506bab8769 (patch) | |
tree | 609506709269c7c25ae9b8a5ddf3601fbf1bed5b /config | |
parent | bda435f6eac75f7614aed3996e5d45e481627fc0 (diff) | |
parent | d74fecac031df1c3b4e817f49f7bafe2b175be11 (diff) | |
download | gitlab-ce-019b18f3267f341e8d6847c7c969bb506bab8769.tar.gz |
Merge branch 'sh-filter-csrf-params' into 'master'
Filter additional parameters that have shown up in our logs
See merge request !13945
Diffstat (limited to 'config')
-rw-r--r-- | config/application.rb | 15 |
1 files changed, 4 insertions, 11 deletions
diff --git a/config/application.rb b/config/application.rb index f69dab4de39..32a290f2002 100644 --- a/config/application.rb +++ b/config/application.rb @@ -51,31 +51,24 @@ module Gitlab # Configure sensitive parameters which will be filtered from the log file. # # Parameters filtered: - # - Password (:password, :password_confirmation) - # - Private tokens + # - Any parameter ending with `_token` + # - Any parameter containing `password` + # - Any parameter containing `secret` # - Two-factor tokens (:otp_attempt) # - Repo/Project Import URLs (:import_url) # - Build variables (:variables) # - GitLab Pages SSL cert/key info (:certificate, :encrypted_key) # - Webhook URLs (:hook) - # - GitLab-shell secret token (:secret_token) # - Sentry DSN (:sentry_dsn) # - Deploy keys (:key) + config.filter_parameters += [/_token$/, /password/, /secret/] config.filter_parameters += %i( - authentication_token certificate encrypted_key hook import_url - incoming_email_token - rss_token key otp_attempt - password - password_confirmation - private_token - runners_token - secret_token sentry_dsn variables ) |