Skip to content

drivers: hwinfo: Avoid kernel memory leak to user - #4610

Open
bjarki-andreasen wants to merge 1 commit into
nrfconnect:ncs-v3.4-branchfrom
bjarki-andreasen:avoid_kernel_memory_leak_to_user_v3_4_branch
Open

bjarki-andreasen wants to merge 1 commit into
nrfconnect:ncs-v3.4-branchfrom
bjarki-andreasen:avoid_kernel_memory_leak_to_user_v3_4_branch

Conversation

@bjarki-andreasen

Copy link
Copy Markdown
Contributor

cherry pick of drivers: hwinfo: Avoid kernel memory leak to user

z_vrfy_hwinfo_get_reset_cause() and
z_vrfy_hwinfo_get_supported_reset_cause() pass an uninitialized stack
variable to the implementation and then copy it to the user buffer
whatever the implementation returned. In those cases memory from
kernel stack are copied to user memory.

Signed-off-by: Flavio Ceolin <flavio@hubble.com>

(cherry picked from commit b98e1c7)
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

Successfully merging this pull request may close these issues.

2 participants