leyline-http 0.1.5

HTTP client that impersonates Chrome, Firefox, and Safari on the wire: TLS (JA3/JA4), HTTP/2, and HTTP/3 fingerprints
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
use super::redact;

#[test]
fn userinfo_is_redacted() {
    assert_eq!(
        redact("https://user:secretpw@example.com/x?a=1"),
        "https://user:***@example.com/x?***"
    );
    assert_eq!(redact("https://example.com/x"), "https://example.com/x");
    assert_eq!(
        redact("https://onlyuser@example.com/"),
        "https://***@example.com/"
    );
}