Skip to content

Commit edd8b21

Browse files
committed
test(dcv): poll for GENERATED *with body*, not just GENERATED
The algo issuance matrix asserted the cert body immediately on GENERATED, but CERTInext flips status to GENERATED a beat before GetCertificate returns the PEM — so a fast-issuing order (ECDSA-P256, RSA-3072) could report GENERATED with an empty body and fail the body assertion despite issuing fine. Wait for GENERATED with a materialized body (slower-issuing RSA-2048/4096 + ECDSA-P384 already passed because their DCV propagation gave the body time to land).
1 parent 71fa546 commit edd8b21

1 file changed

Lines changed: 4 additions & 1 deletion

File tree

CERTInext.IntegrationTests/DcvLifecycleTests.cs

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -436,7 +436,10 @@ record = await plugin.GetSingleRecord(enrollResult.CARequestID);
436436
int status = record?.Status ?? -1;
437437
_output.WriteLine($"[{tag}] poll #{poll}: status={status} certLen={record?.Certificate?.Length ?? 0}");
438438

439-
if (status == (int)EndEntityStatus.GENERATED)
439+
// Wait for GENERATED *with a materialized body*. CERTInext flips status to
440+
// GENERATED a beat before GetCertificate returns the PEM, so an order that
441+
// issues quickly can report GENERATED with an empty body for a poll or two.
442+
if (status == (int)EndEntityStatus.GENERATED && !string.IsNullOrWhiteSpace(record?.Certificate))
440443
break;
441444
if (status == (int)EndEntityStatus.FAILED)
442445
{

0 commit comments

Comments
 (0)