RegexpFilter is a Caddy log field filter that replaces the field matching the provided regexp with the indicated string. If the field is an array of strings, each of them will have the regexp replacement applied.
| 570 | // array of strings, each of them will have the |
| 571 | // regexp replacement applied. |
| 572 | type RegexpFilter struct { |
| 573 | // The regular expression pattern defining what to replace. |
| 574 | RawRegexp string `json:"regexp,omitempty"` |
| 575 | |
| 576 | // The value to use as replacement |
| 577 | Value string `json:"value,omitempty"` |
| 578 | |
| 579 | regexp *regexp.Regexp |
| 580 | } |
| 581 | |
| 582 | // CaddyModule returns the Caddy module information. |
| 583 | func (RegexpFilter) CaddyModule() caddy.ModuleInfo { |
nothing calls this directly
no outgoing calls
no test coverage detected