Skip to content

Security: Unverified remote wheel installation enables supply-chain compromise#3998

Open
tuanaiseo wants to merge 1 commit intohuggingface:mainfrom
tuanaiseo:contribai/fix/security/unverified-remote-wheel-installation-ena
Open

Security: Unverified remote wheel installation enables supply-chain compromise#3998
tuanaiseo wants to merge 1 commit intohuggingface:mainfrom
tuanaiseo:contribai/fix/security/unverified-remote-wheel-installation-ena

Conversation

@tuanaiseo
Copy link
Copy Markdown

Problem

The helper installs torch_xla directly from a remote URL using pip install without pinning a hash/signature. If the wheel source is tampered with, users can execute attacker-controlled code during installation.

Severity: high
File: src/accelerate/utils/torch_xla.py

Solution

Avoid direct unauthenticated wheel URLs. Pin exact versions and hashes (e.g., --require-hashes), prefer trusted indexes, and verify provenance/signatures before installation.

Changes

  • src/accelerate/utils/torch_xla.py (modified)

Testing

  • Existing tests pass
  • Manual review completed
  • No new warnings/errors introduced

…es suppl

The helper installs `torch_xla` directly from a remote URL using `pip install` without pinning a hash/signature. If the wheel source is tampered with, users can execute attacker-controlled code during installation.

Affected files: torch_xla.py

Signed-off-by: tuanaiseo <221258316+tuanaiseo@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant