Skip to content

Credentials from continueWithAuth are reused for subsequent requests #968

@juliandescottes

Description

@juliandescottes

Spawned from https://bugzilla.mozilla.org/show_bug.cgi?id=1977378

On Firefox, if a client uses network.continueWithAuth to successfully authenticate, the same credentials can then be reused for the upcoming requests.
Quickly checking the http and fetch spec, this seems correct because:

  • BiDi's continueWithAuth will set the response's authentication credentials (spec)
  • fetch will proceed to create an authentication entry for request and realm (spec)
  • http considers valid credentials as applicable to other requests for the same realm (spec):

    If a request is authenticated and a realm specified, the same credentials are presumed to be valid for all other requests within this realm (assuming that the authentication scheme itself does not require otherwise, such as credentials that vary according to a challenge value or using synchronized clocks).

Assuming my understanding of the spec is correct we should still discuss if this behavior is good enough for testing / automation purposes.
Do we want to give users control over how authentication entries are stored (eg have a flag on continueWithAuth so that the entry is not persisted?) or add another command to allow to manage the stored credentials (eg to clear it, or to disable storing credentials).

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions