Gets the distribution points.

@param cert the cert
@return the url distribution points
344795
private static URI[] getDistributionPoints(final X509Certificate cert) {
        try {
            val points = new ExtensionReader(cert).readCRLDistributionPoints();
            val urls = new ArrayList<URI>();
            if (points != null) {
                points.stream().map(DistributionPoint::getDistributionPoint).filter(Objects::nonNull).forEach(pointName -> {
                    val nameSequence = ASN1Sequence.getInstance(pointName.getName());
                    IntStream.range(0, nameSequence.size()).mapToObj(i -> GeneralName.getInstance(nameSequence.getObjectAt(i))).forEach(name -> {
                        LOGGER.debug("Found CRL distribution point [{}].", name);
                        try {
                            addURL(urls, DERIA5String.getInstance(name.getName()).getString());
                        } catch (final Exception e) {
                            LOGGER.warn("[{}] not supported. String or GeneralNameList expected.", pointName);
                        }
                    });
                });
            }
            return urls.toArray(URI[]::new);
        } catch (final Exception e) {
            LOGGER.error("Error reading CRLDistributionPoints extension field on [{}]", CertUtils.toString(cert), e);
            return new URI[0];
        }
    }
978819
def _get_crl_url(self, distribution_points):
        

        if distribution_points is None:
            return None

        for distribution_point in distribution_points:
            name = distribution_point['distribution_point']
            if name.name == 'full_name' and name.chosen[0].name == 'uniform_resource_identifier':
                return name.chosen[0].chosen.native

        return None
423114
def _get_cached_certs(cert_uri, cache):
  
  certs = cache.get(cert_uri, namespace=_CERT_NAMESPACE)
  if certs is None:
    _logger.debug('Cert cache miss for %s', cert_uri)
    try:
      result = urlfetch.fetch(cert_uri)
    except AssertionError:
      # This happens in unit tests.  Act as if we couldn't get any certs.
      return None

    if result.status_code == 200:
      certs = json.loads(result.content)
      expiration_time_seconds = _get_cert_expiration_time(result.headers)
      if expiration_time_seconds:
        cache.set(cert_uri, certs, time=expiration_time_seconds,
                  namespace=_CERT_NAMESPACE)
    else:
      _logger.error(
          'Certs not available, HTTP request returned %d', result.status_code)

  return certs
558777
public X509Certificate[] getDirectConnectionPeerCertificates()
    {
        if (WCCustomProperties.CHECK_REQUEST_OBJECT_IN_USE){
            checkRequestObjectInUse();
        }
        Class<? extends IRequest> requestClass = _request.getClass();
        X509Certificate[] certs = null;
        //PI75166
        if(checkAssignableFromIRequestImpl(requestClass)){
        
            Method method;
            try {
                method = requestClass.getMethod("getConnectionPeerCertificates", null);               
                certs = (X509Certificate[]) method.invoke(_request, null);
                
                if (TraceComponent.isAnyTracingEnabled()&&logger.isLoggable (Level.FINE)) {
                    logger.logp(Level.FINE, CLASS_NAME,"getDirectConnectionPeerCertificates", "this->"+this+": "+" certs value --> " + certs);
                }
                
            } catch (Exception e) {
                com.ibm.wsspi.webcontainer.util.FFDCWrapper.processException(e, "com.ibm.ws.webcontainer.srt.SRTServletRequest.getDirectConnectionPeerCertificates", "635", this);
                if (TraceComponent.isAnyTracingEnabled()&&logger.isLoggable (Level.FINE)) {
                    logger.logp(Level.FINE, CLASS_NAME,"getDirectConnectionPeerCertificates", "failed to retrieve direction connection cipher suite",e);
                }
            }
        }

        if (TraceComponent.isAnyTracingEnabled()&&logger.isLoggable (Level.FINE)) {
            logger.logp(Level.FINE, CLASS_NAME,"getDirectConnectionPeerCertificates", "this->"+this+": "+" value --> " + certs);
        }
        return certs;
    }
1233157
@Override
    public String[] getCacheStatisticNames() {

        DCache cache = null;

        if (ServerCache.servletCacheEnabled) {
            cache = ServerCache.cache;
        } else if (ServerCache.objectCacheEnabled) {
            cache = ServerCache.getConfiguredCache(DCacheBase.DEFAULT_DISTRIBUTED_MAP_NAME);
        } else {
            //DYNA1061E=DYNA1061E: Neither servlet cache nor object caching is enabled.
            Tr.error(tc, "DYNA1061E");
        }

        return getCacheStatisticNames(cache);
    }
30350
private static X509CRL getCRL(URIName name) throws CertStoreException {
        URI uri = name.getURI();
        if (debug != null) {
            debug.println("Trying to fetch CRL from DP " + uri);
        }
        CertStore ucs = null;
        try {
            ucs = URICertStore.getInstance
                (new URICertStore.URICertStoreParameters(uri));
        } catch (InvalidAlgorithmParameterException |
                 NoSuchAlgorithmException e) {
            if (debug != null) {
                debug.println("Can't create URICertStore: " + e.getMessage());
            }
            return null;
        }

        Collection<? extends CRL> crls = ucs.getCRLs(null);
        if (crls.isEmpty()) {
            return null;
        } else {
            return (X509CRL) crls.iterator().next();
        }
    }
502428
@java.lang.Deprecated
  public java.util.Map<java.lang.String, alluxio.grpc.MountPointInfo> getMountPoints() {
    return getMountPointsMap();
  }
971113
private void getTCerts() {
        GetTCertBatchRequest req = new GetTCertBatchRequest(this.member.getName(), this.member.getEnrollment(),
                this.member.getTCertBatchSize(), attrs);
        try {
            List<TCert> tcerts = this.memberServices.getTCertBatch(req);
            // Add to member's tcert list
            for (TCert tcert : tcerts) {
                this.tcerts.push(tcert);
            }
        } catch (GetTCertBatchException e) {
            // ignore the exception for now
        }
    }
95513
public static CompletableFuture<EndpointDescription[]> getEndpoints(String endpointUrl) {
        UaTcpStackClientConfig config = UaTcpStackClientConfig.builder()
                .setEndpointUrl(endpointUrl)
                .build();

        UaTcpStackClient client = new UaTcpStackClient(config);

        GetEndpointsRequest request = new GetEndpointsRequest(
                new RequestHeader(null, DateTime.now(), uint(1), uint(0), null, uint(5000), null),
                endpointUrl, null, new String[]{Stack.UA_TCP_BINARY_TRANSPORT_URI});

        return client.<GetEndpointsResponse>sendRequest(request)
                .whenComplete((r, ex) -> client.disconnect())
                .thenApply(GetEndpointsResponse::getEndpoints);
    }
1027680
static CertStore getInstance(AccessDescription ad) {
        if (!ad.getAccessMethod().equals((Object)
                AccessDescription.Ad_CAISSUERS_Id)) {
            return null;
        }
        GeneralNameInterface gn = ad.getAccessLocation().getName();
        if (!(gn instanceof URIName)) {
            return null;
        }
        URI uri = ((URIName) gn).getURI();
        try {
            return URICertStore.getInstance
                (new URICertStore.URICertStoreParameters(uri));
        } catch (Exception ex) {
            if (debug != null) {
                debug.println("exception creating CertStore: " + ex);
                ex.printStackTrace();
            }
            return null;
        }
    }
1340578
public ApiResponse<ApiEndpointsSuccess> getApiEndpointsWithHttpInfo() throws ApiException {
        com.squareup.okhttp.Call call = getApiEndpointsValidateBeforeCall(null, null);
        Type localVarReturnType = new TypeToken<ApiEndpointsSuccess>(){}.getType();
        return apiClient.execute(call, localVarReturnType);
    }
887323
public static mps_ssl_certkey[] get(nitro_service client) throws Exception
	{
		mps_ssl_certkey resource = new mps_ssl_certkey();
		resource.validate("get");
		return (mps_ssl_certkey[]) resource.get_resources(client);
	}
843490
public static InputStream get(@javax.annotation.Nonnull String url) throws NoSuchAlgorithmException, KeyManagementException, IOException {
    @javax.annotation.Nonnull final TrustManager[] trustManagers = {
      new X509TrustManager() {
        @Override
        public void checkClientTrusted(
          final X509Certificate[] certs, final String authType) {
        }
        
        @Override
        public void checkServerTrusted(
          final X509Certificate[] certs, final String authType) {
        }
        
        @javax.annotation.Nonnull
        @Override
        public X509Certificate[] getAcceptedIssuers() {
          return new X509Certificate[0];
        }
      }
    };
    @javax.annotation.Nonnull final SSLContext ctx = SSLContext.getInstance("TLS");
    ctx.init(null, trustManagers, null);
    final SSLSocketFactory sslFactory = ctx.getSocketFactory();
    final URLConnection urlConnection = new URL(url).openConnection();
    if (urlConnection instanceof HttpsURLConnection) {
      @javax.annotation.Nonnull final HttpsURLConnection conn = (HttpsURLConnection) urlConnection;
      conn.setSSLSocketFactory(sslFactory);
      conn.setRequestMethod("GET");
    }
    return urlConnection.getInputStream();
  }
351627
@RequestMapping(value = "/cert/{hostname:.+}", method = {RequestMethod.GET, RequestMethod.HEAD})
    public
    @ResponseBody
    void getCert(Locale locale, Model model, HttpServletResponse response, @PathVariable String hostname) throws Exception {
        // Set the appropriate headers so the browser thinks this is a file
        response.reset();
        response.setContentType("application/x-x509-ca-cert");
        response.setHeader("Content-Disposition", "attachment;filename=" + hostname + ".cer");

        // special handling for hostname=="root"
        // return the CyberVillians Root Cert in this case
        if (hostname.equals("root")) {
            hostname = "cybervillainsCA";
            response.setContentType("application/pkix-cert ");
        }

        // get the cert for the hostname
        KeyStoreManager keyStoreManager = com.groupon.odo.bmp.Utils.getKeyStoreManager(hostname);

        if (hostname.equals("cybervillainsCA")) {
            // get the cybervillians cert from resources
            File root = new File("seleniumSslSupport" + File.separator + hostname);

            // return the root cert
            Files.copy(new File(root.getAbsolutePath() + File.separator + hostname + ".cer").toPath(), response.getOutputStream());
            response.flushBuffer();
        } else {
            // return the cert for the appropriate alias
            response.getOutputStream().write(keyStoreManager.getCertificateByAlias(hostname).getEncoded());
            response.flushBuffer();
        }


    }
812791
public List<Certificate> getCertificates() throws CertificateException, IOException {
        final String methodName = "getCertificates";
        logger.entry(this, methodName);
        
        final String fileData = getPemFileData();

        final List<ByteBuf> certDataList = new ArrayList<ByteBuf>();
        final Matcher m = CERTIFICATE_PATTERN.matcher(fileData);
        int start = 0;
        while (m.find(start)) {            
            final ByteBuf base64CertData = Unpooled.copiedBuffer(m.group(1), Charset.forName("US-ASCII"));
            final ByteBuf certData = Base64.decode(base64CertData);
            base64CertData.release();
            certDataList.add(certData);
            start = m.end();
        }
        
        if (certDataList.isEmpty()) {
            final CertificateException exception = new CertificateException("No certificates found in PEM file: " + pemFile);
            logger.throwing(this,  methodName, exception);
            throw exception;
        }
        
        final CertificateFactory cf = CertificateFactory.getInstance("X.509");
        final List<Certificate> certificates = new ArrayList<Certificate>();

        try {
            for (ByteBuf certData: certDataList) {
                certificates.add(cf.generateCertificate(new ByteBufInputStream(certData)));
            }
        } finally {
            for (ByteBuf certData: certDataList) certData.release();
        }
        
        logger.exit(this, methodName, certificates);
        
        return certificates;
    }
1283688
public static sslcertkey_crldistribution_binding[] get(nitro_service service, String certkey) throws Exception{
		sslcertkey_crldistribution_binding obj = new sslcertkey_crldistribution_binding();
		obj.set_certkey(certkey);
		sslcertkey_crldistribution_binding response[] = (sslcertkey_crldistribution_binding[]) obj.get_resources(service);
		return response;
	}
508576
public DistributerProtocolEnum getProtocol() {
    if (isReference()) {
      final DistributerDef refDistributer = (DistributerDef) getCheckedRef(DistributerDef.class, "DistributerDef");
      return refDistributer.getProtocol();
    }
    return this.protocol;
  }