PrivateKey

public struct PrivateKey : NISTECPrivateKey

Undocumented

P521 + PrivateKey

  • Generates an ECDSA signature over the P521 elliptic curve.

    Throws

    If there is a failure producing the signature

    Declaration

    Swift

    public func signature<D>(for digest: D) throws -> P521.Signing.ECDSASignature where D : Digest

    Parameters

    digest

    The digest to sign.

    Return Value

    The ECDSA Signature.

  • Generates an ECDSA signature over the P521 elliptic curve. SHA512 is used as the hash function.

    Throws

    If there is a failure producing the signature.

    Declaration

    Swift

    public func signature<D>(for data: D) throws -> P521.Signing.ECDSASignature where D : DataProtocol

    Parameters

    data

    The data to sign.

    Return Value

    The ECDSA Signature.