You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Include in your CMakeLists.txt file the main CMakeLists.txt file of EasySSL library
add_subdirectory(easyssl)
link the EasySSL library to your target
target_link_libraries(yourLib PUBLIC easyssl)
rebuild yuor project
Independet of SSL build
Dependency on the ssl library greatly complicates the deployment of the final product. For fix this issue, you can build EasySSL library with static SSL library. In this case, SSL library code will be saved in your EasySell binary, and deploy of your application will be easily. The ssl code will not available for your application or other libraries, so you will not get conflicts between different major versions ssl libraries if your distribution kit has it.
Just set the EASYSSL_STATIC_SSL option to true.
cmake .. -DEASYSSL_STATIC_SSL=1
The described case may be useful for the Qt 5.15.x, because the QNetwork 5.15 depends on the SSL v1.1 and EasySsl works with the SSL >= 3.0.
Usage
Encryption
#include"easyssl/rsassl.h"// create a publick and private keys array.intmain() {
QByteArray pub, priv;
EasySSL::RSASSL crypto;
crypto.makeKeys(pub, priv)
auto siganture = crypto.signMessage(message, priv);
crypto.checkSign(message, siganture, pub);
auto encryptedMsg = crypto.encrypt(message, pub);
auto decryptedMsg = crypto.decrypt(encryptedMsg, priv);
}