BUF_MEM_grow(nm.x->bytes, p - q))gotoerr;memcpy(nm.x->bytes->data, q, p - q);/* Convert internal representation to X509_NAME structure */for(i =0; i < sk_STACK_OF_X509_NAME_ENTRY_num(intname.s); i++) {
On further analyzing, we found that handshake failure is due to the "BUF_MEM_grow : malloc failure" in the server after the 'n' number of authentications. The memory buffer gets completely allocated and handshake is failed when we tried to allocate the memory. ...
BUF_MEM *buf =NULL;if((buf = BUF_MEM_new()) ==NULL)gotoerr;if(!BUF_MEM_grow(buf, size))gotoerr;if((ret = (TXT_DB *)OPENSSL_malloc(sizeof(TXT_DB))) ==NULL)gotoerr; ret->num_fields = num; ret->index =NULL; ret->qual =NULL;if((ret->data = sk_new_null()) ==NULL...