UNPKG

@cerbos/core

Version:

Common types used by the @cerbos/grpc, @cerbos/http, and @cerbos/embedded client libraries

69 lines 1.9 kB
import { type CheckInput, type CheckOutput, type PlanResourcesInput, type PlanResourcesOutput } from "../../engine/v1/engine"; import { type SourceAttributes } from "../../policy/v1/policy"; export declare const protobufPackage = "cerbos.audit.v1"; export interface AccessLogEntry { callId: string; timestamp: Date | undefined; peer: Peer | undefined; metadata: { [key: string]: MetaValues; }; method: string; statusCode: number; } export interface AccessLogEntry_MetadataEntry { key: string; value: MetaValues | undefined; } export interface DecisionLogEntry { callId: string; timestamp: Date | undefined; peer: Peer | undefined; inputs: CheckInput[]; outputs: CheckOutput[]; error: string; method?: { $case: "checkResources"; checkResources: DecisionLogEntry_CheckResources; } | { $case: "planResources"; planResources: DecisionLogEntry_PlanResources; } | undefined; metadata: { [key: string]: MetaValues; }; auditTrail: AuditTrail | undefined; } export interface DecisionLogEntry_CheckResources { inputs: CheckInput[]; outputs: CheckOutput[]; error: string; } export interface DecisionLogEntry_PlanResources { input: PlanResourcesInput | undefined; output: PlanResourcesOutput | undefined; error: string; } export interface DecisionLogEntry_MetadataEntry { key: string; value: MetaValues | undefined; } export interface MetaValues { values: string[]; } export interface Peer { address: string; authInfo: string; userAgent: string; forwardedFor: string; } export interface AuditTrail { effectivePolicies: { [key: string]: SourceAttributes; }; } export interface AuditTrail_EffectivePoliciesEntry { key: string; value: SourceAttributes | undefined; } //# sourceMappingURL=audit.d.ts.map