public static function checksum($algo, $data, $checksumLen = 4)
    {
        // shortcuts + use Buffer always
        $data = self::prepareInputBuffer($data);
        $hash = self::hash($algo, $data, false)->getBinary();
        $out = new Buffer(substr($hash, 0, $checksumLen), $checksumLen);
        return $out;
    }