<p>Friendly Automation <strong>submitted</strong> this change.</p><p><a href="https://gerrit.asterisk.org/c/asterisk/+/14112">View Change</a></p><div style="white-space:pre-wrap">Approvals:
Joshua Colp: Looks good to me, approved
George Joseph: Looks good to me, but someone else must approve
Friendly Automation: Approved for Submit
</div><pre style="font-family: monospace,monospace; white-space: pre-wrap;">app_osplookup: Avoid a format truncation.<br><br>Ensure that output buffers for the osp_convert_inout<br>function have sufficient space for additional data<br>such as brackets and ports.<br><br>ASTERISK-28804<br><br>Change-Id: Ie54c8241ff0cc653910539c2db00ff2a4869750b<br>---<br>M apps/app_osplookup.c<br>1 file changed, 7 insertions(+), 6 deletions(-)<br><br></pre><pre style="font-family: monospace,monospace; white-space: pre-wrap;"><span>diff --git a/apps/app_osplookup.c b/apps/app_osplookup.c</span><br><span>index 78f573a..4e6e5df 100644</span><br><span>--- a/apps/app_osplookup.c</span><br><span>+++ b/apps/app_osplookup.c</span><br><span>@@ -449,6 +449,7 @@</span><br><span> #define OSP_SIZE_UUID ((unsigned int)16) /* UUID size */</span><br><span> #define OSP_SIZE_UUIDSTR ((unsigned int)36) /* UUID string size */</span><br><span> #define OSP_SIZE_QOSSTR ((unsigned int)1024) /* QoS string buffer size */</span><br><span style="color: hsl(120, 100%, 40%);">+#define OSP_SIZE_OUTSTR ((unsigned int)288) /* OSP out size for osp_convert_inout */</span><br><span> </span><br><span> /* Call ID Type*/</span><br><span> #define OSP_CALLID_UNDEF ((unsigned int)0) /* Undefined */</span><br><span>@@ -1089,8 +1090,8 @@</span><br><span> int res;</span><br><span> int tokenlen;</span><br><span> unsigned char tokenstr[OSP_SIZE_TOKSTR];</span><br><span style="color: hsl(0, 100%, 40%);">- char src[OSP_SIZE_NORSTR];</span><br><span style="color: hsl(0, 100%, 40%);">- char dest[OSP_SIZE_NORSTR];</span><br><span style="color: hsl(120, 100%, 40%);">+ char src[OSP_SIZE_OUTSTR];</span><br><span style="color: hsl(120, 100%, 40%);">+ char dest[OSP_SIZE_OUTSTR];</span><br><span> unsigned int authorised;</span><br><span> unsigned int dummy = 0;</span><br><span> int error;</span><br><span>@@ -1518,14 +1519,14 @@</span><br><span> char* tmp;</span><br><span> unsigned int tokenlen;</span><br><span> char token[OSP_SIZE_TOKSTR];</span><br><span style="color: hsl(0, 100%, 40%);">- char src[OSP_SIZE_NORSTR];</span><br><span style="color: hsl(0, 100%, 40%);">- char dev[OSP_SIZE_NORSTR];</span><br><span style="color: hsl(0, 100%, 40%);">- char host[OSP_SIZE_NORSTR];</span><br><span style="color: hsl(120, 100%, 40%);">+ char src[OSP_SIZE_OUTSTR];</span><br><span style="color: hsl(120, 100%, 40%);">+ char dev[OSP_SIZE_OUTSTR];</span><br><span style="color: hsl(120, 100%, 40%);">+ char host[OSP_SIZE_OUTSTR];</span><br><span> unsigned int i, type;</span><br><span> struct osp_callid callid;</span><br><span> unsigned int callidnum;</span><br><span> OSPT_CALL_ID* callids[OSP_CALLID_MAXNUM];</span><br><span style="color: hsl(0, 100%, 40%);">- char dest[OSP_SIZE_NORSTR];</span><br><span style="color: hsl(120, 100%, 40%);">+ char dest[OSP_SIZE_OUTSTR];</span><br><span> const char* preferred[2] = { NULL };</span><br><span> unsigned int dummy = 0;</span><br><span> OSPEFAILREASON reason;</span><br><span></span><br></pre><p>To view, visit <a href="https://gerrit.asterisk.org/c/asterisk/+/14112">change 14112</a>. To unsubscribe, or for help writing mail filters, visit <a href="https://gerrit.asterisk.org/settings">settings</a>.</p><div itemscope itemtype="http://schema.org/EmailMessage"><div itemscope itemprop="action" itemtype="http://schema.org/ViewAction"><link itemprop="url" href="https://gerrit.asterisk.org/c/asterisk/+/14112"/><meta itemprop="name" content="View Change"/></div></div>
<div style="display:none"> Gerrit-Project: asterisk </div>
<div style="display:none"> Gerrit-Branch: 16 </div>
<div style="display:none"> Gerrit-Change-Id: Ie54c8241ff0cc653910539c2db00ff2a4869750b </div>
<div style="display:none"> Gerrit-Change-Number: 14112 </div>
<div style="display:none"> Gerrit-PatchSet: 3 </div>
<div style="display:none"> Gerrit-Owner: Alexander Traud <pabstraud@compuserve.com> </div>
<div style="display:none"> Gerrit-Reviewer: Friendly Automation </div>
<div style="display:none"> Gerrit-Reviewer: George Joseph <gjoseph@digium.com> </div>
<div style="display:none"> Gerrit-Reviewer: Joshua Colp <jcolp@sangoma.com> </div>
<div style="display:none"> Gerrit-MessageType: merged </div>