Class RedundantPeerVerifier
SecurityContext is this gateway's own redundant
peer: the master/backup sibling that shares this gateway's system name with the opposite
redundancy role, calling over a direct (non-proxied) connection.
Backs the SecuredEntity.allowRedundantPeer() exemption, and is equally usable by a
service's own fine-grained checks to treat the verified sibling as implicitly granted. The trust
rationale: a redundant pair already shares full configuration through the redundancy channel
(which service security does not gate), so recognizing the sibling adds no new access beyond what
redundancy itself grants.
Trust floor: the identity compared here is the caller-asserted per-message source
address (SOURCE_ID_STR), authenticated only transitively by Gateway Network connection
admission (approval/whitelist, plus TLS when enabled) — the same floor the security-zone system's
gw-name trait matching rests on. A connection-admitted peer asserting the sibling's name
and role would pass this check; deployments that admit untrusted or plaintext GAN connections
should weigh that before opting an entity into the exemption.
-
Method Summary
Modifier and TypeMethodDescriptionstatic booleanisRedundantPeer(GatewayContext gatewayContext, com.inductiveautomation.metro.api.security.SecurityContext securityContext) Returns whether the given security context identifies this gateway's redundant sibling.
-
Method Details
-
isRedundantPeer
public static boolean isRedundantPeer(GatewayContext gatewayContext, com.inductiveautomation.metro.api.security.SecurityContext securityContext) Returns whether the given security context identifies this gateway's redundant sibling.- Parameters:
gatewayContext- the local gateway context (supplies system name + redundancy role).securityContext- the active GAN call's security context.- Returns:
truewhen redundancy is enabled locally and the caller is the sibling — same system name, opposite redundancy role — on a direct connection;falseotherwise.
-