Address sanitizer flagged stack buffer overflows in sc_loads_tests.c
Nobody has claimed this yet.
- Dominant language
- C
- Stars
- 46
- Forks
- 39
- PR merge metrics
- No merged PRs in 30d
Description
I enabled the address sanitizer and it flagged
SC_LoadAts_Test_AtsEntryOverflow(void)
https://github.com/nasa/SC/blob/draco-rc5/unit-test/sc_loads_tests.c#L412
for a stack buffer overflows.
The issue, is that the function
AtsTable size is too small.
https://github.com/nasa/SC/blob/draco-rc5/unit-test/sc_loads_tests.c#L416
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Open unit-test/sc_loads_tests.c around lines 412 and 416, starting with SC_LoadAts_Test_AtsEntryOverflow(void) and the AtsTable declaration. Run this test with AddressSanitizer to reproduce the stack buffer overflow. Done means the test no longer reports an overflow after the AtsTable size is corrected.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- c
- Domain
- testing-qa
- Issue type
- Bug
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Activity status
- Stale
- Clarity
- Clearly specified
- Newbie friendliness
- 55/100