Uploaded image for project: 'Hive'
  1. Hive
  2. HIVE-11179

HIVE should allow custom converting from HivePrivilegeObjectDesc to privilegeObject for different authorizers

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Closed
    • Major
    • Resolution: Fixed
    • None
    • 1.3.0, 2.0.0
    • None

    Description

      HIVE should allow custom converting from HivePrivilegeObjectDesc to privilegeObject for different authorizers:

      There is a case in Apache Sentry: Sentry support uri and server level privilege, but in hive side, it uses AuthorizationUtils.getHivePrivilegeObject(privSubjectDesc) to do the converting, and the code in getHivePrivilegeObject() only handle the scenes for table and database

      privSubjectDesc.getTable() ? HivePrivilegeObjectType.TABLE_OR_VIEW :
              HivePrivilegeObjectType.DATABASE;
      

      A solution is move this method to HiveAuthorizer, so that a custom Authorizer could enhance it.

      Attachments

        1. HIVE-11179.001.patch
          7 kB
          Dapeng Sun
        2. HIVE-11179.001.patch
          7 kB
          Ferdinand Xu

        Issue Links

          Activity

            People

              dapengsun Dapeng Sun
              dapengsun Dapeng Sun
              Votes:
              0 Vote for this issue
              Watchers:
              7 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: