Skip to content

Commit a586f73

Browse files
committed
fix: Prevent collection data from being returned through policies
1 parent 815232c commit a586f73

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

  • packages/uma/src/util/routeSpecific

‎packages/uma/src/util/routeSpecific/get.ts‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -86,7 +86,7 @@ const buildPolicyRetrievalQuery = (policyID: string, resourceOwner: string) => `
8686
* @returns a store containing the policy and its permissions
8787
*/
8888
export const getPolicy = (store: Store, policyID: string, resourceOwner: string) =>
89-
executeGet(store, buildPolicyRetrievalQuery(policyID, resourceOwner), ['policy', 'perm', 'target']);
89+
executeGet(store, buildPolicyRetrievalQuery(policyID, resourceOwner), ['policy', 'perm']);
9090

9191
/**
9292
* Build a query to retrieve all policies for a given client.
@@ -120,7 +120,7 @@ const buildPoliciesRetrievalQuery = (resourceOwner: string) => `
120120
* @returns a store containing all policies and their permissions
121121
*/
122122
export const getPolicies = (store: Store, resourceOwner: string) =>
123-
executeGet(store, buildPoliciesRetrievalQuery(resourceOwner), ['perm', 'target']);
123+
executeGet(store, buildPoliciesRetrievalQuery(resourceOwner), ['perm']);
124124

125125
// TODO: slight improvement over existing solution so constraints get returned but definitely not ideal yet
126126
function permissionToQuads(store: Store, permission: Quad_Subject): Quad[] {

0 commit comments

Comments
 (0)