Implements hash_pbkdf2.

Closes #1675