Merge pull request #329 from iibclothier/master

Remedy CVE-2018-12913
This commit is contained in:
Martin Raiber 2024-12-29 22:45:57 +01:00 committed by GitHub
commit 0c30a001bc
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 8 additions and 2 deletions

View File

@ -16,7 +16,7 @@ jobs:
fuzz-seconds: 900
dry-run: false
- name: Upload Crash
uses: actions/upload-artifact@v1
uses: actions/upload-artifact@v4
if: failure()
with:
name: artifacts

View File

@ -491,6 +491,12 @@ extern "C"
bit_buf >>= code_len;
num_bits -= code_len;
/* assert(sym2 != 0 && counter != 0); */
if (sym2 == 0 && counter == 0)
{
TINFL_CR_RETURN_FOREVER(40, TINFL_STATUS_FAILED);
}
pOut_buf_cur[0] = (mz_uint8)counter;
if (sym2 & 256)
{