Uploaded image for project: 'WildFly Core'
  1. WildFly Core
  2. WFCORE-1077

Properties authentication in Security Realms does not work with equals sign in password

    XMLWordPrintable

Details

    • Bug
    • Resolution: Done
    • Major
    • 2.0.2.Final
    • 2.0.0.CR8
    • Management, Security
    • None
    • Hide

      1. Create users.properties file with content:

      user5=Pass\=word1
      

      2. Add following security realm to standalone.xml (set path to users.properties file instead of PATH_TO_USERS_PROPERTIES):

      <security-realm name="delimiters-test">
          <authentication>
              <properties path="PATH_TO_USERS_PROPERTIES" plain-text="true"/>
          </authentication>
      </security-realm>
      

      3. Set "delimiters-test" security realm for http-interface:

      <http-interface security-realm="delimiters-test" http-upgrade-enabled="true">
      

      4. Start server

      Security realm delimiters-test is not started.

      Show
      1. Create users.properties file with content: user5=Pass\=word1 2. Add following security realm to standalone.xml (set path to users.properties file instead of PATH_TO_USERS_PROPERTIES): <security-realm name= "delimiters-test" > <authentication> <properties path= "PATH_TO_USERS_PROPERTIES" plain-text= "true" /> </authentication> </security-realm> 3. Set "delimiters-test" security realm for http-interface: <http-interface security-realm= "delimiters-test" http-upgrade-enabled= "true" > 4. Start server Security realm delimiters-test is not started.

    Description

      Security realm doesnt start in case when password contains "\=" e.g.

      user5=Pass\=word1

      .

      Thrown exception is

      ^[[0m^[[31m07:00:10,342 ERROR [org.jboss.msc.service.fail] (MSC service thread 1-6) MSC000001: Failed to start service jboss.server.controller.management.security_realm.DelimitersRealm.properties_authentication: org.jboss.msc.service.StartException in service jboss.server.controller.management.security_realm.DelimitersRealm.properties_authentication: Failed to start service
              at org.jboss.msc.service.ServiceControllerImpl$StartTask.run(ServiceControllerImpl.java:1904)
              at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
              at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
              at java.lang.Thread.run(Thread.java:745)
      Caused by: java.lang.ArrayIndexOutOfBoundsException: 11
              at org.jboss.as.domain.management.security.PropertiesFileLoader.cleanKey(PropertiesFileLoader.java:236)
              at org.jboss.as.domain.management.security.UserPropertiesFileLoader.load(UserPropertiesFileLoader.java:106)
              at org.jboss.as.domain.management.security.PropertiesFileLoader.loadAsRequired(PropertiesFileLoader.java:164)
              at org.jboss.as.domain.management.security.PropertiesFileLoader.getProperties(PropertiesFileLoader.java:144)
              at org.jboss.as.domain.management.security.PropertiesFileLoader.start(PropertiesFileLoader.java:131)
              at org.jboss.as.domain.management.security.PropertiesCallbackHandler.start(PropertiesCallbackHandler.java:128)
              at org.jboss.msc.service.ServiceControllerImpl$StartTask.startService(ServiceControllerImpl.java:1948)
              at org.jboss.msc.service.ServiceControllerImpl$StartTask.run(ServiceControllerImpl.java:1881)
              ... 3 more
      

      Attachments

        Issue Links

          Activity

            People

              darran.lofthouse@redhat.com Darran Lofthouse
              mchoma@redhat.com Martin Choma
              Martin Choma Martin Choma
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: