Bug 1377818 - [GSS](6.4.z) Unable to use property substitution for remote.connection.default.password in jboss-ejb-client.properties
Summary: [GSS](6.4.z) Unable to use property substitution for remote.connection.defaul...
Keywords:
Status: CLOSED NOTABUG
Alias: None
Product: JBoss Enterprise Application Platform 6
Classification: JBoss
Component: EJB, Remoting
Version: 6.4.9
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
: ---
Assignee: Radovan Netuka
QA Contact: Jan Martiska
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2016-09-20 16:49 UTC by Ranjith Pulluru
Modified: 2019-12-16 06:50 UTC (History)
3 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2017-01-18 16:10:18 UTC
Type: Bug


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Knowledge Base (Solution) 2625841 0 None None None 2016-09-20 16:59:42 UTC

Description Ranjith Pulluru 2016-09-20 16:49:09 UTC
Description of problem:
=======================
1) Remote EJB invocation with jboss-ejb-client.properties file.

2) I used a placeholder for the property `remote.connection.default.password` in jboss-ejb-client.properties

-------- content in  jboss-ejb-client.properties ---------------
remote.connections=default
remote.connection.default.host=10.65.193.6
remote.connection.default.port=4447
remote.connection.default.username=test_user
remote.connection.default.password=${test_password}
----------------------------------------------------------------

3) and started the ejb client as below:
---------
 java -Dtest_password=test@123 com.client.RemoteEJBClient
--------- 

4) but ejb client unable to connect to remote ejb.


Version-Release number of selected component (if applicable):
==============================================================
- JBoss EAP 6.4.x


Actual results:
===============
- Below exception is thrown at client side:
------------
[rpulluru@rpulluru Client]$ java -Dtest_password=test@123 com.client.RemoteEJBClient

Sep 20, 2016 10:05:34 PM org.jboss.ejb.client.EJBClient <clinit>
INFO: JBoss EJB Client version 1.0.35.Final-redhat-1
		:
INFO: JBoss Remoting version 3.3.8.Final-redhat-1
Sep 20, 2016 10:05:35 PM org.jboss.ejb.client.remoting.ConfigBasedEJBClientContextSelector setupEJBReceivers
WARN: Could not register a EJB receiver for connection to 10.65.193.6:4447
javax.security.sasl.SaslException: Authentication failed: the server presented no authentication mechanisms
	at org.jboss.remoting3.remote.ClientConnectionOpenListener$Capabilities.handleEvent(ClientConnectionOpenListener.java:389)
	at org.jboss.remoting3.remote.ClientConnectionOpenListener$Capabilities.handleEvent(ClientConnectionOpenListener.java:243)

------------

Expected results:
=================
----------------------
[rpulluru@rpulluru Client]$ java -Dtest_password=test@123 com.client.RemoteEJBClient

Sep 20, 2016 10:05:56 PM org.jboss.ejb.client.EJBClient <clinit>
INFO: JBoss EJB Client version 1.0.35.Final-redhat-1
		:
INFO: JBoss Remoting version 3.3.8.Final-redhat-1
Sep 20, 2016 10:05:57 PM org.jboss.ejb.client.remoting.VersionReceiver handleMessage
INFO: EJBCLIENT000017: Received server version 2 and marshalling strategies [river]
Sep 20, 2016 10:05:57 PM org.jboss.ejb.client.remoting.RemotingConnectionEJBReceiver associate
INFO: EJBCLIENT000013: Successful version handshake completed for receiver context EJBReceiverContext{clientContext=org.jboss.ejb.client.EJBClientContext@7c0e2abd, receiver=Remoting connection EJB receiver [connection=org.jboss.ejb.client.remoting.ConnectionPool$PooledConnection@48eff760,channel=jboss.ejb,nodename=anijhawa]} on channel Channel ID ae2394af (outbound) of Remoting connection 3d331e1f to /10.65.193.6:4447
-----------------------

Additional info:
=================
- I unable to replicate this issue when I use EAP 6.2 jboss-client.jar at ejb client side.
- I am able to replicate the same issue in JBoss EAP 7.0.2 version.

Comment 5 Brad Maxwell 2017-01-18 16:10:18 UTC
This property needs to be set to use system properties in the password field: 
-Djboss-ejb-client.expandPasswords=true

Closing not a but


Note You need to log in before you can comment on or make changes to this bug.