Skip to content

Cryptographic Clang

Security Algorithms

A collection of fundamental cryptographic algorithms implemented in C for educational and demonstration purposes.

The library includes implementations for several widely-used cryptographic primitives:

AES

Advanced Encryption Standard with support for CBC mode.

SHA256

Secure Hash Algorithm 256-bit for data integrity.

HMAC

Hash-based Message Authentication Code using SHA256.

RSA

Asymmetric encryption and digital signatures using large number arithmetic.

  • aes.c / aes.h: Core AES implementation.
  • aes_cbc.c: Cipher Block Chaining mode for AES.
  • aes_cmac.c: Cipher-based Message Authentication Code.
  • sha256.c: The hashing engine.
  • hmac.c: Keyed-hash message authentication.
  • rsa.c: RSA key generation and encryption.
  • bignum.c: Custom big integer library for handling large primes and modular exponentiation.

The project includes a Makefile for easy compilation of the source files and demonstration clients.

  1. Compile the library

    Terminal window
    make
  2. Run Demonstration Execute the compiled clients (e.g., aes_client or signature_client) to see the algorithms in action.