Skip to content
Snippets Groups Projects
Commit 4d3b4f9e authored by Kurt Zeilenga's avatar Kurt Zeilenga
Browse files

return PROTOCOL_ERROR if reqdata is empty.

parent 09a2a8fb
No related branches found
No related tags found
No related merge requests found
......@@ -88,6 +88,11 @@ int slap_passwd_parse( struct berval *reqdata,
return LDAP_SUCCESS;
}
if( reqdata->bv_len == 0 ) {
*text = "empty request data field";
return LDAP_PROTOCOL_ERROR;
}
/* ber_init2 uses reqdata directly, doesn't allocate new buffers */
ber_init2( ber, reqdata, 0 );
......@@ -204,7 +209,6 @@ decoding_error:
(long) len, 0, 0 );
#endif
*text = "data decoding error";
rc = LDAP_PROTOCOL_ERROR;
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment