Closed
Description
Node should not allow calls to crypto.createCipher
to succeed when the AES mode selected is CTR. AES-CTR is fundamentally broken when an initialization vector is used twice, and crypto.createCipher
will always generate the same initialization vector for the same key, so crypto.createCipheriv
needs to be used.
In the short term, there should probably be a warning about this in the function's documentation.
Posted because of HainaLi/horcrux_password_manager#1.