Skip Menu |

This queue is for tickets about the Net-SIP CPAN distribution.

Report information
The Basics
Id: 121585
Status: resolved
Priority: 0/
Queue: Net-SIP

People
Owner: Nobody in particular
Requestors: richard.carver [...] cloudmont.co.uk
Cc:
AdminCc:

Bug Information
Severity: (no value)
Broken in: (no value)
Fixed in: (no value)



Subject: Net::SIP::Util sip_parts2hdrval encoding of special characters
Date: Tue, 9 May 2017 14:32:37 +0000
To: "bug-Net-SIP [...] rt.cpan.org" <bug-Net-SIP [...] rt.cpan.org>
From: Richard Carver <richard.carver [...] cloudmont.co.uk>
When calling the sip_parts2hdrval function with a parameter that contains a '%' character it triggers an extra encoding, but because the 'e' is missing off the expression it causes the literal 'sprintf "%%%02x",ord($1)' to be inserted into the resultant string. *** /usr/local/share/perl5/Net/SIP/Util.pm.orig --- /usr/local/share/perl5/Net/SIP/Util.pm *************** sub sip_parts2hdrval { *** 189,195 **** my $v = $param->{$k}; if ( defined $v ) { # escape special chars ! $v =~s{([%\r\n\t"[:^print:]])}{ sprintf "%%%02x",ord($1) }sg; $v = '"'.$v.'"' if $v =~m{\s|$delim}; $val .= '='.$v } --- 189,195 ---- my $v = $param->{$k}; if ( defined $v ) { # escape special chars ! $v =~s{([%\r\n\t"[:^print:]])}{ sprintf "%%%02x",ord($1) }sge; $v = '"'.$v.'"' if $v =~m{\s|$delim}; $val .= '='.$v }
Am Di 09. Mai 2017, 19:07:11, richard.carver@cloudmont.co.uk schrieb: Show quoted text
> When calling the sip_parts2hdrval function with a parameter that > contains a '%' character it triggers an extra encoding, but because > ...
Thanks for reporting. It is fixed in commit 9687d9b.