anonrig / nestjs-keycloak-admin

Keycloak client and admin provider for Nest.js applications with built-in User Managed Access (UMA) and ACL support.
https://npmjs.com/package/nestjs-keycloak-admin
MIT License
181 stars 25 forks source link

Role Guard #107

Closed legitimoth closed 2 years ago

legitimoth commented 2 years ago

I would like to know what is the annotation for Roles like we have in nest-keycloak-connect. Ex: @ Roles({ roles: ['admin'], mode: RoleMatchingMode.ANY })

anonrig commented 2 years ago

Hi @tharbts

We don't currently support Role guards. The only guards we support be found from https://github.com/anonrig/nestjs-keycloak-admin/tree/master/src/guards

If you'd like to implement Role guards, you can always open a pull request!

aktraore commented 2 years ago

@tharbts it's been implemented in the latest release.