Element cr = new ClientX224ConnectionRequestPDU("cr", cookie, RdpConstants.RDP_NEG_REQ_PROTOCOL_SSL);
Element tpkt = new ClientTpkt("tpkt");
Element sink = new MockSink("sink", ByteBuffer.convertByteArraysToByteBuffers(packet));
Element mainSink = new MockSink("mainSink", ByteBuffer.convertByteArraysToByteBuffers(new byte[] {1, 2, 3}));
Pipeline pipeline = new PipelineImpl("test");
pipeline.add(source, cr, tpkt, sink, mainSink);
pipeline.link("source", "cr", "mainSink");
pipeline.link("cr >" + OTOUT, "tpkt", "sink");
pipeline.runMainLoop("source", STDOUT, false, false);
}