Uploaded image for project: 'Red Hat Data Grid'
  1. Red Hat Data Grid
  2. JDG-7450

[RESP] User with no authorization to default cache (alias 0) is unable to access any other cache

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Unresolved
    • Icon: Major Major
    • None
    • RHDG 8.5.1 GA, RHDG 8.5.x CD
    • None
    • False
    • None
    • False

      Consider two RESP caches bellow and two users admin and observer. Observer is unable to use the second caches even though they have authorization to do so as they are always refused access to the cache 0 and thus forbidden from any other actions as changing DB.

      Caches:

      <distributed-cache name="respCache" aliases="0" owners="2" mode="ASYNC" statistics="true" key-partitioner="org.infinispan.distribution.ch.impl.RESPHashFunctionPartitioner">
               <encoding media-type="application/octet-stream"/>
               <security>
                  <authorization roles="admin"/>
               </security>
            </distributed-cache>
            <distributed-cache name="respCacheAlt" aliases="1" owners="2" mode="ASYNC" statistics="true" key-partitioner="org.infinispan.distribution.ch.impl.RESPHashFunctionPartitioner">
               <encoding media-type="application/octet-stream"/>
               <security>
                  <authorization roles="admin observer"/>
               </security>
            </distributed-cache>
      

      Setup:

      $ ${ISPN_HOME}/bin/cli.sh user create admin -p admin -g admin
      $ ${ISPN_HOME}/bin/cli.sh user create observer -p observer -g observer
      $ ${ISPN_HOME}/bin/server.sh
      

      Reproducer:

      $ redis-cli -p 11222 --user observer --pass observer
      Warning: Using a password with '-a' or '-u' option on the command line interface may not be safe.
      AUTH failed: WRONGPASS invalid username-password pair or user is disabled.
      ...
      $ redis-cli -p 11222 --user observer --pass observer -n 1
      Warning: Using a password with '-a' or '-u' option on the command line interface may not be safe.
      AUTH failed: WRONGPASS invalid username-password pair or user is disabled.
      ...
      $ redis-cli -p 11222
      127.0.0.1:11222> select 1
      (error) WRONGPASS invalid username-password pair or user is disabled.
      ...
      $ redis-cli -p 11222
      127.0.0.1:11222> auth observer observer
      (error) WRONGPASS invalid username-password pair or user is disabled.
      

              ttarrant@redhat.com Tristan Tarrant
              rhn-support-pdrobek Pavel Drobek
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

                Created:
                Updated: