Skip to content

fix: Verify MemoryShm::byte_size inside shared memory boundary #406

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

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

yinggeh
Copy link
Contributor

@yinggeh yinggeh commented Jul 2, 2025

What does the PR do?

When attacker registers the same shm created by python backend, they can overwrite MemoryShm::byte_size data with a very large value. Identity model will read a large chunk of sensitive data (e.g. glibc.so) as input tensor, copy to the output tensor and send back to the client.

Checklist

  • PR title reflects the change and is of format <commit_type>: <Title>
  • Changes are described in the pull request.
  • Related issues are referenced.
  • Populated github labels field
  • Added test plan and verified test passes.
  • Verified that the PR passes existing CI.
  • Verified copyright is correct on all changed files.
  • Added succinct git squash message before merging ref.
  • All template sections are filled out.
  • Optional: Additional screenshots for behavior/output changes with before/after.

Commit Type:

  • fix

Related PRs:

Where should the reviewer start?

Test plan:

  • CI Pipeline ID:
    30911637

Caveats:

Background

Related Issues: (use one of the action keywords Closes / Fixes / Resolves / Relates to)

  • closes GitHub issue: #xxx

@yinggeh yinggeh self-assigned this Jul 2, 2025
@yinggeh yinggeh added the bug Something isn't working label Jul 2, 2025
@yinggeh
Copy link
Contributor Author

yinggeh commented Jul 2, 2025

No unit test because triton-inference-server/server#8273 makes the exploitation impossible.

@yinggeh yinggeh requested a review from Tabrizian July 2, 2025 23:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Development

Successfully merging this pull request may close these issues.

1 participant