Rewind the file before calculating the hash