Michael Smith has submitted this change and it was merged. ( http://gerrit.cloudera.org:8080/24315 )
Change subject: IMPALA-14956: Produce Ranger audit events for GRANT/REVOKE ROLE ...................................................................... IMPALA-14956: Produce Ranger audit events for GRANT/REVOKE ROLE Due to RANGER-5595, Impala could not produce Ranger audit events for the GRANT/REVOKE ROLE statements. This patch works around this issue by mimicking what RangerHiveAuthorizer#grantRole() does at https://github.com/apache/ranger/blob/3fd46db/hive-agent/src/main/java/org/apache/ranger/authorization/hive/authorizer/RangerHiveAuthorizer.java#L609-L612. On a related note, adding the test cases for the GRANT/REVOKE privilege statements is not in the scope of this JIRA. IMPALA-15011 was created to keep track of this. Testing: - Added Java test cases to verify Ranger audit events could be produced for the GRANT/REVOKE ROLE statements. Change-Id: I7e0527af0532749817ea538c253262a5e2a65c61 Reviewed-on: http://gerrit.cloudera.org:8080/24315 Reviewed-by: Michael Smith <[email protected]> Tested-by: Impala Public Jenkins <[email protected]> Reviewed-by: Jason Fehr <[email protected]> --- M fe/src/main/java/org/apache/impala/authorization/AuthorizationManager.java M fe/src/main/java/org/apache/impala/authorization/NoopAuthorizationFactory.java M fe/src/main/java/org/apache/impala/authorization/ranger/RangerCatalogdAuthorizationManager.java M fe/src/main/java/org/apache/impala/authorization/ranger/RangerImpalaResourceBuilder.java M fe/src/main/java/org/apache/impala/authorization/ranger/RangerImpaladAuthorizationManager.java M fe/src/main/java/org/apache/impala/service/CatalogOpExecutor.java A fe/src/test/java/org/apache/impala/authorization/ranger/RangerCatalogdAuthorizationManagerTest.java 7 files changed, 396 insertions(+), 22 deletions(-) Approvals: Michael Smith: Looks good to me, but someone else must approve Impala Public Jenkins: Verified Jason Fehr: Looks good to me, approved -- To view, visit http://gerrit.cloudera.org:8080/24315 To unsubscribe, visit http://gerrit.cloudera.org:8080/settings Gerrit-Project: Impala-ASF Gerrit-Branch: master Gerrit-MessageType: merged Gerrit-Change-Id: I7e0527af0532749817ea538c253262a5e2a65c61 Gerrit-Change-Number: 24315 Gerrit-PatchSet: 11 Gerrit-Owner: Fang-Yu Rao <[email protected]> Gerrit-Reviewer: Abhishek Rawat <[email protected]> Gerrit-Reviewer: Csaba Ringhofer <[email protected]> Gerrit-Reviewer: Fang-Yu Rao <[email protected]> Gerrit-Reviewer: Impala Public Jenkins <[email protected]> Gerrit-Reviewer: Jason Fehr <[email protected]> Gerrit-Reviewer: Joe McDonnell <[email protected]> Gerrit-Reviewer: Michael Smith <[email protected]> Gerrit-Reviewer: Quanlong Huang <[email protected]> Gerrit-Reviewer: Yida Wu <[email protected]>
