mirror of https://github.com/shred/acme4j
Use 'Terms of Service'
parent
34c7950c75
commit
8ada797df3
|
@ -93,7 +93,7 @@ public class ClientTest {
|
|||
LOG.info("Account does already exist, URI: " + reg.getLocation());
|
||||
}
|
||||
|
||||
LOG.info("Terms and Conditions: " + reg.getAgreement());
|
||||
LOG.info("Terms of Service: " + reg.getAgreement());
|
||||
|
||||
if (createdNewKeyPair) {
|
||||
boolean accepted = acceptAgreement(client, account, reg);
|
||||
|
@ -212,7 +212,7 @@ public class ClientTest {
|
|||
}
|
||||
|
||||
/**
|
||||
* Presents the user a link to the Terms and Conditions, and asks for confirmation.
|
||||
* Presents the user a link to the Terms of Service, and asks for confirmation.
|
||||
*
|
||||
* @param client
|
||||
* {@link AcmeClient} to send confirmation to
|
||||
|
@ -225,16 +225,16 @@ public class ClientTest {
|
|||
public boolean acceptAgreement(AcmeClient client, Account account, Registration reg)
|
||||
throws AcmeException {
|
||||
int option = JOptionPane.showConfirmDialog(null,
|
||||
"Do you accept the Terms and Conditions?\n\n" + reg.getAgreement(),
|
||||
"Do you accept the Terms of Service?\n\n" + reg.getAgreement(),
|
||||
"Accept T&C",
|
||||
JOptionPane.YES_NO_OPTION);
|
||||
if (option == JOptionPane.NO_OPTION) {
|
||||
LOG.error("User did not accept Terms and Conditions");
|
||||
LOG.error("User did not accept Terms of Service");
|
||||
return false;
|
||||
}
|
||||
|
||||
client.modifyRegistration(account, reg);
|
||||
LOG.info("Updated user's T&C");
|
||||
LOG.info("Updated user's ToS");
|
||||
|
||||
return true;
|
||||
}
|
||||
|
|
|
@ -23,11 +23,11 @@ You should always copy the `location` to a safe place. If you should lose your k
|
|||
|
||||
## Update an Account
|
||||
|
||||
At some point, you may want to update your account. For example your contact address might have changed, or you were asked by the CA to accept the current terms and conditions.
|
||||
At some point, you may want to update your account. For example your contact address might have changed, or you were asked by the CA to accept the current terms of service.
|
||||
|
||||
To do so, create a `Registration` object again, and set the `location` property to the URI that you previously got via `newRegistration()`. Also set whatever you like to change to your account.
|
||||
|
||||
The following example accepts the terms and conditions by explicitly setting the URL to the agreement document.
|
||||
The following example accepts the terms of service by explicitly setting the URL to the agreement document.
|
||||
|
||||
```java
|
||||
URI accountLocationUri = ... // your account's URI
|
||||
|
|
Loading…
Reference in New Issue