@Test public void getIntermediateCertificateAuthorities() throws Exception { List<ApprovedCaDto> caDtos = certificateAuthorityService.getCertificateAuthorities(null, true); assertEquals(4, caDtos.size()); ApprovedCaDto topCa = caDtos.get(2); assertEquals("mock-top-ca", topCa.getName()); assertFalse(topCa.isAuthenticationOnly()); assertEquals(MOCK_TOP_CA_SUBJECT_DN, topCa.getIssuerDistinguishedName()); assertEquals(MOCK_TOP_CA_SUBJECT_DN, topCa.getSubjectDistinguishedName()); assertEquals(Collections.singletonList(MOCK_TOP_CA_SUBJECT_DN), topCa.getSubjectDnPath()); assertTrue(topCa.isTopCa()); assertEquals("good", topCa.getOcspResponse()); assertEquals(OffsetDateTime.parse("2039-06-09T06:11:31Z"), topCa.getNotAfter()); ApprovedCaDto intermediateCa = caDtos.get(3); assertEquals("mock-intermediate-ca", intermediateCa.getName()); assertFalse(intermediateCa.isAuthenticationOnly()); assertEquals(MOCK_TOP_CA_SUBJECT_DN, intermediateCa.getIssuerDistinguishedName()); assertEquals(MOCK_INTERMEDIATE_CA_SUBJECT_DN, intermediateCa.getSubjectDistinguishedName()); assertEquals(Arrays.asList(MOCK_TOP_CA_SUBJECT_DN, MOCK_INTERMEDIATE_CA_SUBJECT_DN), intermediateCa.getSubjectDnPath()); assertFalse(intermediateCa.isTopCa()); assertEquals("good", intermediateCa.getOcspResponse()); assertEquals(OffsetDateTime.parse("2040-02-28T07:53:49Z"), intermediateCa.getNotAfter()); }
@Cacheable(GET_CERTIFICATE_AUTHORITIES_CACHE) public List<ApprovedCaDto> getCertificateAuthorities(KeyUsageInfo keyUsageInfo) throws InconsistentCaDataException { return getCertificateAuthorities(keyUsageInfo, false); }
CertificateAuthorityService { @Cacheable(GET_CERTIFICATE_AUTHORITIES_CACHE) public List<ApprovedCaDto> getCertificateAuthorities(KeyUsageInfo keyUsageInfo) throws InconsistentCaDataException { return getCertificateAuthorities(keyUsageInfo, false); } }
CertificateAuthorityService { @Cacheable(GET_CERTIFICATE_AUTHORITIES_CACHE) public List<ApprovedCaDto> getCertificateAuthorities(KeyUsageInfo keyUsageInfo) throws InconsistentCaDataException { return getCertificateAuthorities(keyUsageInfo, false); } @Autowired  CertificateAuthorityService(GlobalConfService globalConfService,
            GlobalConfFacade globalConfFacade,
            ClientService clientService,
            SignerProxyFacade signerProxyFacade,
            CurrentSecurityServerId currentSecurityServerId); }
CertificateAuthorityService { @Cacheable(GET_CERTIFICATE_AUTHORITIES_CACHE) public List<ApprovedCaDto> getCertificateAuthorities(KeyUsageInfo keyUsageInfo) throws InconsistentCaDataException { return getCertificateAuthorities(keyUsageInfo, false); } @Autowired  CertificateAuthorityService(GlobalConfService globalConfService,
            GlobalConfFacade globalConfFacade,
            ClientService clientService,
            SignerProxyFacade signerProxyFacade,
            CurrentSecurityServerId currentSecurityServerId); @Cacheable(GET_CERTIFICATE_AUTHORITIES_CACHE) List<ApprovedCaDto> getCertificateAuthorities(KeyUsageInfo keyUsageInfo); @Cacheable(GET_CERTIFICATE_AUTHORITIES_CACHE) List<ApprovedCaDto> getCertificateAuthorities(KeyUsageInfo keyUsageInfo,
            boolean includeIntermediateCas); CertificateProfileInfo getCertificateProfile(String caName, KeyUsageInfo keyUsageInfo, ClientId memberId,
            boolean isNewMember); ApprovedCAInfo getCertificateAuthorityInfo(String caName); }
CertificateAuthorityService { @Cacheable(GET_CERTIFICATE_AUTHORITIES_CACHE) public List<ApprovedCaDto> getCertificateAuthorities(KeyUsageInfo keyUsageInfo) throws InconsistentCaDataException { return getCertificateAuthorities(keyUsageInfo, false); } @Autowired  CertificateAuthorityService(GlobalConfService globalConfService,
            GlobalConfFacade globalConfFacade,
            ClientService clientService,
            SignerProxyFacade signerProxyFacade,
            CurrentSecurityServerId currentSecurityServerId); @Cacheable(GET_CERTIFICATE_AUTHORITIES_CACHE) List<ApprovedCaDto> getCertificateAuthorities(KeyUsageInfo keyUsageInfo); @Cacheable(GET_CERTIFICATE_AUTHORITIES_CACHE) List<ApprovedCaDto> getCertificateAuthorities(KeyUsageInfo keyUsageInfo,
            boolean includeIntermediateCas); CertificateProfileInfo getCertificateProfile(String caName, KeyUsageInfo keyUsageInfo, ClientId memberId,
            boolean isNewMember); ApprovedCAInfo getCertificateAuthorityInfo(String caName); static final String OCSP_RESPONSE_NOT_AVAILABLE; }