feat: display SSH cert principals in expanded certificate details
This commit is contained in:
@@ -291,6 +291,9 @@ function CertificateRow({ cert }: { cert: AdminUserSshCertificate }) {
|
||||
<span className="text-muted-foreground">CA ID</span>
|
||||
<span className="font-mono truncate">{cert.ca_id}</span>
|
||||
|
||||
<span className="text-muted-foreground">Principals</span>
|
||||
<span className="font-mono">{cert.principals.join(", ")}</span>
|
||||
|
||||
{cert.request_ip && (
|
||||
<>
|
||||
<span className="text-muted-foreground">Request IP</span>
|
||||
|
||||
@@ -47,6 +47,7 @@ import {
|
||||
AlertDialogTitle,
|
||||
} from "@/components/ui/alert-dialog";
|
||||
import { useToast } from "@/hooks/use-toast";
|
||||
import { useOrg } from "@/contexts/OrgContext";
|
||||
import { api, SSHKey, SSHCertificate, ApiError, PrincipalOption, MyPrincipalsOrg, DeptCertPolicy } from "@/lib/api";
|
||||
import { formatDate as _formatDate } from "@/lib/date";
|
||||
|
||||
@@ -87,6 +88,7 @@ function CopyButton({ text }: { text: string }) {
|
||||
|
||||
export default function SSHKeysPage() {
|
||||
const { toast } = useToast();
|
||||
const { selectedOrgId } = useOrg();
|
||||
|
||||
// Key list state
|
||||
const [keys, setKeys] = useState<SSHKey[]>([]);
|
||||
@@ -379,6 +381,7 @@ export default function SSHKeysPage() {
|
||||
principals.length > 0 ? principals : undefined,
|
||||
certType,
|
||||
parsedExpiry,
|
||||
selectedOrgId ?? undefined,
|
||||
);
|
||||
setCertResult(result.certificate);
|
||||
fetchCerts(); // refresh certs list
|
||||
|
||||
Reference in New Issue
Block a user