Implement all the checks that Scrypt needs on its parameters.
More Scrypt improvements.