-
Notifications
You must be signed in to change notification settings - Fork 6.6k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[M-118] usb: Validate isochronous transfer packet lengths
USBDevice.isochronousTransferIn and USBDevice.isochronousTransferOut take a parameter containing a list of packet lengths. This CL adds validation that the total packet length does not exceed the maximum buffer size. For isochronousTransferOut, it also checks that the total length of all packets in bytes is equal to the size of the data buffer. Passing invalid packet lengths causes the promise to be rejected with a DataError. (cherry picked from commit bb36f73) Bug: 1492381, 1492384 Change-Id: Id9ae16c7e6f1c417e0fc4f21d53e9de11560b2b7 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/4944690 Reviewed-by: Reilly Grant <reillyg@chromium.org> Commit-Queue: Matt Reynolds <mattreynolds@chromium.org> Cr-Original-Commit-Position: refs/heads/main@{#1212916} Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/4974416 Commit-Queue: Reilly Grant <reillyg@chromium.org> Auto-Submit: Matt Reynolds <mattreynolds@chromium.org> Cr-Commit-Position: refs/branch-heads/5993@{#1425} Cr-Branched-From: 5113507-refs/heads/main@{#1192594}
- Loading branch information
Showing
4 changed files
with
259 additions
and
11 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters