Mageia Bugzilla – Attachment 10135 Details for
Bug 22961
qpdf new security issue CVE-2018-9918
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
Log In
[x]
|
New Account
|
Forgot Password
Demo program for the listed PoC
openpdf.cc (text/plain), 438 bytes, created by
Len Lawrence
on 2018-05-08 00:34:20 CEST
(
hide
)
Description:
Demo program for the listed PoC
Filename:
MIME Type:
Creator:
Len Lawrence
Created:
2018-05-08 00:34:20 CEST
Size:
438 bytes
patch
obsolete
> >#include <string.h> >#include <stdlib.h> >#include <qpdf/QPDF.hh> >#include <qpdf/QUtil.hh> >#include <stdint.h> > >int main(void) >{ > int pageno = 2; > try > { > QPDF pdf; > pdf.processFile("fuzzed.pdf"); > std::vector pages = pdf.getAllPages(); > if ((pageno < 1) || (static_cast<size_t>(pageno) > pages.size())) > { > exit(1); > } > } > catch (std::exception& e) > { > return 0; > } > return 0; >}
#include <string.h> #include <stdlib.h> #include <qpdf/QPDF.hh> #include <qpdf/QUtil.hh> #include <stdint.h> int main(void) { int pageno = 2; try { QPDF pdf; pdf.processFile("fuzzed.pdf"); std::vector pages = pdf.getAllPages(); if ((pageno < 1) || (static_cast<size_t>(pageno) > pages.size())) { exit(1); } } catch (std::exception& e) { return 0; } return 0; }
View Attachment As Raw
Actions:
View
Attachments on
bug 22961
:
10132
| 10135