L parameter for CCM #252
Labels
No labels
bug
duplicate
enhancement
feature
help wanted
improve API
invalid
needs documentation
not-planned
rtfm
stale
support
wishlist
No milestone
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
gh-libtom/libtomcrypt#252
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
If I understand RFC3610 correctly, L can be chosen freely as long as it allows the payload size to be encoded. But the current implementation of ccm_init uses the minimal value for L that can encode the payload size. So right now libtomcrypt can not be used to decrypt CCM messages that use an L that is bigger than necessary. In OpenSSL L defaults to 8 and can be changed to any allowed value.
If I understand our implementation correctly you can "choose"
Lindirectly by choosingnonceof proper length:L = 15 - length(nonce)where7 <= length(nonce) <= 13Oh, you are right, ccm_add_nonce increases L or truncates the nonce depending on its size.
Sorry for the noise.