NOTE: THIS PROJECT IS STILL IN ITS EARLY STAGES AND LIKELY CONTAINS BUGS
NOT YET RECCOMENDED FOR PRODUCTION USE
RSA + NTRU + AES
Combination of Classical and Post-Quantum Symmetric and Asymmetric Encryption
PQCC is a Python library which allows for easy use of classical and post-quantum cryptography. The library uses a user-defined communication channel to another machine using the same library in which classical and post-quantum asymmetric algorithms are used to set up symmetric encryption for further communications. Ideally, this mechanism would protect against brute-force attacks from classical and quantum computers, but since there is no post-quantum cryptographic algorithm that has recieved a NIST certification yet, the mechanism can only be guaranteed to be at least as secure as RSA and AES.
- Liboqs static library (necessary for NTRU)
- Requires OpenSSL >= 1.1.1 or flag
-DOQS_USE_OPENSSL=OFF
can be passed toCmake
Cmake
flag-DOQS_MINIMAL_BUILD="OQS_ENABLE_KEM_ntru_hps2048509"
can be used to minimize the library size
- Requires OpenSSL >= 1.1.1 or flag
- Linux-based operating system (for now)
- Clone this Github repository
- Compile liboqs separately and copy
liboqs.a
tolib
directory - Run
python3 setup.py install
-
Define a Channel Class
- This class must extend
Channel
as defined inpqcc/pqcc.py
- It must override both
send()
andrecv()
functions send()
must accept any number of bytes and send them to the communication partnerrecv()
must accept any number of bytes from communication partner and return it as onebytes
object (should block until recieve buffer is empty)
- This class must extend
-
Set the channel custom channel to be used by PQCC through
set_channel_class()
-
Call either
client_initialize()
orserver_initialize()
client_initialize()
will initiate a communication whileserver_initialize()
will listen for a client to connect
-
Use the resulting
aes_secret
to continue communication over the channel- Encryption and decryption must be done manually (for now)