Error - Error dataPaddingRequired
iZooto-sdk opened this issue · 0 comments
iZooto-sdk commented
public static func decrypt(input:String)->String?{
do{
let d=Data(base64Encoded: input)
let decrypted = try AES(key: key, iv: key, padding: .pkcs7).decrypt(
d!.bytes)
return String(data: Data(decrypted), encoding: .utf8)
}catch let error{
print("Error",error)
}
return nil
}