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:
1 parent
48ee757e8d
commit
85a318c351
14 files changed
+642
-22
No files matched your search
@@ -2,16 +2,14 @@ import { useQuery } from '@tanstack/react-query'
|
||||
import { useState } from 'react'
|
||||
import type { BaoClient } from '../../api/bao'
|
||||
import { engineFor, mountKind } from '../../api/engines/registry'
|
||||
import { listMounts, listSecrets } from '../../api/secrets'
|
||||
import { listSecrets } from '../../api/secrets'
|
||||
import { RequireConnection } from '../shared/RequireConnection'
|
||||
import { useMounts } from '../shared/useMounts'
|
||||
import { AccessPanel } from './AccessPanel'
|
||||
import { EngineView } from './EngineView'
|
||||
|
||||
function Browser({ client }: { client: BaoClient }) {
|
||||
const mounts = useQuery({
|
||||
queryKey: ['mounts'],
|
||||
queryFn: async () => (await listMounts(client)).filter((m) => mountKind(m) !== null),
|
||||
})
|
||||
const mounts = useMounts(client)
|
||||
const [mountChoice, setMount] = useState<string | null>(null)
|
||||
const [prefix, setPrefix] = useState('')
|
||||
const [selected, setSelected] = useState<string | null>(null)
|
||||
|
||||
Reference in new issue
Block a user