import java.security.cert.CertPathBuilderException;\r
import java.security.cert.CertStore;\r
import java.security.cert.Certificate;\r
+import java.security.cert.CertificateEncodingException;\r
import java.security.cert.CertificateFactory;\r
import java.security.cert.CollectionCertStoreParameters;\r
import java.security.cert.PKIXBuilderParameters;\r
import org.bouncycastle.jce.interfaces.PKCS12BagAttributeCarrier;\r
import org.bouncycastle.openssl.PEMWriter;\r
import org.bouncycastle.operator.ContentSigner;\r
+import org.bouncycastle.operator.OperatorCreationException;\r
import org.bouncycastle.operator.jcajce.JcaContentSignerBuilder;\r
import org.slf4j.Logger;\r
import org.slf4j.LoggerFactory;\r
x509log.log(MessageFormat.format("Revoked certificate {0,number,0} reason: {1} [{2}]",\r
cert.getSerialNumber(), reason.toString(), cert.getSubjectDN().getName()));\r
return true;\r
- } catch (Exception e) {\r
+ } catch (IOException | OperatorCreationException | CertificateEncodingException e) {\r
logger.error(MessageFormat.format("Failed to revoke certificate {0,number,0} [{1}] in {2}",\r
cert.getSerialNumber(), cert.getSubjectDN().getName(), caRevocationList));\r
}\r