Code Monkey home page Code Monkey logo

Comments (7)

Vouzamo avatar Vouzamo commented on July 18, 2024

Also seems odd that AuthorizeWith() and RequireAuthorization() extensions methods don't do any authorization checks by calling the internal Authorization evaluator and only check for claim matches.

from authorization.

joemcbride avatar joemcbride commented on July 18, 2024

The β€œnext” branch adds an Authorization requirement that you can use to check for an authenticated user. You can add that requirement today in your own codebase if you wish.

5795fb5

from authorization.

Vouzamo avatar Vouzamo commented on July 18, 2024

Ahhhh...

.RequireAuthorization() is not to mark a type as requiring authorization. It is a convenience method for checking if any policies have been defined against the type using the .AuthorizeWith() method.

As such there is no method currently for flagging a type needs to be authorized but not against specific policies, correct?

I guess the requirement you suggest would still need to be registered against a policy and that policy used e.g. .AuthorizeWith("authenticated");

from authorization.

joemcbride avatar joemcbride commented on July 18, 2024

Yes. A policy could be anything, not only related to the authenticated user. Such as, maybe your policy checks a configuration value or something like that.

from authorization.

OpenSpacesAndPlaces avatar OpenSpacesAndPlaces commented on July 18, 2024

See #49 (comment)
for an example flow.

Once you get used to the setup, it's actually pretty straight forward.

from authorization.

sungam3r avatar sungam3r commented on July 18, 2024

@Vouzamo Is this issue still actual?

from authorization.

sungam3r avatar sungam3r commented on July 18, 2024

Closed due to inactivity.

from authorization.

Related Issues (20)

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.