[s-xml-rpc-devel] bug: S-XML-RPC sends unencoded strings with invalid characters

Sven Van Caekenberghe scaekenberghe at common-lisp.net
Fri Jul 28 13:18:16 UTC 2006


Hi Taylor,

Thanks for the feedback!

Could you please be a bit more specific ? It has been a while since I  
have been reading these specs ;-)

The function s-xml:print-string-xml does a bit of escaping and is  
used from s-xml-rpc::encode-xml-rpc-value, what exactly are they  
doing wrong ?
Could you give some concrete example, a CL listener session maybe ?
I know that s-xml-rpc is used by a couple of other projects/people,  
so changing the string encoding must be done carefully.

Regards,

Sven


On 26 Jul 2006, at 23:08, Taylor R Campbell wrote:

> Well-formed XML is not allowed to include character entities that are
> not legal XML characters, according to the definition of character
> entity references in section 4.1 of the XML 1.0 specification:
>
>    [66] CharRef ::= '&#' [0-9]+ ';' | '&#x' [0-9a-fA-F]+ ';'
>
>    Well-formedness constraint:  Legal Character
>    - Characters referred to using character references MUST match the
>    - production for Char.
>
> The production for Char is defined in section 2.2:
>
>   [2] Char ::= #x9 | #xA | #xD | [#x20-#xD7FF] | [#xE000-#xFFFD] |
>                [#x10000-#x10FFFF]
>
> Strings with any other characters ought to be base64-encoded.  I just
> encountered a problem when lisppaste sent an XML-RPC response with a
> paste that contains form feed characters to client with an extremely
> strict XML parser.
> _______________________________________________
> s-xml-rpc-devel site list
> s-xml-rpc-devel at common-lisp.net
> http://common-lisp.net/mailman/listinfo/s-xml-rpc-devel




More information about the S-xml-rpc-devel mailing list