Skip to main content

Module body

Module body 

Source
Expand description

The one bounded decode of a signed request body (v16 §5.2).

DecodedRequestBody is produced exactly once per request by the service’s generated decoder (crate::service::RequestService::decode_request_body) and then feeds every consumer of the request’s method identity and content:

  • the generated per-method signature policy (proof::policy) resolves its row with DecodedRequestBody::leaf_path;
  • the dispatch MAC PEP receives the same leaf path as its object coordinate; and
  • the handler dispatch reads the request from the same decoded message via DecodedRequestBody::root — there is no second capnp::serialize::read_message anywhere between admission and handler.

The leaf path is the chain of Cap’n Proto union discriminants from the service root request union down to the executed leaf (v16 §5.1): nested scope unions contribute their discriminants, so a nested method selects a distinct policy row rather than collapsing onto its parent. Human-readable names are review metadata; the numeric discriminants are wire identity.

Structs§

DecodedRequestBody
A request body decoded exactly once, with its derived full method leaf.

Constants§

BODY_NESTING_LIMIT
Maximum pointer nesting depth for the signed-body decode.
BODY_TRAVERSAL_LIMIT_WORDS
Reviewed decode caps for the single signed-body decode (v16 §5.2).

Functions§

bounded_reader_options
The bounded reader options every generated signed-body decoder uses.