fix(deps): apply security fixes to td-shim-AzCVMEmu#932
Open
MichalTarnacki wants to merge 1 commit into
Open
Conversation
0fc9afb to
b476644
Compare
sgrams
requested changes
Jul 6, 2026
- tdx_emu: add bounds checks in tdcall_servtd_rebind_approve for target_td_uuid and rebind_session_token slices - idt: validate vector < 256 in register_interrupt_callback - shared: replace Box::from_raw with Layout-based dealloc in free_shared_pages, add checked_mul overflow guard Signed-off-by: Michal Tarnacki <[email protected]> Co-authored-by: GitHub Copilot <[email protected]>
b476644 to
d243b83
Compare
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The "Layout mismatch → heap UB" half is a real defect but only a weakness, not the T1/MUST-FIX it is labeled. Reconstructing the dealloc Box from the caller's num instead of the recorded allocation size is a genuine footgun in an unsafe fn, but it only bites if some caller frees with a different count than it allocated. No in-tree caller does that — every path (the vsock Allocator, and virtio_pci storing dma_size and freeing with dma_size / PAGE_SIZE) is self-consistent. Crucially, the VMM does not control the free num; it controls bounded packet contents/lengths, while the page count is internal allocation bookkeeping. So the "directly reachable from untrusted VMM / oob_write" tag is overstated. This is also emulation-only code (td-payload-emu), outside the production TDX TCB.