-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/69987/
-----------------------------------------------------------

(Updated Feb. 21, 2019, 8:17 p.m.)


Review request for sentry, Arjun Mishra, kalyan kumar kalvagadda, and Na Li.


Changes
-------

Changed logic so that the HiveAuthzConf is not needed. Instead if scheme is 
null, check if the URI path is absolute and if so return true.


Repository: sentry


Description
-------

The "show grant role" logic tries to use a URI's scheme to tell whether it's a 
local URI or a DFS URI. However, it's valid for the scheme to be undefined. In 
that case Sentry throws a NPE because it's trying to access a null scheme.

The logic has been updated to instead use the default filesystem set in the 
"fs.defaultFS" property if the scheme is not defined.


Diffs (updated)
-----

  
sentry-binding/sentry-binding-hive/src/main/java/org/apache/sentry/binding/util/SentryAuthorizerUtil.java
 5996b6c 


Diff: https://reviews.apache.org/r/69987/diff/2/

Changes: https://reviews.apache.org/r/69987/diff/1-2/


Testing
-------

Created and ran testShowGrantWithNullScheme() unit test. Checked that test 
fails without code change, and succeeds with code change.


Thanks,

Haley Reeve

Reply via email to