Subject: | Incorrect serialization of unicode strings. |
The Serializer->typelookup hash incorrectly designates anything with (essentially) non-ascii characters as to be encoded as base64. It should also check for the is_utf8 flag and if set then encode "as_string". As a work around I have done:
sub unicodeString {
my ($value) = @_;
return 1 if $value =~ /[^\x0-\x7f]/ && utf8::is_utf8($value);
return 0;
}
$server->serializer->typelookup->{unicodeString} = [9,\&unicodeString, 'as_string'];
This picks up any unicode strings with non-ascii characters and utf8 encodes them while allowing for other binary data to be encoded base64 and also the other checks for number and date etc to take place.