DataStructure
public class VerifiedDestination extends Destination
修飾子とタイプ | フィールド | 説明 |
---|---|---|
static int |
CERTIFICATE_LENGTH_SIGNED |
Defaults for Signed Certs
|
static int |
CERTIFICATE_LENGTH_SIGNED_WITH_HASH |
|
static int |
MIN_HASHCASH_EFFORT |
Defaults for HashCash Certs
|
_certificate, _padding, _publicKey, _signingKey
コンストラクタ | 説明 |
---|---|
VerifiedDestination() |
|
VerifiedDestination(java.lang.String s) |
alternative constructor which takes a base64 string representation
|
VerifiedDestination(Destination d) |
create from an existing Dest
|
修飾子とタイプ | メソッド | 説明 |
---|---|---|
java.lang.String |
toString() |
|
boolean |
verifyCert(boolean allowNone) |
verify the certificate.
|
protected boolean |
verifyHashCashCert() |
HashCash Certs are used to demonstrate proof-of-work.
|
protected boolean |
verifySignedCert() |
Signed Certs are signed by a 3rd-party Destination.
|
protected boolean |
verifyUnknownCert() |
Reject all unknown certs
|
fromBase64, fromByteArray, read, toByteArray
clearCache, create, equals, hashCode, readBytes, size, toBase32, toBase64, writeBytes
calculateHash, getCertificate, getHash, getPadding, getPublicKey, getSigningPublicKey, getSigType, readBytes, setCertificate, setPadding, setPublicKey, setSigningPublicKey, writeBytes
public static final int MIN_HASHCASH_EFFORT
public static final int CERTIFICATE_LENGTH_SIGNED
public static final int CERTIFICATE_LENGTH_SIGNED_WITH_HASH
public VerifiedDestination()
public VerifiedDestination(java.lang.String s) throws DataFormatException
s
- a Base64 representation of the destination, as (eg) is used in hosts.txtDataFormatException
public VerifiedDestination(Destination d) throws DataFormatException
d
- must be non-nullDataFormatException
public boolean verifyCert(boolean allowNone)
allowNone
- If true, allow a NULL or HIDDEN certificate.protected boolean verifyHashCashCert()
protected boolean verifySignedCert()
protected boolean verifyUnknownCert()
public java.lang.String toString()
toString
クラス内 KeysAndCert