/** * Pre-authorizes a domain. The CA will check if it accepts the domain for * certification, and returns the necessary challenges. * <p> * Some servers may not allow pre-authorization. * <p> * It is not possible to pre-authorize wildcard domains. * * @param domain * Domain name to be pre-authorized. IDN names are accepted and will be ACE * encoded automatically. * @return {@link Authorization} object for this domain * @throws AcmeException * if the server does not allow pre-authorization * @throws AcmeServerException * if the server allows pre-authorization, but will refuse to issue a * certificate for this domain */ public Authorization preAuthorizeDomain(String domain) throws AcmeException { Objects.requireNonNull(domain, "domain"); if (domain.isEmpty()) { throw new IllegalArgumentException("domain must not be empty"); } return preAuthorize(Identifier.dns(domain)); }
/** * Pre-authorizes a domain. The CA will check if it accepts the domain for * certification, and returns the necessary challenges. * <p> * Some servers may not allow pre-authorization. * <p> * It is not possible to pre-authorize wildcard domains. * * @param domain * Domain name to be pre-authorized. IDN names are accepted and will be ACE * encoded automatically. * @return {@link Authorization} object for this domain * @throws AcmeException * if the server does not allow pre-authorization * @throws AcmeServerException * if the server allows pre-authorization, but will refuse to issue a * certificate for this domain */ public Authorization preAuthorizeDomain(String domain) throws AcmeException { Objects.requireNonNull(domain, "domain"); if (domain.isEmpty()) { throw new IllegalArgumentException("domain must not be empty"); } return preAuthorize(Identifier.dns(domain)); }