mirror of https://github.com/shred/acme4j
Do not set autoRenewal on cert replacement (fixes #158)
parent
01249294c8
commit
6120a2b476
|
@ -178,65 +178,6 @@ public class OrderBuilder {
|
|||
return this;
|
||||
}
|
||||
|
||||
/**
|
||||
* Notifies the CA that the ordered certificate will replace a previously issued
|
||||
* certificate. The certificate is identified by its ARI unique identifier.
|
||||
* <p>
|
||||
* Optional, only supported if the CA provides renewal information. However, in this
|
||||
* case the client <em>should</em> include this field.
|
||||
*
|
||||
* @param uniqueId
|
||||
* Certificate's renewal unique identifier.
|
||||
* @return itself
|
||||
* @draft This method is currently based on an RFC draft. It may be changed or removed
|
||||
* without notice to reflect future changes to the draft. SemVer rules do not apply
|
||||
* here.
|
||||
* @since 3.2.0
|
||||
*/
|
||||
public OrderBuilder replaces(String uniqueId) {
|
||||
autoRenewal();
|
||||
this.replaces = Objects.requireNonNull(uniqueId);
|
||||
return this;
|
||||
}
|
||||
|
||||
/**
|
||||
* Notifies the CA that the ordered certificate will replace a previously issued
|
||||
* certificate.
|
||||
* <p>
|
||||
* Optional, only supported if the CA provides renewal information. However, in this
|
||||
* case the client <em>should</em> include this field.
|
||||
*
|
||||
* @param certificate
|
||||
* Certificate to be replaced
|
||||
* @return itself
|
||||
* @draft This method is currently based on an RFC draft. It may be changed or removed
|
||||
* without notice to reflect future changes to the draft. SemVer rules do not apply
|
||||
* here.
|
||||
* @since 3.2.0
|
||||
*/
|
||||
public OrderBuilder replaces(X509Certificate certificate) {
|
||||
return replaces(getRenewalUniqueIdentifier(certificate));
|
||||
}
|
||||
|
||||
/**
|
||||
* Notifies the CA that the ordered certificate will replace a previously issued
|
||||
* certificate.
|
||||
* <p>
|
||||
* Optional, only supported if the CA provides renewal information. However, in this
|
||||
* case the client <em>should</em> include this field.
|
||||
*
|
||||
* @param certificate
|
||||
* Certificate to be replaced
|
||||
* @return itself
|
||||
* @draft This method is currently based on an RFC draft. It may be changed or removed
|
||||
* without notice to reflect future changes to the draft. SemVer rules do not apply
|
||||
* here.
|
||||
* @since 3.2.0
|
||||
*/
|
||||
public OrderBuilder replaces(Certificate certificate) {
|
||||
return replaces(certificate.getCertificate());
|
||||
}
|
||||
|
||||
/**
|
||||
* Sets the earliest date of validity of the first issued certificate. If not set,
|
||||
* the start date is the earliest possible date.
|
||||
|
@ -328,6 +269,64 @@ public class OrderBuilder {
|
|||
return this;
|
||||
}
|
||||
|
||||
/**
|
||||
* Notifies the CA that the ordered certificate will replace a previously issued
|
||||
* certificate. The certificate is identified by its ARI unique identifier.
|
||||
* <p>
|
||||
* Optional, only supported if the CA provides renewal information. However, in this
|
||||
* case the client <em>should</em> include this field.
|
||||
*
|
||||
* @param uniqueId
|
||||
* Certificate's renewal unique identifier.
|
||||
* @return itself
|
||||
* @draft This method is currently based on an RFC draft. It may be changed or removed
|
||||
* without notice to reflect future changes to the draft. SemVer rules do not apply
|
||||
* here.
|
||||
* @since 3.2.0
|
||||
*/
|
||||
public OrderBuilder replaces(String uniqueId) {
|
||||
this.replaces = Objects.requireNonNull(uniqueId);
|
||||
return this;
|
||||
}
|
||||
|
||||
/**
|
||||
* Notifies the CA that the ordered certificate will replace a previously issued
|
||||
* certificate.
|
||||
* <p>
|
||||
* Optional, only supported if the CA provides renewal information. However, in this
|
||||
* case the client <em>should</em> include this field.
|
||||
*
|
||||
* @param certificate
|
||||
* Certificate to be replaced
|
||||
* @return itself
|
||||
* @draft This method is currently based on an RFC draft. It may be changed or removed
|
||||
* without notice to reflect future changes to the draft. SemVer rules do not apply
|
||||
* here.
|
||||
* @since 3.2.0
|
||||
*/
|
||||
public OrderBuilder replaces(X509Certificate certificate) {
|
||||
return replaces(getRenewalUniqueIdentifier(certificate));
|
||||
}
|
||||
|
||||
/**
|
||||
* Notifies the CA that the ordered certificate will replace a previously issued
|
||||
* certificate.
|
||||
* <p>
|
||||
* Optional, only supported if the CA provides renewal information. However, in this
|
||||
* case the client <em>should</em> include this field.
|
||||
*
|
||||
* @param certificate
|
||||
* Certificate to be replaced
|
||||
* @return itself
|
||||
* @draft This method is currently based on an RFC draft. It may be changed or removed
|
||||
* without notice to reflect future changes to the draft. SemVer rules do not apply
|
||||
* here.
|
||||
* @since 3.2.0
|
||||
*/
|
||||
public OrderBuilder replaces(Certificate certificate) {
|
||||
return replaces(certificate.getCertificate());
|
||||
}
|
||||
|
||||
/**
|
||||
* Sends a new order to the server, and returns an {@link Order} object.
|
||||
*
|
||||
|
|
Loading…
Reference in New Issue