Interface ShieldListener


public interface ShieldListener

Callback for shield state changes. Register with AppShield.addListener(ShieldListener).

All callbacks are delivered on the EDT, so they may touch the UI directly. The framework itself never shows a dialog or terminates the app over a shield event -- what the user sees is entirely the app's decision, made here.

  • Method Details

    • statusChanged

      void statusChanged(ShieldStatus status)

      The token status changed, for example from ShieldStatus.OK to ShieldStatus.REJECTED.

      Branch on ShieldStatus.isTransient() before reacting. A transient status means the service was unreachable and will likely be reachable again shortly; reacting to it the same way as ShieldStatus.REJECTED is how an app ends up locking out users on a bad connection.

    • signalRaised

      void signalRaised(ShieldSignal signal)
      A new runtime self-protection observation was recorded. Informational: the attestation service decides what a signal means for token issuance, and it may reach a different conclusion than the device would.