You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@sentry.apache.org by Arjun Mishra via Review Board <no...@reviews.apache.org> on 2018/11/20 19:47:19 UTC

Review Request 69415: SENTRY-2463: Revoking ALL or * should revoke any other privilege on the entity

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

Review request for sentry, kalyan kumar kalvagadda, Na Li, and Sergio Pena.


Bugs: SENTRY-2463
    https://issues.apache.org/jira/browse/SENTRY-2463


Repository: sentry


Description
-------

Right now if we initially grant ALL and revoke SELECT or INSERT, the privilege gets "modified" to INSERT or SELECT. However, conversely if we initially grant SELECT or INSERT and revoke ALL, no privileges are dropped


Diffs
-----

  sentry-service/sentry-service-server/src/main/java/org/apache/sentry/provider/db/service/persistent/SentryStore.java e2d6c85ac 
  sentry-tests/sentry-tests-hive/src/test/java/org/apache/sentry/tests/e2e/dbprovider/TestDatabaseProvider.java 6a7c1f392 


Diff: https://reviews.apache.org/r/69415/diff/1/


Testing
-------

mvn -f sentry-tests/sentry-tests-hive/pom.xml test -Dtest=TestDatabaseProvider
mvn -f sentry-service/sentry-service-server/pom.xml test -Dtest=TestSentryStore


Thanks,

Arjun Mishra


Re: Review Request 69415: SENTRY-2463: Revoking ALL or * should revoke any other privilege on the entity

Posted by Na Li via Review Board <no...@reviews.apache.org>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/69415/#review210870
-----------------------------------------------------------




sentry-tests/sentry-tests-hive/src/test/java/org/apache/sentry/tests/e2e/dbprovider/TestDatabaseProvider.java
Lines 2303 (patched)
<https://reviews.apache.org/r/69415/#comment295671>

    you should test "insert", "create" as well



sentry-tests/sentry-tests-hive/src/test/java/org/apache/sentry/tests/e2e/dbprovider/TestDatabaseProvider.java
Lines 2311 (patched)
<https://reviews.apache.org/r/69415/#comment295670>

    You don't need to close statement and connection for each command, and then created for the same user. You can do it only at the end of the test.



sentry-tests/sentry-tests-hive/src/test/java/org/apache/sentry/tests/e2e/dbprovider/TestDatabaseProvider.java
Lines 2350 (patched)
<https://reviews.apache.org/r/69415/#comment295672>

    test "insert" and "create"


- Na Li


On Nov. 20, 2018, 7:47 p.m., Arjun Mishra wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/69415/
> -----------------------------------------------------------
> 
> (Updated Nov. 20, 2018, 7:47 p.m.)
> 
> 
> Review request for sentry, kalyan kumar kalvagadda, Na Li, and Sergio Pena.
> 
> 
> Bugs: SENTRY-2463
>     https://issues.apache.org/jira/browse/SENTRY-2463
> 
> 
> Repository: sentry
> 
> 
> Description
> -------
> 
> Right now if we initially grant ALL and revoke SELECT or INSERT, the privilege gets "modified" to INSERT or SELECT. However, conversely if we initially grant SELECT or INSERT and revoke ALL, no privileges are dropped
> 
> 
> Diffs
> -----
> 
>   sentry-service/sentry-service-server/src/main/java/org/apache/sentry/provider/db/service/persistent/SentryStore.java e2d6c85ac 
>   sentry-tests/sentry-tests-hive/src/test/java/org/apache/sentry/tests/e2e/dbprovider/TestDatabaseProvider.java 6a7c1f392 
> 
> 
> Diff: https://reviews.apache.org/r/69415/diff/1/
> 
> 
> Testing
> -------
> 
> mvn -f sentry-tests/sentry-tests-hive/pom.xml test -Dtest=TestDatabaseProvider
> mvn -f sentry-service/sentry-service-server/pom.xml test -Dtest=TestSentryStore
> 
> 
> Thanks,
> 
> Arjun Mishra
> 
>