Uploaded image for project: 'Geronimo'
  1. Geronimo
  2. GERONIMO-409

SQLSecurityRealm/SQLLoginModule needs overhaul

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Critical
    • Resolution: Fixed
    • 1.0-M2
    • 1.0
    • security
    • None

    Description

      The SQLSecurityRealm and SQLLoginModule do not scale. In particular, they load all users and all groups in the security realm once when the realm is started, and again for every login request. Imagine a database of thousands of users/groups.

      There should instead be required SQL queries to load a single password given a username, and to load a list of groups for a single user given a username. Then there can be optional SQL queries to load a list of all users or to load a list of all groups, though we still shouldn't care who the group members are.

      Also, it appears that the digesting features provided by SQLSecurityRealmPasswordDigested are never invoked, so that class has no effect. It seems like the best way to implement digesting would be to make the basic SQLLoginModule take a digest algorithm argument. If present, the SQLLoginModule could instantiate and use a digester on the incoming password (and if not, not). Then we don't need any extra class for it, and you could enable digesting simply by adding a login module configuration option.

      Attachments

        1. sqlwithusernamepar.patch
          1 kB
          Vamsavardhana Reddy

        Activity

          People

            djencks David Jencks
            ammulder Aaron Mulder
            Votes:
            2 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: