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

Use native aes-128-gcm support in Node 4 rather than npm-node-aes-gcm package #7548

Merged
merged 2 commits into from Aug 2, 2016

Conversation

Projects
None yet
2 participants
@benjamn
Member

benjamn commented Aug 2, 2016

Inspired by this comment from @glasser.

@benjamn benjamn added this to the Release 1.4.1 milestone Aug 2, 2016

@benjamn benjamn self-assigned this Aug 2, 2016

@benjamn benjamn merged commit 7755d27 into devel Aug 2, 2016

4 checks passed

CLA Author has signed the Meteor CLA.
Details
ci/circleci Your tests passed on CircleCI!
Details
continuous-integration/travis-ci/pr The Travis CI build passed
Details
continuous-integration/travis-ci/push The Travis CI build passed
Details
decipher.setAuthTag(new Buffer(ciphertext.authTag, "base64"));
var chunks = [decipher.update(
new Buffer(ciphertext.ciphertext, "base64"))];
chunks.push(decipher.final());

This comment has been minimized.

@glasser

glasser Aug 2, 2016

Member

Not clear to me at which step crypto throws or otherwise indicates decryption or authentication errors but it looks like this change does affect how errors are detected? Or do you need to add an error handler?

This comment has been minimized.

@glasser

glasser Aug 2, 2016

Member

Oh never mind. I remembered that we tried to remove details from errors but not how it was implemented. Should be fine.

This comment has been minimized.

@benjamn

benjamn Aug 2, 2016

Member

For what it's worth, my understanding is that (de)cipher.final() throws if there are encryption/decryption errors.

@glasser

This comment has been minimized.

Member

glasser commented Aug 2, 2016

There's also a no longer accurate comment in encrypt.js saying that the crypto API doesn't support AAD. Though I doubt we actually want to incur the compatibility issues of changing to follow the suggestion there.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment