Commit Graph

897 Commits

Author SHA1 Message Date
Nathan Loewen
a5ba0bbdf0 let freerdp_image_scale() determine step size 2020-09-14 09:21:33 +02:00
Armin Novak
47d02a76ce Fixed missing input length check for color pointer. 2020-08-10 12:26:33 +02:00
Armin Novak
57b405ca26 Fixed compilation warnings. 2020-08-10 12:14:11 +02:00
akallabeth
c5984ff811 Filter GSM codec for microphone redirection 2020-06-29 13:26:15 +02:00
Pascal Nowack
f25fbaee9c nsc: Fix memory leak
Fixes the following memory leak:

==115716== 16,662,960 bytes in 459 blocks are definitely lost in loss record 3,504 of 3,504
==115716==    at 0x48396AF: malloc (vg_replace_malloc.c:306)
==115716==    by 0x4C6A4E2: nsc_context_initialize_encode (nsc_encode.c:77)
==115716==    by 0x4C6A4E2: nsc_compose_message (nsc_encode.c:497)
2020-06-29 08:12:13 +02:00
akallabeth
0a98c450c5 Fixed out of bound read in RLEDECOMPRESS
CVE-2020-4033 thanks to @antonio-morales for finding this.
2020-06-22 11:51:39 +02:00
akallabeth
733026dada Fixed #6267: adjust write_pixel_16 endian handling 2020-06-08 15:10:24 +02:00
akallabeth
489cb26ac3 Fixed multiple sanitizer errors in codecs 2020-05-20 15:10:07 +02:00
akallabeth
6e59d9597c Fixed history buffer reset. 2020-05-20 15:10:07 +02:00
akallabeth
9b0b47496f Fixed undefined behaviour in ncrush 2020-05-20 15:10:07 +02:00
akallabeth
a1dd25e219 Fixed undefined behaviour in rfx decoder 2020-05-20 15:10:07 +02:00
akallabeth
ee160fc414 Fixed UndefinedBehaviour in planar left shift 2020-05-20 15:10:07 +02:00
akallabeth
722790f4ca Always require aligned memory for interleaved codec. 2020-05-20 15:10:07 +02:00
Kobi Mizrachi
8d72051ab1 codec: fix typo in progressive codec log 2020-05-20 10:31:51 +03:00
Vladyslav Hordiienko
f79bb517c1 improve RFX DWT algorithm
merge multiple loops into the one loop for vertical DWT inverse
2020-05-18 10:56:40 +02:00
akallabeth
3a06ce058f Fixed oob read in rfx_process_message_tileset
Check input data length
Thanks to hac425 CVE-2020-11043
2020-05-06 13:31:57 +02:00
akallabeth
363d7046df Fixed oob read in clear_decompress_subcode_rlex
Fixed length checks before stream read.
Thanks to hac425 CVE-2020-11040
2020-05-06 13:31:57 +02:00
akallabeth
a167f3b779 Fixed possible int overflow. 2020-05-06 13:31:57 +02:00
akallabeth
ca6d2d1b2c Workaround #6072: FFMPEG AAC encoding graded experimental
Due to many reporing issues with different AAC encoder configurations
deactivate support by default. Can be enabled by compiling with
experimental codec support.
2020-04-28 12:39:32 +02:00
Raul Fernandes
db9052e37f Optimize function xcrush_copy_bytes()
Use memcpy to copy the bytes when we can assure that the memory areas does not overlap.
When the areas overlap, copy the area that doesn't overlap repeatly.
With this change, the copy is ~30x faster.
2020-04-25 16:25:36 +02:00
akallabeth
c81feb36b0 Refactored freerdp_image_copy_from_pointer_data
Split monochrome and color pointer handling to separate functions.
2020-04-22 14:21:47 +02:00
Raul Fernandes
971be4fe9b Cache the calculated color
In desktop area, the next color has high odds to be the same of previous color.
If we cache the value, it can be reused by the next pixel avoiding recalculation.
This optimization can halve the function's processing.
2020-04-15 13:25:52 +02:00
akallabeth
1a4f0badf7 Moved PROGRESSIVE_BLOCK_REGION to heap. 2020-04-14 18:27:05 +02:00
akallabeth
17f547ae11 Fixed CVE-2020-11521: Out of bounds write in planar codec.
Thanks to Sunglin and HuanGMz from Knownsec 404
2020-04-09 18:00:51 +02:00
akallabeth
7b1d4b4939 Fix CVE-2020-11524: out of bounds access in interleaved
Thanks to Sunglin and HuanGMz from Knownsec 404
2020-04-09 18:00:51 +02:00
Armin Novak
436b68e416 Fixed #5895: cast warnings. 2020-02-19 10:21:43 +01:00
Armin Novak
c0bf6c0768 working progressive Original Method DWT
Implemented decoding utilizing Original Method DWT
(See [MS-RDPEGFX] 3.2.8.1.2.2 Reduce-Extrapolate Method)
2020-02-18 11:13:52 +01:00
Armin Novak
1fa00c4318 Refactored progressive codec. 2020-02-18 11:13:52 +01:00
Armin Novak
c92bbb37f5 Fixed NULL dereference. 2020-01-23 10:12:12 +01:00
Armin Novak
b0b81af8b8 Fixed #5839: Use correct pointer to cast. 2020-01-16 09:53:57 +01:00
Armin Novak
1c19de5a76 Fixed remaining issues with chroma subsampling. 2020-01-14 17:46:13 +01:00
Armin Novak
b3a642164a Fixed planar size checks. 2020-01-14 15:14:40 +01:00
Armin Novak
c1679d0f2c Added planar RLE chroma subsampling. 2020-01-14 14:06:43 +01:00
Armin Novak
6fd9525823 Implemented chroma subsampling for planar non RLE
Planar frames that are not RLE encoded can now be decoded if
chroma subsampling is enabled. Partly fixes #5822
2020-01-14 12:43:40 +01:00
Martin Fleisz
71feb974ac
Merge pull request #5739 from akallabeth/improve_function_hiding
Improve function hiding
2019-12-02 11:31:35 +01:00
Armin Novak
7c243da6e1 Remove symbols exported by accident. 2019-12-02 10:57:31 +01:00
David Fort
5f0943f0fe primitives: add openCL support
This patch adds the basic infrastructure to have openCL acceleration.
For now only YUV2RGB is implemented but other operations could be
implemented.
The primitives have been massively reworked so that we have an autodetect
mode that will pick the best implementation automatically by performing a
benchmark.

Sponsored-by: Rangee Gmbh(http://www.rangee.com)
2019-11-22 13:21:39 +01:00
Armin Novak
68ed1276c2 MPPC_CONTEXT now opaque 2019-11-14 15:16:36 +01:00
Armin Novak
e83f65b062 NCRUSH_CONTEXT now opaque 2019-11-14 15:16:36 +01:00
Armin Novak
f0353de828 XCRUSH_CONTEXT now opaque 2019-11-14 15:16:36 +01:00
Armin Novak
6afa413669 Modified primitives function pointer to take const pointer to const data 2019-11-14 10:46:24 +01:00
Armin Novak
72ca88f49c Reformatted to new style 2019-11-07 10:53:54 +01:00
Raphaël ZHOU
31962b2fa6 Fix padding of encoded scan-line for XOR mask of pointer. 2019-11-07 10:12:22 +01:00
asapelkin
82eadad4a4 Fix some static analizer warnings 2019-10-22 15:39:54 +02:00
Armin Novak
59b4988f56 Fixed compilation warnings. 2019-10-16 14:54:05 +02:00
Martin Fleisz
799685cb92
Merge pull request #5646 from akallabeth/realloc_fixes
Fixed #5645: realloc return handling
2019-10-07 10:43:11 +02:00
Martin Fleisz
ade6b1007b
Merge pull request #5644 from akallabeth/nsc_cleanup
Cleaned up NSC API
2019-10-07 09:01:26 +02:00
Armin Novak
9fee4ae076 Fixed #5645: realloc return handling 2019-10-04 16:19:23 +02:00
Armin Novak
74f01aab15 Removed check for wrong buffer size. 2019-10-04 11:46:14 +02:00
Armin Novak
e09f739b90 Cleaned up NSC API 2019-10-04 10:33:41 +02:00