https://issues.apache.org/bugzilla/show_bug.cgi?id=51891
--- Comment #3 from Daniel Bonniot <[email protected]> --- I also experience Ole10Native failing in various ways. Note that in Bug 46392, which initially introduced the Ole10Native class, Trejkaz attached several Ole streams which also fail with the current code. What seems clear is that a \1Ole10Native stream starts with 4 bytes giving the size of the rest of the stream. After that, the current Ole10Native class distinguishes between the "plain" mode where all the rest is simply the attached data, and the "structured" mode where a structured format is present, including several unknown flags, the fileName and the attached data proper. What is also clear is that currently the code fails in the "structured" mode for some inputs. I attach another failing case (oleObject2.bin) for which I know (given the data) that the "plain" mode should be used, but currently isn't (leading to a failure in the "structured" parsing code). I could not find a definitive specification of this "structured" mode and when it should be used. Analysis of the examples at hand lead me to tweak the logic (and use the "plain" mode more often), but this is purely speculative at this point. Any further insight would be welcome. Still, this avoids failures in all the cases from Bug 46392, from Bug 51891 and for my own testcase. I attach a patch that adds all these testcases, and changes the decision to use plain mode or not. Review would be welcome. -- You are receiving this mail because: You are the assignee for the bug. --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
