publicKey
TypeScriptget publicKey(): P384_Signing_PublicKeySwift declarationvar publicKey: P384.Signing.PublicKey { get }The corresponding public key.
struct · iOS 13.0+ · SDK 27.1
struct PrivateKeyA P-384 private key used to create cryptographic signatures.
get publicKey(): P384_Signing_PublicKeySwift declarationvar publicKey: P384.Signing.PublicKey { get }The corresponding public key.
get derRepresentation(): ArrayBufferSwift declarationvar derRepresentation: Data { get }A Distinguished Encoding Rules (DER) encoded representation of the private key.
static initDerRepresentation(derRepresentation: Array<number>): P384_Signing_PrivateKeySwift declarationinit<Bytes>(derRepresentation: Bytes) throws where Bytes : RandomAccessCollection, Bytes.Element == UInt8Creates a P-384 private key for signing from a Distinguished Encoding Rules (DER) encoded representation. - Parameters: - derRepresentation: A DER-encoded representation of the key.
static initPemRepresentation(pemRepresentation: string): P384_Signing_PrivateKeySwift declarationinit(pemRepresentation: String) throwsCreates a P-384 private key for signing from a Privacy-Enhanced Mail PEM) representation. - Parameters: - pemRepresentation: A PEM representation of the key.
get pemRepresentation(): stringSwift declarationvar pemRepresentation: String { get }A Privacy-Enhanced Mail (PEM) representation of the private key.
get rawRepresentation(): ArrayBufferSwift declarationvar rawRepresentation: Data { get }A data representation of the private key.
static initRawRepresentation(rawRepresentation: ArrayBuffer): P384_Signing_PrivateKeySwift declarationinit<Bytes>(rawRepresentation: Bytes) throws where Bytes : ContiguousBytesCreates a P-384 private key for signing from a collection of bytes. - Parameters: - rawRepresentation: A raw representation of the key as a collection of contiguous bytes.
get x963Representation(): ArrayBufferSwift declarationvar x963Representation: Data { get }An ANSI x9.63 representation of the private key.
static initX963Representation(x963Representation: ArrayBuffer): P384_Signing_PrivateKeySwift declarationinit<Bytes>(x963Representation: Bytes) throws where Bytes : ContiguousBytesCreates a P-384 private key for signing from an ANSI x9.63 representation. - Parameters: - x963Representation: An ANSI x9.63 representation of the key.
static initCompactRepresentable(compactRepresentable?: boolean): P384_Signing_PrivateKeySwift declarationinit(compactRepresentable: Bool = true)Creates a random P-384 private key for signing. Keys that use a compact point encoding enable shorter public keys, but aren’t compliant with FIPS certification. If your app requires FIPS certification, create a key with ``init(rawRepresentation:)``. - Parameters: - compactRepresentable: A Boolean value that indicates whether CryptoKit creates the key with the structure to enable compact point encoding.
signature(data: ArrayBuffer): P384_Signing_ECDSASignatureSwift declarationfunc signature<D>(for data: D) throws -> P384.Signing.ECDSASignature where D : DataProtocolGenerates an Elliptic Curve Digital Signature Algorithm (ECDSA) signature of the data you provide over the P-384 elliptic curve, using SHA-384 as the hash function. - Parameters: - data: The data to sign. - Returns: The signature corresponding to the data. The signing algorithm employs randomization to generate a different signature on every call, even for the same data and key.
1 declarations were excluded from these bindings. Each reason comes from the generator or the iOS SDK compiler.
P384.Signing.PrivateKey.signature(for:)
This declaration needs Swift generic type arguments. (no canonical witness for D)