public byte[] create() throws IOException {
ByteArrayWriter msg = new ByteArrayWriter();
msg.writeString(launchSession == null ? "" : launchSession.getId());
msg.writeInt(tunnel.getResourceId());
msg.writeString(tunnel.getResourceName());
msg.writeInt(tunnel.getType());
msg.writeString(tunnel.getTransport());
msg.writeString(tunnel.getSourceInterface());
msg.writeInt(tunnel.getSourcePort());
msg.writeInt(tunnel.getDestination().getPort());
msg.writeString(tunnel.getDestination().getHost());