mask_password

Function mask_password 

Source
pub fn mask_password(url: &str) -> String
Expand description

Mask password in connection URLs for safe display.

Replaces the password portion of database/broker URLs with asterisks to prevent sensitive information from being displayed.

ยงExamples

let url = "postgres://user:secret@localhost/db";
let masked = mask_password(url);
assert!(masked.contains("****"));
assert!(!masked.contains("secret"));