Class NuggetAuthenticationRequest
java.lang.Object
org.j7m.middleware.operations.api.NuggetAuthenticationRequest
UI-neutral metadata for one nugget PIN admission request.
The reusable credential is deliberately not stored in this public request
object. Runtime admission services accept the credential as a separate
shortest-scope argument so request diagnostics, toString(), audit,
and JSON-style representations cannot expose it. Correlation and source
identifiers are normalized by the constructor before throttle bucketing or
audit use so hostile pre-authentication text cannot expand retained state or
leak secrets.
-
Method Summary
Modifier and TypeMethodDescriptionReturns the audit correlation id.static NuggetAuthenticationRequestfrom(NuggetAuthenticationSource source) Creates request metadata with a generated correlation id.static NuggetAuthenticationRequestof(String correlationId, NuggetAuthenticationSource source, String sourceId, boolean trustedSource, Instant requestedAt) Creates request metadata.Returns the request timestamp.source()Returns the coarse source class.sourceId()Returns a bounded endpoint or listener identifier when it is safe.toString()booleanReturns whethersourceId()is owned and trusted by the runtime.
-
Method Details
-
from
Creates request metadata with a generated correlation id.- Parameters:
source- source class- Returns:
- request metadata
-
of
public static NuggetAuthenticationRequest of(String correlationId, NuggetAuthenticationSource source, String sourceId, boolean trustedSource, Instant requestedAt) Creates request metadata.- Parameters:
correlationId- caller-supplied audit correlation id; blank, overlong, malformed, or sensitive values are replacedsource- source classsourceId- bounded endpoint or listener identifier; unsafe values are omittedtrustedSource- whether the runtime owns and trustssourceIdrequestedAt- request creation timestamp for diagnostics- Returns:
- request metadata
-
correlationId
-
source
-
sourceId
Returns a bounded endpoint or listener identifier when it is safe.- Returns:
- source identifier, or empty string
-
trustedSource
public boolean trustedSource()Returns whethersourceId()is owned and trusted by the runtime.- Returns:
- trusted-source flag
-
requestedAt
-
toString
-