Actor resource credential runtime¶
When someone publishes a block's package, their CLI uploads the archive straight to your registry, and it needs a credential that allows that one upload and nothing more. The actor resource credential runtime is where the node produces it. For a package publication the control plane has authorised, the node asks your cloud provider for a short-lived credential scoped to the release's repository and to the archive's exact digest and size, checks it, and encrypts it to the publishing CLI's session key. This page covers the target the credential is bound to, what the node returns, and how it relates to the ASPTC exchange.
For what an ASPTC is and what it guarantees, see ASPTC and ASPTC in data plane trust.
What the credential is bound to¶
flowchart TB
subgraph REQ["UPLOAD CONTRACT REQUEST, in the publication assignment"]
direction LR
AC["actor_id, organization_uuid,<br/>workspace_uuid"]
PK["package_id, release_version"]
AR["archive_sha256,<br/>archive_size_bytes"]
SK["cli_session_key_id,<br/>cli_session_public_key"]
OP["publication_operation_id"]
end
subgraph NODE["NODE"]
direction TB
TDS[("Target descriptor<br/>repository_root/packages/package/releases/version")]
MINT{{"Mint through the infra<br/>identity runtime, 300 s"}}
VAL{{"Validate the live credential<br/>provider, scope, claims, digest"}}
ENC[("Encrypted credential<br/>for the CLI session key")]
SAN[("Sanitized upload contract<br/>no credential inside")]
TDS --> MINT --> VAL --> ENC
VAL --> SAN
end
CP["Control plane<br/>relays both"]
REQ --> TDS
ENC --> CP
SAN --> CP
The credential is bound to one repository, one archive digest and size, one actor and one publication, and it is encrypted before it leaves the node, so the control plane relays it without being able to read it. The sanitized contract the control plane records describes the credential without containing it.
The target¶
The node builds the repository from your tenant artifact runtime and the request:
The target descriptor adds your registry's endpoint, the provider, the archive's SHA-256 and size, the workspace and organization, and the publication operation. A descriptor that fails validation refuses the mint:
See Tenant artifact runtime and Artifact registry and blob references.
The exchange¶
- Mint. The node asks the infra identity runtime for a registry upload contract for the build workload, with the actor's context and a lifetime of 300 seconds. See Infra identity runtime.
- Validate. The live credential must be provider-issued and carry the provider's provenance, scope and audit claims, and match the actor, organization, workspace, digest and size.
- Encrypt. The credential is encrypted to the CLI session's public key.
- Sanitize. A contract describing the upload, without the credential, is built and validated.
The node returns system.actor_resource_credential_runtime.v1:
upload_contract the sanitized upload contract
encrypted_credential_doc the credential, encrypted to the CLI session key
The control plane passes both to the CLI, which decrypts the credential locally, uploads the archive to the repository, and the node then verifies the upload against the bound digest and size. See Publishing a release.