[Home]

Summary:ASTERISK-28083: res_agi: Asterisk truncates result of get_variable to 1024 characters
Reporter:Daan Roet (DRoet)Labels:
Date Opened:2018-09-28 08:31:33Date Closed:
Priority:MinorRegression?No
Status:Open/NewComponents:Resources/res_agi
Versions:15.6.0 Frequency of
Occurrence
Constant
Related
Issues:
Environment:linuxAttachments:
Description:In asterisk, you can set a very long variable (>1024 characters) using:
$agi->set_variable("test", $longString);

You can verify this by running the verbose() function and checking the asterisk console, however when you then try and retrieve the same variable using:
$result = $agi->get_variable("test");

The variable gets truncated and limited to 1024 characters, making it impossible to retrieve the original string
Comments:By: Asterisk Team (asteriskteam) 2018-09-28 08:31:35.717-0500

Thanks for creating a report! The issue has entered the triage process. That means the issue will wait in this status until a Bug Marshal has an opportunity to review the issue. Once the issue has been reviewed you will receive comments regarding the next steps towards resolution.

A good first step is for you to review the [Asterisk Issue Guidelines|https://wiki.asterisk.org/wiki/display/AST/Asterisk+Issue+Guidelines] if you haven't already. The guidelines detail what is expected from an Asterisk issue report.

Then, if you are submitting a patch, please review the [Patch Contribution Process|https://wiki.asterisk.org/wiki/display/AST/Patch+Contribution+Process].

By: Joshua C. Colp (jcolp) 2018-10-01 04:32:56.701-0500

Yes, res_agi has a fixed 1024 sized buffer in the handle_getvariable function. I'm accepting this issue but if you want to submit a patch to change that, then it can be resolved faster.