Skip to content

CryptoppECC-Encryption/Decryption using ECC(Elliptic curve cryptography) for iOS and MacOSX

License

Notifications You must be signed in to change notification settings

SandeepAggarwal/CryptoppECC

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

23 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

CryptoppECC for iOS and MacOSX

Cocoapods Compatible Platform

CryptoppECC-Encryption/Decryption using ECC(Elliptic curve cryptography).

Motivation

Cryptopp is a great free C++ class library of cryptographic schemes. But for performing such encryption one has to make a static library first from the source code files which is a headache to make for every platform. So, I here made a pod which runs a script to make that library depending upon your Xcode SDK (both iOS and MacOSX) and then installs it as a dependency in your project. I also included some Encryption/Decryption methods which took my lot of time to work properly.

Features

  1. Also supports Verify the signed message using ECDSA
  2. Compatible with Android's Bouncy Castle.

Installation with CocoaPods

Podfile

pod "CryptoppECC"

Methods

Encyption/Decryption

#import "CryptoppECC.h"
-(void)randomKeysEncryptDecrypt;

-(void)encrypt:(NSString*) public_point;

-(void)decrypt:(NSString*)private_point;

-(NSString*) decrypt:(NSString*) encryptedMessageInBase64 : (NSString*) privateKeyExponentInBase64 curve:(CurveType)curveType;

-(NSString*) encrypt:(NSString*) message : (NSString*) compressedPublicKeyPointInBase64 curve:(CurveType)curveType;

Verify Signing

#import "CryptoppECDSA.h"
-(BOOL)verifyMessage:(NSString*)message signedCertificate:(NSString*)signedCertificateInBase64  compressedServerPublicPoint:(NSString*)compressedServerPublicPointInBase64  curve:(CurveType)curveType;
-(void)exampleVerify;

Added Example file for Android's Bouncy Castle interoperability

CryptoppECC/ECC.java

Requirements

ViewPager supports minimum iOS 7 and minimum MacOSX 10.10 and uses ARC.

Contact

@sandeepCool77

Sandeep Aggarwal

License

CryptoppECC is released under the MIT license. See LICENSE for details.

About

CryptoppECC-Encryption/Decryption using ECC(Elliptic curve cryptography) for iOS and MacOSX

Resources

License

Stars

Watchers

Forks

Sponsor this project

Packages

No packages published