Sensitive data in a logger message detected.

  • Rule ID: ruby_lang_logger
  • Languages: ruby
  • Source: logger.yml


Leaking sensitive data to loggers is a common cause of data leaks and can lead to data breaches. This rule looks for instances of sensitive data sent to loggers.


❌ Avoid using sensitive data in logger messages:'User is: #{}')

✅ If you need to identify a user, ensure to use their unique identifier instead of their personal identifiable information:'User is: #{user.uuid}')


Associated CWE

OWASP Top 10