File r1937-Really-fix-CVE-2017-7383.patch of Package podofo.34526

------------------------------------------------------------------------
r1937 | mabri | 2018-08-25 00:07:55 +0200 (sáb, 25 ago 2018) | 1 line

Really fix CVE-2017-7383

Index: src/doc/PdfFontFactory.cpp
===================================================================
--- src/doc/PdfFontFactory.cpp	(revision 1936)
+++ src/doc/PdfFontFactory.cpp	(revision 1937)
@@ -192,8 +192,14 @@
     PdfObject*      pDescriptor = NULL;
     PdfObject*      pEncoding   = NULL;
 
-    if( pObject->GetDictionary().GetKey( PdfName::KeyType )->GetName() != PdfName("Font") )
+    PdfVariant* pTypeKey = pObject->GetDictionary().GetKey( PdfName::KeyType );
+    if ( NULL == pTypeKey )
     {
+        PODOFO_RAISE_ERROR_INFO( ePdfError_InvalidDataType, "Font: No Type" );
+    }
+
+    if( pTypeKey->GetName() != PdfName("Font") )
+    {
         PODOFO_RAISE_ERROR( ePdfError_InvalidDataType );
     }
 

------------------------------------------------------------------------
openSUSE Build Service is sponsored by