Skip to content

feat(controlplane): allow system tokens to flag CAS credentials as internal#3199

Merged
migmartri merged 1 commit into
mainfrom
feat/cas-creds-source-internal
Jun 11, 2026
Merged

feat(controlplane): allow system tokens to flag CAS credentials as internal#3199
migmartri merged 1 commit into
mainfrom
feat/cas-creds-source-internal

Conversation

@migmartri

Copy link
Copy Markdown
Member

Adds an opt-in source_internal field to CASCredentialsServiceGetRequest so platform-side background processing can mark the CAS tokens it exchanges as internal traffic, suppressing CASArtifactUploaded/CASArtifactDownloaded audit events for it.

The flag is only honored when the caller authenticates with a system API token; any other caller requesting it is rejected with a forbidden error. User-token and regular API-token exchanges are unaffected and keep emitting transfer events. This implements the opt-in option from the linked issue, so sandbox and platform-generated uploads remain visible in transfer accounting unless explicitly flagged.

Closes #3198


AI disclosure: this contribution was produced with AI assistance (Claude Code).

🤖 Posted by Maximus bot (Claude Code) on behalf of @migmartri

…ternal

Add an opt-in source_internal field to CASCredentialsServiceGetRequest
that marks the minted CAS token as internal platform traffic so the
Artifact CAS skips audit event emission for it. The flag is only
honored when the caller authenticates with a system API token; any
other caller requesting it is rejected.

Closes #3198

Assisted-by: Claude Code
Signed-off-by: Miguel Martinez Trivino <miguel@chainloop.dev>

Chainloop-Trace-Sessions: a7b18cae-6c02-4a48-9f17-dd88f510e6f2
@chainloop-platform

Copy link
Copy Markdown
Contributor

AI Session Analysis

Missing AI Coding Sessions

We detected commits in this PR that were AI-assisted, but the matching Chainloop Trace session(s) could not be found in Chainloop.

Please make sure the AI coding session evidence has been sent by the Chainloop CLI, or add the skip-ai-session label to this PR to bypass this check.

Learn more about Chainloop Trace.


Powered by Chainloop and Chainloop Trace

@cubic-dev-ai cubic-dev-ai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No issues found across 10 files

Re-trigger cubic

@migmartri migmartri requested a review from a team June 11, 2026 16:16
@migmartri migmartri merged commit 655a1fb into main Jun 11, 2026
15 of 16 checks passed
@migmartri migmartri deleted the feat/cas-creds-source-internal branch June 11, 2026 22:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

CAS credentials: allow flagging system-token exchanges as SourceInternal to suppress transfer audit events

2 participants