- priority: 5 --> 3
When a request is rejected because of insufficient authorization, the SOAP servlet returns the following faultcode element (with "modernFaultCodes" enabled):
<faultcode xmlns:ns1="urn:oasis:names:tc:ebxml-regrep:rs:exception">ns1:org.freebxml.omar.common.exceptions.UnauthorizedRequestException</faultcode>
According to section 2.1.1.4 of ebRS the correct faultcode should be:
<faultcode xmlns:ns1="urn:oasis:names:tc:ebxml-regrep:rs:exception">ns1:AuthorizationException</faultcode>
OMAR should not use a fully qualified Java class name in the faultcode. This seems to be a general problem that can be traced back to the following code in RegistrySOAPServlet#createFaultSOAPMessage:
String exceptionName = e.getClass().getName();
Name name = env.createName(exceptionName, "ns1", BindingUtility.SOAP_FAULT_PREFIX);
fault.setFaultCode(name);
In this particular case there is in addition a mismatch between the (unqualified) Java class name and the exception name specified in ebRS.