Intention is not obvious around this method.  Try to copy the BCrypt implementation.  It works, but it isnt clear to another casual viewer what's going on.