Closed Kejiasir closed 6 years ago
Oh, I found a solution, thank you
initWithData
expects the binary data not a BASE64 encoded string of the data. But there is a helper included NSData *publicKeyData = [yourPublicKeyString MIH_dataByBase64DecodingString]
. However, you don't even need that helper anymore since In more recent iOS and macOS versions a base64 encoding helper is included on the NSString
class already.
@hohl hey! my server returns a public key string that needs to be decrypted through it, but it crashes when it is initialized by the following method
Hope to get your help, be grateful, wish you a happy life