Class TwoFADevicesResource<T extends UserDevicesDao>

  • Type Parameters:
    T - the type of UserDevicesDao used to access the user's devices
    All Implemented Interfaces:
    org.forgerock.json.resource.CollectionResourceProvider
    Direct Known Subclasses:
    OathDevicesResource, PushDevicesResource

    public abstract class TwoFADevicesResource<T extends UserDevicesDao>
    extends UserDevicesResource<T>
    Abstract sub-implementation of the UserDevicesResource. A TwoFADevice must have the ability to skip the module, if desired by the user and the configuration of that server allows it.
    • Constructor Detail

      • TwoFADevicesResource

        public TwoFADevicesResource​(T userDevicesDao,
                                    ContextHelper helper)
        Constructs a new UserDevicesResource.
        Parameters:
        userDevicesDao - An instance of the UserDevicesDao.
        helper - An instance of the ContextHelper.
    • Method Detail

      • getUserIdFromUri

        protected AMIdentity getUserIdFromUri​(org.forgerock.services.context.Context context)
                                       throws org.forgerock.json.resource.InternalServerErrorException
        Retrieving the user id in this fashion ensures that an admin can utilise these functions.
        Throws:
        org.forgerock.json.resource.InternalServerErrorException