Access: grant and inspect access to dynamic engine roles

dynamicGrantRules expands a grant on a role into the credential paths
its requests need (generate) and the role CRUD paths (manage); unticked
access comes back empty so writing it revokes. Roles get an Access panel
showing who can generate credentials or manage them, and the identity
Access editor can pick dynamic mounts and roles. Checked against
capabilities-self and a real token in the integration tests.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
This commit is contained in:
mattandClaude Sonnet 5.5 committed 2026-11-09 13:51:28 +00:00
1 parent 48ee757e8d
commit 85a318c351
14 files changed
+642 -22

No files matched your search

+14 -3
View File
@@ -64,7 +64,18 @@ export function AccessPanel({ client, mount, secret }: Props) {
)
}
function Entries({ data, path }: { data: NonNullable<ReturnType<typeof useAccessInputs>['data']>; path: string }) {
/** Who can reach `path`, from every identity's effective policies. */
export function Entries({
data,
path,
label = 'Who can access this secret',
empty = 'No identity can reach this secret.',
}: {
data: NonNullable<ReturnType<typeof useAccessInputs>['data']>
path: string
label?: string
empty?: string
}) {
const entries = accessForPath(data.identities, data.policies, path, pathMatches)
return (
<>
@@ -74,9 +85,9 @@ function Entries({ data, path }: { data: NonNullable<ReturnType<typeof useAccess
</p>
))}
{entries.length === 0 ? (
<p>No identity can reach this secret.</p>
<p>{empty}</p>
) : (
<table aria-label="Who can access this secret">
<table aria-label={label}>
<thead>
<tr>
<th>Identity</th>