Class X509PemFilesSecret
- java.lang.Object
- 
- jadex.platform.service.security.auth.AbstractAuthenticationSecret
- 
- jadex.platform.service.security.auth.AbstractX509PemSecret
- 
- jadex.platform.service.security.auth.X509PemFilesSecret
 
 
 
- 
- All Implemented Interfaces:
- java.lang.Cloneable
 
 public class X509PemFilesSecret extends AbstractX509PemSecret Secret based on PEM-encoded X.509 certificate files and key.
- 
- 
Field SummaryFields Modifier and Type Field Description protected java.lang.StringcertThe local certificate.protected java.lang.StringkeyThe local certificate key.static java.lang.StringPREFIXPrefix used to encode secret type as strings.- 
Fields inherited from class jadex.platform.service.security.auth.AbstractAuthenticationSecretSECRET_TYPES
 
- 
 - 
Constructor SummaryConstructors Constructor Description X509PemFilesSecret(java.lang.String encodedstring)X509PemFilesSecret(java.lang.String cert, java.lang.String key)Creates the secret.
 - 
Method SummaryAll Methods Instance Methods Concrete Methods Modifier and Type Method Description booleancanSign()Tests if the secret can be used for signing or, alternatively, verification only.booleanequals(java.lang.Object obj)Equals.inthashCode()Hashcode generation.java.io.InputStreamopenCertificate()Opens the local certificate.java.io.InputStreamopenPrivateKey()Opens the private key used for signing.java.lang.StringtoString()Converts to encoded string.- 
Methods inherited from class jadex.platform.service.security.auth.AbstractAuthenticationSecretclone, fromKeyPair, fromString, fromString, main
 
- 
 
- 
- 
- 
Field Detail- 
PREFIXpublic static final java.lang.String PREFIX Prefix used to encode secret type as strings.- See Also:
- Constant Field Values
 
 - 
certprotected java.lang.String cert The local certificate.
 - 
keyprotected java.lang.String key The local certificate key.
 
- 
 - 
Constructor Detail- 
X509PemFilesSecretpublic X509PemFilesSecret(java.lang.String encodedstring) 
 - 
X509PemFilesSecretpublic X509PemFilesSecret(java.lang.String cert, java.lang.String key)Creates the secret.- Parameters:
- cacert- Path to the trust anchor certificate.
- cert- Path to the local certificate.
- key- Path to the local certificate key.
 
 
- 
 - 
Method Detail- 
canSignpublic boolean canSign() Tests if the secret can be used for signing or, alternatively, verification only.- Specified by:
- canSignin class- AbstractAuthenticationSecret
- Returns:
- True, if the secret can be used for signing.
 
 - 
openCertificatepublic java.io.InputStream openCertificate() Opens the local certificate.- Specified by:
- openCertificatein class- AbstractX509PemSecret
- Returns:
- The local certificate.
 
 - 
openPrivateKeypublic java.io.InputStream openPrivateKey() Opens the private key used for signing.- Specified by:
- openPrivateKeyin class- AbstractX509PemSecret
- Returns:
- The private key.
 
 - 
hashCodepublic int hashCode() Hashcode generation.- Overrides:
- hashCodein class- AbstractAuthenticationSecret
 
 - 
equalspublic boolean equals(java.lang.Object obj) Equals.- Overrides:
- equalsin class- AbstractAuthenticationSecret
 
 - 
toStringpublic java.lang.String toString() Converts to encoded string.- Overrides:
- toStringin class- java.lang.Object
 
 
- 
 
-