Skip to content

Verify a Pumpkin plugin ​v0.0.5

Add this action after your workflow has produced or downloaded a signed Pumpkin .wasm file and before you publish, deploy, or use it as a dependency. It checks the Ed25519 signature. To confirm the signer, set expected-public-key to a key you obtained through a trusted channel. Without this pin, the action can verify the signature but cannot tell you who owns the embedded key.

See the action guide and API reference on the documentation site.

For one file, set wasm-file to its path. The optional plugin-name and version inputs require exact matches in the signed metadata; enter versions without a leading v. This example checks all three values and pins the signer:

yaml
steps:
  - uses: filiphsps/pumpkin-plugins/actions/verify-pumpkin-plugin@verify-pumpkin-plugin-v0.0.5
    with:
      wasm-file: dist/my-plugin.wasm
      expected-public-key: ${{ vars.PLUGIN_SIGNING_PUBLIC_KEY }}
      plugin-name: MyPlugin
      version: 1.2.3

The examples use this action's current Release Please tag, verify-pumpkin-plugin-v0.0.5. Replace it with the release you want to use. Each action has its own release version, independent of plugin releases and other actions.

To verify several files in one step, write a non-empty JSON array to the path you pass as plugins-manifest. Each entry must include the plugin name, version, and .wasm path:

json
[
  {
    "plugin-name": "MyPlugin",
    "version": "1.2.3",
    "wasm-file": "dist/my-plugin.wasm"
  },
  {
    "plugin-name": "AnotherPlugin",
    "version": "2.0.0",
    "wasm-file": "dist/another-plugin.wasm"
  }
]

Pass that file to the action. The public-key pin applies to every entry, and each entry's name and version must match its signed metadata:

yaml
steps:
  - uses: filiphsps/pumpkin-plugins/actions/verify-pumpkin-plugin@verify-pumpkin-plugin-v0.0.5
    with:
      plugins-manifest: ${{ runner.temp }}/plugins.json
      expected-public-key: ${{ vars.PLUGIN_SIGNING_PUBLIC_KEY }}

Use exactly one of wasm-file or plugins-manifest. In manifest mode, put the expected name and version in each entry instead of setting the single-file plugin-name or version inputs. Paths are resolved from the job's working directory; they are not relative to the manifest file. The action fails if any file is missing or does not pass verification, and it does not modify files.

Both modes set verified-count. Single-file mode also returns the signed name, version, developer, public key, and signing timestamp as step outputs.

Inputs ​

InputRequiredDefaultDescription
wasm-fileNoPath to one signed Pumpkin plugin .wasm file; use this or plugins-manifest
plugins-manifestNoJSON manifest of plugin-name, version, and wasm-file entries to verify; use this or wasm-file
expected-public-keyNoExpected 32-byte Ed25519 public key as 64 hexadecimal characters; pins the trusted signer
plugin-nameNoSingle-file mode; fail unless the signed metadata contains this exact plugin name
versionNoSingle-file mode; fail unless the signed metadata contains this exact version

Outputs ​

OutputDescription
verified-countNumber of files successfully verified
plugin-nameSingle-file mode; plugin name from the signed metadata
versionSingle-file mode; version from the signed metadata
developer-nameSingle-file mode; developer name from the signed metadata
public-keySingle-file mode; public key embedded in the signature
issued-atSingle-file mode; signing timestamp from the signed metadata

Development ​

Define the action's inputs and outputs in action.yml, implement them in src/index.mjs, and cover their behavior in src/*.test.mjs. The README tables come from action.yml, so update the descriptions there and run pnpm readme rather than editing the tables. Use the shared getInput() and setOutput() helpers from ../../common/src/utils.mjs; they handle GitHub's runner environment and output-file format for every action. The runtime is also declared in action.yml, so this action needs no separate build step.

pumpkin-plugins documentation