implement partial sha1 type