Packages

final case class JwtFieldOptions(claim: JwtClaimInclude = kalix.jwt.JwtFieldOptions.JwtClaimInclude.UNSPECIFIED, name: String = "", token: Boolean = false, includeParentClaims: Boolean = false, includeBearerTokenClaim: Seq[String] = _root_.scala.Seq.empty, issuer: Seq[String] = _root_.scala.Seq.empty, expiresSeconds: Long = 0L, staticClaim: Seq[JwtStaticClaim] = _root_.scala.Seq.empty, unknownFields: UnknownFieldSet = _root_.scalapb.UnknownFieldSet.empty) extends GeneratedMessage with Updatable[JwtFieldOptions] with Product with Serializable

claim

The inclusion strategy for this field as a claim.

name

The name of the claim for this field. Only valid for fields with a claim annotation of INCLUDE or NEST. If not set, the name will be the name of this field.

token

Indicates that this field contains a token, either to be validated, or to be written to. If the field is a single string, then the JWT claim for the containing message will be written to it. If the field is a message or repeated field of messages, then this instructs validation and signing to descend into the message or messages, and validate/sign each one according to the annotations present. If no token annotation is present in the child message, an error will be raised.

includeParentClaims

If this token annotated field is a child message of a parent, include the claims from the parent in the token.

includeBearerTokenClaim

A list of bearer token claims to include when signing or validating a token annotated field. The most common use case for this will be pinning tokens contained in this message to the subject in the bearer token, to ensure that the tokens in the message can't be used by other subjects. Bearer token claims will only be included if the method is configured to validate the bearer token, otherwise, validation will fail if the claim can't be read.

issuer

If set, then when validating a token, only accept the token if it comes from this issuer, and when signing, set the issuer to this value. This can be used in combination with the issuer field of configuration for JWT secrets, if there is at least one secret that has this issuer set, then only those secrets with that issuer set will be used for validating or signing this token, so you can be sure that the token did come from a particular issuer. If an issuer (iss) claim is extracted from another field, this configuration, if set, will override that.

expiresSeconds

When signing, set the expires claim to be in this many seconds. If unset or zero, will default to 3600 (1 hour). Set to -1 for no expiry. This configuration will override any expiry (exp) claim extracted from other fields. Leave unset, or set to -1, to allow the expiry to be dynamically set.

staticClaim

If set, the static claims provided and their values will be required when calling the service. When multiple claims are provided, all of them will be required to successfully call the service. When signing, these static claims will also included in the token.

Annotations
@SerialVersionUID()
Source
JwtFieldOptions.scala
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. JwtFieldOptions
  2. Updatable
  3. GeneratedMessage
  4. Serializable
  5. Product
  6. Equals
  7. AnyRef
  8. Any
Implicitly
  1. by any2stringadd
  2. by StringFormat
  3. by Ensuring
  4. by ArrowAssoc
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. Protected

Instance Constructors

  1. new JwtFieldOptions(claim: JwtClaimInclude = kalix.jwt.JwtFieldOptions.JwtClaimInclude.UNSPECIFIED, name: String = "", token: Boolean = false, includeParentClaims: Boolean = false, includeBearerTokenClaim: Seq[String] = _root_.scala.Seq.empty, issuer: Seq[String] = _root_.scala.Seq.empty, expiresSeconds: Long = 0L, staticClaim: Seq[JwtStaticClaim] = _root_.scala.Seq.empty, unknownFields: UnknownFieldSet = _root_.scalapb.UnknownFieldSet.empty)

    claim

    The inclusion strategy for this field as a claim.

    name

    The name of the claim for this field. Only valid for fields with a claim annotation of INCLUDE or NEST. If not set, the name will be the name of this field.

    token

    Indicates that this field contains a token, either to be validated, or to be written to. If the field is a single string, then the JWT claim for the containing message will be written to it. If the field is a message or repeated field of messages, then this instructs validation and signing to descend into the message or messages, and validate/sign each one according to the annotations present. If no token annotation is present in the child message, an error will be raised.

    includeParentClaims

    If this token annotated field is a child message of a parent, include the claims from the parent in the token.

    includeBearerTokenClaim

    A list of bearer token claims to include when signing or validating a token annotated field. The most common use case for this will be pinning tokens contained in this message to the subject in the bearer token, to ensure that the tokens in the message can't be used by other subjects. Bearer token claims will only be included if the method is configured to validate the bearer token, otherwise, validation will fail if the claim can't be read.

    issuer

    If set, then when validating a token, only accept the token if it comes from this issuer, and when signing, set the issuer to this value. This can be used in combination with the issuer field of configuration for JWT secrets, if there is at least one secret that has this issuer set, then only those secrets with that issuer set will be used for validating or signing this token, so you can be sure that the token did come from a particular issuer. If an issuer (iss) claim is extracted from another field, this configuration, if set, will override that.

    expiresSeconds

    When signing, set the expires claim to be in this many seconds. If unset or zero, will default to 3600 (1 hour). Set to -1 for no expiry. This configuration will override any expiry (exp) claim extracted from other fields. Leave unset, or set to -1, to allow the expiry to be dynamically set.

    staticClaim

    If set, the static claims provided and their values will be required when calling the service. When multiple claims are provided, all of them will be required to successfully call the service. When signing, these static claims will also included in the token.

Value Members

  1. final def !=(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  2. final def ##: Int
    Definition Classes
    AnyRef → Any
  3. def +(other: String): String
    Implicit
    This member is added by an implicit conversion from JwtFieldOptions toany2stringadd[JwtFieldOptions] performed by method any2stringadd in scala.Predef.
    Definition Classes
    any2stringadd
  4. def ->[B](y: B): (JwtFieldOptions, B)
    Implicit
    This member is added by an implicit conversion from JwtFieldOptions toArrowAssoc[JwtFieldOptions] performed by method ArrowAssoc in scala.Predef.
    Definition Classes
    ArrowAssoc
    Annotations
    @inline()
  5. final def ==(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  6. def addAllIncludeBearerTokenClaim(__vs: Iterable[String]): JwtFieldOptions
  7. def addAllIssuer(__vs: Iterable[String]): JwtFieldOptions
  8. def addAllStaticClaim(__vs: Iterable[JwtStaticClaim]): JwtFieldOptions
  9. def addIncludeBearerTokenClaim(__vs: String*): JwtFieldOptions
  10. def addIssuer(__vs: String*): JwtFieldOptions
  11. def addStaticClaim(__vs: JwtStaticClaim*): JwtFieldOptions
  12. final def asInstanceOf[T0]: T0
    Definition Classes
    Any
  13. val claim: JwtClaimInclude
  14. def clearIncludeBearerTokenClaim: JwtFieldOptions
  15. def clearIssuer: JwtFieldOptions
  16. def clearStaticClaim: JwtFieldOptions
  17. def clone(): AnyRef
    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.CloneNotSupportedException]) @native()
  18. def companion: JwtFieldOptions.type
    Definition Classes
    JwtFieldOptions → GeneratedMessage
  19. def discardUnknownFields: JwtFieldOptions
  20. def ensuring(cond: (JwtFieldOptions) => Boolean, msg: => Any): JwtFieldOptions
    Implicit
    This member is added by an implicit conversion from JwtFieldOptions toEnsuring[JwtFieldOptions] performed by method Ensuring in scala.Predef.
    Definition Classes
    Ensuring
  21. def ensuring(cond: (JwtFieldOptions) => Boolean): JwtFieldOptions
    Implicit
    This member is added by an implicit conversion from JwtFieldOptions toEnsuring[JwtFieldOptions] performed by method Ensuring in scala.Predef.
    Definition Classes
    Ensuring
  22. def ensuring(cond: Boolean, msg: => Any): JwtFieldOptions
    Implicit
    This member is added by an implicit conversion from JwtFieldOptions toEnsuring[JwtFieldOptions] performed by method Ensuring in scala.Predef.
    Definition Classes
    Ensuring
  23. def ensuring(cond: Boolean): JwtFieldOptions
    Implicit
    This member is added by an implicit conversion from JwtFieldOptions toEnsuring[JwtFieldOptions] performed by method Ensuring in scala.Predef.
    Definition Classes
    Ensuring
  24. final def eq(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  25. val expiresSeconds: Long
  26. final def getClass(): Class[_ <: AnyRef]
    Definition Classes
    AnyRef → Any
    Annotations
    @native()
  27. def getField(__field: FieldDescriptor): PValue
    Definition Classes
    JwtFieldOptions → GeneratedMessage
  28. def getFieldByNumber(__fieldNumber: Int): Any
    Definition Classes
    JwtFieldOptions → GeneratedMessage
  29. val includeBearerTokenClaim: Seq[String]
  30. val includeParentClaims: Boolean
  31. final def isInstanceOf[T0]: Boolean
    Definition Classes
    Any
  32. val issuer: Seq[String]
  33. val name: String
  34. final def ne(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  35. final def notify(): Unit
    Definition Classes
    AnyRef
    Annotations
    @native()
  36. final def notifyAll(): Unit
    Definition Classes
    AnyRef
    Annotations
    @native()
  37. def productElementNames: Iterator[String]
    Definition Classes
    Product
  38. def serializedSize: Int
    Definition Classes
    JwtFieldOptions → GeneratedMessage
  39. val staticClaim: Seq[JwtStaticClaim]
  40. final def synchronized[T0](arg0: => T0): T0
    Definition Classes
    AnyRef
  41. final def toByteArray: Array[Byte]
    Definition Classes
    GeneratedMessage
  42. final def toByteString: ByteString
    Definition Classes
    GeneratedMessage
  43. final def toPMessage: PMessage
    Definition Classes
    GeneratedMessage
  44. def toProtoString: String
    Definition Classes
    JwtFieldOptions → GeneratedMessage
  45. val token: Boolean
  46. val unknownFields: UnknownFieldSet
  47. def update(ms: (Lens[JwtFieldOptions, JwtFieldOptions]) => Mutation[JwtFieldOptions]*): JwtFieldOptions
    Definition Classes
    Updatable
  48. final def wait(): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.InterruptedException])
  49. final def wait(arg0: Long, arg1: Int): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.InterruptedException])
  50. final def wait(arg0: Long): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.InterruptedException]) @native()
  51. def withClaim(__v: JwtClaimInclude): JwtFieldOptions
  52. def withExpiresSeconds(__v: Long): JwtFieldOptions
  53. def withIncludeBearerTokenClaim(__v: Seq[String]): JwtFieldOptions
  54. def withIncludeParentClaims(__v: Boolean): JwtFieldOptions
  55. def withIssuer(__v: Seq[String]): JwtFieldOptions
  56. def withName(__v: String): JwtFieldOptions
  57. def withStaticClaim(__v: Seq[JwtStaticClaim]): JwtFieldOptions
  58. def withToken(__v: Boolean): JwtFieldOptions
  59. def withUnknownFields(__v: UnknownFieldSet): JwtFieldOptions
  60. final def writeDelimitedTo(output: OutputStream): Unit
    Definition Classes
    GeneratedMessage
  61. def writeTo(_output__: CodedOutputStream): Unit
    Definition Classes
    JwtFieldOptions → GeneratedMessage
  62. final def writeTo(output: OutputStream): Unit
    Definition Classes
    GeneratedMessage

Deprecated Value Members

  1. def finalize(): Unit
    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.Throwable]) @Deprecated
    Deprecated

    (Since version 9)

  2. def formatted(fmtstr: String): String
    Implicit
    This member is added by an implicit conversion from JwtFieldOptions toStringFormat[JwtFieldOptions] performed by method StringFormat in scala.Predef.
    Definition Classes
    StringFormat
    Annotations
    @deprecated @inline()
    Deprecated

    (Since version 2.12.16) Use formatString.format(value) instead of value.formatted(formatString), or use the f"" string interpolator. In Java 15 and later, formatted resolves to the new method in String which has reversed parameters.

  3. def [B](y: B): (JwtFieldOptions, B)
    Implicit
    This member is added by an implicit conversion from JwtFieldOptions toArrowAssoc[JwtFieldOptions] performed by method ArrowAssoc in scala.Predef.
    Definition Classes
    ArrowAssoc
    Annotations
    @deprecated
    Deprecated

    (Since version 2.13.0) Use -> instead. If you still wish to display it as one character, consider using a font with programming ligatures such as Fira Code.

Inherited from Updatable[JwtFieldOptions]

Inherited from GeneratedMessage

Inherited from Serializable

Inherited from Product

Inherited from Equals

Inherited from AnyRef

Inherited from Any

Inherited by implicit conversion any2stringadd fromJwtFieldOptions to any2stringadd[JwtFieldOptions]

Inherited by implicit conversion StringFormat fromJwtFieldOptions to StringFormat[JwtFieldOptions]

Inherited by implicit conversion Ensuring fromJwtFieldOptions to Ensuring[JwtFieldOptions]

Inherited by implicit conversion ArrowAssoc fromJwtFieldOptions to ArrowAssoc[JwtFieldOptions]

Ungrouped