Skip to content

Unable to load p12 certificate  #154

@rashmi2487

Description

@rashmi2487

I am unable to load the p12 certificate after adding new certificate , it is returning nil on at this line : identity = CertificateIdentity(p12URL: identityURL!, passphrase: "")

Code snippet

if secureMode! {
let caCertificateURL = Bundle.main.url(forResource: "certificate", withExtension: "der")
caCertificate = Certificate(derURL: caCertificateURL!)

        let identityURL = Bundle.main.url(forResource: "certificate", withExtension: "p12")
        identity = CertificateIdentity(p12URL: identityURL!, passphrase: "")
        
        server = Server(identity: identity, caCertificates: [caCertificate])
    } else {
        server = Server()
    }. What  could be possible root cause for this?
Screenshot 2024-10-16 at 6 48 49 AM

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions