Codebase list openssl / 3b5edb4
Document OCSP_REQ_CTX_i2d. This is a backport of the documentation from #13620. Reviewed-by: David von Oheimb <david.von.oheimb@siemens.com> Reviewed-by: Tomas Mraz <tmraz@fedoraproject.org> (Merged from https://github.com/openssl/openssl/pull/13691) Rich Salz authored 3 years ago Tomas Mraz committed 3 years ago
1 changed file(s) with 23 addition(s) and 5 deletion(s). Raw diff Collapse all Expand all
11
22 =head1 NAME
33
4 OCSP_sendreq_new, OCSP_sendreq_nbio, OCSP_REQ_CTX_free,
5 OCSP_set_max_response_length, OCSP_REQ_CTX_add1_header,
6 OCSP_REQ_CTX_set1_req, OCSP_sendreq_bio - OCSP responder query functions
4 OCSP_sendreq_new,
5 OCSP_sendreq_nbio,
6 OCSP_REQ_CTX_free,
7 OCSP_set_max_response_length,
8 OCSP_REQ_CTX_add1_header,
9 OCSP_REQ_CTX_set1_req,
10 OCSP_sendreq_bio,
11 OCSP_REQ_CTX_i2d
12 - OCSP responder query functions
713
814 =head1 SYNOPSIS
915
2430 int OCSP_REQ_CTX_set1_req(OCSP_REQ_CTX *rctx, OCSP_REQUEST *req);
2531
2632 OCSP_RESPONSE *OCSP_sendreq_bio(BIO *io, const char *path, OCSP_REQUEST *req);
33
34 int OCSP_REQ_CTX_i2d(OCSP_REQ_CTX *rctx, const char *content_type,
35 const ASN1_ITEM *it, ASN1_VALUE *req);
2736
2837 =head1 DESCRIPTION
2938
5059
5160 OCSP_REQ_CTX_set1_req() sets the OCSP request in B<rctx> to B<req>. This
5261 function should be called after any calls to OCSP_REQ_CTX_add1_header().
62 OCSP_REQ_CTX_set1_req(rctx, req) is equivalent to the following:
63
64 OCSP_REQ_CTX_i2d(rctx, "application/ocsp-request",
65 ASN1_ITEM_rptr(OCSP_REQUEST), (ASN1_VALUE *)req)
66
67 OCSP_REQ_CTX_i2d() sets the request context B<rctx> to have the request
68 B<req>, which has the ASN.1 type B<it>.
69 The B<content_type>, if not NULL, will be included in the HTTP request.
70 The function should be called after all other headers have already been added.
5371
5472 OCSP_sendreq_bio() performs an OCSP request using the responder B<io>, the URL
5573 path B<path>, and the OCSP request B<req> with a response header maximum line
6381 OCSP_sendreq_nbio() returns B<1> if the operation was completed successfully,
6482 B<-1> if the operation should be retried and B<0> if an error occurred.
6583
66 OCSP_REQ_CTX_add1_header() and OCSP_REQ_CTX_set1_req() return B<1> for success
67 and B<0> for failure.
84 OCSP_REQ_CTX_add1_header(), OCSP_REQ_CTX_set1_req(), and OCSP_REQ_CTX_i2d()
85 return B<1> for success and B<0> for failure.
6886
6987 OCSP_sendreq_bio() returns the B<OCSP_RESPONSE> structure sent by the
7088 responder or B<NULL> if an error occurred.