Class UserAuditFactory
java.lang.Object
de.hybris.platform.servicelayer.user.impl.UserAuditFactory
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected static final Stringprotected ModelServiceprotected UserService -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptioncreateBruteForceLoginDisabledAudit(UserModel user, Integer numFailedLogins) createUserPasswordChangeAudit(PK pk, String uid, String previousPassword, String previousEncoding) Initializes UserAuditModel with uid, pk, previous password and encoding of the user.protected StringTries to return context path if in webcontextprotected StringReturns user of current sessionprotected <X extends AbstractUserAuditModel>
XprocessAfterCreation(X user) Extension point that allows to modify or store additional data if UserAudit model is extended.voidsetModelService(ModelService modelService) voidsetUserService(UserService userService)
-
Field Details
-
userService
-
modelService
-
IP_ADDRESS
- See Also:
-
-
Constructor Details
-
UserAuditFactory
public UserAuditFactory()
-
-
Method Details
-
createUserPasswordChangeAudit
public UserPasswordChangeAuditModel createUserPasswordChangeAudit(PK pk, String uid, String previousPassword, String previousEncoding) Initializes UserAuditModel with uid, pk, previous password and encoding of the user. Additionally ip address, user and context path of application that caused the change are stored.- Parameters:
pk- pk of user that changed passworduid- uid of user that changed passwordpreviousPassword- previous password (hashed)previousEncoding- encoding of previous password- Returns:
-
createBruteForceLoginDisabledAudit
public BruteForceLoginDisabledAuditModel createBruteForceLoginDisabledAudit(UserModel user, Integer numFailedLogins) -
processAfterCreation
Extension point that allows to modify or store additional data if UserAudit model is extended. This method is called after createUserAudit and returned object will be the one that is returned by factory.- Parameters:
user-- Returns:
-
determineContextPath
Tries to return context path if in webcontext- Returns:
- servlet context path or null if not exists
-
determineCurrentUser
Returns user of current session- Returns:
- uid of current user
-
setUserService
-
setModelService
-