2013-08-25 15:43:36 -04:00
|
|
|
package com.fsck.k9.mail;
|
|
|
|
|
|
|
|
import java.security.cert.CertificateException;
|
|
|
|
import java.security.cert.X509Certificate;
|
|
|
|
|
|
|
|
/**
|
|
|
|
* A {@link CertificateException} extension that provides access to
|
|
|
|
* the pertinent certificate chain.
|
|
|
|
*
|
|
|
|
*/
|
|
|
|
public class CertificateChainException extends CertificateException {
|
|
|
|
|
|
|
|
private static final long serialVersionUID = 1103894512106650107L;
|
|
|
|
private X509Certificate[] mCertChain;
|
|
|
|
|
2014-10-11 11:11:12 -04:00
|
|
|
public CertificateChainException(String msg, X509Certificate[] chain, Throwable cause) {
|
|
|
|
super(msg, cause);
|
2013-08-25 15:43:36 -04:00
|
|
|
setCertChain(chain);
|
|
|
|
}
|
|
|
|
|
|
|
|
public void setCertChain(X509Certificate[] chain) {
|
|
|
|
mCertChain = chain;
|
|
|
|
}
|
|
|
|
public X509Certificate[] getCertChain() {
|
|
|
|
return mCertChain;
|
|
|
|
}
|
|
|
|
}
|