{"record":{"id":"993b23b5771b70e4","repo":"kubernetes/kops","slug":"kops-controller-did-not-return-a-q-certificate","errorCode":null,"errorMessage":"kops-controller did not return a %q certificate","messagePattern":"kops-controller did not return a %q certificate","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"error","filePath":"upup/pkg/fi/nodeup/nodetasks/bootstrap_client.go","lineNumber":136,"sourceCode":"\n\t\tpkData, err := x509.MarshalPKIXPublicKey(key.Key.Public())\n\t\tif err != nil {\n\t\t\treturn fmt.Errorf(\"marshalling public key: %v\", err)\n\t\t}\n\t\t// TODO perhaps send a CSR instead to prove we own the private key?\n\t\treq.Certs[name] = string(pem.EncodeToMemory(&pem.Block{Type: \"RSA PUBLIC KEY\", Bytes: pkData}))\n\t}\n\n\tvar resp nodeup.BootstrapResponse\n\terr := b.Client.Query(ctx, &req, &resp)\n\tif err != nil {\n\t\treturn err\n\t}\n\n\tfor name, certRequest := range b.Certs {\n\t\tcert, ok := resp.Certs[name]\n\t\tif !ok {\n\t\t\treturn fmt.Errorf(\"kops-controller did not return a %q certificate\", name)\n\t\t}\n\t\tcertificate, err := pki.ParsePEMCertificate([]byte(cert))\n\t\tif err != nil {\n\t\t\treturn fmt.Errorf(\"parsing %q certificate: %v\", name, err)\n\t\t}\n\t\tcertRequest.Cert.Resource = asBytesResource{certificate}\n\t}\n\n\treturn nil\n}\n","sourceCodeStart":118,"sourceCodeEnd":147,"githubUrl":"https://github.com/kubernetes/kops/blob/4c8573c808a73d578c5eadc86d410646ea0b0d73/upup/pkg/fi/nodeup/nodetasks/bootstrap_client.go#L118-L147","documentation":"Error \"kops-controller did not return a %q certificate\" thrown in kubernetes/kops.","triggerScenarios":"Thrown at upup/pkg/fi/nodeup/nodetasks/bootstrap_client.go:136 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":[],"exampleFix":null,"handlingStrategy":null,"validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"4c8573c808a73d578c5eadc86d410646ea0b0d73","analyzedAt":"2026-09-05T04:13:19.212Z","contentChangedAt":"2026-09-05T04:13:19.212Z","schemaVersion":2},"datasetVersion":"2026-09-12T07:17:12.445Z"}