You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@ranger.apache.org by Alok Lal <al...@hortonworks.com> on 2016/03/12 01:58:04 UTC

Review Request 44744: Scrub received policies before policy engine uses it to guard against inadvertant data corruption: remove null policy resource values

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

Review request for ranger and Madhan Neethiraj.


Bugs: RANGER-822
    https://issues.apache.org/jira/browse/RANGER-822


Repository: ranger


Description
-------

Scrub null values from policy resource before policy evaluators use them.


Diffs
-----

  agents-common/src/main/java/org/apache/ranger/plugin/policyengine/RangerPolicyEngineImpl.java 92481f6 

Diff: https://reviews.apache.org/r/44744/diff/


Testing
-------

Reproduced the problem and tested the fix in an older version of the code.  Checked that WARNING messsages shows up containing the policy id and resource level to identify the problem source.

Apache JIRA seems to be down currently.  I'll update it with review request once I can get at it.


Thanks,

Alok Lal


Re: Review Request 44744: Scrub received policies before policy engine uses it to guard against inadvertant data corruption: remove null policy resource values

Posted by Madhan Neethiraj <ma...@apache.org>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/44744/#review124094
-----------------------------------------------------------


Ship it!




Ship It!

- Madhan Neethiraj


On March 17, 2016, 7:38 p.m., Alok Lal wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/44744/
> -----------------------------------------------------------
> 
> (Updated March 17, 2016, 7:38 p.m.)
> 
> 
> Review request for ranger and Madhan Neethiraj.
> 
> 
> Bugs: RANGER-882
>     https://issues.apache.org/jira/browse/RANGER-882
> 
> 
> Repository: ranger
> 
> 
> Description
> -------
> 
> Scrub null values from policy resource before policy evaluators use them.
> 
> 
> Diffs
> -----
> 
>   agents-common/src/main/java/org/apache/ranger/plugin/service/RangerBasePlugin.java b864e61 
> 
> Diff: https://reviews.apache.org/r/44744/diff/
> 
> 
> Testing
> -------
> 
> Reproduced the problem and tested the fix in an older version of the code.  Checked that WARNING messsages shows up containing the policy id and resource level to identify the problem source.
> 
> Apache JIRA seems to be down currently.  I'll update it with review request once I can get at it.
> 
> 
> Thanks,
> 
> Alok Lal
> 
>


Re: Review Request 44744: Scrub received policies before policy engine uses it to guard against inadvertant data corruption: remove null policy resource values

Posted by Alok Lal <al...@hortonworks.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/44744/
-----------------------------------------------------------

(Updated March 17, 2016, 12:38 p.m.)


Review request for ranger and Madhan Neethiraj.


Changes
-------

Moved preCleanup() into try-catch block.


Bugs: RANGER-882
    https://issues.apache.org/jira/browse/RANGER-882


Repository: ranger


Description
-------

Scrub null values from policy resource before policy evaluators use them.


Diffs (updated)
-----

  agents-common/src/main/java/org/apache/ranger/plugin/service/RangerBasePlugin.java b864e61 

Diff: https://reviews.apache.org/r/44744/diff/


Testing
-------

Reproduced the problem and tested the fix in an older version of the code.  Checked that WARNING messsages shows up containing the policy id and resource level to identify the problem source.

Apache JIRA seems to be down currently.  I'll update it with review request once I can get at it.


Thanks,

Alok Lal


Re: Review Request 44744: Scrub received policies before policy engine uses it to guard against inadvertant data corruption: remove null policy resource values

Posted by Madhan Neethiraj <ma...@apache.org>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/44744/#review124083
-----------------------------------------------------------




agents-common/src/main/java/org/apache/ranger/plugin/service/RangerBasePlugin.java (line 119)
<https://reviews.apache.org/r/44744/#comment186421>

    I think it will be safer to move preCleanup() call into try block.


- Madhan Neethiraj


On March 17, 2016, 7:25 p.m., Alok Lal wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/44744/
> -----------------------------------------------------------
> 
> (Updated March 17, 2016, 7:25 p.m.)
> 
> 
> Review request for ranger and Madhan Neethiraj.
> 
> 
> Bugs: RANGER-882
>     https://issues.apache.org/jira/browse/RANGER-882
> 
> 
> Repository: ranger
> 
> 
> Description
> -------
> 
> Scrub null values from policy resource before policy evaluators use them.
> 
> 
> Diffs
> -----
> 
>   agents-common/src/main/java/org/apache/ranger/plugin/service/RangerBasePlugin.java b864e61 
> 
> Diff: https://reviews.apache.org/r/44744/diff/
> 
> 
> Testing
> -------
> 
> Reproduced the problem and tested the fix in an older version of the code.  Checked that WARNING messsages shows up containing the policy id and resource level to identify the problem source.
> 
> Apache JIRA seems to be down currently.  I'll update it with review request once I can get at it.
> 
> 
> Thanks,
> 
> Alok Lal
> 
>


Re: Review Request 44744: Scrub received policies before policy engine uses it to guard against inadvertant data corruption: remove null policy resource values

Posted by Alok Lal <al...@hortonworks.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/44744/
-----------------------------------------------------------

(Updated March 17, 2016, 12:25 p.m.)


Review request for ranger and Madhan Neethiraj.


Changes
-------

Added an overall try/catch for the policy engine initialization – to ensure that the plugin will continue to pull policies periodically, even if the initialization hits any issue.


Bugs: RANGER-882
    https://issues.apache.org/jira/browse/RANGER-882


Repository: ranger


Description
-------

Scrub null values from policy resource before policy evaluators use them.


Diffs (updated)
-----

  agents-common/src/main/java/org/apache/ranger/plugin/service/RangerBasePlugin.java b864e61 

Diff: https://reviews.apache.org/r/44744/diff/


Testing
-------

Reproduced the problem and tested the fix in an older version of the code.  Checked that WARNING messsages shows up containing the policy id and resource level to identify the problem source.

Apache JIRA seems to be down currently.  I'll update it with review request once I can get at it.


Thanks,

Alok Lal


Re: Review Request 44744: Scrub received policies before policy engine uses it to guard against inadvertant data corruption: remove null policy resource values

Posted by Alok Lal <al...@hortonworks.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/44744/
-----------------------------------------------------------

(Updated March 11, 2016, 5:43 p.m.)


Review request for ranger and Madhan Neethiraj.


Changes
-------

Corrected the BUG number on the review.


Bugs: RANGER-882
    https://issues.apache.org/jira/browse/RANGER-882


Repository: ranger


Description
-------

Scrub null values from policy resource before policy evaluators use them.


Diffs
-----

  agents-common/src/main/java/org/apache/ranger/plugin/policyengine/RangerPolicyRepository.java e79b5cd 

Diff: https://reviews.apache.org/r/44744/diff/


Testing
-------

Reproduced the problem and tested the fix in an older version of the code.  Checked that WARNING messsages shows up containing the policy id and resource level to identify the problem source.

Apache JIRA seems to be down currently.  I'll update it with review request once I can get at it.


Thanks,

Alok Lal


Re: Review Request 44744: Scrub received policies before policy engine uses it to guard against inadvertant data corruption: remove null policy resource values

Posted by Madhan Neethiraj <ma...@apache.org>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/44744/#review123250
-----------------------------------------------------------


Fix it, then Ship it!





agents-common/src/main/java/org/apache/ranger/plugin/policyengine/RangerPolicyRepository.java (line 471)
<https://reviews.apache.org/r/44744/#comment185459>

    "<==" -> "==>"



agents-common/src/main/java/org/apache/ranger/plugin/policyengine/RangerPolicyRepository.java (line 477)
<https://reviews.apache.org/r/44744/#comment185458>

    level ==> resourceName


- Madhan Neethiraj


On March 12, 2016, 1:26 a.m., Alok Lal wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/44744/
> -----------------------------------------------------------
> 
> (Updated March 12, 2016, 1:26 a.m.)
> 
> 
> Review request for ranger and Madhan Neethiraj.
> 
> 
> Bugs: RANGER-822
>     https://issues.apache.org/jira/browse/RANGER-822
> 
> 
> Repository: ranger
> 
> 
> Description
> -------
> 
> Scrub null values from policy resource before policy evaluators use them.
> 
> 
> Diffs
> -----
> 
>   agents-common/src/main/java/org/apache/ranger/plugin/policyengine/RangerPolicyRepository.java e79b5cd 
> 
> Diff: https://reviews.apache.org/r/44744/diff/
> 
> 
> Testing
> -------
> 
> Reproduced the problem and tested the fix in an older version of the code.  Checked that WARNING messsages shows up containing the policy id and resource level to identify the problem source.
> 
> Apache JIRA seems to be down currently.  I'll update it with review request once I can get at it.
> 
> 
> Thanks,
> 
> Alok Lal
> 
>


Re: Review Request 44744: Scrub received policies before policy engine uses it to guard against inadvertant data corruption: remove null policy resource values

Posted by Alok Lal <al...@hortonworks.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/44744/
-----------------------------------------------------------

(Updated March 11, 2016, 5:26 p.m.)


Review request for ranger and Madhan Neethiraj.


Changes
-------

Moved to just before policy evaluator creation to deal with both tag and resource based policies.


Bugs: RANGER-822
    https://issues.apache.org/jira/browse/RANGER-822


Repository: ranger


Description
-------

Scrub null values from policy resource before policy evaluators use them.


Diffs (updated)
-----

  agents-common/src/main/java/org/apache/ranger/plugin/policyengine/RangerPolicyRepository.java e79b5cd 

Diff: https://reviews.apache.org/r/44744/diff/


Testing
-------

Reproduced the problem and tested the fix in an older version of the code.  Checked that WARNING messsages shows up containing the policy id and resource level to identify the problem source.

Apache JIRA seems to be down currently.  I'll update it with review request once I can get at it.


Thanks,

Alok Lal