Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type CensorFormatter ¶
type CensorFormatter struct {
CensorItems []CensorItem
UnderlyingFormatter log.Formatter
}
CensorFormatter makes sure sensitive data is not logged. It works as a middleware and sensors the data before sending it to an underlying formatter
func NewCensorFormatter ¶ added in v0.33.2
func NewCensorFormatter(underlyingFormatter log.Formatter, additionalCensoring ...CensorItem) *CensorFormatter
NewCensorFormatter creates a new formatter that censors sensitive logs. It contains some default censoring rules, but additional items may be used
Click to show internal directories.
Click to hide internal directories.