From: Andreas Beeker Date: Sun, 26 Apr 2020 21:38:14 +0000 (+0000) Subject: Throw exception on null/placeholder arrays in TNEF X-Git-Tag: before_ooxml_3rd_edition~292 X-Git-Url: https://source.dussan.org/?a=commitdiff_plain;h=23acaff78d1e2a08a879a1422e4ed18ff6290e12;p=poi.git Throw exception on null/placeholder arrays in TNEF git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1877044 13f79535-47bb-0310-9956-ffa450edef68 --- diff --git a/src/scratchpad/src/org/apache/poi/hmef/attribute/MAPIAttribute.java b/src/scratchpad/src/org/apache/poi/hmef/attribute/MAPIAttribute.java index 695822909a..0533705c2e 100644 --- a/src/scratchpad/src/org/apache/poi/hmef/attribute/MAPIAttribute.java +++ b/src/scratchpad/src/org/apache/poi/hmef/attribute/MAPIAttribute.java @@ -166,6 +166,11 @@ public class MAPIAttribute { if(isMV || isVL) { values = LittleEndian.readInt(inp); } + + if (type == Types.NULL && values > 1) { + throw new IOException("Placeholder/NULL arrays aren't supported."); + } + for(int j=0; j