Class Fido2Request

java.lang.Object
com.thalesgroup.gemalto.fido2.client.Fido2Request

public abstract class Fido2Request extends Object
Represents a FIDO2 request received from a Relying Party, such as a registration or authentication request.

This class is the starting point for processing a FIDO2 operation. An instance is created from a JSON string provided by the FIDO2 server.

Since:
1.0.0
  • Constructor Details

  • Method Details

    • hybridJsonText

      public static Fido2Request hybridJsonText(@NonNull String jsonText) throws Fido2Exception
      Creates a FIDO2 request from a JSON string, with support for hybrid (cross-device) flows enabled.

      This factory method parses the JSON to determine if it's a registration or authentication request and creates the appropriate request object.

      Parameters:
      jsonText - The FIDO2 request in JSON format. Must not be null.
      Returns:
      A new Fido2Request instance.
      Throws:
      Fido2Exception - If the JSON is malformed or represents an unsupported request type.
      IllegalArgumentException - if jsonText is null.
      Since:
      1.8.0
    • jsonText

      public static Fido2Request jsonText(@NonNull String jsonText) throws Fido2Exception
      Creates a FIDO2 request from a JSON string.

      This factory method parses the JSON to determine if it's a registration or authentication request and creates the appropriate request object.

      Parameters:
      jsonText - The FIDO2 request in JSON format. Must not be null.
      Returns:
      A new Fido2Request instance.
      Throws:
      Fido2Exception - If the JSON is malformed or represents an unsupported request type.
      IllegalArgumentException - if jsonText is null.
      Since:
      1.0.0
    • getType

      public Fido2OperationType getType()
      Gets the type of the FIDO2 operation for this request.
      Returns:
      The Fido2OperationType (e.g., REGISTRATION or AUTHENTICATION).
      Since:
      1.0.0
    • wipe

      public abstract void wipe()
      Securely wipes any sensitive data held by this request object from memory.
      Since:
      1.2.0