Cryptographic QCA

Cryptographic QCA

Aurora OS application to demonstrate working with the cryptography by using QCA API.

RU | EN


Cryptographic

Aurora OS application to demonstrate working with the cryptographic.

The application is used to demonstrate how to work with the QCA API.

The application allow to:

  • Encode, decode, encrypt and hash strings,
  • Encrypt and decrypt using a private key,
  • Read certificates,
  • Authenticate messages,
  • Generate random numbers,
  • Implement a password and token request handler,
  • View available cryptographic providers,
  • Run a client-side cryptographic provider.

The project uses the qca2-qt5 library dependency.

Table of Contents

  1. Table of Contents
  2. Compatibility
  3. Features of use and build
  4. Branch info
  5. Install and Run
  6. Screenshots
  7. Use cases
  8. Known errors
  9. Project Structure
  10. Terms of Use and Participation in Development

Compatibility

The application is working correctly since 5.1.3.45 version of Aurora OS.

Features of use and build

This example being built using the Aurora SDK: Documentation

Branch info

Branches

Install and Run

The project being built in the usual way using the Aurora SDK: Documentation.

Screenshots

screenshots

Use cases

Encode and decode string using Base64 or Hex

  • To demonstrate encoding and decoding string, select "Encode/Decode strings" on the main screen.
  • On the opened page you can select Base64 or Hex encoding method, enter a string, encode or decode it by clicking the buttons.

Encrypt string using Blowfish, TripleDES, DES, AES128, AES192, AES256, CAST5

  • To demonstrate encrypting string, select "String encryption" on the main screen.
  • On the opened page you can select encryption method, enter a string and encrypt it by clicking the button.

String encryption using md5crypt

  • To demonstrate string encryption using md5crypt, select "String encryption using md5crypt" on the main screen.
  • On the opened page you can enter a salt and string and encrypt it by clicking the button.

String hashing using SHA-0, SHA-1, MD2, MD4, MD5, RIPEMD160, SHA-224, SHA-256, SHA-384, SHA-512, Whirlpool

  • To demonstrate string hashing, select "String hashing" on the main screen.
  • On the opened page you can select hashing method, enter string and hash it by clicking the button.

Message authentication using HMAC with SHA-1, MD5, RIPEMD160, SHA-224, SHA-256, SHA-384, SHA-512

  • To demonstrate message authentication, select "Message authentication" on the main screen.
  • On the opened page you can select message authentication method, enter code phrase and message and perform authentication by clicking the button.

Random number generation

  • To demonstrate random number generation, select "Random number generation" on the main screen.
  • On the opened page you can select the data type of the number and generate it by clicking the button.

List of available crypto-providers on the divice

  • To see a list of available crypto-providers on the divice, select "All available cryptoproviders" on the main screen.
  • On the opened page you can see the list of available crypto-providers divided into groups.

Client side handler for password and token requests from crypto-providers

  • To demonstrate the work process of the requests handler, select "Request handler" on the main screen.
  • On the opened page you can select password request style, enter a password, token id and token name and initiate a request with this data.

Read certificates X509 from PEM-file

  • To demonstrate reading certificates, select "CertX509 reading" on the main screen.
  • On the opened page you can select cert source and read this certificate by clicking the button.

Encrypt and decrypt using private key

  • To demonstrate encrypting and decrypting using private key, select "Operations with public and private keys" on the main screen.
  • On the opened page you can select private key source, enter a passphrase and message and encrypt this message by clicking the button.

Client side crypto-provider with AEC CMAC

  • To demonstrate client side crypto provider, select "Own crypto provider with AES CMAC" on the main screen.
  • On the opened page you can enter a key and message and encrypt this message by clicking the button.

Known errors

The project has the following limitations:

  • There is no implementation of the async key loading.
  • There is no implementation of the RSA-key operations.

Project structure

The project has a standard structure of an application based on C++ and QML for Aurora OS.

  • CMakeLists.txt file describes the project structure for the CMake build system.
  • icons directory contains application icons for different screen resolutions.
  • pem directory contains examples of PEM-files that are used in application.
  • qml directory contains the QML source code and the UI resources.
    • components directory contains the custom UI components.
    • cover directory contains the application cover implementations.
    • icons directory contains the custom UI icons.
    • pages directory contains the application pages.
    • Cryptographic.qml file provides the application window implementation.
  • rpm directory contains the rpm-package build settings.
  • src directory contains the C++ source code.
    • all-cryptos directory contains the source code classes to show a list of all available crypto-providers on the device.
    • certX509 directory contains the source code classes to perform a CertX509 reading from user file or system storage.
    • common directory contains the common source code used by the other classes.
    • mac directory contains the source code classes to perform a message authentication.
    • md5crypt directory contains the source code classes to perform a string encryption with md5crypt algotirthm.
    • own-cryptoprovider directory contains the source code classes to insert custom crypto-provider into QCA.
    • publickey directory contains the source code classes to perform an encryption and decryption using private key.
    • random directory contains the source code classes to perform a random number generation.
    • request-handler directory contains the source code classes of a client side Event Handler.
    • string-coding directory contains the source code classes to perform a string encoding and decoding.
    • string-encrypt directory contains the source code classes to perform a string encryption.
    • string-hash directory contains the source code classes to perform a string hashing.
    • main.cpp file is the application entry point.
  • translations directory contains the UI translation files.
  • ru.auroraos.Cryptographic.desktop file defines the display and parameters for launching the application.

Terms of Use and Participation in Development

The source code of the project is provided under the license, which allows it to be used in third-party applications.

Contributor License Agreement The contributor agreement documents the rights granted by contributors of the Open Mobile Platform.

Information about the contributors is specified in the AUTHORS file.

Code of conduct is a current set of rules of the Open Mobile Platform which informs you how we expect the members of the community will interact while contributing and communicating.