add version and handshake callback