HandshakeStatus is always WRAP
I am getting into the state where the status always stays at wrap...here is a code snippet....Any ideas what is wrong with my code? My buffer is logging the following over and over and over....(notice there is plenty of room in the buffer)...what is wrong?
Jun 18, 2005 1:13:43 PM biz.xsoftware.impl.niosecure.SecureDataHandler sendHandshakeMessage
FINE: [ClientChannel] bufPos2=139
Jun 18, 2005 1:13:43 PM biz.xsoftware.impl.niosecure.SecureDataHandler sendHandshakeMessage
FINE: [ClientChannel] bufLim2=16665
log.fine(id+"status = "+sslEngine.getHandshakeStatus());
log.fine(id+"bufCap="+engineToSocketData.capacity());
log.fine(id+"bufPos="+engineToSocketData.position());
log.fine(id+"bufLim="+engineToSocketData.limit());
helper.eraseBuffer(engineToSocketData);
HandshakeStatus status = HandshakeStatus.NEED_WRAP;
while(status == HandshakeStatus.NEED_WRAP){
log.fine(id+"bufPos2="+engineToSocketData.position());
log.fine(id+"bufLim2="+engineToSocketData.limit());
SSLEngineResult result = sslEngine.wrap(empty, engineToSocketData);
status = result.getHandshakeStatus();
log.fine(id+"bufPos3="+engineToSocketData.position());
log.fine(id+"bufLim3="+engineToSocketData.limit());
}
helper.doneFillingBuffer(engineToSocketData);
log.fine(id+"bufPos4="+engineToSocketData.position());
log.fine(id+"bufLim4="+engineToSocketData.limit());
Then the log is like so....

