mirror of https://github.com/fafhrd91/actix-web
refactor: redact sensitive header
This commit is contained in:
parent
4957233405
commit
9482d2972a
|
@ -448,6 +448,8 @@ impl fmt::Debug for HttpRequest {
|
|||
// Hide sensitive header from debug output
|
||||
if key != http::header::AUTHORIZATION {
|
||||
writeln!(f, " {:?}: {:?}", key, val)?;
|
||||
} else {
|
||||
writeln!(f, " {:?}: {:?}", key, "*redacted*")?;
|
||||
}
|
||||
}
|
||||
Ok(())
|
||||
|
|
Loading…
Reference in New Issue