class TrustStoreImpl extends ComponentSupport implements EventAware, TrustStore {

  @Override
  public void removeTrustCertificate(final String alias) throws KeystoreException {
    freezeService.checkWritable("Unable to remove a certificate while database is frozen.");

    Certificate certificate = getTrustedCertificate(alias);
    keyStoreManager.removeTrustCertificate(alias);
    sslcontext = null;

    eventManager.post(new CertificateDeletedEvent(alias, certificate));

    log.info(
        "Certificate removed successfully from trust-store with Fingerprint : {}, Name : {} and SHA1 Identifier : {}",
        alias,
        getCertificateName(certificate),
        getCertificateSha1(certificate));
  }

  @Inject public  TrustStoreImpl(final EventManager eventManager,
                        @Named("ssl") final KeyStoreManager keyStoreManager,
                        final FreezeService freezeService);

}