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

CF use of STATIC_CAST without NULL checks #37

Closed
jphickey opened this issue Nov 23, 2021 · 0 comments · Fixed by #137
Closed

CF use of STATIC_CAST without NULL checks #37

jphickey opened this issue Nov 23, 2021 · 0 comments · Fixed by #137
Milestone

Comments

@jphickey
Copy link
Contributor

This issue was imported from the GSFC issue tracking system

Imported from: [GSFCCFS-1773] CF use of STATIC_CAST without NULL checks
Originally submitted by: Hickey, Joseph P. (GSFC-582.0)[VANTAGE SYSTEMS INC] on Tue Nov 16 14:05:37 2021

Original Description:
This issue was originally reported by IV&V, creating Jira issue to track its disposition and resolution.

There are 7 instances in the CFS CF App source code in which the PDU hedaer pointer 'ph' can be a NULL value from a prior function call, and then it is passed into the function STATIC_CAST() where it is eventually dereferenced without any checks.

These calls to STATIC_CAST() pass 'ph' to CF_HeaderSize() which dereferences the pointer.

cf_cfdp.c line 476
cf_cfdp.c line 616
cf_cfdp.c line 654
cf_cfdp.c line 695
cf_cfdp_r.c line 491
cf_cfdp_s.c line 125
cf_cfdp.c line 1277

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

Successfully merging a pull request may close this issue.

2 participants