Don't give an error if response reason absent in OCSP HTTP.
This commit is contained in:
parent
e6539fe22d
commit
bc441b739b
@ -110,7 +110,7 @@ Content-Length: %d\r\n\r\n";
|
|||||||
}
|
}
|
||||||
/* Parse the HTTP response. This will look like this:
|
/* Parse the HTTP response. This will look like this:
|
||||||
* "HTTP/1.0 200 OK". We need to obtain the numeric code and
|
* "HTTP/1.0 200 OK". We need to obtain the numeric code and
|
||||||
* informational message.
|
* (optional) informational message.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
/* Skip to first white space (passed protocol info) */
|
/* Skip to first white space (passed protocol info) */
|
||||||
@ -138,13 +138,19 @@ Content-Length: %d\r\n\r\n";
|
|||||||
if(*r) goto err;
|
if(*r) goto err;
|
||||||
/* Skip over any leading white space in message */
|
/* Skip over any leading white space in message */
|
||||||
while(*q && isspace((unsigned char)*q)) q++;
|
while(*q && isspace((unsigned char)*q)) q++;
|
||||||
if(!*q) goto err;
|
if(*q) {
|
||||||
/* Finally zap any trailing white space in message (include CRLF) */
|
/* Finally zap any trailing white space in message (include CRLF) */
|
||||||
/* We know q has a non white space character so this is OK */
|
/* We know q has a non white space character so this is OK */
|
||||||
for(r = q + strlen(q) - 1; isspace((unsigned char)*r); r--) *r = 0;
|
for(r = q + strlen(q) - 1; isspace((unsigned char)*r); r--) *r = 0;
|
||||||
|
}
|
||||||
if(retcode != 200) {
|
if(retcode != 200) {
|
||||||
OCSPerr(OCSP_F_OCSP_SENDREQ_BIO,OCSP_R_SERVER_RESPONSE_ERROR);
|
OCSPerr(OCSP_F_OCSP_SENDREQ_BIO,OCSP_R_SERVER_RESPONSE_ERROR);
|
||||||
ERR_add_error_data(4, "Code=", p, ",Reason=", q);
|
if(!*q) {
|
||||||
|
ERR_add_error_data(2, "Code=", p);
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
ERR_add_error_data(4, "Code=", p, ",Reason=", q);
|
||||||
|
}
|
||||||
goto err;
|
goto err;
|
||||||
}
|
}
|
||||||
/* Find blank line marking beginning of content */
|
/* Find blank line marking beginning of content */
|
||||||
|
Loading…
x
Reference in New Issue
Block a user