<feed xmlns='http://www.w3.org/2005/Atom'>
<title>openjpeg/src/lib/openjp2/jp2.c, branch dcpomatic-2.5.4</title>
<subtitle>Fork of openjpeg library for JPEG2000 encoding and decoding</subtitle>
<id>https://git.carlh.net/cgit/openjpeg/atom?h=dcpomatic-2.5.4</id>
<link rel='self' href='https://git.carlh.net/cgit/openjpeg/atom?h=dcpomatic-2.5.4'/>
<link rel='alternate' type='text/html' href='https://git.carlh.net/cgit/openjpeg/'/>
<updated>2025-02-11T12:05:58Z</updated>
<entry>
<title>Fixed ICC profile copy failure on write (#1574)</title>
<updated>2025-02-11T12:05:58Z</updated>
<author>
<name>Mirco Miranda</name>
<email>mircomir@users.noreply.github.com</email>
</author>
<published>2025-02-11T12:05:58Z</published>
<link rel='alternate' type='text/html' href='https://git.carlh.net/cgit/openjpeg/commit/?id=578c67b3291042377ab3aa82265a304d3fdfed4a'/>
<id>urn:sha1:578c67b3291042377ab3aa82265a304d3fdfed4a</id>
<content type='text'>
</content>
</entry>
<entry>
<title>opj_jp2_read_header: Check for error after parsing header.</title>
<updated>2025-01-16T01:24:21Z</updated>
<author>
<name>Sebastian Rasmussen</name>
<email>sebras@gmail.com</email>
</author>
<published>2025-01-16T01:13:43Z</published>
<link rel='alternate' type='text/html' href='https://git.carlh.net/cgit/openjpeg/commit/?id=f809b80c67717c152a5ad30bf06774f00da4fd2d'/>
<id>urn:sha1:f809b80c67717c152a5ad30bf06774f00da4fd2d</id>
<content type='text'>
Consider the case where the caller has not set the p_image
pointer to NULL before calling opj_read_header().

If opj_j2k_read_header_procedure() fails while obtaining the rest
of the marker segment when calling opj_stream_read_data() because
the data stream is too short, then opj_j2k_read_header() will
never have the chance to initialize p_image, leaving it
uninitialized.

opj_jp2_read_header() will check the p_image value whether
opj_j2k_read_header() suceeded or failed. This may be detected as
an error in valgrind or ASAN.

The fix is to check whether opj_j2k_read_header() suceeded before
using the output argument p_image.
</content>
</entry>
<entry>
<title>Support setting enumcs for CMYK and EYCC color space (#1529)</title>
<updated>2024-06-14T12:21:12Z</updated>
<author>
<name>Andrew Murray</name>
<email>3112309+radarhere@users.noreply.github.com</email>
</author>
<published>2024-06-14T12:21:12Z</published>
<link rel='alternate' type='text/html' href='https://git.carlh.net/cgit/openjpeg/commit/?id=2f5a299cbae9856dccd98ed33971bac4d1283fd0'/>
<id>urn:sha1:2f5a299cbae9856dccd98ed33971bac4d1283fd0</id>
<content type='text'>
</content>
</entry>
<entry>
<title>opj_jp2_read_header(): move setting icc_profile here instead in opj_jp2_decode()/get_tile() + add unit test (fixes #570)</title>
<updated>2023-03-26T12:03:59Z</updated>
<author>
<name>Even Rouault</name>
<email>even.rouault@spatialys.com</email>
</author>
<published>2023-03-26T12:03:59Z</published>
<link rel='alternate' type='text/html' href='https://git.carlh.net/cgit/openjpeg/commit/?id=59ec1f0ae6edb19f45ab06792aa8902759af6954'/>
<id>urn:sha1:59ec1f0ae6edb19f45ab06792aa8902759af6954</id>
<content type='text'>
</content>
</entry>
<entry>
<title>opj_jp2_read_header(): move setting color_space here instead in opj_jp2_decode()/get_tile() (fixes #570)</title>
<updated>2023-03-17T17:16:35Z</updated>
<author>
<name>Even Rouault</name>
<email>even.rouault@spatialys.com</email>
</author>
<published>2023-03-17T17:16:35Z</published>
<link rel='alternate' type='text/html' href='https://git.carlh.net/cgit/openjpeg/commit/?id=0f528e95788863608aa1772f5370659edf618793'/>
<id>urn:sha1:0f528e95788863608aa1772f5370659edf618793</id>
<content type='text'>
</content>
</entry>
<entry>
<title>Fix Heap-buffer-overflow READ in opj_jp2_apply_pclr (#1441)</title>
<updated>2022-08-12T13:48:41Z</updated>
<author>
<name>Aleks L</name>
<email>93376818+sashashura@users.noreply.github.com</email>
</author>
<published>2022-08-12T13:48:41Z</published>
<link rel='alternate' type='text/html' href='https://git.carlh.net/cgit/openjpeg/commit/?id=be95561917aa9b1d8ea4614820a534917cfa6bbe'/>
<id>urn:sha1:be95561917aa9b1d8ea4614820a534917cfa6bbe</id>
<content type='text'>
The issue was found while fuzzing opencv:
https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=47342

The read overflow triggered by reading `src[j]` in
```cpp
            for (j = 0; j &lt; max; ++j) {
                dst[j] = src[j];
            }
```
The max is calculated as `new_comps[pcol].w * new_comps[pcol].h`, however the `src = old_comps[cmp].data;` which may have different `w` and `h` dimensions.</content>
</entry>
<entry>
<title>Add support for partial bitstream decoding (#1407) (fixes #715)</title>
<updated>2022-02-10T13:27:17Z</updated>
<author>
<name>Robert Gabriel Jakabosky</name>
<email>rjakabosky+github@neoawareness.com</email>
</author>
<published>2022-02-10T13:27:17Z</published>
<link rel='alternate' type='text/html' href='https://git.carlh.net/cgit/openjpeg/commit/?id=883c31dbe09771aab043744ac2b490d7386878e3'/>
<id>urn:sha1:883c31dbe09771aab043744ac2b490d7386878e3</id>
<content type='text'>
Add a -allow-partial option to opj_decompress utility and a opj_decoder_set_strict_mode() option to the API

Co-authored-by: Chris Hafey &lt;chafey@gmail.com&gt;</content>
</entry>
<entry>
<title>Fix potential overflow related issues spotted by LGTM code analysis (#1402)</title>
<updated>2022-01-18T20:55:10Z</updated>
<author>
<name>Eric Harvey</name>
<email>71228603+Eharve14@users.noreply.github.com</email>
</author>
<published>2022-01-18T20:55:10Z</published>
<link rel='alternate' type='text/html' href='https://git.carlh.net/cgit/openjpeg/commit/?id=241e9e8efeb6750ef4202a61b3a436628e4f6d23'/>
<id>urn:sha1:241e9e8efeb6750ef4202a61b3a436628e4f6d23</id>
<content type='text'>
</content>
</entry>
<entry>
<title>Fix some typos (found by codespell)</title>
<updated>2021-12-05T12:14:33Z</updated>
<author>
<name>Stefan Weil</name>
<email>sw@weilnetz.de</email>
</author>
<published>2021-12-05T12:04:30Z</published>
<link rel='alternate' type='text/html' href='https://git.carlh.net/cgit/openjpeg/commit/?id=667149ffa11f0255db92f522bc5b5fc8aefb16ec'/>
<id>urn:sha1:667149ffa11f0255db92f522bc5b5fc8aefb16ec</id>
<content type='text'>
Signed-off-by: Stefan Weil &lt;sw@weilnetz.de&gt;
</content>
</entry>
<entry>
<title>Testing for invalid values of width, height, numcomps (#1254)</title>
<updated>2020-06-10T15:40:50Z</updated>
<author>
<name>szukw000</name>
<email>szukw000@arcor.de</email>
</author>
<published>2020-06-10T15:40:50Z</published>
<link rel='alternate' type='text/html' href='https://git.carlh.net/cgit/openjpeg/commit/?id=25fb144c42f97489594302e1e6ff886791e0a5b3'/>
<id>urn:sha1:25fb144c42f97489594302e1e6ff886791e0a5b3</id>
<content type='text'>
</content>
</entry>
</feed>
