Add password-stretching algorithms
- Dominant language
- Java
- Stars
- 1.4k
- Forks
- 326
- Avg merge
- 16h 22m
- Merged PRs (30d)
- 17
Description
BoringSSL has support for [password-stretching algorithms](https://commondatastorage.googleapis.com/chromium-boringssl-docs/evp.h.html#Password-stretching) such as [PBKDF2](https://commondatastorage.googleapis.com/chromium-boringssl-docs/evp.h.html#PKCS5_PBKDF2_HMAC) and [Scrypt](https://commondatastorage.googleapis.com/chromium-boringssl-docs/evp.h.html#EVP_PBE_scrypt). Android has added its [own hidden API of Scrypt](https://android.googlesource.com/platform/frameworks/base/+/master/core/java/android/security/Scrypt.java), so there is need for it in the Android codebase itself.
I originally added the [external/scrypt](https://android.googlesource.com/platform/external/scrypt) library since BoringSSL did not have support for it at the time. I patched it to run as fast as possible with intrinsic implementations of Salsa for NEON, but it appears that the BoringSSL implementation is twice as fast anyway.
I propose adding PBKDF2 and Scrypt to Conscrypt and eliminating the `external/scrypt` library. The issue is that it's difficult to put `AlgorithmParameters` for these without exposing Conscrypt's namespace into the API.
Contributor guide
Assessment
This issue has not been assessed yet.