[asterisk-dev] [Code Review] 2986: ari: Add application/x-www-form-urlencoded parameter support

Joshua Colp reviewboard at asterisk.org
Thu Nov 7 10:02:02 CST 2013


-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviewboard.asterisk.org/r/2986/#review10137
-----------------------------------------------------------

Ship it!


Ship It!


/branches/12/res/res_ari.c
<https://reviewboard.asterisk.org/r/2986/#comment19408>

    Might want to add a comment here about why this isn't a memory leak.


- Joshua Colp


On Nov. 4, 2013, 9:31 p.m., David Lee wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviewboard.asterisk.org/r/2986/
> -----------------------------------------------------------
> 
> (Updated Nov. 4, 2013, 9:31 p.m.)
> 
> 
> Review request for Asterisk Developers.
> 
> 
> Bugs: ASTERISK-22743
>     https://issues.asterisk.org/jira/browse/ASTERISK-22743
> 
> 
> Repository: Asterisk
> 
> 
> Description
> -------
> 
> ARI POST calls only accept parameters via the URL's query string.
> While this works, it's atypical for HTTP API's in general, and
> specifically frowned upon with RESTful API's.
> 
> This patch adds parsing for application/x-www-form-urlencoded request
> bodies if they are sent in with the request. Any variables parsed this
> way are prepended to the variable list supplied by the query string.
> 
> 
> Diffs
> -----
> 
>   /branches/12/res/res_ari.c 402368 
>   /branches/12/main/manager.c 402368 
>   /branches/12/main/http.c 402368 
> 
> Diff: https://reviewboard.asterisk.org/r/2986/diff/
> 
> 
> Testing
> -------
> 
> curl -vs --data "channel=1383326738.0&api_key=ari:ari" http://localhost:8088/ari/bridges/e78019f3-9710-43c7-8421-de5cff48e3d3/addChannel
> 
> Testsuite test: https://reviewboard.asterisk.org/r/2993/
> 
> 
> Thanks,
> 
> David Lee
> 
>

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.digium.com/pipermail/asterisk-dev/attachments/20131107/1365857a/attachment-0001.html>


More information about the asterisk-dev mailing list