First version, needs final check after changing vectors & MD5