I've uploaded a new patch for SSLEngine that passes in the direct buffer address to the wrap/unwrap natives and then updates the byte buffer positions after the call. The handshake test now completes the handshake and application data can be passed between the server and client. I still need to do some work on the handshake and engine states as they aren't quite right at the moment.
Regards, Cath