added checksum functionality