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

Should not have to specify [Headers("Authorization: Bearer")] on the requests #62

Open
fperreaultnv opened this issue Sep 15, 2021 · 0 comments

Comments

@fperreaultnv
Copy link

Expected Behavior

As a consumer of AuthenticationTokenHandler class, I don't expect that my requests should already contain an auth header prior to be sent in the pipeline for my request to be authenticated.

Actual Behavior

If I send a request into the AuthenticationTokenHandler delegating handler and this request doesn't already contain an authorization header, the token will not be fetched nor included in the request.

Steps to Reproduce the Problem

  1. Setup a refit endpoint in an Uno app from UnoApplicationTemplate
  2. Make sure you don't specify any authorization header on an api call (check for default headers too, class and method HeadersAttributes)
  3. Setup an AuthenticationService properly implementing the IAuthenticationTokenProvider, to provide ability to fetch a token.
  4. Make an API call to an authorized service through your pipeline that is using the Mallard AuthenticationTokenHandler.
  5. Notice the call is not authenticated.

Specifications

  • Version: 0.2.0-dev.21
  • Platform: all
  • Subsystem:
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant