868c7ef1f4
When addressing [1], I checked the AEAD code but brain-farted: a key is aligned in that code, but it's the Poly1305 key, which doesn't matter here. It would be nice to align the ChaCha key too, but Android doesn't have |posix_memalign| in the versions that we care about. It does have |memalign|, but that's documented as "obsolete" and we don't have a concept of an Android OS yet and I don't want to add one just for this. So this change uses the buffer for loading the key again. (Note that we never used to check for alignment of the |key| before calling this. We must have gotten it for free somehow when checking the alignment of |in| and |out|. But there are clearly some paths that don't have an aligned key: https://code.google.com/p/chromium/issues/detail?id=454308.) At least the generation script started paying off immediately ☺. [1] https://boringssl-review.googlesource.com/#/c/3132/1/crypto/chacha/chacha_vec.c@185 Change-Id: I4f893ba0733440fddd453f9636cc2aeaf05076ed Reviewed-on: https://boringssl-review.googlesource.com/3270 Reviewed-by: Adam Langley <agl@google.com> |
||
---|---|---|
.. | ||
chacha_generic.c | ||
chacha_vec_arm_generate.go | ||
chacha_vec_arm.S | ||
chacha_vec.c | ||
CMakeLists.txt |