Class RecordSecurityEventUseCase
java.lang.Object
com.irurueta.authserver.authorization.application.mfa.RecordSecurityEventUseCase
Use case that records a security event (login, second factor, lockout, trusted device) in the audit log.
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final ClockSource of the current time.private final SecurityEventRepositoryPort that stores the security events. -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidexecute(SecurityEventType type, UUID userId, String username, String detail) Records an event that happened now.
-
Field Details
-
securityEventRepository
Port that stores the security events. -
clock
Source of the current time.
-
-
Constructor Details
-
RecordSecurityEventUseCase
public RecordSecurityEventUseCase()
-
-
Method Details
-
execute
Records an event that happened now.- Parameters:
type- kind of event.userId- identifier of the user, ornullwhen the user is unknown.username- name the user presented, ornull.detail- extra information, ornull.
-