Uploaded image for project: 'JBoss Enterprise Application Platform'
  1. JBoss Enterprise Application Platform
  2. JBEAP-10608

[7.1] The org.jboss.security.auth.spi.SimpleServerLoginModule does not add role 'admin' when username equals password

    XMLWordPrintable

Details

    Description

      Document URL:

      https://access.redhat.com/documentation/en-us/red_hat_jboss_enterprise_application_platform/7.0/html-single/login_module_reference/#simple_login_module

      Section Number and Name:

      3.7. SIMPLE LOGIN MODULE

      Describe the issue:

      As the documentation is saying :

      • if the password is equal to the user, assign an identity equal to the username and both admin and guest roles.

      But as per the code it never adds 'admin' role :

      protected Group[] getRoleSets() throws LoginException
      {
      Group[] roleSets =

      {new SimpleGroup("Roles")}

      ;
      if( guestOnly == false )
      roleSets[0].addMember(new SimplePrincipal("user"));
      roleSets[0].addMember(new SimplePrincipal("guest"));
      return roleSets;
      }

      Suggestions for improvement:

      Instead of 'admin' role there should be 'user' role .

      Attachments

        Issue Links

          Activity

            People

              sgilda_jira Sande Gilda (Inactive)
              rhn-support-iingawal Indrajit Ingawale
              Ondrej Lukas Ondrej Lukas (Inactive)
              Ondrej Lukas Ondrej Lukas (Inactive)
              Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: