Moved calculate hash into server from client