Commit Graph

9 Commits

Author SHA1 Message Date
shoopea f073d3021d remove all debug 2024-01-20 12:33:07 +01:00
shoopea 331e1f8e16 more debug 2024-01-20 11:43:26 +01:00
Julian Imhof ea9c8490dd feat(auth): add support for MS-PASS
typo: fix comment


fix: fix verify flow and precompile cookies


fix: implement requested changes


fix: implement requested changes


fix: implement requested changes


test(auth): add test for MS-PASS


fix: remove pointless return
2023-06-22 13:37:18 +02:00
Christoph Polcin b601d4bcbf Update preemtiveAuthorizer documentation 2023-06-22 13:32:03 +02:00
Christoph Polcin fcd6cac508 Removes panic from authShim 2023-06-22 13:32:03 +02:00
Christoph Polcin a4cd839b8a Adds len checks to negoAuth 2023-06-22 13:32:03 +02:00
Christoph Polcin d59c1705b2 Explicit assignment of struct fields 2023-06-22 13:32:03 +02:00
Christoph Polcin ad27fc07a7 Adds interface documentation 2023-06-22 13:32:03 +02:00
Christoph Polcin ca40e2802e Feat: Authentication API
The changes simplify the `req` method by moving the
authentication-related code into the API.
This makes it easy to add additional authentication methods.

The API introduces an `Authorizer` that acts as an
authenticator factory. The authentication flow itself
is divided down into `Authorize` and `Verify` steps in order
to encapsulate and control complex authentication challenges.

The default `NewAutoAuth` negotiates the algorithms.
Under the hood, it creates an authenticator shim per request,
which delegates the authentication flow to our authenticators.

The `NewEmptyAuth` and `NewPreemptiveAuth` authorizers
allow you to have more control over algorithms and resources.

The API also allows interception of the redirect mechanism by setting
the `XInhibitRedirect` header.

This closes: #15 #24 #38
2023-06-22 13:32:03 +02:00