Skip to content

chore(security): add the OSS Scanner build, threat model and security policy - #15

Merged
Spomky merged 1 commit into
masterfrom
chore/oss-scanner
Oct 31, 2026
Merged

Spomky merged 1 commit into
masterfrom
chore/oss-scanner

Conversation

@Spomky

@Spomky Spomky commented Oct 31, 2026

Copy link
Copy Markdown
Member

Summary

Prepares the enrolment of this library in the OSS Scanner, as web-auth/webauthn-framework#978 and web-auth/cose-lib#229 did. The scanner builds an enrolled project in an isolated VM, scans it without network access and sends its findings privately to the security contact. It drops the findings located in dependencies, so the AES Key Wrap that cose-lib and the JOSE libraries rely on is only covered if this repository is enrolled on its own. The enrolment itself is a project.yaml in the scanner repository; it points to the two files added under .oss-scanner/, so that they can change without a pull request over there.

The image builds, and the test suite passes in it with the network disabled: 18 tests, 36 assertions.

What's included

  • .oss-scanner/Dockerfile starts from ghcr.io/spomky-labs/phpqa:8.4, the image the CI jobs of the sibling projects run in (the workflows of this repository predate it), installs the Composer dependencies and runs the test suite once with the PHPUnit 9 of composer.json. phpunit.xml.dist and the @test annotations are written for that version; the phpunit-11 of the image runs the same 18 tests but reports 19 deprecations on them. composer.json predates allow-plugins, so the PHPStan and Infection installer plugins are allowed in the global Composer configuration of the image, which leaves composer.json untouched. COMPOSER_ROOT_VERSION is not set: without the Git metadata Composer only notes that it defaults the root version to 1.0.0, and the install and the tests are unaffected. The dev tools themselves are not updated here.
  • .oss-scanner/threat_model.md tells the scanner where untrusted input enters (the wrapped key given to unwrap()), what is trusted (the KEK, the key to wrap, the mode), which properties must hold, which components matter most, how to write a reproducer, how severities are rated and what is out of scope. No advisory exists for this library, so the severity scale follows the threat models of the projects that depend on it, cose-lib first.
  • SECURITY.md is new: it lists the supported versions (7.x) and both private reporting channels, GitHub private vulnerability reporting, which is now enabled on this repository, and e-mail to security@spomky-labs.com.
  • .gitattributes export-ignores /.oss-scanner, so that the scanner files stay out of the Composer archives.

Without a pinned branch the scanner follows the default branch, master.

@Spomky Spomky self-assigned this Oct 31, 2026
@Spomky
Spomky merged commit adceeca into master Oct 31, 2026
0 of 6 checks passed
@Spomky Spomky mentioned this pull request Oct 31, 2026
8 tasks done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant