{"record":{"id":"77caa8b8cd2ccc6f","repo":"grafana/k6","slug":"unknown-cipher-suite-id-d","errorCode":null,"errorMessage":"unknown cipher suite id '%d'","messagePattern":"unknown cipher suite id '(.+?)'","errorType":"validation","errorClass":null,"httpStatus":null,"severity":"error","filePath":"lib/options.go","lineNumber":91,"sourceCode":"\t\tfields.Min = ver\n\t\tfields.Max = ver\n\t}\n\t*v = TLSVersions(fields)\n\treturn nil\n}\n\n// TLSCipherSuites represents a list of TLS cipher suites.\n// Marshals and unmarshals from a list of names, eg. \"TLS_ECDHE_RSA_WITH_RC4_128_SHA\".\ntype TLSCipherSuites []uint16\n\n// MarshalJSON will return the JSON representation according to supported TLS cipher suites\nfunc (s *TLSCipherSuites) MarshalJSON() ([]byte, error) {\n\tvar suiteNames []string\n\tfor _, id := range *s {\n\t\tif suiteName, ok := SupportedTLSCipherSuitesToString[id]; ok {\n\t\t\tsuiteNames = append(suiteNames, suiteName)\n\t\t} else {\n\t\t\treturn nil, fmt.Errorf(\"unknown cipher suite id '%d'\", id)\n\t\t}\n\t}\n\n\treturn json.Marshal(suiteNames)\n}\n\n// UnmarshalJSON implements the json.Unmarshaler interface\nfunc (s *TLSCipherSuites) UnmarshalJSON(data []byte) error {\n\tvar suiteNames []string\n\tif err := StrictJSONUnmarshal(data, &suiteNames); err != nil {\n\t\treturn err\n\t}\n\n\tvar suiteIDs []uint16\n\tfor _, name := range suiteNames {\n\t\tif suiteID, ok := SupportedTLSCipherSuites[name]; ok {\n\t\t\tsuiteIDs = append(suiteIDs, suiteID)\n\t\t} else {","sourceCodeStart":73,"sourceCodeEnd":109,"githubUrl":"https://github.com/grafana/k6/blob/01ffac6f245854c1b8adc6a69857c76a15f90022/lib/options.go#L73-L109","documentation":"Raised by TLSCipherSuites.MarshalJSON when serializing the configured cipher list: a numeric cipher suite ID in the options has no entry in SupportedTLSCipherSuitesToString, so it cannot be rendered as a name. Typically the result of programmatically set or stale options containing an unknown suite constant.","triggerScenarios":"Thrown at lib/options.go:91 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Use only cipher suite names from Go's crypto/tls supported list (e.g. TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256)","Avoid injecting raw numeric cipher IDs into options"],"exampleFix":null,"handlingStrategy":"validation","validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"01ffac6f245854c1b8adc6a69857c76a15f90022","analyzedAt":"2026-08-18T03:05:52.393Z","contentChangedAt":null,"schemaVersion":2},"datasetVersion":"2026-09-14T00:17:10.932Z"}