compare hash