Hi, I have created a Camel route where the user is authenticated using JAAS & ws-security (works fine) ad authorized with Spring Security (works fine) but when the response is populated (IN A WRONG WAY) I get this error :
ERROR https://gist.github.com/a56d18ca8585b9624787 WSDL https://gist.github.com/fd3f8d0b95cc15ec157f CODE OF CAMEL @Override public void configure() throws Exception { onException(CamelAuthorizationException.class) .log(">> User not authorized") .handled(true) .process(new Processor() { @Override public void process(Exchange exchange) throws Exception { String user = "jim"; NotAuthorizedUser notAuthorizedUser = new NotAuthorizedUser(); notAuthorizedUser.setUser(user); exchange.getOut().setBody(notAuthorizedUser); exchange.getOut().setFault(true); } }); from("cxf:bean:WS").id("cxf-to-client-pojo") .beanRef("enrich", "convertToAuthenticationWithRealm") .policy("admin") .... QUESTION : Why Camel-CXF does not return a SOAP Fault message but GetByCustomerResponse containing the user string defined with NotAuthorizedUser object ? Regards, -- Charles Moulliard Apache Committer / Sr. Enterprise Architect (RedHat) Twitter : @cmoulliard | Blog : http://cmoulliard.blogspot.com
