bynk.test.wrong_algorithm_needs_oidc_route
Error A case drives by WrongAlgorithm at an address that is not an http route with an Oidc actor; it sends a token with alg: none and an HS256 token keyed with the JWKS public key, so only an Oidc seam can refuse them.
by WrongAlgorithm sends two otherwise valid tokens under an algorithm the seam must refuse: one with alg: none, and one HS256-signed with the JWKS public key as the secret. Only an Oidc actor's seam is driven with these tokens, so on any other route, a Bearer or Signature one or a public one, the case is refused. Drive a route guarded by an Oidc actor. The same holds for bynk.test.wrong_issuer_needs_oidc_route, bynk.test.wrong_audience_needs_oidc_route and bynk.test.no_subject_needs_oidc_route.
Example
actor User { auth = Bearer(secret = "S"), identity = UserId }actor Workload { auth = Oidc(…on GET("/me") () -> Effect[HttpResult[String]] by u: User { … }on GET("/who") () -> Effect[HttpResult[String]] by w: Workload { … }
// tests/api.test.bynklet r <- api.GET("/me") by WrongAlgorithm // ✗ a `Bearer` route is not an `Oidc` onelet r <- api.GET("/who") by WrongAlgorithm // ✓In the Book
See also
- The grammar rule it governs:
case. - Every code in its category, Tests, on the diagnostic index.
bynk explain bynk.test.wrong_algorithm_needs_oidc_routeshows the same from the installed toolchain, without a network.