This is an example project demonstrating how to use PGP encryption and decryption in an iOS app. It uses the Objective-C implementation of the OpenPGP standard, OpenPGP.framework.
- Manage Keychain:
- Generate new keys: public and private keys
- Import key from local file url
- Import key from clipboard
- Signing the message with private key, output with the signature
- Verify if signature was signed with one of the given keys.
- Get the plain text from the signed message
- Encrypt data
- Decrypt PGP encrypted data
- Others:
- Export keys to local files (*.gpg)
List Keys | Generate New Key | Key Detail |
---|---|---|
Signing | Verify Signing | |
Encryption | Decryption | Settings |
- Save keys to Core Data
- Optimize UI: Add empty background UI for List Keys screen if it have no key in the app
- Delete specific Key in List Keys screen
- Delete all keys
- iOS 15.0+
- Xcode 11+
- To install the app, clone the repository and open the
PGP-example.xcworkspace
file in Xcode.
The cryptographic library used by PGPro, ObjectivePGP, has undergone a complete security audit from Cure53.
This project uses the ObjectivePGP library developed by Marcin Krzyżanowski. Thereby it uses software developed by the OpenSSL Project for use in the OpenSSL Toolkit.
You are welcome to contribute. Please create a Pull Request.