Skip to content

chore: work toward the OpenSSF Best Practices Silver badge - #768

Merged
ricochet merged 10 commits into
wasmCloud:mainfrom
vados-cosmonic:chore/bestpractices-silver
Nov 23, 2026
Merged

ricochet merged 10 commits into
wasmCloud:mainfrom
vados-cosmonic:chore/bestpractices-silver

Conversation

@vados-cosmonic

Copy link
Copy Markdown
Contributor

Changes toward the OpenSSF Best Practices Silver badge.

  • Community docs: a Code of Conduct, plus README links to the roadmap, governance and maintainers.
  • Coding standards: ESLint and Prettier run in a new Lint workflow, with the CI-only tooling at the repository root.
  • Tests:
    • Every example and template has vitest unit tests, with WASI and wasmCloud imports replaced by fakes.
    • Each package must cover at least 80% of its statements.
    • The Templates workflow runs the unit tests.
    • The test policy is in CONTRIBUTING.md.
  • Fixes the tests found:
    • truncated streaming bodies;
    • missing config keys;
    • the keyvalue delta type;
    • axios responses;
    • filesystem errors, large files and short writes;
    • TCP echo replies and writes;
    • XML and CSV scoring;
    • password-checker errors;
    • webgpu edge cases.
  • Input validation and hardening in the Hono templates:
    • request IDs, JSON bodies and pagination are validated;
    • credentials are redacted from logs;
    • secureHeaders() is on.
  • Signed release tags: releases create annotated tags signed with gitsign, verified before they're pushed.
  • Assurance case: SECURITY_ASSESSMENT.md now records the secure design principles and the common weaknesses countered.

After merge, maintainers need to:

  • add Lint to the main ruleset's required checks;
  • create the project's bestpractices.dev entry.

@vados-cosmonic
vados-cosmonic marked this pull request as ready for review November 12, 2026 09:47
@vados-cosmonic
vados-cosmonic requested review from a team as code owners November 12, 2026 09:47
@vados-cosmonic
vados-cosmonic enabled auto-merge (rebase) November 12, 2026 10:44
…tainers

Signed-off-by: Victor Adossi <vadossi@cosmonic.com>
Signed-off-by: Victor Adossi <vadossi@cosmonic.com>
…sts in CI

Signed-off-by: Victor Adossi <vadossi@cosmonic.com>
… templates

Signed-off-by: Victor Adossi <vadossi@cosmonic.com>
Signed-off-by: Victor Adossi <vadossi@cosmonic.com>
… the security assessment

Signed-off-by: Victor Adossi <vadossi@cosmonic.com>
Signed-off-by: Victor Adossi <vadossi@cosmonic.com>
Signed-off-by: Victor Adossi <vadossi@cosmonic.com>
@vados-cosmonic
vados-cosmonic force-pushed the chore/bestpractices-silver branch from 3b0e7e3 to 40e550f Compare November 12, 2026 11:05
Signed-off-by: Mendy Berger <12537668+MendyBerger@users.noreply.github.com>
MendyBerger
MendyBerger previously approved these changes Nov 12, 2026

@MendyBerger MendyBerger left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm a bit concerned about adding fakes in templates and in examples since it might contribute to the notion that wasm apps require weird architectures. But I wouldn't block on that

Template READMEs said the WASI interfaces are "replaced with fakes", which can read as if a component needs an unusual architecture. Say instead that the tests are plain Hono tests run in Node, that the fakes stand in for external dependencies and aren't imported by src/, and that the built component runs against the real host under wash dev. CONTRIBUTING.md records the same rule for new examples and templates.

Signed-off-by: Victor Adossi <vadossi@cosmonic.com>

@MendyBerger MendyBerger left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Much better

@ricochet
ricochet merged commit f94df2e into wasmCloud:main Nov 23, 2026
54 checks passed
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.

3 participants