Skip to content

feat: support Notation verification plugins and pluginConfig - #3133

Open
shivanshs9 wants to merge 2 commits into
notaryproject:mainfrom
shivanshs9:ft/aws-signer
Open

shivanshs9 wants to merge 2 commits into
notaryproject:mainfrom
shivanshs9:ft/aws-signer

Conversation

@shivanshs9

@shivanshs9 shivanshs9 commented Nov 19, 2026 •

Copy link
Copy Markdown

Description

Ratify v2 creates the Notation verifier without a plugin manager, so signatures that carry io.cncf.notary.verificationPlugin (including all AWS Signer signatures) fail with plugin unsupported due to nil verifier.pluginManager.

This PR adds:

  • optional pluginDirectory on the notation verifier → Notation PluginManager (notation plugin install layout)
  • optional pluginConfig forwarded into verification (needs ratify-verifier-go change below), e.g. aws-region: us-east-1
  • Helm value notation.pluginDirectory / notation.pluginConfig
  • design doc docs/design/Notation Verification Plugins.md
  • unit tests with a fake shell verification plugin, plus chart rendering coverage in bats

The chart still does not ship or mount plugin binaries; the image must already contain them. Trust store type signingAuthority remains with #3116.

Which issue(s) does this PR resolve?

Resolves #3131

Depends on: notaryproject/ratify-verifier-go#91 for PluginConfig

Note for reviewers: go.mod currently has replace ... => github.com/shivanshs9/ratify-verifier-go/notation@2096e96... so CI can build before the verifier-go PR merges.
I will replace that with the official module version once it is available.

AWS Signer plugin also depends on PR #3116 for trust store type signingAuthority in the chart.

Type of change

  • New feature (non-breaking change which adds functionality)
  • Helm chart change
  • This change requires a documentation update

Testing and verification

  • go test ./internal/verifier/notation/ -count=1
  • go build ./cmd/ratify-gatekeeper-provider ./cmd/ratify
  • helm template rendering checks for pluginDirectory / pluginConfig (bats test added; bats not run in this environment)
  • Fake Notation verification plugin e2e in-unit (trusted / untrusted identity, missing plugin, wrong plugin)
  • Not covered: a live AWS Signer signature (needs AWS + signed image)

Checklist

  • Does the affected code have corresponding tests?
  • Are the changes documented... (design doc + chart README)
  • Does this introduce breaking changes... (no; optional params)
  • Do all new files have appropriate license header?

Post merge requirements

  • MAINTAINERS: manually trigger the "Publish Package" workflow after merging any PR that indicates Helm Chart Change
  • Update the v2 ("Next") AWS Signer quickstart doc; it still shows v1 dynamic-plugin commands

Add optional pluginDirectory and pluginConfig to the notation verifier so
signatures that name a verification plugin (for example AWS Signer) can be
verified, including cross-region aws-region settings.

Signed-off-by: Shivansh Saini <shivanshs9@gmail.com>
Co-authored-by: Cursor <cursoragent@cursor.com>

Copilot AI 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.

🟡 Changes recommended

The tests do not verify that the configured aws-region reaches the plugin, allowing regressions in cross-region AWS Signer verification to go undetected.

1 open issue
What changed in this PR

Adds optional Notation verification-plugin support to Ratify v2, enabling verification of signatures that require external plugins, including AWS Signer. Plugin binaries must already be present in the image; chart support for signingAuthority trust stores remains separate.

Changes:

  • Adds pluginDirectory validation and forwards pluginConfig to the Notation verifier.
  • Exposes both options through Helm values and documents plugin setup.
  • Adds fake-plugin verification tests and Helm rendering coverage, using a temporary verifier dependency replacement.
File Description
test/​bats/​base-test.bats Tests Helm rendering of plugin settings.
internal/​verifier/​notation/​register.go Initializes the plugin manager and forwards configuration.
internal/​verifier/​notation/​plugin_test.go Tests plugin verification and configuration handling.
go.sum Records checksums for the temporary dependency fork.
go.mod Temporarily replaces the Notation verifier dependency.
docs/​design/​Notation Verification Plugins.md Documents plugin setup, scope, and security considerations.
deployments/​ratify-gatekeeper-provider/​values.yaml Defines optional plugin values.
deployments/​ratify-gatekeeper-provider/​templates/​executor.yaml Renders plugin settings into the Executor.
deployments/​ratify-gatekeeper-provider/​README.md Documents the new Helm values.

Review effort: Balanced

Comment thread internal/verifier/notation/register.go Resolved
Extend the verification-plugin test so success needs the configured
aws-region in the plugin request, and refuse when it is missing or wrong.

Signed-off-by: Shivansh Saini <shivanshs9@gmail.com>
Co-authored-by: Cursor <cursoragent@cursor.com>

This branch has not been deployed

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

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[v2] Verify signatures that need a Notation verification plugin (AWS Signer)

2 participants