When developing an application that implies user authentification or sensitive data, you'll need to encrypt or hash data. There are few C/C++ APIs that provide encryption, digital signature and hashing algorithms. One of them, QCA, is developed using Qt datatypes and conventions. I chosen to use it because it is cross-platform, since my application had to run on both Windows and Linux. I encountered few issues at installing it, so I thought that it might be a good idea to write a tutorial about it.
In this tutorial, I'll show you how to compile QCA and QCA-ossl plugin with mingw. QCA has built-in support for the SHA1 and MD5 hash algorithms, and a weak random number source, so we must compile QCA-ossl plugin, that adds support for some well-known encryption, hashing and digital signature algorithms. Then I'll show you how to include QCA into your project, then encrypt and decrypt some data.