handshake: write from position in pipeline

Channel.write() will cause the outgoing message to pass through the
entire pipeline, including handlers behind the codec, which is
undesirable as those handlers do not expect to participate in the
handshake.