Instance Methodswift-crypto 3.8.0Crypto
isValidSignature(_:for:)
Verifies an elliptic curve digital signature algorithm (ECDSA) signature on a block of data over the P-521 elliptic curve.
ECDSA.swift:519func isValidSignature<D>(_ signature: P521.Signing.ECDSASignature, for data: D) -> Bool where D : DataProtocol
Parameters
Returns
A Boolean value that’s true
if the signature is valid for the given data; otherwise, false
.
Other members in extension
Type members
init<Bytes>(compactRepresentation: Bytes
) throws Creates a P-521 public key for signing from a compact representation of the key.
init<Bytes>(compressedRepresentation: Bytes
) throws Creates a P-521 public key for signing from a compressed representation of the key.
init<Bytes>(derRepresentation: Bytes
) throws Creates a P-521 public key for signing from a Distinguished Encoding Rules (DER) encoded representation.
init(pemRepresentation: String
) throws Creates a P-521 public key for signing from a Privacy-Enhanced Mail (PEM) representation.
init<D>(rawRepresentation: D
) throws Creates a P-521 public key for signing from a collection of bytes.
init<Bytes>(x963Representation: Bytes
) throws Creates a P-521 public key for signing from an ANSI x9.63 representation.
Instance members
var compactRepresentation: Data?
A compact representation of the public key.
var compressedRepresentation: Data
A compressed representation of the public key.
var derRepresentation: Data
A Distinguished Encoding Rules (DER) encoded representation of the public key.
var pemRepresentation: String
A Privacy-Enhanced Mail (PEM) representation of the public key.
var rawRepresentation: Data
A full representation of the public key.
var x963Representation: Data
An ANSI x9.63 representation of the public key.
func isValidSignature<D>(P521.Signing.ECDSASignature, for: D
) -> Bool Verifies an elliptic curve digital signature algorithm (ECDSA) signature on a digest over the P-521 elliptic curve.