I have created application which is accessing alfresco using web service client. Now I want to audit all events of that application in alfresco, so I have enabled alfresco-access audit application. Here when I execute simple audit query it is returning all results properly, but when I execute query to get all audit events related to specific file it returning 0 entries.
Simple Query to get all audit events
http://localhost:8080/alfresco/service/api/audit/query/alfresco-access?verbose=true
Advanced Query to only get audit events of specific file
http://localhost:8080/alfresco/service/api/audit/query/alfresco-access/transaction/path?verbose=true&value="/app:company_home/cm:test/cm:test1/cm:test2/cm:testfile.pdf"
I have added following configuration in my alfresco-global.properties:
audit.enabled=true
audit.tagging.enabled=true
audit.alfresco-access.enabled=true
audit.alfresco-access.sub-events.enabled=true
audit.cmischangelog.enabled=true
audit.dod5015.enabled=true
audit.config.strict=false
audit.filter.alfresco-access.default.enabled=true
audit.filter.alfresco-access.transaction.user=~System;~null;.*
audit.filter.alfresco-access.transaction.type=cm:folder;cm:content;st:site<br>
audit.filter.alfresco-access.transaction.path=~/sys:archivedItem;~/ver:;.*
Following query is now working, just need to add application name in key parameter –