Tag: 椭圆曲线

如何在iOS中使用ECC

在iOS中有使用ECC的例子吗? 我注意到在Apple Developer Documents中的kSecAttrKeyTypeEC,但我不能用它来通用密钥对。 下面的代码是从示例CryptoExercise中修改的 // Container dictionaries. NSMutableDictionary * privateKeyAttr = [[NSMutableDictionary alloc] init]; NSMutableDictionary * publicKeyAttr = [[NSMutableDictionary alloc] init]; NSMutableDictionary * keyPairAttr = [[NSMutableDictionary alloc] init]; // Set top level dictionary for the keypair. [keyPairAttr setObject:(id)kSecAttrKeyTypeEC forKey:(id)kSecAttrKeyType]; [keyPairAttr setObject:[NSNumber numberWithUnsignedInteger:keySize] forKey:(id)kSecAttrKeySizeInBits]; // Set the private key dictionary. [privateKeyAttr setObject:[NSNumber numberWithBool:YES] forKey:(id)kSecAttrIsPermanent]; [privateKeyAttr […]

椭圆曲线encryption在iOS中

我正在尝试将ECC整合到用于安全通信的iPhone应用程序中,但是我很难find一个合适的库/教程来介绍如何在objective-c中执行此操作。 我读了这篇文章: 如何在iOS中使用ECC但是大概在一年前发布,没有任何回应。 任何提示/build议将不胜感激 谢谢!