Skip to content

Fix: Docker Build Vulnerable to Malicious Package Installation Attack in docker/custom-tokenizers.dockerfile #39394

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

kira-offgrid
Copy link

Context and Purpose:

This PR automatically remediates a security vulnerability:

  • Description: When --extra-index-url is used in a pip install command, this is usually meant to install a package from a package index other than the public one. However, if a package is added with the same name to the public PyPi repository, and if the version number is high enough, this package will be installed when building this docker image. This package may be a malicious dependency. Such an attack is called a dependency confusion attack. If using a private package index, prefer to use --index-url if possible.
  • Rule ID: dockerfile.audit.dockerfile-pip-extra-index-url.dockerfile-pip-extra-index-url
  • Severity: HIGH
  • File: docker/custom-tokenizers.dockerfile
  • Lines Affected: 20 - 20

This change is necessary to protect the application from potential security risks associated with this vulnerability.

Solution Implemented:

The automated remediation process has applied the necessary changes to the affected code in docker/custom-tokenizers.dockerfile to resolve the identified issue.

Please review the changes to ensure they are correct and integrate as expected.

…xtra-index-url-docker-custom-tokenizers.dockerfile
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