Kibana: config-schema shouldn't log sensitive data

Created on 26 Feb 2020  路  3Comments  路  Source: elastic/kibana

A customer complains that we config-schema logs sensitive data in the plain text

We provided an invalid encryption key for Kibana 7.6.0 and were surprised to find that when there is an error it logs the encryption key in plain text:
config validation of [xpack.encryptedSavedObjects].encryptionKey]: value is [some_value] but it must have a minimum length of [32].

We need to provide a way to filter out sensitive data. For example, we can mark a key as containing sensitive data to prevent disclosure.

New Platform Core

Most helpful comment

One other option would be to have a convention to never display the actual data value in any error message. It seems there are only very few messages where we do display the raw values. Most messages are like expected value of type [string] but got [${typeDetect(value)}]

The value is [some_value] but it must have a minimum length of [32] could be changed to valuehas length [XX] but it must have a minimum length of [32].

This would avoid introducing a parameter for that, and the risk that a developer actually forget to flag sensitive data validation with it.

All 3 comments

Pinging @elastic/kibana-platform (Team:Platform)

One other option would be to have a convention to never display the actual data value in any error message. It seems there are only very few messages where we do display the raw values. Most messages are like expected value of type [string] but got [${typeDetect(value)}]

The value is [some_value] but it must have a minimum length of [32] could be changed to valuehas length [XX] but it must have a minimum length of [32].

This would avoid introducing a parameter for that, and the risk that a developer actually forget to flag sensitive data validation with it.

Was this page helpful?
0 / 5 - 0 ratings