Re: [Podofo-users] PoDoFo PdfString::Write buffer overflow

2018-05-18 Thread Matthew Brincke
Hello Mark, hello all, > On 02 May 2018 at 10:20 Mark Rogers wrote: > > > Hi > > That sounds good. > > > if( pEncrypt && m_buffer.GetSize() && IsValid() ) > > As IsValid() contains only a NULL check on the buffer in m_buffer, > > the size check needs to be > 2 if ... > > At th

Re: [Podofo-users] PoDoFo PdfString::Write buffer overflow

2018-05-02 Thread Matthew Brincke
Hello all, > On 01 May 2018 at 00:54 Matthew Brincke wrote: > > > Hello Mark, hello all, > > On 20 April 2018 at 00:09 Mark Rogers wrote: > > > > > > Hi > > > > > > This code from PdfString::Write has a buffer overflow – it checks > > buffer.GetSize() > 0 then sets nInputBufferLen=GetSiz

Re: [Podofo-users] PoDoFo PdfString::Write buffer overflow

2018-04-30 Thread Matthew Brincke
Hello Mark, hello all, > On 20 April 2018 at 00:09 Mark Rogers wrote: > > > Hi > > > This code from PdfString::Write has a buffer overflow – it checks > buffer.GetSize() > 0 then sets nInputBufferLen=GetSize()-2 which is passed > to new[nInputBufferLen] and memcpy I'd like to contribute

[Podofo-users] PoDoFo PdfString::Write buffer overflow

2018-04-19 Thread Mark Rogers
Hi This code from PdfString::Write has a buffer overflow – it checks buffer.GetSize() > 0 then sets nInputBufferLen=GetSize()-2 which is passed to new[nInputBufferLen] and memcpy if( pEncrypt && m_buffer.GetSize() && IsValid() ) { pdf_long nInputBufferLen = m_buffer.GetSize() - 2; // Cut off th