Giter Club home page Giter Club logo

neasyauthmiddleware's People

Contributors

dasiths avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

neasyauthmiddleware's Issues

Commas in name result in truncation

Having commas in the name field result in the name being truncated. I assume this is due to the Split(',') call in the middleware.

{ "typ": "name", "val": "User, Mock" }

Results in only "User" being added to the claim as the Identity.

access_token from the /.auth/me endpoint?

Lets say I wanted to get the value of id_token or access_token from the /.auth/me endpoint
Is there a way to map those fields to the HttpContext.User? or can that field be mapped with the use of the CustomClaimMapper?

[Authorize(Roles = "Resource.Read")]

image

I have an ASP.NET Core React Project. It has 1 controller that is the C# backend API to my React frontend. This project is deployed in to an Azure App Service with EasyAuth enabled.

I've been using the NEasyAuthMiddleware package without the Authorize attribute and it has worked great.
NEasyAuthMiddleware has been fantastic for allowing us to mock EasyAuth when dev'ing locally/ running tests, and fetch the /auth/.me in an intuitive way through enabling the use of HttpContext.User.Identity.Name. Great work - thanks for this.

The issue I am experiencing is to do with caching. When the token expires, the browser still attempts to make calls to the backend API from a cached version. All these calls return a 302 redirect. This shows as a CORS error from Microsoft Login Server.

To resolve this, I thought it'd be wise to add in the [Authorize] attribute above my backend API controller class. When I do this, it doesn't seem to integrate with EasyAuth.

Instead, it displays a login popup. Is this behavior as expected?

Testing from Postman always returns 401

'ello

While testing with postman, I always get a 401 Unauthorized.

I'm testing this for an Api that I want to call from Unity using Google sign-in.

I pass the Authentication Token I get from the ".auth/login/google" endpoint on my App Service to my API in the X-ZUMO-AUTH header.

Am I misunderstanding something?

Thanx
Hein

NEasyAuthMiddleware 2.0.0 is not compatible with net50-windows7.0

##[error]The nuget command failed with exit code(1) and error(NU1202: Package NEasyAuthMiddleware 2.0.0 is not compatible with net50-windows7.0 (.NETFramework,Version=v5.0,Profile=windows7.0). Package NEasyAuthMiddleware 2.0.0 supports: netcoreapp3.0 (.NETCoreApp,Version=v3.0)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.