Skip to content
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

Migrate crypto-aes and cprng-aes to cryptonite. #36

Merged
merged 1 commit into from
Jul 18, 2023

Conversation

jmazon
Copy link
Contributor

@jmazon jmazon commented Oct 23, 2022

crypto-aes's encryption now fails on my machine with Illegal Instruction errors, and the package has been deprecated in favor of cryptonite for years, so migrate to that.

cprng-aes is an indirect dependency on crypto-aes. cryptonite doesn't offer an AES-based CPRNG, but its ChaCha-based one has the closest interface, so I used that.

The former code has a comment L308 (patched file line numbers) regarding RNG performance. I do not know the referenced benchmark's whereabouts, so I'm delegating that to someone in the know (or signalling for clean-up).

stack (or ghc or cabal) failed to build at stack.yaml's specified lts-6.6, so I tested on lts-19.29.

crypto-aes's encryption now fail on my machine with Illegal Instruction
errors, and the package has been deprecated in favor of cryptonite for
years, so migrate to that.

cprng-aes is an indirect dependency on crypto-aes.  cryptonite doesn't
offer an AES-based CPRNG, but its ChaCha-based one has the closest
interface.
@andreasabel
Copy link
Contributor

@jmazon : Maybe you can port this PR to crypton, a maintained fork of cryptonite?

Copy link
Member

@snoyberg snoyberg left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you!

@snoyberg snoyberg merged commit 0a80022 into yesodweb:master Jul 18, 2023
snoyberg added a commit that referenced this pull request Jul 18, 2023
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.

3 participants