X509.fromPem constructor

X509.fromPem(
  1. String pem
)

Creates a certificate from a PEM encoded string.

Implementation

factory X509.fromPem(String pem) => X509.fromDer(
      Uint8List.fromList(
        PemCodec(PemLabel.certificate).decode(pem),
      ),
    );