Closed witchent closed 4 years ago
node-webcrypto-ossl
has got tests for AES-CTR
. It supports 128, 192, and 256 keys
See test logs
Thats weird, shouldn't this prevent it?:
LOG_INFO("length");
if (length < 1 || length > 128) {
THROW_ERROR("Incorrect value 'length'. Must be between 1 and 128.");
}
(From aes_ctr.cpp)
It's 'length' for encrypt
and decrypt
params AesCtrParams
Alright that makes sense. Sorry then, I just thought that this would be the case because signal complains about it and needs 256. But this seems to warrant another fork then. Thanks anyway :)
Yep thats the one I think. Just changing 128 to 256 fixes it but I don't know if this would introduce more problems than help, so feel free to close this issue
Not sure I understand. So signal is requiring something that the browser webcrypto does not support (256 bitlength)? And enabling this allows you to build signal desktop on this package?
Correct. But as I said in the other issue, while with this check changed to 256 it builds and runs fine, it still does not work (complaining about bad mac, which I actually think has nothing to do with the HMAC but rather with the curve crypto), so it wouldn't really help if you change it anyway.
As far as I can see the length for AES_CTR is capped at 128. Could you maybe add support for 256?