Garret Rieger
bdb50f1c6e
[repacker] Also rename api method from hb_subset_repack_or_fail -> hb_subset_serialize_or_fail.
2025-01-07 13:39:51 -07:00
Garret Rieger
056504168c
[repacker] rename hb-subset-repacker -> hb-subset-serialize.
...
Also hb_link_t and hb_object_t to hb_subset_serialize_link_t and hb_subset_serialize_object_t.
2025-01-07 13:39:51 -07:00
Garret Rieger
5a6f5922dd
[repacker] Promote repacking API to stable.
...
For #227 .
2025-01-07 11:28:38 -07:00
Julien Nabet
e157205499
unused-parameter in test/fuzzing/hb-draw-fuzzer.cc
...
../test/fuzzing/hb-draw-fuzzer.cc:19:28: error: unused parameter 'dfuncs' [-Werror,-Wunused-parameter]
_move_to (hb_draw_funcs_t *dfuncs, void *draw_data_,
^
../test/fuzzing/hb-draw-fuzzer.cc:22:10: error: unused parameter 'user_data' [-Werror,-Wunused-parameter]
void *user_data)
^
../test/fuzzing/hb-draw-fuzzer.cc:31:28: error: unused parameter 'dfuncs' [-Werror,-Wunused-parameter]
_line_to (hb_draw_funcs_t *dfuncs, void *draw_data_,
^
../test/fuzzing/hb-draw-fuzzer.cc:34:10: error: unused parameter 'user_data' [-Werror,-Wunused-parameter]
void *user_data)
^
../test/fuzzing/hb-draw-fuzzer.cc:44:33: error: unused parameter 'dfuncs' [-Werror,-Wunused-parameter]
_quadratic_to (hb_draw_funcs_t *dfuncs, void *draw_data_,
^
../test/fuzzing/hb-draw-fuzzer.cc:46:15: error: unused parameter 'control_x' [-Werror,-Wunused-parameter]
float control_x, float control_y,
^
../test/fuzzing/hb-draw-fuzzer.cc:46:32: error: unused parameter 'control_y' [-Werror,-Wunused-parameter]
float control_x, float control_y,
^
../test/fuzzing/hb-draw-fuzzer.cc:48:15: error: unused parameter 'user_data' [-Werror,-Wunused-parameter]
void *user_data)
^
../test/fuzzing/hb-draw-fuzzer.cc:58:29: error: unused parameter 'dfuncs' [-Werror,-Wunused-parameter]
_cubic_to (hb_draw_funcs_t *dfuncs, void *draw_data_,
^
../test/fuzzing/hb-draw-fuzzer.cc:60:11: error: unused parameter 'control1_x' [-Werror,-Wunused-parameter]
float control1_x, float control1_y,
^
../test/fuzzing/hb-draw-fuzzer.cc:60:29: error: unused parameter 'control1_y' [-Werror,-Wunused-parameter]
float control1_x, float control1_y,
^
../test/fuzzing/hb-draw-fuzzer.cc:61:11: error: unused parameter 'control2_x' [-Werror,-Wunused-parameter]
float control2_x, float control2_y,
^
../test/fuzzing/hb-draw-fuzzer.cc:61:29: error: unused parameter 'control2_y' [-Werror,-Wunused-parameter]
float control2_x, float control2_y,
^
../test/fuzzing/hb-draw-fuzzer.cc:63:11: error: unused parameter 'user_data' [-Werror,-Wunused-parameter]
void *user_data)
^
../test/fuzzing/hb-draw-fuzzer.cc:73:31: error: unused parameter 'dfuncs' [-Werror,-Wunused-parameter]
_close_path (hb_draw_funcs_t *dfuncs, void *draw_data_,
^
../test/fuzzing/hb-draw-fuzzer.cc:75:13: error: unused parameter 'user_data' [-Werror,-Wunused-parameter]
void *user_data)
^
16 errors generated.
2024-10-06 22:48:37 +03:00
Khaled Hosny
cf1fdf1632
Drop autotools build
...
Fixes https://github.com/harfbuzz/harfbuzz/issues/4720
2024-06-27 15:28:38 +03:00
Behdad Esfahbod
49c8493f5c
[test] Build with HB_MINI
...
Also add CONFIG.md instructions for building configs with meson.
Fixes https://github.com/harfbuzz/harfbuzz/issues/4760
2024-06-20 11:17:10 -07:00
Garret Rieger
0660a4d408
[subset] fix fuzzer found heap use after free in BASE subsetting.
2024-05-13 13:39:20 -07:00
Behdad Esfahbod
ba1f194a1d
[gsubgpos] Reduce stack use in recursion
2024-05-02 16:37:51 -05:00
Garret Rieger
c84acc8e07
[subset] Fix fuzzer found memory leak.
...
Fixes https://oss-fuzz.com/testcase-detail/6159925345583104 .
2024-04-09 08:41:32 -05:00
Garret Rieger
ef1f5c4e0c
[subset] Re-use common Coverage subsetting function in PairPosFormat2.
...
Was using an identical but less efficient version. Fixes fuzzer test case: https://oss-fuzz.com/testcase-detail/6151390002806784
2024-01-08 15:34:45 -07:00
Garret Rieger
333946b00e
[subset] Fix fuzzer timeout.
...
Fixes https://oss-fuzz.com/testcase-detail/5458896606855168 . Limit iteration over coverage in MarkLigPosFormat1 subsetting to the number of glyphs in the liga array.
2023-09-28 14:22:51 -06:00
Qunxin Liu
9ceb800ac2
fuzzer fix https://oss-fuzz.com/testcase-detail/5842152921628672
...
Access TupleVariationData through blob, because we don't sanitize
var_data
2023-09-28 12:51:44 -06:00
Qunxin Liu
fd3eb2c672
fuzzer fix: https://oss-fuzz.com/testcase-detail/6032126569742336
2023-09-05 21:51:02 +03:00
Garret Rieger
a1f034eaac
[repacker] fix fuzzer failure.
...
Fixes: https://oss-fuzz.com/testcase-detail/6490945267564544
2023-08-28 23:17:13 -04:00
Garret Rieger
ca906e8747
[repacker] fix fuzzer timeout.
...
Corrects some mistakes in the handling of incoming_edges_ when memory allocation failures happen.
2023-08-17 12:01:44 -06:00
Behdad Esfahbod
94d4283b12
[graph] Handle a malloc fail
...
Fixes https://oss-fuzz.com/testcase-detail/4579249263345664
2023-08-01 15:06:01 -06:00
Behdad Esfahbod
997986ab30
[subset/hvar] Error handling
...
Fixes https://oss-fuzz.com/testcase-detail/5029952234586112
2023-07-09 15:16:06 -06:00
Behdad Esfahbod
f60dbd906a
Fix thinko
...
Fixes https://oss-fuzz.com/testcase-detail/4787105656864768
2023-07-08 16:21:24 -06:00
Behdad Esfahbod
25297408de
[COLR] Fix PaintComposite sanitize timeout
...
Was timing out after recent sanitize() change.
Fixes https://oss-fuzz.com/testcase-detail/5692635449524224
2023-07-03 10:35:27 -06:00
Behdad Esfahbod
0cf759b0d4
[Glyph] Don't shift anchored Composite if phantom_only
...
Fixes https://oss-fuzz.com/testcase-detail/5114131137822720
2023-07-02 12:15:43 -06:00
Behdad Esfahbod
cc44b3bce0
[subset/cff1] Handle an error condition
...
Fixes https://oss-fuzz.com/testcase-detail/5191907895279616
2023-06-29 16:13:19 -06:00
Behdad Esfahbod
62f5ed461e
[subset/cff] Fix an infinite loop
...
Fixes https://oss-fuzz.com/testcase-detail/5419002026131456
2023-06-28 12:04:28 -06:00
Behdad Esfahbod
347b944811
[null] Fix getting Crap(hb_bytes_t)
...
Fixes https://oss-fuzz.com/testcase-detail/6187272924692480
2023-06-26 18:10:36 -06:00
Behdad Esfahbod
6c4f975dcb
Add a fuzzer font
2023-06-25 23:37:08 -06:00
Garret Rieger
db700b5670
[subset] fix fuzzer timeout.
...
Fixes: https://oss-fuzz.com/testcase-detail/6681253479579648 . Limits iteration of coverage table during MATH subset to valid glyphs.
2023-06-13 08:42:36 -06:00
Behdad Esfahbod
2e6919d526
[subset/cff2] Error handling
...
Fixes https://oss-fuzz.com/testcase-detail/4916785942757376
2023-06-10 10:08:56 -06:00
Behdad Esfahbod
d08aee5a7e
Add fuzzing test
2023-06-08 13:20:28 -06:00
Behdad Esfahbod
ada1e9a924
[graph/serialize] Handle empty blob
...
Fixes https://oss-fuzz.com/testcase-detail/4877513265119232
2023-06-06 14:46:47 -06:00
Behdad Esfahbod
a92b288e65
[serializer] Handle snapshotting when current is nullptr
...
Happens with memory failure / fuzzing.
Fixes https://oss-fuzz.com/testcase-detail/6292420615340032
2023-06-06 14:32:25 -06:00
Behdad Esfahbod
c2eaedd2cd
[fuzzing] Add a test font
...
From https://oss-fuzz.com/testcase-detail/5855710991482880
2023-06-04 09:25:17 -06:00
Garret Rieger
f3b4d35f36
[subset] Fix fuzzer crash.
...
https://oss-fuzz.com/testcase-detail/6608005089853440
2023-05-30 18:56:48 +02:00
Garret Rieger
20c564bc76
[repacker] Fix fuzzer memory leak.
...
https://oss-fuzz.com/testcase-detail/6419865171525632
2023-05-27 01:16:46 +02:00
Garret Rieger
a652281ed6
[subset] Fix fuzzer timeout.
...
Fixes https://oss-fuzz.com/testcase-detail/5979721620652032 . Timeout was caused by degenerate map insert behaviour due to poor integer hash function. Presize the map to avoid it. Also fixes collect_mapping() for cmap format 13.
2023-05-27 00:25:47 +02:00
Garret Rieger
db23be642f
[subset] clamp head *Min/*Max values to fit within 16 bit signed int.
...
Fixes fuzzer https://oss-fuzz.com/testcase-detail/4549472192692224 .
2023-05-01 20:28:58 -06:00
Garret Rieger
b3fed4fa64
[repacker] fix fuzzer found memory leak.
...
Fixes https://oss-fuzz.com/testcase-detail/5196242811748352
2023-04-27 17:18:47 -06:00
Garret Rieger
2175f5d050
[subset] Fix inefficient ItemVariationStore subsetting w/ retain_gids.
...
ItemVariationStore is relying on the assumption that the inner_map is populated for all output glyphs, this is not true for subsetting operations with retain gids enabled. Fixes fuzzer timeout: https://oss-fuzz.com/testcase-detail/4575222591520768 .
2023-04-24 18:11:48 -06:00
Garret Rieger
647b024784
[subset] Fix fuzzer issue https://oss-fuzz.com/testcase-detail/6521393809588224
2023-04-18 13:21:46 -06:00
Garret Rieger
2cd81fdfb6
[subset] fix memory leak.
...
Fixes fuzzer issue https://oss-fuzz.com/testcase-detail/6169920089227264
2023-03-30 16:19:41 -06:00
Garret Rieger
be87200106
[subset] fix buffer overflow fuzzer reported issue.
2023-03-25 10:11:46 -04:00
Garret Rieger
79ae6b657f
[subset] Fix fuzzer found memory leaks.
2023-03-25 10:11:46 -04:00
Garret Rieger
f0f7f22525
[subset] fix fuzzer found null deref.
...
https://oss-fuzz.com/testcase-detail/5844352760152064
2023-03-21 11:41:09 -06:00
Garret Rieger
3d05b96181
[subset] track which glyphs have allocated memory so we can clean up correctly.
...
Fixes https://oss-fuzz.com/testcase-detail/5388270411579392
2023-03-13 16:03:58 -06:00
Garret Rieger
7a87b17742
Check for failed subset input creation in the fuzzer.
2023-03-13 15:21:25 -06:00
Garret Rieger
28b05e1cb6
[subset] Fix memory leak in glyf subset.
...
Fixes fuzzer issue: https://oss-fuzz.com/testcase-detail/6525813890875392 .
2023-03-08 17:02:04 -07:00
Garret Rieger
9286e12525
Don't subset a glyf table with an unknown format.
...
Fixes fuzzer issue: https://oss-fuzz.com/testcase-detail/4875306193518592
2023-03-08 14:51:54 -07:00
Behdad Esfahbod
2d33a6b4df
[subset-fuzzer] Protect against overflow
...
Fixes
https://github.com/harfbuzz/harfbuzz/issues/4137#issuecomment-1448994447
2023-02-28 15:31:45 -07:00
Garret Rieger
c0fac016dc
[subset] update the subset fuzzer to be able to reach instancing code.
2023-02-27 15:07:04 -07:00
Garret Rieger
918193ebf9
[subset] fix a class of fuzzer timeouts caused by large shared coverage tables.
...
More acurately estimates the op count for CoverageFormat2 tables as the population size instead of the size in bytes.
2023-02-22 16:57:39 -07:00
Behdad Esfahbod
64fa5cd482
[GPOS] Fix assert fail introduced recently
...
Was introduced in 8708b9e081
.
If these lookups are recursed to from (Chain)Context out-of-order,
it was possible that last_base > buffer->idx, in which case we
were attaching marks to a base after them... and an assertion
was failing fortunately.
Fixes https://oss-fuzz.com/testcase-detail/6377756666757120
2023-02-07 15:52:53 -07:00
Garret Rieger
e4fff64ce3
[repacker] check duplicate() for success.
...
Fixes fuzzer testcase https://oss-fuzz.com/testcase-detail/5475787333828608 .
2023-01-23 18:37:13 -07:00