Refactor SCRAM code to dynamically handle hash type and key length

Refactor SCRAM code to dynamically handle hash type and key length

Edit