Hi
Just answer how to configure AegisBinding on the Servlet-side.
You can create the service by using spring to wire the JaxWsServerFactoryBean in the bean.xml.

Here is an example:
<beans xmlns="http://www.springframework.org/schema/beans";
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"; xsi:schemaLocation=" http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans.xsd
">

<bean id="AegisDatabinding" class="org.apache.cxf.aegis.databinding.AegisDatabinding"/>

<bean id="JaxWsServiceFactoryBean" class="org.apache.cxf.jaxws.support.JaxWsServiceFactoryBean">
   <property name="wrapped" value="false"/>
   <property name="dataBinding" ref="AegisDatabinding"/>
</bean>

<bean id="greeterServerFactory"
class="org.apache.cxf.jaxws.JaxWsServerFactoryBean" init-method="create"> <property name="serviceClass" value="org.apache.cxf.customer.bare.CustomerService" />
   <property name="serviceBean">
     <bean class="org.apache.cxf.customer.bare.CustomerService"/>
   </property>
   <property name="address" value="/services/test"/>
<property name="bus" ref="cxf"/> <property name="serviceFactory" ref="JaxWsServiceFactoryBean"/> </bean>
Cheers,

Willem.

Jan Kriesten wrote:
hi freeman,

Would you please append your whole testcase?
Is Authentication class defined as para or return type for your SEI?

the interface is defined as follows:

import javax.jws.WebMethod;
import javax.jws.WebParam;
import javax.jws.WebResult;
import javax.jws.WebService;
import org.acegisecurity.Authentication;

public interface IAuthService
{
  @WebMethod
  @WebResult( name="authenticated" )
  public boolean authenticate( @WebParam(name="sid") String sid,
@WebParam(name="uid") String username, @WebParam(name="pwd") String password );

  @WebMethod
  @WebResult( name="authentication" )
  public Authentication getAuthentication( @WebParam(name="sid") String sid );

  @WebMethod
  @WebResult( name="roles" )
  public Set<String> getRoles( @WebParam(name="sid") String sid );
}

Authentication is an interface which extends Principal and Serializable.

I'm using the CXFServlet, so it might be that I have to configure AegisBinding
on the Servlet-side (client is set to Aegis), but the documentation doesn't say 
how.

Best regards, --- Jan.



Reply via email to