<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>question Documentation: Ranger policy json example incorrect HDFS and Hive example in Archives of Support Questions (Read Only)</title>
    <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/Documentation-Ranger-policy-json-example-incorrect-HDFS-and/m-p/140098#M56264</link>
    <description>&lt;P&gt;The Create Policy Json request example given for HDFS and Hive seems to be incorrect. This applies to both 2.4 and 2.5 documentation. &lt;/P&gt;&lt;P&gt;&lt;A href="https://docs.hortonworks.com/HDPDocuments/HDP2/HDP-2.4.3/bk_Security_Guide/content/ranger_rest_api_create_policy.html" target="_blank"&gt;https://docs.hortonworks.com/HDPDocuments/HDP2/HDP-2.4.3/bk_Security_Guide/content/ranger_rest_api_create_policy.html&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="http://docs.hortonworks.com/HDPDocuments/HDP2/HDP-2.5.0/bk_security/content/ranger_rest_api_create_policy.html" target="_blank"&gt;http://docs.hortonworks.com/HDPDocuments/HDP2/HDP-2.5.0/bk_security/content/ranger_rest_api_create_policy.html&lt;/A&gt;&lt;/P&gt;&lt;P&gt;1) The HDFS example request json lists "SELECT", "UPDATE" .. as permissions for hdfs resources which is wrong. HDFS resources has only "read","write","execute".. as allowed permissions.&lt;/P&gt;&lt;P&gt;2) The Hive example request json lists "Select", "Update"... as permissions with uppercase starting letter. This is not working. It works only when these are given in all lower case like "select", "update"...&lt;/P&gt;</description>
    <pubDate>Mon, 06 Mar 2017 19:58:10 GMT</pubDate>
    <dc:creator>nmahadevuni1</dc:creator>
    <dc:date>2017-03-06T19:58:10Z</dc:date>
    <item>
      <title>Documentation: Ranger policy json example incorrect HDFS and Hive example</title>
      <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/Documentation-Ranger-policy-json-example-incorrect-HDFS-and/m-p/140098#M56264</link>
      <description>&lt;P&gt;The Create Policy Json request example given for HDFS and Hive seems to be incorrect. This applies to both 2.4 and 2.5 documentation. &lt;/P&gt;&lt;P&gt;&lt;A href="https://docs.hortonworks.com/HDPDocuments/HDP2/HDP-2.4.3/bk_Security_Guide/content/ranger_rest_api_create_policy.html" target="_blank"&gt;https://docs.hortonworks.com/HDPDocuments/HDP2/HDP-2.4.3/bk_Security_Guide/content/ranger_rest_api_create_policy.html&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="http://docs.hortonworks.com/HDPDocuments/HDP2/HDP-2.5.0/bk_security/content/ranger_rest_api_create_policy.html" target="_blank"&gt;http://docs.hortonworks.com/HDPDocuments/HDP2/HDP-2.5.0/bk_security/content/ranger_rest_api_create_policy.html&lt;/A&gt;&lt;/P&gt;&lt;P&gt;1) The HDFS example request json lists "SELECT", "UPDATE" .. as permissions for hdfs resources which is wrong. HDFS resources has only "read","write","execute".. as allowed permissions.&lt;/P&gt;&lt;P&gt;2) The Hive example request json lists "Select", "Update"... as permissions with uppercase starting letter. This is not working. It works only when these are given in all lower case like "select", "update"...&lt;/P&gt;</description>
      <pubDate>Mon, 06 Mar 2017 19:58:10 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Archives-of-Support-Questions/Documentation-Ranger-policy-json-example-incorrect-HDFS-and/m-p/140098#M56264</guid>
      <dc:creator>nmahadevuni1</dc:creator>
      <dc:date>2017-03-06T19:58:10Z</dc:date>
    </item>
    <item>
      <title>Re: Documentation: Ranger policy json example incorrect HDFS and Hive example</title>
      <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/Documentation-Ranger-policy-json-example-incorrect-HDFS-and/m-p/140099#M56265</link>
      <description>&lt;P&gt;&lt;A href="https://community.hortonworks.com/users/12851/nmahadevuni.html"&gt;Naveen Kumar Mahadevuni&lt;/A&gt; you first point is valid, example for hdfs and hive seems to be wrong ,thanks for pointing it out, our documentation team will fix it soon.&lt;/P&gt;&lt;P&gt;but I tried the second point you mentioned , passing uppercase starting letter in input json and it worked for me.&lt;/P&gt;&lt;PRE&gt;{
    "allowExceptions": [],
    "denyExceptions": [],
    "denyPolicyItems": [
        {
            "accesses": [
                {
                    "isAllowed": true,
                    "type": "drop"
                }
            ],
            "conditions": [],
            "delegateAdmin": true,
            "groups": [],
            "users": [
        "user1"
            ]
        }
    ],
    "description": "Policy for Service: cl1_test",
    "isAuditEnabled": true,
    "isEnabled": true,
    "name": "cl1_test-3",
    "policyItems": [
        {
            "accesses": [
                {
                    "isAllowed": true,
                    "type": "Select"
                },
                {
                    "isAllowed": true,
                    "type": "Update"
                },
                {
                    "isAllowed": true,
                    "type": "Create"
                },
                {
                    "isAllowed": true,
                    "type": "Drop"
                }
            ],
            "conditions": [],
            "delegateAdmin": true,
            "groups": ["public"],
            "users": [
            ]
        }
    ],
    "resources": {
        "database": {
            "isExcludes": false,
            "isRecursive": false,
            "values": [
                "abcd"
            ]
        },
        "table": {
            "isExcludes": false,
            "isRecursive": false,
            "values": [
                "*"
            ]
        },
        "column": {
            "isExcludes": false,
            "isRecursive": false,
            "values": [
                "*"
            ]
        }
    },
    "service": "hive_repo",
    "version": 1
}&lt;/PRE&gt;&lt;P&gt;can you please make sure you are using public v2 apis , and for time being following wiki will help you in ranger rest api calls:&lt;/P&gt;&lt;P&gt;&lt;A href="https://cwiki.apache.org/confluence/display/RANGER/REST+APIs+for+Service+Definition%2C+Service+and+Policy+Management#RESTAPIsforServiceDefinition,ServiceandPolicyManagement-CreatePolicy" target="_blank"&gt;https://cwiki.apache.org/confluence/display/RANGER/REST+APIs+for+Service+Definition%2C+Service+and+Policy+Management#RESTAPIsforServiceDefinition,ServiceandPolicyManagement-CreatePolicy&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 06 Mar 2017 20:31:21 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Archives-of-Support-Questions/Documentation-Ranger-policy-json-example-incorrect-HDFS-and/m-p/140099#M56265</guid>
      <dc:creator>dsharma</dc:creator>
      <dc:date>2017-03-06T20:31:21Z</dc:date>
    </item>
    <item>
      <title>Re: Documentation: Ranger policy json example incorrect HDFS and Hive example</title>
      <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/Documentation-Ranger-policy-json-example-incorrect-HDFS-and/m-p/140100#M56266</link>
      <description>&lt;P&gt;Thanks &lt;A rel="user" href="https://community.cloudera.com/users/505/dsharma.html" nodeid="505"&gt;@Deepak Sharma&lt;/A&gt;. We are using HDP 2.4. Documentation has no mention of v2 api. &lt;/P&gt;</description>
      <pubDate>Mon, 06 Mar 2017 20:49:28 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Archives-of-Support-Questions/Documentation-Ranger-policy-json-example-incorrect-HDFS-and/m-p/140100#M56266</guid>
      <dc:creator>nmahadevuni1</dc:creator>
      <dc:date>2017-03-06T20:49:28Z</dc:date>
    </item>
    <item>
      <title>Re: Documentation: Ranger policy json example incorrect HDFS and Hive example</title>
      <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/Documentation-Ranger-policy-json-example-incorrect-HDFS-and/m-p/140101#M56267</link>
      <description>&lt;P&gt;Thanks &lt;A rel="user" href="https://community.cloudera.com/users/12851/nmahadevuni.html" nodeid="12851"&gt;@Naveen Kumar Mahadevuni&lt;/A&gt; &amp;amp; &lt;A rel="user" href="https://community.cloudera.com/users/505/dsharma.html" nodeid="505"&gt;@Deepak Sharma&lt;/A&gt;, we will update the docs ASAP.&lt;/P&gt;</description>
      <pubDate>Mon, 06 Mar 2017 23:35:07 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Archives-of-Support-Questions/Documentation-Ranger-policy-json-example-incorrect-HDFS-and/m-p/140101#M56267</guid>
      <dc:creator>dhoyle</dc:creator>
      <dc:date>2017-03-06T23:35:07Z</dc:date>
    </item>
  </channel>
</rss>

