Infisical is the open-source platform for securing secrets, certificates, access, and AI Agents.
TypeScript acmeagentsai-agentscertificate-managementdevsecopsenvironment-variableskubernetesopen-sourcepampkipostgresprivate-caprivileged-access-managementsecret-managementsecret-managersecretssecrets-managementsecuritysecurity-toolsvault
Get all authorizations
Fang-Pen Lind880c4c6c9e9
diff --git a/backend/src/ee/services/pki-acme/pki-acme-service.ts b/backend/src/ee/services/pki-acme/pki-acme-service.tsindex 20cc5f21d3..9e1167aecc 100644--- a/backend/src/ee/services/pki-acme/pki-acme-service.ts+++ b/backend/src/ee/services/pki-acme/pki-acme-service.ts@@ -260,21 +260,23 @@ export const pkiAcmeServiceFactory = ({accountId: account.id,status: AcmeOrderStatus.Pending});- payload.identifiers.forEach(async (identifier) => {- if (identifier.type === AcmeIdentifierType.DNS) {- // TODO: reuse existing authorizations for this identifier if they exist- const auth = await acmeAuthDAL.create({- accountId: account.id,- status: AcmeAuthStatus.Pending,- identifierType: identifier.type,- identifierValue: identifier.value,- // TODO: read config from the profile to get the expiration time instead- expiresAt: new Date(Date.now() + 24 * 60 * 60 * 1000)- });- } else {- throw new AcmeMalformedError({ detail: "Only DNS identifiers are supported" });- }- });+ const authorizations = await Promise.all(+ payload.identifiers.map(async (identifier) => {+ if (identifier.type === AcmeIdentifierType.DNS) {+ // TODO: reuse existing authorizations for this identifier if they exist+ return await acmeAuthDAL.create({+ accountId: account.id,+ status: AcmeAuthStatus.Pending,+ identifierType: identifier.type,+ identifierValue: identifier.value,+ // TODO: read config from the profile to get the expiration time instead+ expiresAt: new Date(Date.now() + 24 * 60 * 60 * 1000)+ });+ } else {+ throw new AcmeMalformedError({ detail: "Only DNS identifiers are supported" });+ }+ })+ );// FIXME: Implement ACME new order creationconst orderId = "FIXME-order-id";