fix secret hashing to match what the rest api expects