Description of problem: Currently the only validation for JNDI names is: JNDI name has to start with 'java:/' or 'java:jboss/'. But user is able to enter just 'java:/' or 'java:jboss/' as JNDI name. Using this JNDI name for eg. data-source will lead to java.lang.IllegalArgumentException: Empty name segment is not allowed for jboss. Further more this data-source cannot be removed (expect deleting from XML directly). Version-Release number of selected component (if applicable): EAP 6.2.0.ER5 How reproducible: Always Steps to Reproduce: 1. Start out-of-box EAP 2. Connect to EAP eg. via web console 3. Add a new Datasource (use 'java:/' or 'java:jboss/' as JNDI name) 4. Enable the datasource Actual results: 13:26:02,708 ERROR [org.jboss.as.controller.management-operation] (HttpManagementService-threads - 2) JBAS014612: Operation ("enable") failed - address: ([ ("subsystem" => "datasources"), ("data-source" => "test") ]): java.lang.IllegalArgumentException: Empty name segment is not allowed for java Expected results: User is unable to use 'java:/' or 'java:jboss/' as JNDI name.
Corner case, so not a priority
https://github.com/wildfly/wildfly/pull/6738 upstream PR sent.
https://github.com/jbossas/jboss-eap/pull/1871
Verified on EAP 6.4.0.DR8