0 Replies Latest reply on Mar 9, 2011 8:52 PM by snkd

    Chimp Security

    snkd

      I need dinamically load previleges for FLEX UI.And i have store the action,role,componentId in DB.

      And I need to do as follow

       

      1. login -get authondication ()
      2. if success get user level (ex:ROLE_ADMIN,ROLE_USER)
      3. Then dinamically load previleges(that mean enable/disable buttons,visible/invisible forms,remove/add components from layout) according to values in my DB

       

      I am ok with 1 and 2 step with spring security.

      And I am trying to do 3rd step with chimp.But it is hardcording the previleges in source code.(But it is not hard cording ROLES)

      as like

       

      <fx:Metadata>
              [Protected(permissions="user",notInPermissionAction="disable",componentId="btnAdd")]
              [Protected(permissions="user",notInPermissionAction="disable",componentId="fmAdmin")]
              [Protected(permissions="user",notInPermissionAction="disable",componentId="fmUser")]
          </fx:Metadata>

       

      But when I want to change previleges I need to change my source code also.So that is not the way I expect.I wanna store it in a DB and load previleges.So Any ideas appreiciate?

      thnx for your time