Uploaded image for project: 'Infinispan'
  1. Infinispan
  2. ISPN-10219

security session doc with wrong declarative configuration

XMLWordPrintable

      Session 23.1.3. Embedded Configuration has some wrong declarative configurations.
      The following declarative configuration has some errors:

      <cache-container default-cache="secured">
         <security>
            <authorization enabled="true">
               <identity-role-mapper />
               <role name="admin" permissions="ALL" />
               <role name="reader" permissions="READ" />
               <role name="writer" permissions="WRITE" />
               <role name="supervisor" permissions="READ WRITE EXEC BULK" />
            </authorization>
         </security>
         <local-cache name="secured">
            <security>
               <authorization roles="admin reader writer supervisor" />
            </security>
         </local-cache>
      </cache-container>
      
      1. name attribute is mandatory into cache-container
      2. 'enabled' isn't an allowed attribute for the 'authorization' element. The 'authorization' element doesn't allow any attributes
      3. There's no permission BULK

      The XML should be like this:

      <cache-container name="secure" default-cache="secured">
         <security>
            <authorization>
               <identity-role-mapper />
               <role name="admin" permissions="ALL" />
               <role name="reader" permissions="READ" />
               <role name="writer" permissions="WRITE" />
               <role name="supervisor" permissions="READ WRITE EXEC" />
            </authorization>
         </security>
         <local-cache name="secured">
            <security>
               <authorization roles="admin reader writer supervisor" />
            </security>
         </local-cache>
      </cache-container>
      

              gustavolira Gustavo Lira Silva
              gustavolira Gustavo Lira Silva
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

                Created:
                Updated:
                Resolved: