@Security public class TrustedDeviceServiceSecurity extends BaseServiceSecurity implements TrustedDeviceService
TrustedDeviceService| Constructor and Description |
|---|
TrustedDeviceServiceSecurity() |
| Modifier and Type | Method and Description |
|---|---|
ActivateTrustedDeviceDTO |
activate(java.lang.String code)
Activates the trusted device with the given code for the logged user.
|
TrustedDeviceActivationData |
getActivationData()
Returns data required to activate a device for the logged user.
|
TrustedDeviceData |
getData(long id)
Returns data about a trusted device.
|
java.util.List<TrustedDeviceVO> |
list(UserLocatorVO locator)
Returns the list of trusted devices for the given user (null resolves to the logged user).
|
void |
remove(java.lang.Long id)
Removes a trusted device by id for the logged user.
|
RequestActivationResult |
requestActivationCode(@NotNull RequestDeviceActivationParams params)
Requests for an activation code.
|
protected org.cyclos.impl.access.EntityCheck<?> |
resolveEntityCheck()
Must be implemented in order to return the
EntityCheck managed by this security component, or null if
none |
void |
save(TrustedDeviceDTO dto)
Updates a given trusted device for the logged user.
|
checkGuest, checkId, checkIds, checkInternalName, checkLoggedIn, checkManagesUser, checkRelatesToUser, checkVO, checkVOs, doInitialize, getEntityCheckRegistry, getUser, initializecanManage, checkManagesUser, checkPermission, checkRelatesToUser, checkValue, clearAlreadyValidated, getBaseEntityManagerHandler, getConfiguration, getLoggedBasicUser, getLoggedUser, getProducts, getTranslatedName, getTranslatedValue, hasPermission, hasValue, inSameNetwork, inSameNetworkOrGlobal, isAdmin, isAlreadyValidated, isBroker, isGlobalAdmin, isGlobalAdminInNetwork, isGuest, isLoggedIn, isMember, isMemberOnly, isNetworkAdmin, isOperator, isRelatedToUser, isSystem, isUserManager, isUserManagerOf, message, message, permission, permission, permissionOptionalValue, permissionOptionalValue, toDate, toDateTime, validatedelete, detach, find, flush, from, getApplicationContext, getFormatter, getFormatter, getFormatter, getLogger, getRemoteAddress, getSessionData, mailContentBuilder, message, message, persist, processBatch, processBatch, refresh, remove, selectFrom, subQuery, updatepublic ActivateTrustedDeviceDTO activate(java.lang.String code) throws FrameworkException
TrustedDeviceServiceactivate in interface TrustedDeviceServiceFrameworkExceptionpublic TrustedDeviceActivationData getActivationData() throws FrameworkException
TrustedDeviceServicegetActivationData in interface TrustedDeviceServiceFrameworkExceptionpublic TrustedDeviceData getData(long id) throws FrameworkException
TrustedDeviceServicegetData in interface TrustedDeviceServiceFrameworkExceptionpublic java.util.List<TrustedDeviceVO> list(UserLocatorVO locator) throws FrameworkException
TrustedDeviceServicePermission.USER_TRUSTED_DEVICES_VIEW permission.list in interface TrustedDeviceServiceFrameworkExceptionpublic void remove(java.lang.Long id)
throws FrameworkException
TrustedDeviceServiceremove in interface TrustedDeviceServiceFrameworkExceptionpublic RequestActivationResult requestActivationCode(@NotNull @NotNull RequestDeviceActivationParams params) throws FrameworkException
TrustedDeviceServiceRequestDeviceActivationParams.DEVICE_ID is given then the same existing code for that device
will be send again and the the name won't be changed (it's ignored if given). Otherwise, a new pending trusted
device will be created for the logged user and the code will be sent (in that case the name is required).
(phone / e-mail). If RequestDeviceActivationParams.MEDIUM is SendMedium.SMS then the message will
be send to the (required) RequestDeviceActivationParams#PHONE.requestActivationCode in interface TrustedDeviceServiceFrameworkExceptionpublic void save(TrustedDeviceDTO dto) throws FrameworkException
TrustedDeviceServicesave in interface TrustedDeviceServiceFrameworkExceptionprotected org.cyclos.impl.access.EntityCheck<?> resolveEntityCheck()
BaseServiceSecurityEntityCheck managed by this security component, or null if
noneresolveEntityCheck in class BaseServiceSecurity