Record Class ServiceClientKeyProperties

java.lang.Object
java.lang.Record
com.irurueta.authserver.serviceclient.infrastructure.resourceserver.ServiceClientKeyProperties
Record Components:
privateKey - the PEM text, or null / blank when there is none.
privateKeyPath - path of a PEM file, or null when there is none.
keyId - kid written in the assertion header, or null to write none.

@ConfigurationProperties(prefix="service-client.auth.key") public record ServiceClientKeyProperties(String privateKey, Path privateKeyPath, String keyId) extends Record
Private key with which the private_key_jwt assertion is signed (service-client.auth.key.*): an unencrypted RSA key in PKCS#8 PEM, given inline (the CLI profiles read it from the SERVICE_CLIENT_PRIVATE_KEY environment variable) or as the path of a file. The inline value wins when both are given.
  • Field Details

    • privateKey

      private final String privateKey
      The field for the privateKey record component.
    • privateKeyPath

      private final Path privateKeyPath
      The field for the privateKeyPath record component.
    • keyId

      private final String keyId
      The field for the keyId record component.
  • Constructor Details

    • ServiceClientKeyProperties

      public ServiceClientKeyProperties(String privateKey, Path privateKeyPath, String keyId)
      Creates an instance of a ServiceClientKeyProperties record class.
      Parameters:
      privateKey - the value for the privateKey record component
      privateKeyPath - the value for the privateKeyPath record component
      keyId - the value for the keyId record component
  • Method Details

    • toString

      public String toString()
      Describes the settings without the key.
      Specified by:
      toString in class Record
      Returns:
      the description.
    • hashCode

      public final int hashCode()
      Returns a hash code value for this object. The value is derived from the hash code of each of the record components.
      Specified by:
      hashCode in class Record
      Returns:
      a hash code value for this object
    • equals

      public final boolean equals(Object o)
      Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. All components in this record class are compared with Objects::equals(Object,Object).
      Specified by:
      equals in class Record
      Parameters:
      o - the object with which to compare
      Returns:
      true if this object is the same as the o argument; false otherwise.
    • privateKey

      public String privateKey()
      Returns the value of the privateKey record component.
      Returns:
      the value of the privateKey record component
    • privateKeyPath

      public Path privateKeyPath()
      Returns the value of the privateKeyPath record component.
      Returns:
      the value of the privateKeyPath record component
    • keyId

      public String keyId()
      Returns the value of the keyId record component.
      Returns:
      the value of the keyId record component