Skip to content

Conversation

@balladyna
Copy link
Collaborator

@balladyna balladyna commented Jul 22, 2025

The branch is named AES-CTR as it focuses on implementing AES encryption in Counter (CTR) mode, a widely used and efficient encryption mode that enables parallel processing of data. It does so by turning a block cipher into a stream cipher: it encrypts successive values of a counter and XORs the result with the plaintext. While this implementation currently targets AES256Randomized (256-bit key size), the architecture is designed to be extensible, allowing future support for other AES key lengths (e.g., 128-bit, 192-bit) and additional cipher modes such as (e.g., CBC or GCM). This branch introduces reimplementation of the AES-CTR encryption algorithm using principles and components inspired by the encrypt and pointycastle packages. The goal was to provide a modular, testable, and extensible AES infrastructure, enabling secure encryption and decryption of sensitive data in compliance with cryptographic standards.

List of changes:

  • created aes_ctr.dart, aes256_randomized.dart, and aes_engine.dart to implement AES encryption logic and coordinate the encryption process
  • created cipher_text.dart to represent the result of an encryption algorithm and encapsulate the encrypted data
  • created aes_iv.dart to represent the initialization vector (IV), enabling unique encryption sessions
  • created aes_key.dart to store AES key used in encryption
  • created i_cipher_key.dart, a_block_cipher.dart, i_cipher_padding.dart, to define the base abstraction to block, padding and cipher key
  • created cipher_key_with_iv.dart to encapsulate both AES key and IV for cipher initialization
  • created ctr_stream_cipher.dart to implement CTR (Counter) mode to stream cipher using a block cipher
  • created padded_block_cipher.dart and ctr_block_cipher.dart to enable AES block cipher processing with support for padding and arbitrary-length input
  • created pkcs7_padding.dart to implement the PKCS7 padding scheme used for aligning plaintext blocks before encryption
  • unrelated with domain: changed the Ubuntu Actions runner image to the latest general availability version 24.04, due to the deprecation of the version 20.04

@balladyna balladyna requested review from dpajak99 and kronikarz July 22, 2025 10:38
The branch is named AES-CTR as it focuses on implementing AES encryption in Counter (CTR) mode, a widely used and efficient encryption mode that enables parallel processing of data. It does so by turning a block cipher into a stream cipher: it encrypts successive values of a counter and XORs the result with the plaintext. While this implementation currently targets AES256Randomized (256-bit key size), the architecture is designed to be extensible, allowing future support for other AES key lengths (e.g., 128-bit, 192-bit) and additional cipher modes such as  (e.g., CBC or GCM).
This branch introduces reimplementation of the AES-CTR encryption algorithm using principles and components inspired by the encrypt and pointycastle packages. The goal was to provide a modular, testable, and extensible AES infrastructure, enabling secure encryption and decryption of sensitive data in compliance with cryptographic standards.

List of changes:
- created aes_ctr.dart, aes256_randomized.dart, and aes_engine.dart to implement AES encryption logic and coordinate the encryption process
- created cipher_text.dart to represent the result of an encryption algorithm and encapsulate the encrypted data
- created aes_iv.dart to represent the initialization vector (IV), enabling unique encryption sessions
- created aes_key.dart to store AES key used in encryption
- created i_cipher_key.dart, a_block_cipher.dart, i_cipher_padding.dart, to define the base abstraction to block, padding and cipher key
- created cipher_key_with_iv.dart to encapsulate both AES key and IV for cipher initialization
- created ctr_stream_cipher.dart to implement CTR (Counter) mode to stream cipher using a block cipher
- created padded_block_cipher.dart and ctr_block_cipher.dart to enable AES block cipher processing with support for padding and arbitrary-length input
- created pkcs7_padding.dart to implement the PKCS7 padding scheme used for aligning plaintext blocks before encryption
- unrelated with domain: changed the Ubuntu Actions runner image to the latest general availability version 24.04, due to the deprecation of the version 20.04
@balladyna balladyna force-pushed the ow-feature/aes-ctr branch from 30854a5 to 982b4eb Compare July 22, 2025 10:55
@kronikarz kronikarz merged commit f87b1e0 into master Jul 22, 2025
2 checks passed
@kronikarz kronikarz deleted the ow-feature/aes-ctr branch July 22, 2025 11:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants