Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

bpp-recv/defec.c: null-pointer deref in defecInit() #198

Open
pesco opened this issue Aug 8, 2017 · 0 comments
Open

bpp-recv/defec.c: null-pointer deref in defecInit() #198

pesco opened this issue Aug 8, 2017 · 0 comments
Assignees

Comments

@pesco
Copy link

pesco commented Aug 8, 2017

if defecInit is called after defecRecv processed a parameter packet
(serial=0) that specifies an invalid decoder algorithm, the parameters are
already in savedStatus so a subsequent defecInit will attempt to restore
the decoder but yield NULL, leading to a crash in

      currDecoder->init(currK, currN, maxLen);

this can happen if an invalid parameter packet is received before the system
enters deep sleep (-> defecInit after wakeup).

likewise, if the decoder parameters (k/n) are invalid, the unchecked call above will fail and subsequent decoder calls will access uninitialized memory or reuse stale values.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants