"[EMAIL PROTECTED]" wrote : Change the "properties" on the jms provider to use jndi 
over https.

Adrian:

Unfortunately, I am still not there yet.  I'm sorry for the apparently simple 
questions, but I have been reading everything I can find and digging into this as hard 
as I can for well over a week now and am still not making much progress.  Based on 
your suggestions to date, I am now getting the following exception whenever I try to 
deploy my MDB.

javax.naming.NamingException: Failed to retrieve Naming interface [Root exception is 
java.io.IOException]
        at 
org.jboss.naming.HttpNamingContextFactory.getInitialContext(HttpNamingContextFactory.java:69)
        at javax.naming.spi.NamingManager.getInitialContext(NamingManager.java:662)
        at javax.naming.InitialContext.getDefaultInitCtx(InitialContext.java:243)
        at javax.naming.InitialContext.init(InitialContext.java:219)
        at javax.naming.InitialContext.(InitialContext.java:195)
        at 
org.jboss.jms.jndi.JNDIProviderAdapter.getInitialContext(JNDIProviderAdapter.java:49)
        at org.jboss.ejb.plugins.jms.DLQHandler.createService(DLQHandler.java:148)
        at 
org.jboss.system.ServiceMBeanSupport.jbossInternalCreate(ServiceMBeanSupport.java:237)
        at org.jboss.system.ServiceMBeanSupport.create(ServiceMBeanSupport.java:164)
        at 
org.jboss.ejb.plugins.jms.JMSContainerInvoker.innerCreate(JMSContainerInvoker.java:542)
        at 
org.jboss.ejb.plugins.jms.JMSContainerInvoker.startService(JMSContainerInvoker.java:764)
        at 
org.jboss.system.ServiceMBeanSupport.jbossInternalStart(ServiceMBeanSupport.java:271)
        at 
org.jboss.system.ServiceMBeanSupport.jbossInternalLifecycle(ServiceMBeanSupport.java:221)
        at sun.reflect.GeneratedMethodAccessor2.invoke(Unknown Source)
        at 
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
        at java.lang.reflect.Method.invoke(Method.java:324)
        at 
org.jboss.mx.server.ReflectedDispatcher.dispatch(ReflectedDispatcher.java:60)
        at org.jboss.mx.server.Invocation.dispatch(Invocation.java:61)
        at org.jboss.mx.server.Invocation.dispatch(Invocation.java:53)
        at org.jboss.mx.server.Invocation.invoke(Invocation.java:86)
        at 
org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInvoker.java:185)
        at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:473)
        at 
org.jboss.system.ServiceController$ServiceProxy.invoke(ServiceController.java:837)

....

The base of this stack trace shows the following:

Caused by: javax.net.ssl.SSLHandshakeException: 
sun.security.validator.ValidatorException: No trusted certificate found
        at com.sun.net.ssl.internal.ssl.BaseSSLSocketImpl.a(DashoA12275)
        at com.sun.net.ssl.internal.ssl.SSLSocketImpl.a(DashoA12275)
        at com.sun.net.ssl.internal.ssl.SSLSocketImpl.a(DashoA12275)
        at com.sun.net.ssl.internal.ssl.SunJSSE_az.a(DashoA12275)
        at com.sun.net.ssl.internal.ssl.SunJSSE_az.a(DashoA12275)
        at com.sun.net.ssl.internal.ssl.SunJSSE_ax.a(DashoA12275)
        at com.sun.net.ssl.internal.ssl.SSLSocketImpl.a(DashoA12275)
        at com.sun.net.ssl.internal.ssl.SSLSocketImpl.j(DashoA12275)
        at com.sun.net.ssl.internal.ssl.SSLSocketImpl.startHandshake(DashoA12275)
        at sun.net.www.protocol.https.HttpsClient.afterConnect(DashoA12275)
        at 
sun.net.www.protocol.https.AbstractDelegateHttpsURLConnection.connect(DashoA12275)
        at 
sun.net.www.protocol.http.HttpURLConnection.getInputStream(HttpURLConnection.java:626)
        at 
sun.net.www.protocol.http.HttpURLConnection.getHeaderField(HttpURLConnection.java:1465)
        at java.net.URLConnection.getHeaderFieldInt(URLConnection.java:476)
        at java.net.URLConnection.getContentLength(URLConnection.java:371)
        at 
sun.net.www.protocol.https.HttpsURLConnectionImpl.getContentLength(DashoA12275)
        at 
org.jboss.naming.HttpNamingContextFactory.getNamingServer(HttpNamingContextFactory.java:112)
        ... 107 more
Caused by: sun.security.validator.ValidatorException: No trusted certificate found
        at 
sun.security.validator.SimpleValidator.buildTrustedChain(SimpleValidator.java:304)
        at 
sun.security.validator.SimpleValidator.engineValidate(SimpleValidator.java:107)
        at sun.security.validator.Validator.validate(Validator.java:202)
        at 
com.sun.net.ssl.internal.ssl.X509TrustManagerImpl.checkServerTrusted(DashoA12275)
        at 
com.sun.net.ssl.internal.ssl.JsseX509TrustManager.checkServerTrusted(DashoA12275)
        ... 121 more

This obviously indicates an SSL problem and I suspect it is because the Provider is 
not configured in the correct domain?  I cannot seem to figure out how to do this 
correctly through any of the docs or examples so far.  However, there may be other 
problems as well.  Please note that SSL and HTTP using the SSL domain work flawlessly 
on this JBoss instance for other applications including JNDI/HTTPS EJB/HTTPS/RMI/SSL, 
HTTPS.

The relevant files as they now stand are listed below:

MDB jboss.xml deployment descriptor contains:

    <message-driven>
  |        <ejb-name>ResultsBean</ejb-name>
  |        <destination-jndi-name>topic/discoveryResults</destination-jndi-name>
  |       <!--
  |         Use the following to tunnel over HTTPS
  |       -->
  |       <invoker-bindings>
  |           <invoker>
  |               <invoker-proxy-binding-name>
  |                   message-driven-bean-https</invoker-proxy-binding-name>
  |           </invoker>
  |       </invoker-bindings>
  |     </message-driven>

$JBOSS_DIST/server/default/conf/standardjboss.xml contains:


  |       <invoker-proxy-binding>
  |          <name>message-driven-bean-https</name>
  |          <invoker-mbean>
  |              jboss.mq:service=JMSProviderLoader,name=HTTPSJMSProvider,socketType
  | =SSL
  |          </invoker-mbean>
  |          <proxy-factory>org.jboss.ejb.plugins.jms.JMSContainerInvoker</proxy-fac>
  |          <proxy-factory-config>
  |             <JMSProviderAdapterJNDI>HTTPSJMSProvider</JMSProviderAdapterJNDI>
  |             <ServerSessionPoolFactoryJNDI>StdJMSPool</ServerSessionPoolFactoryJN>
  |             <!-- WARN: Don't set this to zero until a bug in the pooled executor
  |  is fixed -->
  |             <MinimumSize>1</MinimumSize>
  |             <MaximumSize>15</MaximumSize>
  |             <KeepAliveMillis>30000</KeepAliveMillis>
  |             <MaxMessages>1</MaxMessages>
  |             <MDBConfig>
  |                <ReconnectIntervalSec>10</ReconnectIntervalSec>
  |                <DLQConfig>
  |                   <DestinationQueue>queue/DLQ</DestinationQueue>
  |                   <MaxTimesRedelivered>10</MaxTimesRedelivered>
  |                   <TimeToLive>0</TimeToLive>
  |                </DLQConfig>
  |             </MDBConfig>
  |          </proxy-factory-config>
  |       </invoker-proxy-binding>

AND

      <container-configuration>
  |           <container-name>HTTPS Message Driven Bean</container-name>
  |           <call-logging>true</call-logging>
  |           
<invoker-proxy-binding-name>message-driven-bean-https</invoker-proxy-binding-name>
  |           <container-interceptors>
  |              
<interceptor>org.jboss.ejb.plugins.ProxyFactoryFinderInterceptor</interceptor>
  |              <interceptor>org.jboss.ejb.plugins.LogInterceptor</interceptor>
  |              
<interceptor>org.jboss.ejb.plugins.RunAsSecurityInterceptor</interceptor>
  |              <!-- CMT -->
  |              <interceptor 
transaction="Container">org.jboss.ejb.plugins.TxInterceptorCMT</interceptor>
  |              <interceptor transaction="Container" 
metricsEnabled="true">org.jboss.ejb.plugins.MetricsInterceptor</interceptor>
  |              <interceptor 
transaction="Container">org.jboss.ejb.plugins.MessageDrivenInstanceInterceptor</interceptor>
  |              <!-- BMT -->
  |              <interceptor 
transaction="Bean">org.jboss.ejb.plugins.MessageDrivenInstanceInterceptor</interceptor>
  |              <interceptor 
transaction="Bean">org.jboss.ejb.plugins.MessageDrivenTxInterceptorBMT</interceptor>
  |              <interceptor transaction="Bean" 
metricsEnabled="true">org.jboss.ejb.plugins.MetricsInterceptor</interceptor>
  |              
<interceptor>org.jboss.resource.connectionmanager.CachedConnectionInterceptor</interceptor>
  |           </container-interceptors>
  |           
<instance-pool>org.jboss.ejb.plugins.MessageDrivenInstancePool</instance-pool>
  |           <instance-cache></instance-cache>
  |           <persistence-manager></persistence-manager>
  |           <container-pool-conf>
  |              <MaximumSize>100</MaximumSize>
  |           </container-pool-conf>
  |       </container-configuration>

$JBOSS_DIST/server/default/deploy/jms/jms-ds.xml was modified to include:

  <mbean code="org.jboss.jms.jndi.JMSProviderLoader"
  |     name="jboss.mq:service=JMSProviderLoader,name=HTTPSJMSProvider">
  |     <depends>jboss:service=invoker,type=https,target=Naming</depends>
  |     <depends>jboss.mq:service=InvocationLayer,type=HTTP</depends>
  | 
  |     <attribute name="ProviderName">HTTPSJMSProvider</attribute>
  |     <attribute name="ProviderAdapterClass">
  |       org.jboss.jms.jndi.JNDIProviderAdapter
  |     </attribute>
  |     <!-- The queue connection factory -->
  |     <attribute name="QueueFactoryRef">java:/XAConnectionFactory</attribute>
  |     <!-- The topic factory -->
  |     <attribute name="TopicFactoryRef">java:/XAConnectionFactory</attribute>
  |     <attribute name="Properties">
  |        java.naming.factory.initial=org.jboss.naming.HttpNamingContextFactory
  |        java.naming.factory.url.pkgs=org.jboss.naming:org.jnp.interfaces
  |        
java.naming.provider.url=https://192.168.123.200:8633/invoker/JMXInvokerServlet
  |        javax.net.ssl.trustStore=${env.JBOSS_DIST}/server/default/conf/ose.keystore
  | 
  |     </attribute>
  |   </mbean>
  | 

$JBOSS_DIST/server/default/deploy/jms/jbossmq-httpil.sar/META-INF/jboss-service.xml 
looks like:

<?xml version="1.0" encoding="UTF-8"?>
  | 
  | <server>
  |     <mbean code="org.jboss.mq.il.http.HTTPServerILService"
  |      name="jboss.mq:service=InvocationLayer,type=HTTP">
  |     <depends optional-attribute-name="Invoker">jboss.mq:service=Invoker</depends>
  | 
  |     <depends>jboss.web:service=WebServer</depends>
  |     <attribute name="ConnectionFactoryJNDIRef">HTTPConnectionFactory</attribute>
  |     <attribute name="XAConnectionFactoryJNDIRef">HTTPXAConnectionFactory</attrib
  | ute>
  |     <attribute name="PingPeriod">0</attribute>
  |     <attribute name="TimeOut">60</attribute>
  |     <attribute name="RestInterval">0</attribute>
  |     <attribute name="URLPrefix">https://</attribute>
  |     <attribute name="URLPort">8633</attribute>
  |     <attribute name="URLSuffix">jbossmq-httpil/HTTPServerILServlet</attribute>
  |     <!-- <attribute name="UseHostName">true</attribute> -->
  |     <attribute name="UseHostName">false</attribute>
  |   </mbean>
  | 
  |   <!-- JAAS security config for RMI/SSL -->
  |   <mbean code="org.jboss.security.plugins.JaasSecurityDomain"
  |      name="jboss.security:service=JaasSecurityDomain,domain=JMS+SSL">
  |      <constructor>
  |          <arg type="java.lang.String" value="JMS+SSL"/>
  |      </constructor>
  |      <attribute name="KeyStoreURL">my.keystore</attribute>
  |      <attribute name="KeyStorePass">pw</attribute>
  |   </mbean>
  | 
  | </server>

Once again, I greatly appreciate any and all assistance in getting this going 
successfully!  Are there no working samples for HTTPServerILService using SSL anywhere 
that I might reference?  Thanks again in advance for your assistance!

Todd






View the original post : 
http://www.jboss.org/index.html?module=bb&op=viewtopic&p=3846569#3846569

Reply to the post : 
http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=3846569


-------------------------------------------------------
This SF.Net email is sponsored by BEA Weblogic Workshop
FREE Java Enterprise J2EE developer tools!
Get your free copy of BEA WebLogic Workshop 8.1 today.
http://ads.osdn.com/?ad_id=5047&alloc_id=10808&op=click
_______________________________________________
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user

Reply via email to