docs: def build(self, requestor_private_key=None, requestor_certificate=None, other_certificates=None):
          """
          Validates the request information, constructs the ASN.1 structure and
          then optionally signs it.
  
          The requestor_private_key, requestor_certificate and other_certificates
          params are all optional and only necessary if the request needs to be
          signed. Signing a request is uncommon for OCSP requests related to web
          TLS connections.
  
          :param requestor_private_key:
              An asn1crypto.keys.PrivateKeyInfo or oscrypto.asymmetric.PrivateKey
              object for the private key to sign the request with
  
          :param requestor_certificate:
              An asn1crypto.x509.Certificate or oscrypto.asymmetric.Certificate
              object of the certificate associated with the private key
  
          :param other_certificates:
              A list of asn1crypto.x509.Certificate or
              oscrypto.asymmetric.Certificate objects that may be useful for the
              OCSP server to verify the request signature. Intermediate
              certificates would be specified here.
  
          :return:
              An asn1crypto.ocsp.OCSPRequest object of the request
          """
  
          def _make_extension(name, value):
              return {
                  'extn_id': name,
                  'critical': False,
                  'extn_value': value
              }
  
          tbs_request_extensions = []
          request_extensions = []
          has_nonce = False
  
          for name, value in self._tbs_request_extensions.items():
              if name == 'nonce':
                  has_nonce = True
              tbs_request_extensions.append(_make_extension(name, value))
          if self._nonce and not has_nonce:
              tbs_request_extensions.append(
                  _make_extension('nonce', util.rand_bytes(16))
              )
  
          if not tbs_request_extensions:
              tbs_request_extensions = None
  
          for name, value in self._request_extensions.items():
              request_extensions.append(_make_extension(name, value))
  
          if not request_extensions:
              request_extensions = None
  
          tbs_request = ocsp.TBSRequest({
              'request_list': [
                  {
                      'req_cert': {
                          'hash_algorithm': {
                              'algorithm': self._key_hash_algo
                          },
                          'issuer_name_hash': getattr(self._certificate.issuer, self._key_hash_algo),
                          'issuer_key_hash': getattr(self._issuer.public_key, self._key_hash_algo),
                          'serial_number': self._certificate.serial_number,
                      },
                      'single_request_extensions': request_extensions
                  }
              ],
              'request_extensions': tbs_request_extensions
          })
          signature = None
  
          if requestor_private_key or requestor_certificate or other_certificates:
              is_oscrypto = isinstance(requestor_private_key, asymmetric.PrivateKey)
              if not isinstance(requestor_private_key, keys.PrivateKeyInfo) and not is_oscrypto:
                  raise TypeError(_pretty_message(
                      '''
                      requestor_private_key must be an instance of
                      asn1crypto.keys.PrivateKeyInfo or
                      oscrypto.asymmetric.PrivateKey, not %s
                      ''',
                      _type_name(requestor_private_key)
                  ))
  
              cert_is_oscrypto = isinstance(requestor_certificate, asymmetric.Certificate)
              if not isinstance(requestor_certificate, x509.Certificate) and not cert_is_oscrypto:
                  raise TypeError(_pretty_message(
                      '''
                      requestor_certificate must be an instance of
                      asn1crypto.x509.Certificate or
                      oscrypto.asymmetric.Certificate, not %s
                      ''',
                      _type_name(requestor_certificate)
                  ))
  
              if other_certificates is not None and not isinstance(other_certificates, list):
                  raise TypeError(_pretty_message(
                      '''
                      other_certificates must be a list of
                      asn1crypto.x509.Certificate or
                      oscrypto.asymmetric.Certificate objects, not %s
                      ''',
                      _type_name(other_certificates)
                  ))
  
              if cert_is_oscrypto:
                  requestor_certificate = requestor_certificate.asn1
  
              tbs_request['requestor_name'] = x509.GeneralName(
                  name='directory_name',
                  value=requestor_certificate.subject
              )
  
              certificates = [requestor_certificate]
  
              for other_certificate in other_certificates:
                  other_cert_is_oscrypto = isinstance(other_certificate, asymmetric.Certificate)
                  if not isinstance(other_certificate, x509.Certificate) and not other_cert_is_oscrypto:
                      raise TypeError(_pretty_message(
                          '''
                          other_certificate must be an instance of
                          asn1crypto.x509.Certificate or
                          oscrypto.asymmetric.Certificate, not %s
                          ''',
                          _type_name(other_certificate)
                      ))
                  if other_cert_is_oscrypto:
                      other_certificate = other_certificate.asn1
                  certificates.append(other_certificate)
  
              signature_algo = requestor_private_key.algorithm
              if signature_algo == 'ec':
                  signature_algo = 'ecdsa'
  
              signature_algorithm_id = '%s_%s' % (self._hash_algo, signature_algo)
  
              if requestor_private_key.algorithm == 'rsa':
                  sign_func = asymmetric.rsa_pkcs1v15_sign
              elif requestor_private_key.algorithm == 'dsa':
                  sign_func = asymmetric.dsa_sign
              elif requestor_private_key.algorithm == 'ec':
                  sign_func = asymmetric.ecdsa_sign
  
              if not is_oscrypto:
                  requestor_private_key = asymmetric.load_private_key(requestor_private_key)
              signature_bytes = sign_func(requestor_private_key, tbs_request.dump(), self._hash_algo)
  
              signature = ocsp.Signature({
                  'signature_algorithm': {'algorithm': signature_algorithm_id},
                  'signature': signature_bytes,
                  'certs': certificates
              })
  
          return ocsp.OCSPRequest({
              'tbs_request': tbs_request,
              'optional_signature': signature
          })