Contents

SecCertificateCopyData(_:)

Returns a DER representation of a certificate given a certificate object.

Declaration

func SecCertificateCopyData(_ certificate: SecCertificate) -> CFData

Parameters

  • certificate:

    The certificate object for which you wish to return the DER (Distinguished Encoding Rules) representation of the X.509 certificate.

Mentioned in

Return Value

The DER representation of the certificate. In Objective-C, call the CFRelease function to release this object when you are finished with it. Returns nil if the data passed in the certificate parameter is not a valid certificate object.