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

why not AES256 with CTR ? #23

Open
jcmartins opened this issue Apr 17, 2018 · 1 comment
Open

why not AES256 with CTR ? #23

jcmartins opened this issue Apr 17, 2018 · 1 comment

Comments

@jcmartins
Copy link

Advantages of CTR are:
easier to decrypt from a certain offset within the ciphertext
no randomness requirements for the nonce
nonce can be calculated, e.g. be a simple counter
nonce can be a message identifier
E=D
: encryption is the same as decryption, which means only encryption or decryption required from the block cipher less logic required

no padding overhead or mechanism required
key stream can be pre-calculated (latency advantages)

@malnick
Copy link
Owner

malnick commented Apr 18, 2018

I didn't really have an opinion about the mode. Though CTR has advantages due to less complicated implementation, I've implemented CBC before, and I felt comfortable doing it for this project.

That being said, this project hasn't really been kept maintained, and I have a lot on my wish list. One of those things is a pluggable backend for encryption/decryption. That would include the key provider (KMS, RSA keys, etc) and the underlying cryptography (AES256 with CBC, CTR, or OFB).

Great question, and thanks for checking out the project.

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

No branches or pull requests

2 participants