summaryrefslogtreecommitdiff
path: root/res/res_ari_endpoints.c
diff options
context:
space:
mode:
authorRichard Mudgett <rmudgett@digium.com>2015-02-27 18:31:31 +0000
committerRichard Mudgett <rmudgett@digium.com>2015-02-27 18:31:31 +0000
commit9e841e4fb62f072f26f076bd4dd2a8eebe7a9e75 (patch)
treee0040f22d288c44f53089f95868540264a5689fe /res/res_ari_endpoints.c
parentd79670b2694c22ab078e029a6a3b7e066d6ae531 (diff)
ARI: Fix crash if integer values used in JSON payload 'variables' object.
Sending the following ARI commands caused Asterisk to crash if the JSON body 'variables' object passes values of types other than strings. POST /ari/channels POST /ari/channels/{channelid} PUT /ari/endpoints/sendMessage PUT /ari/endpoints/{tech}/{resource}/sendMessage * Eliminated RAII_VAR usage in ast_ari_channels_originate_with_id(), ast_ari_channels_originate(), ast_ari_endpoints_send_message(), and ast_ari_endpoints_send_message_to_endpoint(). ASTERISK-24751 #close Reported by: jeffrey putnam Review: https://reviewboard.asterisk.org/r/4447/ ........ Merged revisions 432404 from http://svn.asterisk.org/svn/asterisk/branches/13 git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@432405 65c4cc65-6c06-0410-ace0-fbb531ad65f3
Diffstat (limited to 'res/res_ari_endpoints.c')
-rw-r--r--res/res_ari_endpoints.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/res/res_ari_endpoints.c b/res/res_ari_endpoints.c
index 3ebe66858..8d8ed716c 100644
--- a/res/res_ari_endpoints.c
+++ b/res/res_ari_endpoints.c
@@ -181,6 +181,7 @@ static void ast_ari_endpoints_send_message_cb(
break;
case 500: /* Internal Server Error */
case 501: /* Not Implemented */
+ case 400: /* Invalid parameters for sending a message. */
case 404: /* Endpoint not found */
is_valid = 1;
break;