[ https://issues.apache.org/jira/browse/HIVE-11498?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Dapeng Sun updated HIVE-11498: ------------------------------ Description: The queries like {{SELECT 1+1;}}, The target table and database will set to {{_dummy_database}} {{_dummy_table}}, authorization should skip these kinds of databases or tables. For authz v1. it has skip them. eg1. [Source code at github|https://github.com/apache/hive/blob/master/ql/src/java/org/apache/hadoop/hive/ql/Driver.java#L600] {noformat} for (WriteEntity write : outputs) { if (write.isDummy() || write.isPathType()) { continue; } {noformat} eg2. [Source code at github|https://github.com/apache/hive/blob/master/ql/src/java/org/apache/hadoop/hive/ql/Driver.java#L633] {noformat} for (ReadEntity read : inputs) { if (read.isDummy() || read.isPathType()) { continue; } ... } {noformat} ... This patch will fix authz v2. > HIVE Authorization v2 should not check permission for dummy entity > ------------------------------------------------------------------ > > Key: HIVE-11498 > URL: https://issues.apache.org/jira/browse/HIVE-11498 > Project: Hive > Issue Type: Bug > Reporter: Dapeng Sun > Assignee: Dapeng Sun > Attachments: HIVE-11498.001.patch, HIVE-11498.002.patch, > HIVE-11498.003.patch > > > The queries like {{SELECT 1+1;}}, The target table and database will set to > {{_dummy_database}} {{_dummy_table}}, authorization should skip these kinds > of databases or tables. > For authz v1. it has skip them. > eg1. [Source code at > github|https://github.com/apache/hive/blob/master/ql/src/java/org/apache/hadoop/hive/ql/Driver.java#L600] > {noformat} > for (WriteEntity write : outputs) { > if (write.isDummy() || write.isPathType()) { > continue; > } > {noformat} > eg2. [Source code at > github|https://github.com/apache/hive/blob/master/ql/src/java/org/apache/hadoop/hive/ql/Driver.java#L633] > {noformat} > for (ReadEntity read : inputs) { > if (read.isDummy() || read.isPathType()) { > continue; > } > ... > } > {noformat} > ... > This patch will fix authz v2. -- This message was sent by Atlassian JIRA (v6.3.4#6332)