-
Notifications
You must be signed in to change notification settings - Fork 5
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
ASCON: repeated transient memory allocation #3
Comments
We have the ASCON code now fixed and will update it soon via PR. UPDATE: the new ASCON code (to be merged at some point) is here: https://github.com/crocs-muni/jc-ascon |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Both
AsconCore#encrypt
andAsconCore#decrypt
allocate a fresh piece of transient memory per every call:https://github.com/MiragePV/OptimizedJCAlgs/blob/056abc90c8bd98b93495470a6077d962087db873/AEAD/ASCON/src/AsconCore.java#L156-L157
https://github.com/MiragePV/OptimizedJCAlgs/blob/056abc90c8bd98b93495470a6077d962087db873/AEAD/ASCON/src/AsconCore.java#L251-L252
This fact makes the implementation practically unusable with cards having no or unreliable garbage collection. Note that the allocations depend on the size of the user provided method argument (cipher/plaintext and associated data) so it is not as trivial to solve as in the case of #2.
Detected-by: JCProfilerNext
The text was updated successfully, but these errors were encountered: