coheigea opened a new pull request, #3814:
URL: https://github.com/apache/cxf/pull/3814

   wsdl2java copied several WSDL values verbatim into Java string literals
   in the generated code, so a double quote, a \u0022 unicode escape or a
   line break could end the literal and add arbitrary code to the
   generated classes:
   
     - soap:address location (server.vm)
     - definitions targetNamespace, service name and port name
       (service.vm, client.vm, impl.vm and annotations)
     - soapAction (@WebMethod) and wsaw:Action (@Action)
     - fault element name and namespace (fault.vm)
     - wsdlLocation (service.vm, impl.vm)
   
   Add org.apache.cxf.tools.util.JavaSourceEscaper, which holds the
   existing Javadoc escaping and a new string-literal escaper (backslash,
   double quote, CR, LF, tab and other control characters; escaping the
   backslash also stops a \uXXXX sequence from being read as a unicode
   escape). It is exposed to every Velocity template as $esc, and all
   contract-derived literals in the jaxws templates now go through
   $esc.literal(...). JAnnotationElement escapes every string value it
   writes. JavaInterface.escapeJavaDocContent delegates to the new class.
   
   Also fix PackageUtils.removeIllegalIdentifierChars, which kept the
   first character of a namespace segment even when it is not valid
   anywhere in an identifier, producing a package declaration that does
   not compile.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to