RsaPublicKey

data class RsaPublicKey(val modulus: ByteArray, val publicExponent: ByteArray) : PublicKey

An RSA Public Key.

Parameters

modulus

the modulus (n) as an unsigned big-endian byte array.

publicExponent

the public exponent (e) as an unsigned big-endian byte array.

Constructors

Link copied to clipboard
constructor(modulus: ByteArray, publicExponent: ByteArray)

Types

Link copied to clipboard
object Companion

Properties

Link copied to clipboard
open val curve: EcCurve?

The EcCurve for this key if it is an elliptic curve key, or null if not an EC key.

Link copied to clipboard

The public exponent (e) as an unsigned big-endian byte array.

Link copied to clipboard
val RsaPublicKey.javaPublicKey: ERROR CLASS: Symbol not found for RSAPublicKey
Link copied to clipboard
Link copied to clipboard

The modulus (n) as an unsigned big-endian byte array.

Link copied to clipboard

Functions

Link copied to clipboard
open operator override fun equals(other: Any?): Boolean
Link copied to clipboard
open override fun hashCode(): Int
Link copied to clipboard
open override fun toCoseKey(additionalLabels: Map<CoseLabel, DataItem>): CoseKey

Creates a CoseKey object for the key.

Link copied to clipboard

Serializes this public key as a CBOR DataItem encoding a COSE_Key.

Link copied to clipboard
Link copied to clipboard
open suspend override fun toJwk(additionalClaims: JsonObject?): JsonObject

Encodes the public key as a JSON Web Key according to RFC 7517.

Link copied to clipboard
open suspend override fun toJwkThumbprint(digestAlgorithm: Algorithm): ByteString

Gets the Json Web Key Thumbprint.

Link copied to clipboard
open override fun toPem(): String

Encode this key in PEM format.

Link copied to clipboard

Encode this public key as a DER-encoded PKCS#1 RSAPublicKey sequence.

Link copied to clipboard

Encode this public key as a DER-encoded SubjectPublicKeyInfo sequence.