Skip to content

Commit 506ebe4

Browse files
authored
Update authorization.md
For the context, I understood that a claim represents what the subject can do. Could you please accept the merge request if it's the case
1 parent b723c5f commit 506ebe4

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

content/security/authorization.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -144,7 +144,7 @@ When a user with insufficient privileges requests an endpoint, Nest automaticall
144144
145145
#### Claims-based authorization
146146

147-
When an identity is created it may be assigned one or more claims issued by a trusted party. A claim is a name-value pair that represents what the subject is, not what the subject can do.
147+
When an identity is created it may be assigned one or more claims issued by a trusted party. A claim is a name-value pair that represents what the subject can do, not what the subject is.
148148

149149
To implement a Claims-based authorization in Nest, you can follow the same steps we have shown above in the [RBAC](/security/authorization#basic-rbac-implementation) section with one significant difference: instead of checking for specific roles, you should compare **permissions**. Every user would have a set of permissions assigned. Likewise, each resource/endpoint would define what permissions are required (for example, through a dedicated `@RequirePermissions()` decorator) to access them.
150150

0 commit comments

Comments
 (0)