send out the raw SSL/TLS headers to the msg_callback and display them in SSL_trace
diff --git a/ssl/s3_pkt.c b/ssl/s3_pkt.c index dca3458..4299af1 100644 --- a/ssl/s3_pkt.c +++ b/ssl/s3_pkt.c
@@ -321,6 +321,8 @@ s->rstate=SSL_ST_READ_BODY; p=s->packet; + if (s->msg_callback) + s->msg_callback(0, 0, SSL3_RT_HEADER, p, 5, s, s->msg_callback_arg); /* Pull apart the header into the SSL3_RECORD */ rr->type= *(p++); @@ -822,6 +824,9 @@ /* record length after mac and block padding */ s2n(wr->length,plen); + if (s->msg_callback) + s->msg_callback(1, 0, SSL3_RT_HEADER, plen - 5, 5, s, s->msg_callback_arg); + /* we should now have * wr->data pointing to the encrypted data, which is * wr->length long */