Skip to content

[Infra] Reproducible WASM build + size budget #32

Open

Description

@Gbangbolaoluwagbemiga

Why this matters

Reviewers and auditors need to confirm that the deployed WASM matches the source. The build must be
reproducible and the artifact published with a checksum. A size budget prevents accidental bloat
(WASM size drives deploy cost on Soroban).

What needs to be done

  • Pin the build via rust-toolchain.toml (already present — verify it covers the wasm target)
  • Produce the optimized .wasm (stellar contract build / soroban contract optimize)
  • In release.yml, attach the optimized .wasm + its sha256sum to each GitHub Release
  • Add a CI gate failing if the optimized WASM exceeds a documented byte budget
  • Document the reproducible build steps in the README/CONTRIBUTING

Acceptance criteria

  • Two clean builds produce byte-identical WASM
  • Release contains .wasm + .sha256
  • Oversized WASM fails CI

Relevant files

.github/workflows/release.yml, rust-toolchain.toml, Cargo.toml

Activity

  1. changed the title [-]Reproducible WASM build + size budget[/-] [+][Infra] Reproducible WASM build + size budget[/+] on Jun 17, 2026
  2. ranjeet150 commented on Oct 7, 2026

    @ranjeet150

    Greetings,

    I would like to work on this issue.

    Solution overview:

    1. Audit storage layout and state invariants ensuring strict auth guards.
    2. Implement deterministic state transitions with safe checked arithmetic.
    3. Add hermetic unit and regression tests covering authorized, unauthorized, and boundary edge cases.
    4. Profile instruction and CPU/gas limits under Soroban host environment.

    Ready to implement immediately upon assignment. Please feel free to assign!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    auditRequired before / part of a security auditinfraCI/CD, builds, tooling

    Type

    No type

    Projects

    No projects

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions