nasa / nasa/CryptoLib

Is AES-256-CCM supported?

Open
#498 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
C
Stars
169
Forks
67
PR merge metrics
No merged PRs in 30d

Description

I see CRYPTO_CIPHER_AES256_CCM is defined in the EncCipherSuite enum and AES256_CCM_KEYLEN exists, but I couldn't find any unit tests using CCM or documentation on how to configure it.

When I try to use it (SA with ecs=CRYPTO_CIPHER_AES256_CCM, 12-byte IV, 16-byte MAC), the output doesn't appear to be encrypted - the data field still contains plaintext.

Looking at the code, I noticed Crypto_Is_AEAD_Algorithm() checks for GCM, CBC_MAC, and GCM_SIV but not CCM. Should CCM be included there, or is CCM not meant to go through the AEAD path?

I also couldn't find the gcry_cipher_ctl(h, GCRYCTL_SET_CCM_LENGTHS, ...) call that libgcrypt requires for CCM mode. Is CCM with libgcrypt still work-in-progress, or am I configuring something wrong?

Thanks!

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by tracing EncCipherSuite, Crypto_Is_AEAD_Algorithm(), and the libgcrypt cipher setup for AES256_CCM. Check existing GCM or CBC_MAC tests and the libgcrypt requirement for GCRYCTL_SET_CCM_LENGTHS. Done means establishing whether CCM is supported, identifying the required configuration or implementation work, and adding coverage and documentation if support is intended.

Written by the indexing model from the issue text.

Assessment

Tech stack
c
Domain
cryptography
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
30/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.