cherry-pick.FILE5_32-65-gfc4b6e34.drop-the-limit-lower-to-satisfy-oss-fuzz-4682.patch 599 B

123456789101112131415161718
  1. Subject: Drop the limit lower to satisfy oss-fuzz 4682
  2. Origin: FILE5_32-65-gfc4b6e34 <https://github.com/file/file/commit/FILE5_32-65-gfc4b6e34>
  3. Upstream-Author: Christos Zoulas <christos@zoulas.com>
  4. Date: Tue Dec 19 00:21:21 2017 +0000
  5. --- a/src/cdf.c
  6. +++ b/src/cdf.c
  7. @@ -840,8 +840,8 @@
  8. return 0;
  9. }
  10. -#define CDF_SHLEN_LIMIT (UINT32_MAX / 8)
  11. -#define CDF_PROP_LIMIT (UINT32_MAX / (8 * sizeof(cdf_property_info_t)))
  12. +#define CDF_SHLEN_LIMIT (UINT32_MAX / 64)
  13. +#define CDF_PROP_LIMIT (UINT32_MAX / (64 * sizeof(cdf_property_info_t)))
  14. static const void *
  15. cdf_offset(const void *p, size_t l)