Skip to content

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

misc: removed updating configuration for internal CAs

Sheen Capadngan5c435f764543
diff --git a/backend/src/services/certificate-authority/certificate-authority-service.ts b/backend/src/services/certificate-authority/certificate-authority-service.ts
index fa66758c37..a57c085ba4 100644
--- a/backend/src/services/certificate-authority/certificate-authority-service.ts
+++ b/backend/src/services/certificate-authority/certificate-authority-service.ts
@@ -311,7 +311,6 @@ export const certificateAuthorityServiceFactory = ({
}
const updatedCa = await internalCertificateAuthorityService.updateCaById({
- ...configuration,
isInternal: true,
enableDirectIssuance,
caId: certificateAuthority.id,
diff --git a/backend/src/services/certificate-authority/internal/internal-certificate-authority-schemas.ts b/backend/src/services/certificate-authority/internal/internal-certificate-authority-schemas.ts
index ffec0d7623..1cf9a8597d 100644
--- a/backend/src/services/certificate-authority/internal/internal-certificate-authority-schemas.ts
+++ b/backend/src/services/certificate-authority/internal/internal-certificate-authority-schemas.ts
@@ -55,8 +55,4 @@ export const CreateInternalCertificateAuthoritySchema = GenericCreateCertificate
configuration: InternalCertificateAuthorityConfigurationSchema
});
-export const UpdateInternalCertificateAuthoritySchema = GenericUpdateCertificateAuthorityFieldsSchema(
- CaType.INTERNAL
-).extend({
- configuration: InternalCertificateAuthorityConfigurationSchema.optional()
-});
+export const UpdateInternalCertificateAuthoritySchema = GenericUpdateCertificateAuthorityFieldsSchema(CaType.INTERNAL);
diff --git a/frontend/src/hooks/api/ca/mutations.tsx b/frontend/src/hooks/api/ca/mutations.tsx
index 9c865d451b..c05760beb1 100644
--- a/frontend/src/hooks/api/ca/mutations.tsx
+++ b/frontend/src/hooks/api/ca/mutations.tsx
@@ -31,10 +31,14 @@ export const useUpdateCa = () => {
return data;
},
- onSuccess: ({ projectId, type }) => {
+ onSuccess: ({ projectId, type }, { caName }) => {
+ caKeys.getCaByNameAndProjectId(caName, projectId);
queryClient.invalidateQueries({
queryKey: caKeys.listCasByTypeAndProjectId(type, projectId)
});
+ queryClient.invalidateQueries({
+ queryKey: caKeys.getCaByNameAndProjectId(caName, projectId)
+ });
}
});
};
diff --git a/frontend/src/pages/cert-manager/CertificateAuthoritiesPage/components/CaModal.tsx b/frontend/src/pages/cert-manager/CertificateAuthoritiesPage/components/CaModal.tsx
index 07bf1493ab..d3040576fa 100644
--- a/frontend/src/pages/cert-manager/CertificateAuthoritiesPage/components/CaModal.tsx
+++ b/frontend/src/pages/cert-manager/CertificateAuthoritiesPage/components/CaModal.tsx
@@ -188,11 +188,7 @@ export const CaModal = ({ popUp, handlePopUpToggle }: Props) => {
name,
type: CaType.INTERNAL,
status,
- enableDirectIssuance,
- configuration: {
- ...configuration,
- maxPathLength: Number(configuration.maxPathLength)
- }
+ enableDirectIssuance
});
} else {
// create