From 6cc44ae8b1d35a43c1e69df900a30d5e691019b3 Mon Sep 17 00:00:00 2001 From: Christoph Hasse Date: Fri, 26 Aug 2022 14:54:56 +0200 Subject: [PATCH] test(quicktimevideo) add poc for #2340 --- test/data/issue_2340_poc.mp4 | Bin 0 -> 80 bytes tests/bugfixes/github/test_issue_2340.py | 13 +++++++++++++ tests/regression_tests/test_regression_allfiles.py | 1 + 3 files changed, 14 insertions(+) create mode 100644 test/data/issue_2340_poc.mp4 create mode 100644 tests/bugfixes/github/test_issue_2340.py diff --git a/test/data/issue_2340_poc.mp4 b/test/data/issue_2340_poc.mp4 new file mode 100644 index 0000000000000000000000000000000000000000..ab3291b93ffe44594d7220b469a7c02bc8d41a99 GIT binary patch literal 80 acmZQzU{EN?%P+~x%+CK00t$EmK?MMuQxgjS literal 0 HcmV?d00001 diff --git a/tests/bugfixes/github/test_issue_2340.py b/tests/bugfixes/github/test_issue_2340.py new file mode 100644 index 00000000..2d98ed78 --- /dev/null +++ b/tests/bugfixes/github/test_issue_2340.py @@ -0,0 +1,13 @@ +# -*- coding: utf-8 -*- + +from system_tests import CaseMeta, check_no_ASAN_UBSAN_errors + +class issue_2320_printDegrees_integer_overflow(metaclass=CaseMeta): + url = "https://github.com/Exiv2/exiv2/issues/2340" + filename = "$data_path/issue_2340_poc.mp4" + commands = ["$exiv2 -q -pa $filename"] + retval = [1] + stderr = ["""$exiv2_exception_message $filename: +$kerCorruptedMetadata +"""] + compare_stdout = check_no_ASAN_UBSAN_errors diff --git a/tests/regression_tests/test_regression_allfiles.py b/tests/regression_tests/test_regression_allfiles.py index a2b51393..f0736bd8 100644 --- a/tests/regression_tests/test_regression_allfiles.py +++ b/tests/regression_tests/test_regression_allfiles.py @@ -58,6 +58,7 @@ def get_valid_files(data_dir): "issue_2190_poc.jp2", # non-zero return code files, most of them are security POC so we don't # really need to worry about them here + "issue_2340_poc.mp4", "2018-01-09-exiv2-crash-001.tiff", "cve_2017_1000126_stack-oob-read.webp", "exiv2-bug1247.jpg",