daml/ledger/ledger-api-auth
pbatko-da ee6a5f9e0e
Handle misc error codes todos. [DPP-606] (#13248)
changelog_begin
changelog_end
2022-03-14 17:16:31 +01:00
..
src Handle misc error codes todos. [DPP-606] (#13248) 2022-03-14 17:16:31 +01:00
BUILD.bazel [User management] Terminate ongoing streams when user state has changed [DPP-830] (#12437) 2022-01-28 16:44:39 +01:00
README.md Move AuthService (#3272) 2019-10-29 15:46:43 +00:00

Ledger API authorization

General authorization in gRPC

An Interceptor reads HTTP headers, and stores relevant information (e.g., claims) in a Context.

GRPC services read the stored data from the Context in order to validate the requests.

Authorization in the ledger API

The AuthService defines an interface for decoding HTTP headers into Claims.

The ledger API server takes an AuthService implementation as an argument.

The ledger API server uses a call interceptor and the given AuthService implementation to to store decoded Claims in the gRPC Context.

All ledger API services use the Claims to validate their requests.