hi people,

I´ve been looking the JBoss 4.0 documentation and I couldn´t make my EJB work 
with SSL. I configured the jboss.xml and jboss-service.xml files and I put the 
annotation @SecurityDomain at the Bean just like the documentation describbed.

My EJB:

package serpro.safe.server.operations;
  | 
  | import java.util.Date;
  | 
  | import javax.ejb.Remote;
  | import javax.ejb.Stateless;
  | import javax.ejb.TransactionAttribute;
  | import javax.ejb.TransactionAttributeType;
  | 
  | import org.jboss.aspects.security.SecurityDomain;
  | 
  | import serpro.safe.negocio.calendario.feriado.Feriado;
  | import serpro.safe.negocio.calendario.feriado.IControladorFeriado;
  | import serpro.safe.server.operations.SafeOperations;
  | import serpro.safe.util.exception.NegocioException;
  | import serpro.safe.util.proxy.ControladorFactory;
  | 
  | @Remote(SafeOperations.class) 
  | @Stateless
  | public @SecurityDomain("RMI+SSL") class  SafeOperationsBean implements 
SafeOperations {
  |     
  |     @TransactionAttribute(TransactionAttributeType.REQUIRED) 
  |     public void inserirFeriado(Feriado feriado) throws NegocioException{
  |             try {
  |                     
  |                     IControladorFeriado controlador = 
(IControladorFeriado)ControladorFactory.criar(IControladorFeriado.class);
  |                     controlador.inserirFeriado(feriado);
  |             } catch (Exception e) {
  |                     throw new NegocioException(e);
  |             }
  |     }
  | 
  |     
  | }


jboss-service.xml:


<server>
  | 
  |     <mbean code="org.jboss.security.plugins.JaasSecurityDomain"
  |             name="jboss.security:service=JaasSecurityDomain,domain=RMI+SSL">
  |             <constructor>
  |                     <arg type="java.lang.String" value="RMI+SSL" />
  |             </constructor>
  |             <attribute name="KeyStoreURL">certs.keystore</attribute>
  |             <attribute name="KeyStorePass">taylor</attribute>
  |     </mbean>
  | 
  |     <mbean code="org.jboss.invocation.jrmp.server.JRMPInvoker"
  |             name="jboss:service=invoker,type=jrmp,socketType=SSL">
  |             <attribute name="RMIObjectPort">14445</attribute>
  |             <attribute name="RMIClientSocketFactory">
  |                     org.jboss.security.ssl.RMISSLClientSocketFactory
  |             </attribute>
  |             <attribute name="RMIServerSocketFactory">
  |                     org.jboss.security.ssl.RMISSLServerSocketFactory
  |             </attribute>
  |             <attribute name="SecurityDomain">java:/jaas/RMI+SSL</attribute>
  |             <depends>
  |                     jboss.security:service=JaasSecurityDomain,domain=RMI+SSL
  |             </depends>
  |     </mbean>
  | </server>



jboss.xml:

<jboss>
  |     <enterprise-beans>
  |         <session>
  |             <ejb-name>SafeOperations</ejb-name>
  |             <configuration-name>Standard Stateless 
SessionBean</configuration-name>
  |             <invoker-bindings>
  |                 <invoker>
  |                     
<invoker-proxy-binding-name>stateless-ssl-invoker</invoker-proxy-binding-name>
  |                 </invoker>
  |             </invoker-bindings>
  |         </session>
  |     </enterprise-beans>
  |     
  |     <invoker-proxy-bindings>
  |         <invoker-proxy-binding>
  |             <name>stateless-ssl-invoker</name>
  |             
<invoker-mbean>jboss:service=invoker,type=jrmp,socketType=SSL</invoker-mbean>
  |             <proxy-factory>org.jboss.proxy.ejb.ProxyFactory</proxy-factory>
  |             <proxy-factory-config>
  |             <client-interceptors>
  |                 <home>
  |                     
<interceptor>org.jboss.proxy.ejb.HomeInterceptor</interceptor>
  |                     
<interceptor>org.jboss.proxy.SecurityInterceptor</interceptor>
  |                     
<interceptor>org.jboss.proxy.TransactionInterceptor</interceptor>
  |                     
<interceptor>org.jboss.invocation.InvokerInterceptor</interceptor>
  |                 </home>
  |                 <bean>
  |                     
<interceptor>org.jboss.proxy.ejb.StatelessSessionInterceptor</interceptor>
  |                     
<interceptor>org.jboss.proxy.SecurityInterceptor</interceptor>
  |                     
<interceptor>org.jboss.proxy.TransactionInterceptor</interceptor>
  |                     
<interceptor>org.jboss.invocation.InvokerInterceptor</interceptor>
  |                 </bean>
  |             </client-interceptors>
  |             </proxy-factory-config>
  |         </invoker-proxy-binding>
  |     </invoker-proxy-bindings>
  | </jboss>


I´ve got the following messages on JBoss console: 

13:32:07,279 INFO  [JaccHelper] Initialising JACC Context for deployment: 
safe-beans.ejb3
13:32:07,310 INFO  [Ejb3AnnotationHandler] found EJB3: ejbName=OperacaoBean, 
class=OperacaoBean, type=STATELESS
13:32:07,560 INFO  [JaccHelper] OperacaoBean has no @SecurityDomain - skipping 
JACC configuration
13:32:07,591 INFO  [Ejb3AnnotationHandler] found EJB3: 
ejbName=serpro.safe.server.operations.SafeOperationsBean, 
class=serpro.safe.server.operations.SafeOperationsBean, type=STATELESS
13:32:07,638 INFO  [JaccHelper] 
serpro.safe.server.operations.SafeOperationsBean has no @SecurityDomain - 
skipping JACC configuration
13:32:07,654 INFO  [JaccHelper] JACC Policy Configuration for deployment has 
been put in service
13:32:07,654 INFO  [Ejb3Deployment] EJB3 deployment time took: 375
13:32:07,794 INFO  [ProxyDeployer] no declared remote bindings for : 
OperacaoBean
13:32:07,794 INFO  [ProxyDeployer] there is remote interfaces for OperacaoBean
13:32:07,794 INFO  [ProxyDeployer] default remote binding has jndiName of 
Operacao
13:32:07,919 INFO  [ProxyDeployer] no declared remote bindings for : 
serpro.safe.server.operations.SafeOperationsBean
13:32:07,919 INFO  [ProxyDeployer] there is remote interfaces for 
serpro.safe.server.operations.SafeOperationsBean
13:32:07,919 INFO  [ProxyDeployer] default remote binding has jndiName of 
serpro.safe.server.operations.SafeOperations
13:32:07,966 INFO  [EJB3Deployer] Deployed: 
file:/C:/jboss-4.0.3SP1/server/default/deploy/safe-beans.ejb3
13:33:38,513 INFO  [JaccHelper] Initialising JACC Context for deployment: 
safe-beans.ejb3
13:33:38,560 INFO  [Ejb3AnnotationHandler] found EJB3: ejbName=OperacaoBean, 
class=OperacaoBean, type=STATELESS
13:33:38,607 INFO  [JaccHelper] OperacaoBean has no @SecurityDomain - skipping 
JACC configuration
13:33:38,685 INFO  [Ejb3AnnotationHandler] found EJB3: 
ejbName=serpro.safe.server.operations.SafeOperationsBean, 
class=serpro.safe.server.operations.SafeOperationsBean, type=STATELESS
13:33:38,732 INFO  [JaccHelper] 
serpro.safe.server.operations.SafeOperationsBean has no @SecurityDomain - 
skipping JACC configuration
13:33:38,732 INFO  [JaccHelper] JACC Policy Configuration for deployment has 
been put in service
13:33:38,732 INFO  [Ejb3Deployment] EJB3 deployment time took: 219
13:33:38,779 INFO  [ProxyDeployer] no declared remote bindings for : 
OperacaoBean
13:33:38,779 INFO  [ProxyDeployer] there is remote interfaces for OperacaoBean
13:33:38,779 INFO  [ProxyDeployer] default remote binding has jndiName of 
Operacao
13:33:38,872 INFO  [ProxyDeployer] no declared remote bindings for : 
serpro.safe.server.operations.SafeOperationsBean
13:33:38,872 INFO  [ProxyDeployer] there is remote interfaces for 
serpro.safe.server.operations.SafeOperationsBean
13:33:38,872 INFO  [ProxyDeployer] default remote binding has jndiName of 
serpro.safe.server.operations.SafeOperations
13:33:38,919 INFO  [EJB3Deployer] Deployed: 
file:/C:/jboss-4.0.3SP1/server/default/deploy/safe-beans.ejb3




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

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


-------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc. Do you grep through log files
for problems?  Stop!  Download the new AJAX search engine that makes
searching your log files as easy as surfing the  web.  DOWNLOAD SPLUNK!
http://ads.osdn.com/?ad_idv37&alloc_id865&op=click
_______________________________________________
JBoss-user mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/jboss-user

Reply via email to