-
Notifications
You must be signed in to change notification settings - Fork 12
[FIPS 8 Compliant] CVE-2024-58002 #601
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
[FIPS 8 Compliant] CVE-2024-58002 #601
Conversation
jira VULN-53462 jira VULN-53461 cve-pre CVE-2024-58002 commit-author Ricardo Ribalda <ribalda@chromium.org> commit 64627da Avoid using the iterators after the list_for_each() constructs. This patch should be a NOP, but makes cocci, happier: drivers/media/usb/uvc/uvc_ctrl.c:1861:44-50: ERROR: invalid reference to the index variable of the iterator on line 1850 drivers/media/usb/uvc/uvc_ctrl.c:2195:17-23: ERROR: invalid reference to the index variable of the iterator on line 2179 Reviewed-by: Sergey Senozhatsky <senozhatsky@chromium.org> Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Ricardo Ribalda <ribalda@chromium.org> Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl> (cherry picked from commit 64627da) Signed-off-by: Jonathan Maple <jmaple@ciq.com>
jira VULN-53462 jira VULN-53461 cve-pre CVE-2024-58002 commit-author Ricardo Ribalda <ribalda@chromium.org> commit d9fecd0 Now we keep a reference to the active fh for any call to uvc_ctrl_set, regardless if it is an actual set or if it is a just a try or if the device refused the operation. We should only keep the file handle if the device actually accepted applying the operation. Cc: stable@vger.kernel.org Fixes: e5225c8 ("media: uvcvideo: Send a control event when a Control Change interrupt arrives") Suggested-by: Hans de Goede <hdegoede@redhat.com> Reviewed-by: Hans de Goede <hdegoede@redhat.com> Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Ricardo Ribalda <ribalda@chromium.org> Link: https://lore.kernel.org/r/20241203-uvc-fix-async-v6-1-26c867231118@chromium.org Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org> (cherry picked from commit d9fecd0) Signed-off-by: Jonathan Maple <jmaple@ciq.com>
jira VULN-53462 jira VULN-53461 cve CVE-2024-58002 commit-author Ricardo Ribalda <ribalda@chromium.org> commit 221cd51 upstream-diff used kernel-lt 5.15 commit 117f7a2 This is due to missing both: - e8c0708 - Kbuild: move to -std=gnu11 - 54da6a0 - locking: Introduce __cleanup() based infrastructure When an async control is written, we copy a pointer to the file handle that started the operation. That pointer will be used when the device is done. Which could be anytime in the future. If the user closes that file descriptor, its structure will be freed, and there will be one dangling pointer per pending async control, that the driver will try to use. Clean all the dangling pointers during release(). To avoid adding a performance penalty in the most common case (no async operation), a counter has been introduced with some logic to make sure that it is properly handled. Cc: stable@vger.kernel.org Fixes: e5225c8 ("media: uvcvideo: Send a control event when a Control Change interrupt arrives") Reviewed-by: Hans de Goede <hdegoede@redhat.com> Signed-off-by: Ricardo Ribalda <ribalda@chromium.org> Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Link: https://lore.kernel.org/r/20241203-uvc-fix-async-v6-3-26c867231118@chromium.org Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> (cherry picked from commit 117f7a2) Signed-off-by: Jonathan Maple <jmaple@ciq.com>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🥌
It looks correct. But I have some questions related to the third commit.
I hope this makes sense. Let me know what you think. I believe this could be solved in check_kernel_commits script easily and I would be happy to do that. |
This is already included in the commit message, but I am not sure if this follows a specific format. It gave me the impression you wrote it yourself.
|
You are right, we don't have a common reference to all LTs in this repo, only 6.12.y right now. When we backport from other LTs we are just using local references to those trees.
We like having the reference to the mainline commit in there, but I do think it would be a good idea to codify when we cherry-pick from someplace else. Right now its just a free form thing in the upstream-diff section, but if we came up with a defined way to reference this then tooling like check_kernel_commits could use it.
Same as above, if we had a codified way to call out backports from places other than mainline, then interdiff based tooling could use it too.
It does! Feel free to make PRs to kernel-src-tree-tools to improve/extend check_kernel_commits. Thanks! |
Both what @roxanan1996 and @bmastbergen said is correct. The reason, to Brett's point, on why we don't mirror all the LT branches into this repo is that this repo is already nearly 6GiB checkout. Additionally Red Hat has backported 120,000+ commits from Mainline into this "4.18.0" kernel. Check our We have a default formatting here: https://github.com/ctrliq/kernel-src-tree/wiki#commit-message-header WRT to the cherry-pick line, you're 100% correct I forgot about this aspect of the commit process.
As with what Brett said maybe we can expand Open to suggestions and its a good set of comments thanks for diggin into the commit and content. |
Thanks for your feedback. I will create a jira ticket (still need to figure out where) with a summary of the discussion and plan of attack. |
Basically the 8.10 version of this PR: #548
BUILD
KSelfTest
KselfTest Diff Experimental