{"record":{"id":"eb11e40bb02ee634","repo":"hashicorp/packer","slug":"signing-mode-q-is-not-implemented","errorCode":null,"errorMessage":"signing_mode %q is not implemented","messagePattern":"signing_mode %q is not implemented","errorType":"validation","errorClass":null,"httpStatus":null,"severity":"error","filePath":"internal/attestation/signer.go","lineNumber":58,"sourceCode":"\tRekorURL          string\n\tUploadTlog        bool\n\tTrustedRootPath   string\n\tKeylessIdentity   string\n\tKeylessOIDCIssuer string\n}\n\ntype signerFactory func(context.Context, BackendConfig) (Signer, error)\n\nvar signerFactories = map[string]signerFactory{}\n\nfunc RegisterSigner(mode string, factory signerFactory) {\n\tsignerFactories[mode] = factory\n}\n\nfunc NewSigner(ctx context.Context, cfg BackendConfig) (Signer, error) {\n\tfactory, ok := signerFactories[cfg.Mode]\n\tif !ok {\n\t\treturn nil, fmt.Errorf(\"signing_mode %q is not implemented\", cfg.Mode)\n\t}\n\n\treturn factory(ctx, cfg)\n}\n\nfunc NewVerifier(ctx context.Context, cfg BackendConfig, signer Signer) (Verifier, error) {\n\tif cfg.VerifierRef != \"\" {\n\t\treturn LoadPEMVerifier(cfg.VerifierRef)\n\t}\n\n\treturn signer.Verifier(ctx, cfg)\n}\n\nfunc VerifyEnvelope(ctx context.Context, envelope Envelope, verifier Verifier) error {\n\tif len(envelope.Signatures) == 0 {\n\t\treturn fmt.Errorf(\"envelope has no signatures\")\n\t}\n","sourceCodeStart":40,"sourceCodeEnd":76,"githubUrl":"https://github.com/hashicorp/packer/blob/eb36e3c3e48a036f3e8cc94087636ee72e1303c9/internal/attestation/signer.go#L40-L76","documentation":"Config error from NewSigner: the configured signing_mode string has no registered signer factory in signerFactories, i.e. it is not one of the built-in modes (file, kms, keyless...). Pure map-lookup guard against a typo'd or unsupported mode.","triggerScenarios":"Thrown at internal/attestation/signer.go:58 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Set signing_mode to a supported value such as \"file\" (PEM), \"kms\", or \"keyless\"","Check for typos in the signing_mode attribute of the provenance post-processor"],"exampleFix":null,"handlingStrategy":"validation","validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"eb36e3c3e48a036f3e8cc94087636ee72e1303c9","analyzedAt":"2026-09-05T13:20:43.127Z","contentChangedAt":"2026-09-05T13:20:43.127Z","schemaVersion":2},"datasetVersion":"2026-09-12T17:17:11.597Z"}