Commit 594484b
🔒️ Redact sensitive values from debug logging output
- Add `OAuth2.config[:filtered_label]` to configure the placeholder used for filtered sensitive values in inspected objects and debug logging output.
- Add `OAuth2.config[:filtered_debug_keys]` to configure which key names have their values redacted from debug logging output.
- Add `OAuth2::ThingFilter` as the shared filtering primitive used by inspect-time and debug-log filtering.
- Make inspect-time and debug-log filters snapshot their configuration at initialization time rather than tracking later config changes.
- Automatically redacted values include:
- Authorization headers
- common token/secret fields in headers
- query strings
- form bodies
- JSON payloads
- NOTE: debug logging has always been, and remains, opt-in. It is turned off by default.
Co-authored-by: autobolt <autobots@9thbit.net>1 parent 31bc13c commit 594484b
61 files changed
Lines changed: 685 additions & 18569 deletions
File tree
- docs
- OAuth2
- FilteredAttributes
- Strategy
- lib
- oauth2
- sig/oauth2
- spec/oauth2
Some content is hidden
Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
19 | 19 | | |
20 | 20 | | |
21 | 21 | | |
| 22 | + | |
22 | 23 | | |
23 | 24 | | |
24 | 25 | | |
| |||
This file was deleted.
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
20 | 20 | | |
21 | 21 | | |
22 | 22 | | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
23 | 27 | | |
24 | 28 | | |
| 29 | + | |
| 30 | + | |
25 | 31 | | |
26 | 32 | | |
27 | 33 | | |
| |||
30 | 36 | | |
31 | 37 | | |
32 | 38 | | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
33 | 44 | | |
34 | 45 | | |
35 | 46 | | |
| |||
54 | 65 | | |
55 | 66 | | |
56 | 67 | | |
57 | | - | |
58 | | - | |
59 | 68 | | |
60 | 69 | | |
61 | 70 | | |
| |||
196 | 205 | | |
197 | 206 | | |
198 | 207 | | |
199 | | - | |
200 | | - | |
201 | 208 | | |
202 | 209 | | |
203 | 210 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
330 | 330 | | |
331 | 331 | | |
332 | 332 | | |
| 333 | + | |
| 334 | + | |
| 335 | + | |
| 336 | + | |
| 337 | + | |
| 338 | + | |
| 339 | + | |
| 340 | + | |
| 341 | + | |
| 342 | + | |
| 343 | + | |
| 344 | + | |
| 345 | + | |
333 | 346 | | |
334 | 347 | | |
335 | 348 | | |
| |||
0 commit comments