Added GenerateHash() method