Modify some functions implement
First commit
Add Sha1 unit test