• spkac {string | Buffer | TypedArray | DataView}
    • encoding {string} The [encoding][] of the spkac string.
    • Returns: {Buffer} The public key component of the spkac data structure, which includes a public key and a challenge.
    1. const { Certificate } = require('crypto');
    2. const spkac = getSpkacSomehow();
    3. const publicKey = Certificate.exportPublicKey(spkac);
    4. console.log(publicKey);
    5. // Prints: the public key as <Buffer ...>