the desired length of the key to produce
the password to derive the key from
a randomly chosen salt
length of salt in bytes
the number of iterations to use (use 10K or more)
if iterations is zero, then instead the PBKDF is run until duration has passed.
the number of iterations performed and the derived key
Derive a key from a passphrase for a number of iterations specified by either iterations or if iterations == 0 then running until seconds time has elapsed.