Skip to content

bricke/Qt-AES

Repository files navigation

Qt-AES

Small and portable AES encryption library for Qt

CI CI (AES-NI) CI (Sanitizers) CI (Fuzzing) CI (OpenSSL Cross-check) License: Unlicense

AES-128 · AES-192 · AES-256  |  ECB · CBC · CFB · OFB · CTR  |  PBKDF2 key derivation  |  AES-NI support


Features

  • All AES key sizes — 128, 192, 256 bit
  • Five cipher modes — ECB, CBC, CFB, OFB, CTR
  • Four padding schemes — ISO (default), PKCS7, ZERO, NONE (stream modes)
  • PBKDF2-HMAC key derivation (RFC 2898) — no QtNetwork required
  • Optional hardware acceleration via AES-NI (all modes)
  • Qt 5 and Qt 6 compatible
  • Single dependency: QtCore

Quick Start

Add to your CMakeLists.txt:

find_package(QtAES REQUIRED)
target_link_libraries(your_target PRIVATE QtAES::QtAES)
#include <QAESEncryption>

QAESEncryption enc(QAESEncryption::AES_256, QAESEncryption::CBC, QAESEncryption::PKCS7);
QByteArray cipher = enc.encode(plainText, key, iv);
QByteArray plain  = enc.removePadding(enc.decode(cipher, key, iv));

Documentation

Topic
Installation & CMake options docs/getting-started.md
API Reference docs/api-reference.md
Usage Examples & Best Practices docs/examples.md
AES-NI Acceleration docs/aesni.md
Testing & Fuzzing docs/testing.md

Disclaimer

This code is not audited or AES-certified by any competent authority. Use it at your own risk.


License

Released under the Unlicense — public domain, no restrictions.


Questions or suggestions? Open an issue on GitHub.