Class OidcApplicationRoutes

java.lang.Object
io.fluxzero.idp.client.OidcApplicationRoutes

public final class OidcApplicationRoutes extends Object
Application-scoped route and callback configuration. This value does not register HTTP handlers. The Fluxzero application identity, independent of the OIDC client identity, owns the route prefix.
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    static final String
    Opts out of automatic OIDC endpoints; environment name FLUXZERO_AUTH_OIDC_DISABLED.
    static final String
    Root-relative or absolute callback setting; environment name FLUXZERO_AUTH_OIDC_REDIRECT_URI.
  • Method Summary

    Modifier and Type
    Method
    Description
    Configured callback path; an absolute override may select another host without changing this path.
    callbackUri(String trustedPublicRequestUrl)
    Resolves the exact callback once at login start.
    from(String applicationId, io.fluxzero.common.application.PropertySource properties)
    Resolves through an explicitly supplied property source, including application-local overrides.
    Resolves defaults from the active application's SDK identity and property source.
    static boolean
    Whether the automatic OIDC endpoints are enabled for the active application.
    static boolean
    isEnabled(io.fluxzero.common.application.PropertySource properties)
    Resolves the opt-out using the supplied application-local source, without requiring application identity, callback, issuer or credentials.
    Default endpoint for both login initiation and the OIDC callback.
    Default application logout endpoint.
    Default application session endpoint.
    boolean
    Whether the default login endpoint should also handle callbacks.

    Methods inherited from class Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Field Details

    • DISABLED_PROPERTY

      public static final String DISABLED_PROPERTY
      Opts out of automatic OIDC endpoints; environment name FLUXZERO_AUTH_OIDC_DISABLED.
      See Also:
    • REDIRECT_URI_PROPERTY

      public static final String REDIRECT_URI_PROPERTY
      Root-relative or absolute callback setting; environment name FLUXZERO_AUTH_OIDC_REDIRECT_URI.
      See Also:
  • Method Details

    • isEnabled

      public static boolean isEnabled()
      Whether the automatic OIDC endpoints are enabled for the active application. Check this before constructing handlers, resolving routes or loading issuer/key configuration. Protocol operations explicitly invoked by the application remain available even when automatic endpoints are disabled.
    • isEnabled

      public static boolean isEnabled(io.fluxzero.common.application.PropertySource properties)
      Resolves the opt-out using the supplied application-local source, without requiring application identity, callback, issuer or credentials. Only an explicit true value disables automatic endpoints.
    • fromCurrentApplication

      public static OidcApplicationRoutes fromCurrentApplication()
      Resolves defaults from the active application's SDK identity and property source.
    • from

      public static OidcApplicationRoutes from(String applicationId, io.fluxzero.common.application.PropertySource properties)
      Resolves through an explicitly supplied property source, including application-local overrides.
    • loginPath

      public String loginPath()
      Default endpoint for both login initiation and the OIDC callback.
    • logoutPath

      public String logoutPath()
      Default application logout endpoint.
    • sessionPath

      public String sessionPath()
      Default application session endpoint.
    • callbackPath

      public String callbackPath()
      Configured callback path; an absolute override may select another host without changing this path.
    • usesDefaultCallback

      public boolean usesDefaultCallback()
      Whether the default login endpoint should also handle callbacks. Custom paths opt out.
    • callbackUri

      public String callbackUri(String trustedPublicRequestUrl)
      Resolves the exact callback once at login start. Save the result with the pending login and reuse it for code exchange; never resolve it again from the incoming callback request.
      Parameters:
      trustedPublicRequestUrl - absolute public destination URL supplied by the HTTP adapter, using trusted ingress information or an explicit external-base-url override; not the Origin header or untrusted Forwarded headers. Ignored when the callback is already absolute. HTTP is supported for localhost only.
      Returns:
      absolute callback URL, preserving absolute overrides verbatim