Skip to content

Conversation

@kernel-patches-daemon-bpf-rc
Copy link

Pull request for series with
subject: Follow-up fix for potential error pointer dereference in propagate_to_outer_instance()
version: 1
url: https://patchwork.kernel.org/project/netdevbpf/list/?series=1012274

@kernel-patches-daemon-bpf-rc
Copy link
Author

Upstream branch: 5fb750e
series: https://patchwork.kernel.org/project/netdevbpf/list/?series=1012274
version: 1

@kernel-patches-daemon-bpf-rc
Copy link
Author

Upstream branch: 0c1999e
series: https://patchwork.kernel.org/project/netdevbpf/list/?series=1012274
version: 1

@kernel-patches-daemon-bpf-rc
Copy link
Author

Upstream branch: 8adc470
series: https://patchwork.kernel.org/project/netdevbpf/list/?series=1012274
version: 1

…to_outer_instance()

propagate_to_outer_instance() calls get_outer_instance() and then uses the
returned pointer to reset/commit stack write marks. When get_outer_instance()
fails (e.g., __lookup_instance() returns -ENOMEM), it may return an ERR_PTR.
Without a check, the code dereferences this error pointer.

Protect the call with IS_ERR() and propagate the error.

Fixes: b3698c3 ("bpf: callchain sensitive stack liveness tracking
using CFG")
Reported-by: kernel-patches-review-bot (kernel-patches/bpf#10006 (comment))
Signed-off-by: Shardul Bankar <[email protected]>
@kernel-patches-daemon-bpf-rc
Copy link
Author

At least one diff in series https://patchwork.kernel.org/project/netdevbpf/list/?series=1012274 expired. Closing PR.

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

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants