mirror of
https://github.com/awatertrevi/infisical.git
synced 2026-10-07 19:28:09 +00:00
Do not enforce empty payload as some client somehow may not follow it and it's probably not defined in the RFC
This commit is contained in:
@@ -2,7 +2,6 @@
|
|||||||
import { FastifyReply, FastifyRequest } from "fastify";
|
import { FastifyReply, FastifyRequest } from "fastify";
|
||||||
import { z } from "zod";
|
import { z } from "zod";
|
||||||
|
|
||||||
import { AcmeMalformedError } from "@app/ee/services/pki-acme/pki-acme-errors";
|
|
||||||
import {
|
import {
|
||||||
AcmeOrderResourceSchema,
|
AcmeOrderResourceSchema,
|
||||||
CreateAcmeAccountResponseSchema,
|
CreateAcmeAccountResponseSchema,
|
||||||
@@ -260,9 +259,6 @@ export const registerPkiAcmeRouter = async (server: FastifyZodProvider) => {
|
|||||||
const { profileId, accountId, payload } = await validateExistingAccount({
|
const { profileId, accountId, payload } = await validateExistingAccount({
|
||||||
req
|
req
|
||||||
});
|
});
|
||||||
if (payload !== "") {
|
|
||||||
throw new AcmeMalformedError({ message: "Payload should be empty" });
|
|
||||||
}
|
|
||||||
return sendAcmeResponse(
|
return sendAcmeResponse(
|
||||||
res,
|
res,
|
||||||
profileId,
|
profileId,
|
||||||
@@ -372,9 +368,6 @@ export const registerPkiAcmeRouter = async (server: FastifyZodProvider) => {
|
|||||||
const { profileId, accountId, payload } = await validateExistingAccount({
|
const { profileId, accountId, payload } = await validateExistingAccount({
|
||||||
req
|
req
|
||||||
});
|
});
|
||||||
if (payload !== "") {
|
|
||||||
throw new AcmeMalformedError({ message: "Payload should be empty" });
|
|
||||||
}
|
|
||||||
res.type("application/pem-certificate-chain");
|
res.type("application/pem-certificate-chain");
|
||||||
return sendAcmeResponse(
|
return sendAcmeResponse(
|
||||||
res,
|
res,
|
||||||
@@ -406,9 +399,6 @@ export const registerPkiAcmeRouter = async (server: FastifyZodProvider) => {
|
|||||||
},
|
},
|
||||||
handler: async (req, res) => {
|
handler: async (req, res) => {
|
||||||
const { profileId, accountId, payload } = await validateExistingAccount({ req });
|
const { profileId, accountId, payload } = await validateExistingAccount({ req });
|
||||||
if (payload !== "") {
|
|
||||||
throw new AcmeMalformedError({ message: "Payload should be empty" });
|
|
||||||
}
|
|
||||||
return sendAcmeResponse(
|
return sendAcmeResponse(
|
||||||
res,
|
res,
|
||||||
profileId,
|
profileId,
|
||||||
|
|||||||
Reference in New Issue
Block a user