Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ACME (RFC 8555) § 8.2 Challenge Retries #242

Open
wants to merge 37 commits into
base: master
Choose a base branch
from
Open

Commits on Apr 30, 2020

  1. git: Ignore *.code-workspace

    These are visual studio code's workspace configuration files.
    dcow committed Apr 30, 2020
    Configuration menu
    Copy the full SHA
    6fdbd85 View commit details
    Browse the repository at this point in the history
  2. Implement acme RFC 8555, challenge retries

    wesgraham authored and dcow committed Apr 30, 2020
    Configuration menu
    Copy the full SHA
    40d7c42 View commit details
    Browse the repository at this point in the history
  3. Add automated challenge retries, RFC 8555

    wesgraham authored and dcow committed Apr 30, 2020
    Configuration menu
    Copy the full SHA
    66b2c4b View commit details
    Browse the repository at this point in the history
  4. Polish retry conditions

    wesgraham authored and dcow committed Apr 30, 2020
    Configuration menu
    Copy the full SHA
    f9779d0 View commit details
    Browse the repository at this point in the history
  5. Implement standard backoff strategy

    wesgraham authored and dcow committed Apr 30, 2020
    Configuration menu
    Copy the full SHA
    8d43567 View commit details
    Browse the repository at this point in the history
  6. Configuration menu
    Copy the full SHA
    8fb558d View commit details
    Browse the repository at this point in the history
  7. handler_test: Add BackoffChallenge

    The mock acme authority needs to in order to conform to the updated acme
    authority interface.
    dcow committed Apr 30, 2020
    Configuration menu
    Copy the full SHA
    f56c449 View commit details
    Browse the repository at this point in the history
  8. acme/authority: Add space around *

    Makes the line more readable.
    dcow committed Apr 30, 2020
    Configuration menu
    Copy the full SHA
    5e6a020 View commit details
    Browse the repository at this point in the history

Commits on May 6, 2020

  1. acme: Retry challenge validation attempts

    Section 8.2 of RFC 8555 explains how retries apply to the validation
    process. However, much is left up to the implementer.
    
    Add retries every 12 seconds for 2 minutes after a client requests a
    validation. The challenge status remains "processing" indefinitely until
    a distinct conclusion is reached. This allows a client to continually
    re-request a validation by sending a post-get to the challenge resource
    until the process fails or succeeds.
    
    Challenges in the processing state include information about why a
    validation did not complete in the error field. The server also includes
    a Retry-After header to help clients and servers coordinate.
    
    Retries are inherently stateful because they're part of the public API.
    When running step-ca in a highly available setup with replicas, care
    must be taken to maintain a persistent identifier for each instance
    "slot". In kubernetes, this implies a *stateful set*.
    dcow committed May 6, 2020
    Configuration menu
    Copy the full SHA
    9af4dd3 View commit details
    Browse the repository at this point in the history

Commits on May 7, 2020

  1. acme: go fmt

    dcow committed May 7, 2020
    Configuration menu
    Copy the full SHA
    bdadea8 View commit details
    Browse the repository at this point in the history

Commits on May 12, 2020

  1. provisioner/acme: Add TODO for retry restarts

    The comment in acme/authority directs users to this file so put a TODO
    in for posterity.
    dcow committed May 12, 2020
    Configuration menu
    Copy the full SHA
    9518ba4 View commit details
    Browse the repository at this point in the history
  2. vscode: Ignore vscode binaries

    It might make sense to check in the vscode workspace file if we can make
    everything relative to the project directory.
    dcow committed May 12, 2020
    Configuration menu
    Copy the full SHA
    8326632 View commit details
    Browse the repository at this point in the history
  3. acme/api: Add missing return

    Stop execution when the error happens. This was previously a typo.
    dcow committed May 12, 2020
    Configuration menu
    Copy the full SHA
    2d0a00c View commit details
    Browse the repository at this point in the history
  4. acme/authority: Polymorph the challenge type

    Prior to validation, we must wrap the base challenge in the correct
    concrete challenge type so that we dispatch the correct validation
    method.
    dcow committed May 12, 2020
    Configuration menu
    Copy the full SHA
    a857c45 View commit details
    Browse the repository at this point in the history
  5. acme/challenge: Copy retry information on clone

    When cloning a challenge, deeply clone the retry field if it is not nil.
    dcow committed May 12, 2020
    Configuration menu
    Copy the full SHA
    9f18882 View commit details
    Browse the repository at this point in the history
  6. acme/challenge: Fix error return type on KeyAuthorization

    In golang, one should always return error types rather than interfaces
    that conform to an error protocol. Why? Because of this:
    
        https://play.golang.org/p/MVa5vowuNRo
    
    Feels ~~like JavaScript~~ bad, man.
    dcow committed May 12, 2020
    Configuration menu
    Copy the full SHA
    089e3ae View commit details
    Browse the repository at this point in the history
  7. acme/api: Fixup handler_test

    Remove superfluous test. Add test checking for the Retry-After header if
    the challenge's RetryAfter field is set.
    dcow committed May 12, 2020
    Configuration menu
    Copy the full SHA
    2514b58 View commit details
    Browse the repository at this point in the history
  8. acme: Fix test compile

    * Add toACME test for the "processing" state.
    dcow committed May 12, 2020
    Configuration menu
    Copy the full SHA
    84af2ad View commit details
    Browse the repository at this point in the history

Commits on May 13, 2020

  1. acme/authority: Move comment onto correct block

    The comment appeared too early.
    dcow committed May 13, 2020
    Configuration menu
    Copy the full SHA
    8556d45 View commit details
    Browse the repository at this point in the history
  2. acme/api: Remove unused BackoffChallenge func

    The mock has an old func that is no longer used. Remove it.
    dcow committed May 13, 2020
    Configuration menu
    Copy the full SHA
    794725b View commit details
    Browse the repository at this point in the history
  3. acme: Fix comment style to appease linter

    The linter likes comments on public functions to start with their name,
    for some reason...
    dcow committed May 13, 2020
    Configuration menu
    Copy the full SHA
    8ae32f5 View commit details
    Browse the repository at this point in the history
  4. acme/api: Write headers for invalid challenges

    Include the "Link" and "Location" headers on invalid challenge
    resources. An invalid challenge is still a perfectly acceptable
    response.
    dcow committed May 13, 2020
    Configuration menu
    Copy the full SHA
    609e131 View commit details
    Browse the repository at this point in the history
  5. acme/authority: Fix error message in test

    The error message was updated. Make the test should reflect the new
    changes.
    dcow committed May 13, 2020
    Configuration menu
    Copy the full SHA
    b061d0a View commit details
    Browse the repository at this point in the history
  6. acme/authority: Fix tests

    Also, return early from ValidateChallenge if the challenge is already
    valid. Interestingly, we aren't actually testing most of the
    ValidateChallenge func, just the early error and return conditions. We
    should add some more coverage here.
    dcow committed May 13, 2020
    Configuration menu
    Copy the full SHA
    976c8f8 View commit details
    Browse the repository at this point in the history
  7. Configuration menu
    Copy the full SHA
    5354906 View commit details
    Browse the repository at this point in the history
  8. acme/api: Set Link and Location headers for all 200

    On the challenge resource, set "Link" and "Location" headers for all
    successful requests to the challenge resource.
    dcow committed May 13, 2020
    Configuration menu
    Copy the full SHA
    5e5a76c View commit details
    Browse the repository at this point in the history
  9. Configuration menu
    Copy the full SHA
    b8b3ca2 View commit details
    Browse the repository at this point in the history

Commits on May 14, 2020

  1. acme: Move ordinal to application

    The authority now receives the ordinal in its constructor rather than a
    global variable set at package initialization time. The ordinal is
    passed via the command line option `--ordinal`.
    dcow committed May 14, 2020
    Configuration menu
    Copy the full SHA
    c378e00 View commit details
    Browse the repository at this point in the history
  2. project: go mod tidy

    dcow committed May 14, 2020
    Configuration menu
    Copy the full SHA
    f022818 View commit details
    Browse the repository at this point in the history
  3. acme: Don't panic on logic errors

    Since it will ultimately 500 anyway, just return an error.
    dcow committed May 14, 2020
    Configuration menu
    Copy the full SHA
    deacbdc View commit details
    Browse the repository at this point in the history

Commits on May 18, 2020

  1. Configuration menu
    Copy the full SHA
    d5f95de View commit details
    Browse the repository at this point in the history

Commits on May 19, 2020

  1. Configuration menu
    Copy the full SHA
    9103880 View commit details
    Browse the repository at this point in the history
  2. acme: Update http-01 challenge tests

    Add tests for the starting challenge statuses.
    Removed unneeded db write test.
    dcow committed May 19, 2020
    Configuration menu
    Copy the full SHA
    0f63e43 View commit details
    Browse the repository at this point in the history

Commits on May 21, 2020

  1. Configuration menu
    Copy the full SHA
    d54f963 View commit details
    Browse the repository at this point in the history
  2. acme/retry: Cleanup tls-alpn-01 tests

    This logic was already in the correct form so it was much easier to
    update.
    dcow committed May 21, 2020
    Configuration menu
    Copy the full SHA
    0578055 View commit details
    Browse the repository at this point in the history
  3. acme: make fmt

    dcow committed May 21, 2020
    Configuration menu
    Copy the full SHA
    6c39439 View commit details
    Browse the repository at this point in the history
  4. make: Fix lint errors

    Add `golanglint-ci` to the modules so it's available when running `make
    lint`.
    dcow committed May 21, 2020
    Configuration menu
    Copy the full SHA
    112fc59 View commit details
    Browse the repository at this point in the history