@Override public void resetNonce(Session session) throws AcmeException { assertConnectionIsClosed(); try { session.setNonce(null); URL newNonceUrl = session.resourceUrl(Resource.NEW_NONCE); LOG.debug("HEAD {}", newNonceUrl); conn = httpConnector.openConnection(newNonceUrl, session.getProxy()); conn.setRequestMethod("HEAD"); conn.setRequestProperty(ACCEPT_LANGUAGE_HEADER, session.getLocale().toLanguageTag()); conn.connect(); logHeaders(); int rc = conn.getResponseCode(); if (rc != HttpURLConnection.HTTP_OK && rc != HttpURLConnection.HTTP_NO_CONTENT) { throwAcmeException(); } String nonce = getNonce(); if (nonce == null) { throw new AcmeProtocolException("Server did not provide a nonce"); } session.setNonce(nonce); } catch (IOException ex) { throw new AcmeNetworkException(ex); } finally { conn = null; } }
@Override public void resetNonce(Session session) throws AcmeException { assertConnectionIsClosed(); try { session.setNonce(null); URL newNonceUrl = session.resourceUrl(Resource.NEW_NONCE); LOG.debug("HEAD {}", newNonceUrl); conn = httpConnector.openConnection(newNonceUrl, session.getProxy()); conn.setRequestMethod("HEAD"); conn.setRequestProperty(ACCEPT_LANGUAGE_HEADER, session.getLocale().toLanguageTag()); conn.connect(); logHeaders(); int rc = conn.getResponseCode(); if (rc != HttpURLConnection.HTTP_OK && rc != HttpURLConnection.HTTP_NO_CONTENT) { throwAcmeException(); } String nonce = getNonce(); if (nonce == null) { throw new AcmeProtocolException("Server did not provide a nonce"); } session.setNonce(nonce); } catch (IOException ex) { throw new AcmeNetworkException(ex); } finally { conn = null; } }
LOG.debug("revoke using the domain key pair"); URL resUrl = session.resourceUrl(Resource.REVOKE_CERT); if (resUrl == null) { throw new AcmeException("Server does not allow certificate revocation");
LOG.debug("revoke using the domain key pair"); URL resUrl = session.resourceUrl(Resource.REVOKE_CERT); if (resUrl == null) { throw new AcmeException("Server does not allow certificate revocation");
URL resUrl = session.resourceUrl(Resource.REVOKE_CERT); if (resUrl == null) { throw new AcmeException("Server does not allow certificate revocation");
URL resUrl = session.resourceUrl(Resource.REVOKE_CERT); if (resUrl == null) { throw new AcmeException("Server does not allow certificate revocation");
URL resourceUrl = session.resourceUrl(Resource.NEW_ACCOUNT);
URL resourceUrl = session.resourceUrl(Resource.NEW_ACCOUNT);
URL keyChangeUrl = getSession().resourceUrl(Resource.KEY_CHANGE); PublicJsonWebKey newKeyJwk = PublicJsonWebKey.Factory.newPublicJwk(newKeyPair.getPublic());
URL keyChangeUrl = getSession().resourceUrl(Resource.KEY_CHANGE); PublicJsonWebKey newKeyJwk = PublicJsonWebKey.Factory.newPublicJwk(newKeyPair.getPublic());
conn.sendSignedRequest(session.resourceUrl(Resource.NEW_ORDER), claims, login);
conn.sendSignedRequest(session.resourceUrl(Resource.NEW_ORDER), claims, login);
Objects.requireNonNull(identifier, "identifier"); URL newAuthzUrl = getSession().resourceUrl(Resource.NEW_AUTHZ);
Objects.requireNonNull(identifier, "identifier"); URL newAuthzUrl = getSession().resourceUrl(Resource.NEW_AUTHZ);