dchest / scrypt-async-js

Fast "async" scrypt implementation in JavaScript
http://dchest.github.io/scrypt-async-js/
BSD 2-Clause "Simplified" License
139 stars 26 forks source link

Idea: Utilize SubtleCrypto when webcrypto is supported by the platform #36

Closed snshn closed 7 years ago

snshn commented 7 years ago

I'd like to ask about the possibility of making scrypt-async-js to be taking advantage of window.crypto when it's available for calculating SHA-256, and possibly performing other cryptographic calculations for the sake of speeding up the performance on newer devices.

Related links: https://www.w3.org/TR/WebCryptoAPI/ https://developer.mozilla.org/en-US/docs/Web/API/SubtleCrypto https://github.com/diafygi/webcrypto-examples

Thank you.

dchest commented 7 years ago

Please see https://github.com/dchest/scrypt-async-js/issues/9#issuecomment-98620761

snshn commented 7 years ago

My apologies, have no idea how I've missed that issue. The reasoning for not implementing webcrypto makes total sense, thank you for pointing me in the right direction.

dchest commented 7 years ago

No worries!