Uploaded image for project: 'HBase'
  1. HBase
  2. HBASE-11452

add getUserPermission feature in AccessControlClient as client API

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Closed
    • Major
    • Resolution: Fixed
    • 0.98.0
    • 0.99.0, 0.98.4
    • Client, security
    • None
    • Reviewed

    Description

      Currently user can 'grant','revoke' and show 'user_permission' through hbase shell. And there are client api implemented in AccessControlClient.java for 'grant' and 'revoke'. This jira is to add the 'user_permission' feature with a new method called 'getUserPermission'

      To keep interface consistant, this jira will also update user_permission.rb to use this API directly. The test result is

      hbase(main):001:0> user_permission
      User                                                Table,Family,Qualifier:Permission                                                                                                                      
       hbase                                              dn:t1,,: [Permission: actions=READ,WRITE,EXEC,CREATE,ADMIN]                                                                                            
       biadmin                                            etest,,: [Permission: actions=READ,WRITE,EXEC,CREATE,ADMIN]                                                                                            
       hive                                               t1_dn,,: [Permission: actions=READ,WRITE]                                                                                                              
       biadmin                                            table1,,: [Permission: actions=READ,WRITE,EXEC,CREATE,ADMIN]                                                                                           
       biadmin                                            table2,,: [Permission: actions=READ,WRITE,EXEC,CREATE,ADMIN]                                                                                           
       biadmin                                            test_dn,,: [Permission: actions=READ,WRITE,EXEC,CREATE,ADMIN]                                                                                          
      6 row(s) in 1.6220 seconds
      
      hbase(main):002:0> user_permission 't.*'
      User                                                Table,Family,Qualifier:Permission                                                                                                                      
       hive                                               t1_dn,,: [Permission: actions=READ,WRITE]                                                                                                              
       biadmin                                            table1,,: [Permission: actions=READ,WRITE,EXEC,CREATE,ADMIN]                                                                                           
       biadmin                                            table2,,: [Permission: actions=READ,WRITE,EXEC,CREATE,ADMIN]                                                                                           
       biadmin                                            test_dn,,: [Permission: actions=READ,WRITE,EXEC,CREATE,ADMIN]                                                                                          
      4 row(s) in 0.2130 seconds
      
      hbase(main):003:0> user_permission 'dn:t1'
      User                                                Table,Family,Qualifier:Permission                                                                                                                      
       hbase                                              dn:t1,,: [Permission: actions=READ,WRITE,EXEC,CREATE,ADMIN]                                                                                            
      1 row(s) in 0.0790 seconds
      

      Attachments

        1. HBASE-11452-master-v0.patch
          9 kB
          Demai Ni
        2. HBASE-11452-master-v1.patch
          9 kB
          Demai Ni
        3. HBASE-11452-master-v1.patch
          9 kB
          Demai Ni
        4. HBASE-11452-master-v2.patch
          9 kB
          Demai Ni
        5. HBASE-11452-master-v3.patch
          9 kB
          Michael Stack

        Activity

          People

            nidmhbase Demai Ni
            nidmhbase Demai Ni
            Votes:
            0 Vote for this issue
            Watchers:
            7 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: