poppler/Linearization.cc | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
New commits: commit 6a76d21661add4f84ee0859c4e7a4c23e7a63bc4 Author: Hib Eris <[email protected]> Date: Sun Jun 10 19:44:18 2012 +0200 Check value of first page in linearization table Fixes crash in broken/fuzzed pdf sent by Mateusz "j00ru" Jurczyk and Gynvael Coldwind diff --git a/poppler/Linearization.cc b/poppler/Linearization.cc index 7b8f1e0..33331d1 100644 --- a/poppler/Linearization.cc +++ b/poppler/Linearization.cc @@ -4,7 +4,7 @@ // // This file is licensed under the GPLv2 or later // -// Copyright 2010 Hib Eris <[email protected]> +// Copyright 2010, 2012 Hib Eris <[email protected]> // //======================================================================== @@ -211,7 +211,7 @@ int Linearization::getPageFirst() linDict.getDict()->lookupInt("P", NULL, &pageFirst); } - if (pageFirst < 0) { + if ((pageFirst < 0) || (pageFirst > getNumPages())) { error(errSyntaxWarning, -1, "First page in linearization table is invalid"); return 0; } _______________________________________________ poppler mailing list [email protected] http://lists.freedesktop.org/mailman/listinfo/poppler
