You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Authorization denials on pricing report the XML AccessDenied, and no test can see an unmapped plugin #653
accessDeniedCodeFor derives an error code from serviceErrorProtocols
(emulator/error_protocol.go), and AuthController.CheckAccess calls it as accessDeniedCodeFor(req.Service, "") — with no Content-Type. So a service absent
from that map does not fall through to the Content-Type sniff in any useful way: it
takes errorProtocolFor's final errProtoQueryXML default and the caller is refused
with the bare XML code AccessDenied.
pricing is absent from the map. The Price List API is protocol: json, jsonVersion 1.1, targetPrefix AWSPriceListService (vendored botocore pricing/2017-10-15/service-2.json.gz), and its model declares an AccessDeniedException shape outright — so the correct code is unambiguous here, not
inferred from the protocol split #595 documents.
Substrate reports two codes for one outcome on one service: the plugin's own pricingErrAccessDenied = "AccessDeniedException" (pricing_plugin.go:46, correct)
versus the generic gate's AccessDenied. That is STS: identity-policy denials report AccessDeniedException where AWS sends AccessDenied #595's exact complaint restated,
and TestAccessDenied_IAMPluginAgreesWithTheGenericGate exists because the same
drift was found for IAM.
pricing is the only remaining unmapped plugin: diffing every Plugin.Name() value
against serviceErrorProtocols yields 67 registered names, of which config (fixed in
the v0.101.0 work) and pricing were missing.
Acceptance criteria
"pricing": errProtoJSONRPC added to serviceErrorProtocols, with the model's
own AccessDeniedException shape cited as the evidence.
A test asserts the plugin's pricingErrAccessDenied equals what accessDeniedCodeFor("pricing", "") derives, mirroring TestAccessDenied_IAMPluginAgreesWithTheGenericGate — the drift, not just the
value.
A property test asserts every registered Plugin.Name() appears in serviceErrorProtocols, so the next plugin cannot land unmapped. The existing TestAccessDenied_MatchesTheServiceErrorProtocol iterates the map, so a service
missing from it is invisible to that test — which is why both gaps survived.
Fixed in #667, shipping in v0.103.0. pricing is now classified as JSON RPC in serviceErrorProtocols, so the generic authorization gate derives AccessDeniedException
for it and the two spellings substrate had for one outcome on one service become one.
One detail your analysis did not have, and it slightly changes where the authority for the
fix comes from. The Price List model does declare an AccessDeniedException shape
("exception": true, "General authentication failure."), but only on GetPriceListFileUrl
and ListPriceLists — not on GetProducts, the operation you reported. So for GetProducts neither spelling is modeled, and the protocol rule alone decides it: the
model's "protocol": "json" with jsonVersion 1.1 and targetPrefix AWSPriceListService.
The shape corroborates the spelling rather than supplying it, which is worth knowing if
this ever needs revisiting.
The second half of the fix is why this survived in the first place. The property test
guarding the mapping iterated serviceErrorProtocols itself, so a service missing from
the map had no entry to iterate and was invisible to it — config sat in the same blind
spot until #580, and pricing would have sat there indefinitely. The assertion is now
driven from the plugin registry: every plugin RegisterDefaultPlugins registers must have
an entry, and a new plugin that lands without one fails with a message naming it and saying
what to add. That is the part that makes this the last time rather than the second time.
Compatibility note for anyone with a fixture on the old string: a pricing authorization
denial changes code from AccessDenied to AccessDeniedException. It was never a code the
Price List SDK could parse, which is the bug you reported.
Activity
feat(config): tagging, the authorization hook, and the teardown order…
scttfrdmn commentedon Aug 20, 2026
Fixed in #667, shipping in v0.103.0.
pricingis now classified as JSON RPC inserviceErrorProtocols, so the generic authorization gate derivesAccessDeniedExceptionfor it and the two spellings substrate had for one outcome on one service become one.
One detail your analysis did not have, and it slightly changes where the authority for the
fix comes from. The Price List model does declare an
AccessDeniedExceptionshape(
"exception": true, "General authentication failure."), but only onGetPriceListFileUrland
ListPriceLists— not onGetProducts, the operation you reported. So forGetProductsneither spelling is modeled, and the protocol rule alone decides it: themodel's
"protocol": "json"with jsonVersion 1.1 and targetPrefixAWSPriceListService.The shape corroborates the spelling rather than supplying it, which is worth knowing if
this ever needs revisiting.
The second half of the fix is why this survived in the first place. The property test
guarding the mapping iterated
serviceErrorProtocolsitself, so a service missing fromthe map had no entry to iterate and was invisible to it —
configsat in the same blindspot until #580, and
pricingwould have sat there indefinitely. The assertion is nowdriven from the plugin registry: every plugin
RegisterDefaultPluginsregisters must havean entry, and a new plugin that lands without one fails with a message naming it and saying
what to add. That is the part that makes this the last time rather than the second time.
Compatibility note for anyone with a fixture on the old string: a
pricingauthorizationdenial changes code from
AccessDeniedtoAccessDeniedException. It was never a code thePrice List SDK could parse, which is the bug you reported.