fix(migtd): input validation and robustness from security audit#942
Draft
MichalTarnacki wants to merge 1 commit into
Draft
fix(migtd): input validation and robustness from security audit#942MichalTarnacki wants to merge 1 commit into
MichalTarnacki wants to merge 1 commit into
Conversation
- clamp pre-session payload length before alloc - parse_events safe indexing on peer event data - log_max_level/logarea header TOCTOU clamp - receive_pre_session_data treat n==0 as EOF - schedule_timeout validate CPUID.15H.EAX!=0 - pci::find_device propagate init failure gracefully - get_ccel/event_log_slice validate CCEL fields - VmcallServiceResponse::try_read truncate to length Signed-off-by: Michal Tarnacki <[email protected]> Co-authored-by: GitHub Copilot <[email protected]>
MichalTarnacki
commented
Jul 9, 2026
| } | ||
|
|
||
| let pre_session_data_payload_size = header.length as usize; | ||
| const MAX_PRE_SESSION_PAYLOAD: usize = 64 * 1024; // 64 KiB |
Contributor
Author
There was a problem hiding this comment.
this limit is too low and it breaks rebinding
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.
if n==0 { return Err(NetworkError) }after each read/write in the while loop.?propagating to a graceful init-failure report (panic_with_guest_crash_reg_report or Err).