grafana/k6 · error
key import not implemented for algorithm {name}
Error message
key import not implemented for algorithm {name} What it means
Error "key import not implemented for algorithm {name}" thrown in grafana/k6.
Source
Thrown at internal/js/modules/k6/webcrypto/key.go:286
}
func newKeyImporter(rt *sobek.Runtime, normalized Algorithm, params sobek.Value) (KeyImporter, error) {
var ki KeyImporter
var err error
switch normalized.Name {
case AESCbc, AESCtr, AESGcm, AESKw:
ki = newAESImportParams(normalized)
case HMAC:
ki, err = newHMACImportParams(rt, normalized, params)
case ECDH, ECDSA:
ki, err = newEcKeyImportParams(rt, normalized, params)
case RSASsaPkcs1v15, RSAPss, RSAOaep:
ki, err = newRsaHashedImportParams(rt, normalized, params)
case PBKDF2:
ki = newPBKDF2ImportParams(normalized)
default:
return nil, errors.New("key import not implemented for algorithm " + normalized.Name)
}
if err != nil {
return nil, err
}
return ki, nil
}
// UsageIntersection returns the intersection of two slices of CryptoKeyUsage.
//
// It implements the algorithm described in the [specification] to
// determine the intersection of two slices of CryptoKeyUsage.
//
// [specification]: https://w3c.github.io/webcrypto/#concept-usage-intersection
func UsageIntersection(a, b []CryptoKeyUsage) []CryptoKeyUsage {
var intersection []CryptoKeyUsage
View on GitHub (pinned to 93accf6570)
When it happens
Trigger: Thrown at internal/js/modules/k6/webcrypto/key.go:286 when the library encounters an invalid state.
Common situations: See trigger scenarios.
AI-assisted analysis of grafana/k6@93accf6570 (2026-08-15).
Data as JSON: /api/errors/2a20608210747568.
Report an issue: GitHub.