[Asterisk-code-review] func strings: negative array index can cause corruption on s... (asterisk[13])

Kevin Harwell asteriskteam at digium.com
Fri Nov 16 14:55:12 CST 2018


Hello Jenkins2, 

I'd like you to reexamine a change. Please visit

    https://gerrit.asterisk.org/10664

to look at the new patch set (#2).

Change subject: func_strings: negative array index can cause corruption on some architectures
......................................................................

func_strings: negative array index can cause corruption on some architectures

When using the HASHKEYS function if there are no matching keys the code writes
a NULL value to a negative index on the given buffer.

This patch protects the write by first checking if the buffer's length is not
zero before writing. If so it skips the write.

ASTERISK-28159
patches:
  ASTERISK-28159.diff submitted by Michael Walton (license 6502)

Change-Id: I6e57fe7307dfd856271753aed5ba64c59b511487
---
M funcs/func_strings.c
1 file changed, 10 insertions(+), 2 deletions(-)


  git pull ssh://gerrit.asterisk.org:29418/asterisk refs/changes/64/10664/2
-- 
To view, visit https://gerrit.asterisk.org/10664
To unsubscribe, or for help writing mail filters, visit https://gerrit.asterisk.org/settings

Gerrit-Project: asterisk
Gerrit-Branch: 13
Gerrit-MessageType: newpatchset
Gerrit-Change-Id: I6e57fe7307dfd856271753aed5ba64c59b511487
Gerrit-Change-Number: 10664
Gerrit-PatchSet: 2
Gerrit-Owner: Kevin Harwell <kharwell at digium.com>
Gerrit-Reviewer: Jenkins2 (1000185)
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.digium.com/pipermail/asterisk-code-review/attachments/20181116/9fba83ee/attachment-0001.html>


More information about the asterisk-code-review mailing list