You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
EPDFText_GetCharGeometry crashes with null pointer on malformed PDFs #85
Calling EPDFText_GetCharGeometry on broken or fuzzed PDFs causes a segmentation fault (AddressSanitizer: SEGV).
This happens when a text object in the PDF has text but no font set.
Crash Trace
#0 CPDF_TextState::GetFont() const at cpdf_textstate.cpp:29
#1 GetCharLocalBoxes(...) at cpdf_textpage.cpp:289
#2 CPDF_TextPage::GetCharLocalGeometry(...) at cpdf_textpage.cpp:678
#3 EPDFText_GetCharGeometry(...) at fpdf_text.cpp:396
Due to this in jpdfium_redact.cpp, EPDFText_GetCharGeometry was removed from bridge. Currently, PDF passed with normal /Rect bounding boxes to EmbedPDF redaction instead of character quads. This workaround may yield some reliability issues, so if/when this fixed, evaluate to migrate back.
Activity