Skip to content

Infisical is the open-source platform for securing secrets, certificates, access, and AI Agents.

fix(pam): scope approve-review audit events and fix config-update audit types

bernie-geadbeeb7413b
diff --git a/backend/src/ee/services/audit-log/audit-log-types.ts b/backend/src/ee/services/audit-log/audit-log-types.ts
index 4edec3c5a2..29f3103321 100644
--- a/backend/src/ee/services/audit-log/audit-log-types.ts
+++ b/backend/src/ee/services/audit-log/audit-log-types.ts
@@ -6122,7 +6122,7 @@ interface PamApprovalConfigUpdateEvent {
type: EventType.PAM_APPROVAL_CONFIG_UPDATE;
metadata: {
folderId: string;
- policyId: string;
+ policyId: string | null;
stepCount: number;
};
}
diff --git a/backend/src/ee/services/pam-access-request/pam-access-request-service.ts b/backend/src/ee/services/pam-access-request/pam-access-request-service.ts
index 915a7eee8f..b173e93b81 100644
--- a/backend/src/ee/services/pam-access-request/pam-access-request-service.ts
+++ b/backend/src/ee/services/pam-access-request/pam-access-request-service.ts
@@ -325,7 +325,7 @@ export const pamAccessRequestServiceFactory = ({
}
if (!hasApprovers) {
- return { policyId: null };
+ return { policyId: null, folderId, stepCount: 0 };
}
if (existingPolicy) {
@@ -930,7 +930,7 @@ export const pamAccessRequestServiceFactory = ({
);
}
- return { request: updatedRequest };
+ return { request: updatedRequest, accountId: requestData?.requestData?.accountId, folderId };
};
// Marks a grant Revoked and terminates the grantee's live sessions on the granted account. An