Initializer
init(_:signature:format:)
Recovers the signer’s public key from a message and its P256K.Recovery.ECDSASignature via secp256k1_ecdsa_recover, hashing data with SHA-256 first.
- iOS 13.0+
- macCatalyst 13.0+
- macOS 10.15+
- tvOS 13.0+
- visionOS 1.0+
- watchOS 6.0+
init<D>(_ data: D, signature: P256K.Recovery.ECDSASignature, format: P256K.Format = .compressed) where D : DataProtocol
Parameters
-
data
-
The original message; it is SHA-256 hashed before recovery.
-
signature
-
The 65-byte P256K.Recovery.ECDSASignature containing the compact signature and recovery ID.
-
format
-
The serialization format of the recovered key; defaults to .compressed.