public class VerifiedDestination extends Destination
| Modifier and Type | Field and Description |
|---|---|
static int | CERTIFICATE_LENGTH_SIGNEDDefaults for Signed Certs |
static int | CERTIFICATE_LENGTH_SIGNED_WITH_HASHLength of a signed certificate including the signer hash. |
_certificate, _paddingBlocks, _publicKey, _signingKey| Constructor and Description |
|---|
VerifiedDestination()Creates a new VerifiedDestination with default values. |
VerifiedDestination(Destination d)create from an existing Dest |
VerifiedDestination(String s)alternative constructor which takes a base64 string representation |
| Modifier and Type | Method and Description |
|---|---|
String | toString()Returns a string representation including verification status. |
boolean | verifyCert(boolean allowNone)verify the certificate. |
protected boolean | verifySignedCert()Signed Certs are signed by a 3rd-party Destination. |
protected boolean | verifyUnknownCert()Reject all unknown certs |
clearCache, create, equals, hashCode, size, toBase32, toBase64, writeBytescalculateHash, combinePadding, getCertificate, getEncType, getHash, getPadding, getPublicKey, getSigningPublicKey, getSigType, isCompressible, readBytes, setCertificate, setPadding, setPublicKey, setSigningPublicKey, writeBytes, writePaddingBytesfromBase64, fromByteArray, read, toByteArraypublic static final int CERTIFICATE_LENGTH_SIGNED
public static final int CERTIFICATE_LENGTH_SIGNED_WITH_HASH
public VerifiedDestination()
public VerifiedDestination(Destination d) throws DataFormatException
d - must be non-nullDataFormatExceptionpublic VerifiedDestination(String s) throws DataFormatException
s - a Base64 representation of the destination, as (eg) is used in hosts.txtDataFormatExceptionpublic String toString()
toString in class KeysAndCertpublic boolean verifyCert(boolean allowNone)
allowNone - If true, allow a NULL or HIDDEN certificate.protected boolean verifySignedCert()
protected boolean verifyUnknownCert()