[asterisk-bugs] [Asterisk 0018046]: [patch] func_curl CURLOPT likes a querycomponent (+-decoding) hashcompat mode

Asterisk Bug Tracker noreply at bugs.digium.com
Mon Sep 27 02:24:57 CDT 2010


A NOTE has been added to this issue. 
====================================================================== 
https://issues.asterisk.org/view.php?id=18046 
====================================================================== 
Reported By:                wdoekes
Assigned To:                
====================================================================== 
Project:                    Asterisk
Issue ID:                   18046
Category:                   Functions/func_curl
Reproducibility:            always
Severity:                   feature
Priority:                   normal
Status:                     feedback
Asterisk Version:           1.6.2.13 
JIRA:                        
Regression:                 No 
Reviewboard Link:            
SVN Branch (only for SVN checkouts, not tarball releases): N/A 
SVN Revision (number only!):  
Request Review:              
====================================================================== 
Date Submitted:             2010-09-24 04:16 CDT
Last Modified:              2010-09-27 02:24 CDT
====================================================================== 
Summary:                    [patch] func_curl CURLOPT likes a querycomponent
(+-decoding) hashcompat mode
Description: 
Hi,

in https://issues.asterisk.org/view.php?id=18037 I've added a QSFIELD
which is pretty much obsoleted by the hashcompat mode of CURLOPT.

However, the ast_uri_decode leaves +'es verbatim in the decoded output,
where I expect them to be decoded to spaces.

The attached patch adds a hashcompat=querycomponent mode that decodes the
pluses properly. (For backwards compatibility the ast_value() works for all
other values.)

Regards,
Walter Doekes
OSSO B.V.
====================================================================== 

---------------------------------------------------------------------- 
 (0127417) wdoekes (reporter) - 2010-09-27 02:24
 https://issues.asterisk.org/view.php?id=18046#c127417 
---------------------------------------------------------------------- 
I concede that you have superior RFC reading skills.

However, not having to beat every user with a clue-bat will save time and
money. You must agree with me that the users will use instinctively use
http_build_query, urllib.urlencode and so forth. x-www-form-urlencoding is
not about to go away any time soon. And often these languages do not have
an equivalent dictionary-to-string function that allows them to not encode
spaces as pluses.

So. I'll gladly redo the patch and rename "querycomponent-mode" to
"deprecated-mode" or whatever you prefer, but I'd still like some version
of it included.

Regards,
Walter 

Issue History 
Date Modified    Username       Field                    Change               
====================================================================== 
2010-09-27 02:24 wdoekes        Note Added: 0127417                          
======================================================================




More information about the asterisk-bugs mailing list