Swift team announced availability of swift-certificates and swift-asn1 projects. These projects target operations with X509 certificates (which are commonly used in TSL connections) and ASN.1 data type definition language.
Swift ASN.1 provides routines for DER serialization and deserialization.
Swift Certificates provides routines for X509 parsing, chain building, validation and OCSP resolution.
Swift team: Introducing Swift Certificates and Swift ASN.1