As we transition to the new Hyland Community, some post links may be temporarily disrupted as we finalize redirects. We apologize for the inconvenience and are working to resolve this as quickly as possible. Details.
Hi,
I want to record users last login datetime.
Which component I need to override? I am using SSO with Azure so need to consider this in mind before implementing any solution.
Help will appreciate.
@angelborroy
Hi, you need to activate audit. See docs
I once created an audit application configuration for that, I'm not sure it's still correct, but you can use it as a base
<?xml version='1.0' encoding='UTF-8'?> <Audit xmlns="http://www.alfresco.org/repo/audit/model/3.2" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.alfresco.org/repo/audit/model/3.2 alfresco-audit-3.2.xsd" > <DataGenerators> <DataGenerator name="currentUser" registeredName="auditModel.generator.user"/> </DataGenerators> <PathMappings> <!-- AlfrescoNTLM logins & REST with Basic Auth (REST calls with ticket does not create a login) --> <PathMap source="/alfresco-api/post/AuthenticationService/authenticate/no-error" target="/audit-basic-logins/login"/> <!-- LDAP Logins --> <PathMap source="/alfresco-api/post/ticketComponent/validateTicket" target="/audit-basic-logins/login"/> <!-- Kerberos --> <PathMap source="/alfresco-api/post/AuthenticationService/getCurrentUserName/no-error" target="/audit-basic-logins/login"/> </PathMappings> <Application name="Audit-Succesfull-Login" key="audit-basic-logins"> <AuditPath key="login"> <GenerateValue key="user" dataGenerator="currentUser"/> </AuditPath> </Application> </Audit>
There's also this addon https://github.com/Acosix/alfresco-audit/tree/master that has a customization for generating some info that are not OOTB available
Great reply Leo!I just fixed your link at the bottom. It had a comma at the end of it.Cheers!Alan