 media: uvcvideo: Skip parsing frames of type UVC_VS_UNDEFINED in uvc_… · gregkh/linux@1ee9d91 · GitHub Skip to content Navigation Menu Toggle navigation Sign in Appearance settings Platform AI CODE CREATION GitHub Copilot Write better code with AI GitHub Spark Build and deploy intelligent apps GitHub Models Manage and compare prompts MCP Registry New Integrate external tools DEVELOPER WORKFLOWS Actions Automate any workflow Codespaces Instant dev environments Issues Plan and track work Code Review Manage code changes APPLICATION SECURITY GitHub Advanced Security Find and fix vulnerabilities Code security Secure your code as you build Secret protection  EXPLORE Why GitHub Documentation Blog Changelog Marketplace View all features Solutions BY COMPANY SIZE Enterprises Small and medium teams Startups Nonprofits BY USE CASE App Modernization DevSecOps DevOps CI/CD View all use cases BY INDUSTRY Healthcare Financial services Manufacturing Government View all industries View all solutions Resources EXPLORE BY TOPIC AI Software Development DevOps Security View all topics EXPLORE BY TYPE Customer stories Events &amp; webinars Ebooks &amp; reports Business insights GitHub Skills SUPPORT &amp; SERVICES Documentation Customer support Community forum Trust center Partners View all resources Open Source COMMUNITY GitHub Sponsors Fund open source developers PROGRAMS Security Lab Maintainer Community Accelerator GitHub Stars Archive Program REPOSITORIES Topics Trending Collections Enterprise ENTERPRISE SOLUTIONS Enterprise platform AI-powered developer platform AVAILABLE ADD-ONS GitHub Advanced Security Enterprise-grade security features Copilot for Business Enterprise-grade AI features Premium Support Enterprise-grade 24/7 support Pricing Search or jump to... Search code, repositories, users, issues, pull requests... --> Search Clear Search syntax tips Provide feedback --> We read every piece of feedback, and take your input very seriously.  Cancel Submit feedback Saved searches Use saved searches to filter your results more quickly --> Name Query To see all available qualifiers, see our documentation . Cancel Create saved search Sign in Sign up Appearance settings Resetting focus You signed in with another tab or window. Reload to refresh your session. You signed out in another tab or window. Reload to refresh your session. You switched accounts on another tab or window. Reload to refresh your session. Dismiss alert {{ message }} gregkh / linux Public Notifications You must be signed in to change notification settings Fork 676 Star 636 Code Actions Security and quality 0 Insights Additional navigation options Code Actions Security and quality Insights Commit 1ee9d91 Browse files Browse files dlelcldkekslele authored and gregkh committed media: uvcvideo: Skip parsing frames of type UVC_VS_UNDEFINED in uvc_parse_format commit ecf2b43 upstream. This can lead to out of bounds writes since frames of this type were not taken into account when calculating the size of the frames buffer in uvc_parse_streaming. Fixes: c0efd23 ("V4L/DVB (8145a): USB Video Class driver") Signed-off-by: Benoit Sevens &lt;bsevens@google.com&gt; Cc: stable@vger.kernel.org Acked-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt; Reviewed-by: Laurent Pinchart &lt;laurent.pinchart@ideasonboard.com&gt; Signed-off-by: Hans Verkuil &lt;hverkuil@xs4all.nl&gt; Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt; 1 parent 8621725 commit 1ee9d91 Copy full SHA for 1ee9d91 1 file changed + 1 - 1 Lines changed: 1 addition &amp; 1 deletion File tree Expand file tree Collapse file tree Open diff view settings Filter options drivers/media/usb/uvc uvc_driver.c Expand file tree Collapse file tree Open diff view settings Collapse file ‎ drivers/media/usb/uvc/uvc_driver.c ‎ Copy file name to clipboard Expand all lines: drivers/media/usb/uvc/uvc_driver.c + 1 - 1 Lines changed: 1 addition &amp; 1 deletion Original file line number Diff line number Diff line change @@ -371,7 +371,7 @@ static int uvc_parse_format(struct uvc_device *dev, 371 371 * Parse the frame descriptors. Only uncompressed, MJPEG and frame 372 372 * based formats have frame descriptors. 373 373 */ 374 - while ( buflen &gt; 2 &amp;&amp; buffer [ 1 ] == USB_DT_CS_INTERFACE &amp;&amp; 374 + while ( ftype &amp;&amp; buflen &gt; 2 &amp;&amp; buffer [ 1 ] == USB_DT_CS_INTERFACE &amp;&amp; 375 375 buffer [ 2 ] == ftype ) { 376 376 unsigned int maxIntervalIndex ; 377 377 0 commit comments Comments 0 ( 0 ) Footer &copy; 2026 GitHub,&nbsp;Inc. Footer navigation Terms Privacy Security Status Community Docs Contact Manage cookies Do not share my personal information You can’t perform that action at this time. 