oss-scanner README

The project's README from github.com/anthropics/oss-scanner. As one markdown file: README.md.

OSS Scanner

OSS Scanner is a service by Anthropic to scan critical open-source repositories for security vulnerabilities. Learn more about the service at red.anthropic.com/oss-scanner.

Note, use of this tool is subject to the terms and conditions outlined in the OSS Scanner terms.

How to sign up

Enroll an open-source project by opening a pull request that adds one directory:

projects/<name>

Our security scanner builds your project in an isolated VM, then analyses it with no Internet access and emails what it finds to primary_contact (and any CCs), each with a reproducer and a proposed patch where available. Reports are model-generated and are not reviewed by a human. Because of this we do not place a 90-day disclosure period on these findings and will not make them public. Project owners should provide project.yaml (to configure the scanner), a Dockerfile (stating how to build the project), and optionally a threat_model.md (providing project-specific threat modeling).

project.yaml

Start from templates/project.yaml:

repo: https://github.com/example/project    # required: the git repository to scan; add #branch to pin one
primary_contact: [email protected]       # required: reports and build problems go here (one address)
auto_ccs:                                   # optional: more addresses on every mail
  - [email protected]
homepage: https://example.org               # optional
disabled: false                             # optional: true pauses reports without removing the enrolment
dockerfile: .oss-scanner/Dockerfile         # required unless a Dockerfile sits in this repo next to your project.yaml
threat_model: .oss-scanner/threat_model.md  # optional; also supports placing the file in this repository

repo and primary_contact are always required. dockerfile is required unless you keep your Dockerfile next to project.yaml (see below). Others are optional.

The email addresses in project.yaml are public. Use addresses you are happy to see published, such as a security alias.

To receive reports encrypted, add your armored OpenPGP public key. Reports then go to primary_contact only; pgp cannot be combined with auto_ccs:

pgp: |
  -----BEGIN PGP PUBLIC KEY BLOCK-----
  mQINBF...
  -----END PGP PUBLIC KEY BLOCK-----

You must provide a Dockerfile, in exactly one of two places:

(The threat model works the same way. Set the threat_model field for its location in your repository, or place it here at projects/<name>/threat_model.md.)

The purpose of the Dockerfile is to set up your environment, install every dependency, and build the project. Initial project setup runs with network access enabled, but the security audit after it runs without Internet access. Anything the build or the tests need must be fetched during the initial Dockerfile setup. We recommend checking that your tests pass inside the built image.

The threat_model.md (optional but strongly recommended) file allows you to provide the scanner with documentation on your intended security goals. We have found it is most useful to provide guidance for how you rate the severity of reports (e.g., do you consider post-auth SQLi high or critical? are buffer overflows without demonstrated exploits capped at high? when is stored XSS medium, high, and critical?) This file can also state what the project does, where untrusted input enters, which components matter and which are out of scope, how you would like reports and patches to look, or anything else you think important or useful.

We suggest you run two commands before opening a pull request:

These tools need your host to have installed git, Docker, and Python 3 with PyYAML (pip install pyyaml); --qemu needs Linux on x86-64 with QEMU instead of Docker.

What happens after the merge

  1. The scanner imports the project, builds it online in an isolated VM, then moves the VM to a network with no Internet access for scanning. If the build fails, we will email primary_contact with an error message.
  2. We scan the project for vulnerabilities.
  3. Findings are emailed to primary_contact and any additional CCs with reproduction steps and a proposed patch where available.

You can edit your project at any time with a PR. To unenroll your project, set the disabled field to true to pause reports or remove projects/\<name\>/ to withdraw the project entirely.

Security considerations

Learn more

Please visit red.anthropic.com/oss-scanner.


Maintenance status: this repository is actively maintained by Anthropic. We review and merge enrollment pull requests (changes under projects/<name>/) only; we do not accept other contributions, including changes to tools/ or templates/. See CONTRIBUTING.md for how to enroll, SECURITY.md to report a vulnerability in this repository, and CODE_OF_CONDUCT.md.

oss-scanner (anthropics/oss-scanner)

Searching Database…

Что это?OSS Scanner — сервис от Anthropic, который сканирует подключённые open-source репозитории на уязвимости безопасности: каждый проект собирается в изолированной VM, а мейнтейнеру на почту приходит воспроизводимый пример и предложенный патч ко всему найденному.
Это инструмент, который я запускаю сам, или я просто подключаю свой проект к Anthropic?Это ни локальное приложение, ни запускаемая библиотека — вы подключаете проект, открыв pull request в этот репозиторий, после чего собственная инфраструктура Anthropic собирает и сканирует его.
Как подключить свой проект к сканеру?Откройте PR, добавляющий каталог projects/<name>/ с project.yaml (на основе templates/project.yaml), где указаны ваш репозиторий и primarycontact, плюс Dockerfile, собирающий ваш проект, и опционально threatmodel.md.
Что нужно локально, чтобы проверить своё подключение до открытия PR?tools/validate.py и tools/check требуют git, Docker и Python 3 с установленным PyYAML; вариант с --qemu требует Linux на x86-64 с QEMU вместо Docker.
Проверяет ли человек отчёты об уязвимостях до того, как я их увижу?Нет — отчёты генерируются моделью и человеком не проверяются; поэтому Anthropic не применяет к ним 90-дневное окно раскрытия и не публикует результаты.
Есть ли у сканера доступ в интернет, пока он изучает мой код?Только во время первичной сборки — проект собирается онлайн в изолированной VM, затем эту VM переносят в сеть без доступа в интернет и лишь после этого запускают само сканирование на уязвимости.
Какую роль Claude Code играет в процессе сканирования?tools/check устанавливает Claude Code в образ сборки точно так же, как это делает боевой сканер, поскольку Claude Code — движок, который анализирует офлайн-сборку и готовит предложенный патч.
Можно хранить мой Dockerfile в собственном репозитории проекта, а не в этом?Да, и это предпочтительный вариант — просто укажите в dockerfile: путь к нему в своём репозитории, чтобы обновлять сборку, вообще не открывая PR здесь.
Как перестать получать отчёты от сканера?Поставьте disabled: true в project.yaml, чтобы приостановить отчёты, или удалите свою папку projects/<name>/ целиком, чтобы вывести проект из сервиса.
Creator
anthropics
Size
1.3 MB
Stars
1.2K
Updated
CommitOct 19
Age
11d
Commits · 90 Days