Commit b7c219a5 by Mandar Ambawane Committed by nixonrodrigues

ATLAS-4016 : Update authorization - 'admin-audits' for retrieving admin audits

parent 801d40c3
...@@ -44,7 +44,9 @@ public enum AtlasPrivilege { ...@@ -44,7 +44,9 @@ public enum AtlasPrivilege {
ENTITY_REMOVE_LABEL("entity-remove-label"), ENTITY_REMOVE_LABEL("entity-remove-label"),
ENTITY_UPDATE_BUSINESS_METADATA("entity-update-business-metadata"), ENTITY_UPDATE_BUSINESS_METADATA("entity-update-business-metadata"),
TYPE_READ("type-read"); TYPE_READ("type-read"),
ADMIN_AUDITS("admin-audits");
private final String type; private final String type;
......
...@@ -624,6 +624,8 @@ public class AdminResource { ...@@ -624,6 +624,8 @@ public class AdminResource {
perf = AtlasPerfTracer.getPerfTracer(PERF_LOG, "AdminResource.getAtlasAudits(" + auditSearchParameters + ")"); perf = AtlasPerfTracer.getPerfTracer(PERF_LOG, "AdminResource.getAtlasAudits(" + auditSearchParameters + ")");
} }
AtlasAuthorizationUtils.verifyAccess(new AtlasAdminAccessRequest(AtlasPrivilege.ADMIN_AUDITS), "Admin Audits");
return auditService.get(auditSearchParameters); return auditService.get(auditSearchParameters);
} finally { } finally {
AtlasPerfTracer.log(perf); AtlasPerfTracer.log(perf);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment