generate client gid from client side