Skip to content

Commit

Permalink
[tests] Add regression test for second bug from #590
Browse files Browse the repository at this point in the history
(cherry picked from commit a557c7f)
  • Loading branch information
D4N committed Feb 27, 2019
1 parent 204a1cd commit 4c94767
Show file tree
Hide file tree
Showing 2 changed files with 24 additions and 0 deletions.
Binary file added test/data/tiffimage_int-out-of-bound-read-poc-2
Binary file not shown.
24 changes: 24 additions & 0 deletions tests/bugfixes/github/test_issue_590.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
# -*- coding: utf-8 -*-

import system_tests


URL = "https://github.com/Exiv2/exiv2/issues/590"


@system_tests.CopyFiles("$data_path/tiffimage_int-out-of-bound-read-poc-2")
class TiffImageIntOutOfBoundsRead(metaclass=system_tests.CaseMeta):
"""
Regression test for the second issue reported in #590.
"""

filename = system_tests.path(
"$data_path/tiffimage_int-out-of-bound-read-poc-2_copy"
)

compare_stderr = system_tests.check_no_ASAN_UBSAN_errors

commands = ["$exiv2 -Y 2011 -O 02 -D 29 adjust $filename"]
stdout = [""]
stderr = [""]
retval = [0]

0 comments on commit 4c94767

Please sign in to comment.