I have a general query on the workflow for forcing an issuance of a new certificate.
Day 1: I can successfully issue a certificate.
Day 2: The key gets compromised for one reason or another and revoke the cert and need to issue another certificate.
Generate a new CSR and a new KEY file and attempt issuing a new cert. No DNS challenge data comes back, presumably because the authorizations are still valid for a full 30 days.
Question: How then can a new certificate be issued within the 30 days, if the key is compromised with these same 30 days ?
First, I think cert_days needs to be 1 to cause it to 'force' renew. That value is how many days the cert remains valid (I just looked at the ansible docs)
Two, yes, domain validations remain active for up to 30 days when reusing the same ACME account. It is not affected by the key or CSR used by the acme client.
So I am a bit confused by what I am reading in your post.
Is this a hypothetical question?
I dont see any a records for the domain you posted....
I do see an MX record but not for the subdomain you mention...
Absolutely everything is timing out from where I am.
2. Were you actually able to obtain a certificate?
3. Was your certificate actually compromised?
4. Did you actually "revoke" the certificate?
5. If so, HOW did you revoke the certificate?
There is more going on here than your inquiry implies. Would you be willing to give us more information? Frankly, I'm not the sharpest tool in the box, maybe someone else here is more familiar with ansible than I.
My reading of the ansible docs says it means how many days should ansible consider a cert valid before it tries to renew it. Some, even most, acme clients do not look at revocation status.
This is a common feature among all acme clients - ansible being just one. By setting it to 1, or maybe even zero, it would force ansible to try renewal.
Even if I misunderstand, it is easy to try since what you have done has not worked.
It's hypothetical in the sense I'm testing on a real LetsEncrypted issued certificate.
Certificate was not compromised, but I'm simulating a loss of the key. I want to build a process/procedure where I want to know what happens IF the key gets compromised.
Yes, I revoked the certificate. ( community.crypto.acme_certificate_revoke ansible module ). The OCSP status @ crt.sh shows the state as 'Revoked'
They are not 2 certs, they are the same cert. Signatures etc are the same. I don't know though, why we have 2 crs.sh ID's though.
The question is as simple as how do I get a new certificate issued. My attempt at getting a new cert does not work because the authorization of the last cert is active for 30 days and the DNS challenges are both empty for the new cert attempt.
The ACME authorization there indicates, not that the old certificate is valid or exclusively valid, but that your account is (already) authorized to request certificates for a particular subject name. Do you not expect to be authorized that way? Is this ACME client unable to request certificates without performing challenge? (Is it hard-coded to make challenges mandatory in some way even when the certificate authority says they're not required?)
You may be right with respect to the Authorization. I was under the impression this has something to do with Authorizations, but it does not look like it is.
I'm still trying to figure out why the dns challenges responses are coming back empty. I expect to be challenged again since it's a new key and csr.
No, a (valid) authorization is coupled to an account and a specific hostname only. It does not have anything to do with the keypair of a previously issued certificate.
I'm not sure if a previously used, but rotated key can be used for a second key rotation again. In that case, actual revocation would have made the second rotation impossible, but if Boulder allows an older key to be used for rotation again, you can't call it revocation.
In my experimenting some months ago, once an account key was rotated, there didn't seem to be any record of it in the CA's database anymore. You could use the old account key again on a different (or the same) account, or even get a certificate using it as the private key. But in practice, if you know your account key is compromised, but you rotate your account to a different key (before an attacker does!), then I don't think there's any action that needs to be taken to "revoke" the compromised account key. An attacker could create their own account using it, but I don't think they could do anything to your account with it since your account uses a different key now.