#helper #rustls #pem #cert #key #server

yanked rustls-helper

Helpers for rustls

2 releases

0.2.1 Jul 17, 2023
0.2.0 Jul 17, 2023
0.1.3 Jul 17, 2023

#20 in #cert

MIT/Apache

5KB
75 lines

Helpers for rustls

https://docs.rs/rustls-helper

let config = rustls_helper::create_server_config(
        rustls_helper::cert_from_pem(
            tokio::fs::read("server.pem").await?,
        )?,
        rustls_helper::key_from_pem(
            tokio::fs::read("server-key.pem").await?,
        )?,
        Some(rustls_helper::cert_from_pem(
            tokio::fs::read("rootCA.pem").await?,
        )?),
    )?;

Dependencies

~7–14MB
~274K SLoC