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

Support setAutoPadding()? #12

Closed
jprichardson opened this issue Dec 23, 2014 · 3 comments
Closed

Support setAutoPadding()? #12

jprichardson opened this issue Dec 23, 2014 · 3 comments

Comments

@jprichardson
Copy link
Member

See bitcoinjs/bip38#6 for reference.

@calvinmetcalf
Copy link
Contributor

yeah I can implement that, in the mean time instead of

cipher.end(xorBuf)

var cipherText = cipher.read()

you can do

var cipherText = cipher.update(xorBuf)

@dcousens
Copy link
Member

update only returns if an entire block is waiting?

This isn't always the case in that implementation.

@calvinmetcalf
Copy link
Contributor

this line is only ever called with n even block size so it is equivalent, but that wouldn't work for decrypting because it keeps one in reserve for padding, but this is actually fixed here just needs to be merged upstream browserify/crypto-browserify#92

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

3 participants