Skip to content

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

Return more msg in challenge

Fang-Pen Lin25102757e8e2
diff --git a/backend/src/ee/services/pki-acme/pki-acme-challenge-service.ts b/backend/src/ee/services/pki-acme/pki-acme-challenge-service.ts
index 8bfe360d48..9148b03366 100644
--- a/backend/src/ee/services/pki-acme/pki-acme-challenge-service.ts
+++ b/backend/src/ee/services/pki-acme/pki-acme-challenge-service.ts
@@ -76,7 +76,9 @@ export const pkiAcmeChallengeServiceFactory = ({
// challenge validation at the same time, it should be fine.
const challengeResponse = await fetch(challengeUrl, { signal: AbortSignal.timeout(timeoutMs) });
if (challengeResponse.status !== 200) {
- throw new BadRequestError({ message: "ACME challenge response is not 200" });
+ throw new AcmeIncorrectResponseError({
+ message: `ACME challenge response is not 200: ${challengeResponse.status}`
+ });
}
const challengeResponseBody = await challengeResponse.text();
const thumbprint = challenge.auth.account.publicKeyThumbprint;