MCPcopy Create free account
hub / github.com/Dstack-TEE/dstack / read_pem

Function read_pem

certbot/src/acme_client.rs:576–582  ·  view source on GitHub ↗
(cert_pem: &str)

Source from the content-addressed store, hash-verified

574}
575
576pub(crate) fn read_pem(cert_pem: &str) -> Result<Pem> {
577 Pem::iter_from_buffer(cert_pem.as_bytes())
578 .next()
579 .transpose()
580 .context("Invalid pem")?
581 .context("no certificate in pem")
582}
583
584fn extract_subject_alt_names(cert_pem: &str) -> Result<Vec<String>> {
585 let pem = read_pem(cert_pem)?;

Callers 3

read_pubkeyFunction · 0.85
need_renewFunction · 0.85

Calls 1

nextMethod · 0.80

Tested by

no test coverage detected