Git Product home page Git Product logo

Comments (6)

casbin-bot avatar casbin-bot commented on July 26, 2024

@tangyang9464 @JalinWang @imp2002

from casdoor.

hsluoyz avatar hsluoyz commented on July 26, 2024

@link89 see docs: https://casdoor.org/docs/permission/permission-configuration

How to forbid a user from logging into an application: https://door.casdoor.com/permissions/casbin/permission_deny_role

image

from casdoor.

link89 avatar link89 commented on July 26, 2024

@hsluoyz The example you show it is to deny specify users to read specific apps. Is it possible to use white list rule?
For example, if there are 3 apps in an organization, how to setup rules so that

  • all users can access App1
  • only users in group whitelist-app2 can access App2
  • only users in group whitelist-app3 can access App3

from casdoor.

hsluoyz avatar hsluoyz commented on July 26, 2024

@link89 you deny all first, then allow someone

from casdoor.

jump2cn avatar jump2cn commented on July 26, 2024

@link89 you deny all first, then allow someone

hi @hsluoyz
I have created two permissions for users, one is to deny all, the other one allow a role. and the user have matched by permission in the user info page, but it still deny when user login.
图片
图片

[request_definition]
r = sub, obj, act

[policy_definition]
p = sub, obj, act

[role_definition]
g = _, _

[policy_effect]
e = some(where (p.eft == allow))

[matchers]
m = g(r.sub, p.sub) && r.obj == p.obj && r.act == p.act

from casdoor.

hsluoyz avatar hsluoyz commented on July 26, 2024

Closed issues won't be responded.

from casdoor.

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.