Uploaded image for project: 'ZooKeeper'
  1. ZooKeeper
  2. ZOOKEEPER-1673

Zookeeper don't support cidr in expression in ACL with ip scheme

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Minor
    • Resolution: Fixed
    • 3.4.5
    • 3.5.0
    • None

    Description

      Currently, when i try to set ACL with cidr in expression, i get exception:

      [zk: localhost:2181(CONNECTED) 2] setAcl /AS0 ip:127.0.0.1/8:cdrwa
      Exception in thread "main" org.apache.zookeeper.KeeperException$InvalidACLException: KeeperErrorCode = InvalidACL for /AS0
      	at org.apache.zookeeper.KeeperException.create(KeeperException.java:112)
      	at org.apache.zookeeper.KeeperException.create(KeeperException.java:42)
      	at org.apache.zookeeper.ZooKeeper.setACL(ZooKeeper.java:1175)
      	at org.apache.zookeeper.ZooKeeperMain.processZKCmd(ZooKeeperMain.java:716)
      	at org.apache.zookeeper.ZooKeeperMain.processCmd(ZooKeeperMain.java:581)
      	at org.apache.zookeeper.ZooKeeperMain.executeLine(ZooKeeperMain.java:353)
      	at org.apache.zookeeper.ZooKeeperMain.run(ZooKeeperMain.java:311)
      	at org.apache.zookeeper.ZooKeeperMain.main(ZooKeeperMain.java:270)
      

      Also, there is no support for CIDR in IPAuthenticationProvider.isValid, but IPAuthenticationProvider.matches has it.

      Attachments

        1. ZOOKEEPER-1673.patch
          3 kB
          Craig Condit
        2. ZOOKEEPER-1673.patch
          2 kB
          Craig Condit
        3. ZOOKEEPER-1673.patch
          2 kB
          Craig Condit

        Activity

          People

            ccondit Craig Condit
            blackwithwhite666 Lipin Dmitriy
            Votes:
            1 Vote for this issue
            Watchers:
            7 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: