changed hash function to sha256