docs: public String generateCertificationRequest(String subject, KeyPair pair)
              throws InvalidArgumentException {
  
          try {
              PKCS10CertificationRequestBuilder p10Builder = new JcaPKCS10CertificationRequestBuilder(
                      new X500Principal("CN=" + subject), pair.getPublic());
  
              JcaContentSignerBuilder csBuilder = new JcaContentSignerBuilder("SHA256withECDSA");
  
              if (null != SECURITY_PROVIDER) {
                  csBuilder.setProvider(SECURITY_PROVIDER);
              }
              ContentSigner signer = csBuilder.build(pair.getPrivate());
  
              return certificationRequestToPEM(p10Builder.build(signer));
          } catch (Exception e) {
  
              logger.error(e);
              throw new InvalidArgumentException(e);
  
          }
  
      }