Class PemCredentialConfigurationProperties
java.lang.Object
se.swedenconnect.security.credential.config.properties.AbstractBaseCredentialConfigurationProperties
se.swedenconnect.security.credential.config.properties.PemCredentialConfigurationProperties
- All Implemented Interfaces:
BaseCredentialConfiguration, PemCredentialConfiguration
public class PemCredentialConfigurationProperties
extends AbstractBaseCredentialConfigurationProperties
implements PemCredentialConfiguration
Configuration properties for creating a
PkiCredential
using PEM-encoded certificate(s) and private keys.- Author:
- Martin Lindström
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionLocation or content of the certificate or certificate chain in PEM format.booleanGets the location or content of the certificate or certificate chain in PEM format.Gets the password used to decrypt the private key.Gets the location or content of the private key in PEM format.Gets the location or content of the public key in PEM format.inthashCode()Password used to decrypt an encrypted private key.Location or content of the private key in PEM format.Location or content of the public key in PEM format.voidsetCertificates(String certificates) Assigns the location or content of the certificate or certificate chain in PEM format.voidsetKeyPassword(String keyPassword) Assigns the password used to decrypt the private key.voidsetPrivateKey(String privateKey) Assigns the location or content of the private key in PEM format.voidsetPublicKey(String publicKey) Assigns the location or content of the public key in PEM format.Methods inherited from class AbstractBaseCredentialConfigurationProperties
activeFrom, activeTo, expiresAt, getActiveFrom, getActiveTo, getExpiresAt, getIssuedAt, getKeyId, getMetadata, getName, getUsage, issuedAt, keyId, metadata, name, setActiveFrom, setActiveTo, setExpiresAt, setIssuedAt, setKeyId, setName, setUsage, usageMethods inherited from class Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface BaseCredentialConfiguration
activeFrom, activeTo, expiresAt, issuedAt, keyId, metadata, name, usage
-
Constructor Details
-
PemCredentialConfigurationProperties
public PemCredentialConfigurationProperties()
-
-
Method Details
-
getPublicKey
Gets the location or content of the public key in PEM format.- Returns:
- the public key location or content
-
setPublicKey
Assigns the location or content of the public key in PEM format.- Parameters:
publicKey- the public key location or content
-
getCertificates
Gets the location or content of the certificate or certificate chain in PEM format.- Returns:
- the certificate(s) location or content
-
setCertificates
Assigns the location or content of the certificate or certificate chain in PEM format.- Parameters:
certificates- the certificate(s) location or content
-
getPrivateKey
Gets the location or content of the private key in PEM format.- Returns:
- the private key location or content
-
setPrivateKey
Assigns the location or content of the private key in PEM format.- Parameters:
privateKey- the private key location or content
-
getKeyPassword
Gets the password used to decrypt the private key.- Returns:
- the private key password
-
setKeyPassword
Assigns the password used to decrypt the private key.- Parameters:
keyPassword- the private key password
-
publicKey
Location or content of the public key in PEM format.This setting is mutually exclusive with the
PemCredentialConfiguration.certificates()setting.- Specified by:
publicKeyin interfacePemCredentialConfiguration- Returns:
- the location or content of the public key
-
certificates
Location or content of the certificate or certificate chain in PEM format.If more than one certificate is supplied, the entity certificate, i.e., the certificate holding the public key of the key pair, must be placed first.
This setting is mutually exclusive with the
PemCredentialConfiguration.publicKey()setting.- Specified by:
certificatesin interfacePemCredentialConfiguration- Returns:
- the location or content of the certificate or certificate chain in PEM format
-
privateKey
Location or content of the private key in PEM format.- Specified by:
privateKeyin interfacePemCredentialConfiguration- Returns:
- the location or content of the private key in PEM format
-
keyPassword
Password used to decrypt an encrypted private key.- Specified by:
keyPasswordin interfacePemCredentialConfiguration- Returns:
- key password
-
equals
- Overrides:
equalsin classAbstractBaseCredentialConfigurationProperties
-
hashCode
public int hashCode()- Overrides:
hashCodein classAbstractBaseCredentialConfigurationProperties
-