Convert a public key to the appropriate format
static public savePublicKey ( phpseclib\Math\BigInteger $n, phpseclib\Math\BigInteger $e ) : string | ||
$n | phpseclib\Math\BigInteger | |
$e | phpseclib\Math\BigInteger | |
return | string |
/** * Convert a public key to the appropriate format * * @access public * @param \phpseclib\Math\BigInteger $n * @param \phpseclib\Math\BigInteger $e * @return string */ static function savePublicKey(BigInteger $n, BigInteger $e) { $key = PKCS1::savePublicKey($n, $e); $key = ASN1::extractBER($key); return self::wrapPublicKey($key, '1.2.840.113549.1.1.1'); }