Class Certificates

java.lang.Object
swiss.trustbroker.federation.xmlconfig.Certificates
All Implemented Interfaces:
Serializable

public class Certificates extends Object implements Serializable
The certificate configurations contain file paths relative to
${TRUSTBOKER_HOME}/keystore
. Files can contain a certificate for trust checks and optionally a private key required for signing. The following formats are supported and the files should have this as extensions:
  • pem: OpenSSL compatible text representation
  • p12: PKCS12 keystore format
  • jks: Java specific keystore format (not recommended)

Always specify
$PKI_PASSPHRASE
for passwords as a place-holder for the key decryption passphrase to be passed to the running XTB process.
See Also:
  • Constructor Details

    • Certificates

      public Certificates()
    • Certificates

      public Certificates(SignerKeystore signerKeystore, SignerTruststore signerTruststore, SignerKeystore encryptionKeystore, SignerTruststore encryptionTruststore, SignerKeystore backendKeystore, SignerTruststore backendTruststore, SignerKeystore artifactResolutionKeystore, SignerTruststore artifactResolutionTruststore)
      Creates a new Certificates instance.
      Parameters:
      signerKeystore - Keystore for signing.
      signerTruststore - Truststore for signature verification.
      encryptionKeystore - Keystore for encryption.
      encryptionTruststore - Truststore for encryption verification.
      backendKeystore - Keystore for backend connections (via SAML the artifact resolution or OIDC metadata protocol).
      backendTruststore - Truststore for backend connections (via SAML the artifact resolution or OIDC metadata protocol).
      artifactResolutionKeystore - @deprecated Use backendKeystore
      artifactResolutionTruststore - @deprecated Use backendTruststore
      Since:
      1.9.0, 1.9.0
  • Method Details

    • getBackendKeystore

      public SignerKeystore getBackendKeystore()
    • getBackendTruststore

      public SignerTruststore getBackendTruststore()
    • builder

      public static Certificates.CertificatesBuilder builder()
    • getSignerKeystore

      public SignerKeystore getSignerKeystore()
      Keystore for signing.
    • getSignerTruststore

      public SignerTruststore getSignerTruststore()
      Truststore for signature verification.
    • getEncryptionKeystore

      public SignerKeystore getEncryptionKeystore()
      Keystore for encryption.
    • getEncryptionTruststore

      public SignerTruststore getEncryptionTruststore()
      Truststore for encryption verification.
    • getArtifactResolutionKeystore

      @Deprecated public SignerKeystore getArtifactResolutionKeystore()
      Deprecated.
      Use backendKeystore
    • getArtifactResolutionTruststore

      @Deprecated public SignerTruststore getArtifactResolutionTruststore()
      Deprecated.
      Use backendTruststore
    • setSignerKeystore

      public void setSignerKeystore(SignerKeystore signerKeystore)
      Keystore for signing.
    • setSignerTruststore

      public void setSignerTruststore(SignerTruststore signerTruststore)
      Truststore for signature verification.
    • setEncryptionKeystore

      public void setEncryptionKeystore(SignerKeystore encryptionKeystore)
      Keystore for encryption.
    • setEncryptionTruststore

      public void setEncryptionTruststore(SignerTruststore encryptionTruststore)
      Truststore for encryption verification.
    • setBackendKeystore

      public void setBackendKeystore(SignerKeystore backendKeystore)
      Keystore for backend connections (via SAML the artifact resolution or OIDC metadata protocol).
      Since:
      1.9.0
    • setBackendTruststore

      public void setBackendTruststore(SignerTruststore backendTruststore)
      Truststore for backend connections (via SAML the artifact resolution or OIDC metadata protocol).
      Since:
      1.9.0
    • setArtifactResolutionKeystore

      @Deprecated public void setArtifactResolutionKeystore(SignerKeystore artifactResolutionKeystore)
      Deprecated.
      Use backendKeystore
    • setArtifactResolutionTruststore

      @Deprecated public void setArtifactResolutionTruststore(SignerTruststore artifactResolutionTruststore)
      Deprecated.
      Use backendTruststore
    • equals

      public boolean equals(Object o)
      Overrides:
      equals in class Object
    • canEqual

      protected boolean canEqual(Object other)
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object
    • toString

      public String toString()
      Overrides:
      toString in class Object