PORT_Assert( ssl_Have1stHandshakeLock(ss) );
PORT_Assert( ss->opt.noLocks || ssl_Have1stHandshakeLock(ss) );
ssl2_SendSessionKeyMessage(sslSocket *ss, int cipher, int keySize,		      PRUint8 *ca, int caLen,		      PRUint8 *ck, int ckLen,		      PRUint8 *ek, int ekLen){    PRUint8 *        msg;    int              sendLen;    int              sent;    SECStatus        rv;    PORT_Assert( ssl_Have1stHandshakeLock(ss) );    ssl_GetXmitBufLock(ss);    /***************************************/    sendLen = SSL_HL_CLIENT_MASTER_KEY_HBYTES + ckLen + ekLen + caLen;    rv = ssl2_GetSendBuffer(ss, sendLen);    if (rv != SECSuccess) 	goto done;    SSL_TRC(3, ("%d: SSL[%d]: sending client-session-key",		SSL_GETPID(), ss->fd));    msg = ss->sec.ci.sendBuf.buf;    msg[0] = SSL_MT_CLIENT_MASTER_KEY;    msg[1] = cipher;    msg[2] = MSB(keySize);    msg[3] = LSB(keySize);    msg[4] = MSB(ckLen);    msg[5] = LSB(ckLen);    msg[6] = MSB(ekLen);    msg[7] = LSB(ekLen);    msg[8] = MSB(caLen);    msg[9] = LSB(caLen);    PORT_Memcpy(msg+SSL_HL_CLIENT_MASTER_KEY_HBYTES, ck, ckLen);    PORT_Memcpy(msg+SSL_HL_CLIENT_MASTER_KEY_HBYTES+ckLen, ek, ekLen);    PORT_Memcpy(msg+SSL_HL_CLIENT_MASTER_KEY_HBYTES+ckLen+ekLen, ca, caLen);    DUMP_MSG(29, (ss, msg, sendLen));    sent = (*ss->sec.send)(ss, msg, sendLen, 0);    rv = (sent >= 0) ? SECSuccess : (SECStatus)sent;done:    ssl_ReleaseXmitBufLock(ss);    /***************************************/    return rv;}