Skip to content

Commit

Permalink
feat: introduce leaklog for debugging oidc map payloads
Browse files Browse the repository at this point in the history
  • Loading branch information
aeneasr committed May 6, 2020
1 parent e0f3b92 commit 238d7a4
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions x/leaklog.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
package x

import "github.com/ory/kratos/driver/configuration"

func RedactInProd(d configuration.Provider, value interface{}) interface{} {
if d.IsInsecureDevMode() {
return value
}
return "This value has been redacted to prevent leak of sensitive information to logs. Switch to ORY Kratos Development Mode using --dev to view the original value."
}

0 comments on commit 238d7a4

Please sign in to comment.