Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Security Issue for Change View of Exposed Entity #133

Open
I590232 opened this issue Oct 29, 2024 · 1 comment
Open

Security Issue for Change View of Exposed Entity #133

I590232 opened this issue Oct 29, 2024 · 1 comment

Comments

@I590232
Copy link

I590232 commented Oct 29, 2024

Hi Team,

Trying to implement security for Change Tracking of an Entity through navigation but still able to access it by expanding through url.
I have below service with ErrorPricing Entity for which Change Tracking is enabled.
service ErrorPricingService { @(Capabilities: { InsertRestrictions.Insertable: true, UpdateRestrictions.Updatable : true, DeleteRestrictions.Deletable : false }) @odata.draft.enabled: true entity ErrorPricing as projection on errorPricing.ErrorPricing; }

Below is the security service implemented for the entity.
annotate ErrorPricingService.ErrorPricing with @(restrict: [ { grant: ['*'], to : 'PriceAdminInternal' }, { grant: ['READ'], to : 'PriceViewerInternal' }, { grant: ['READ'], to : 'PriceAdminExternal' } ]);

I tried using below approach but it results in internal server error.
annotate ErrorPricingService.ErrorPricing.changes with @(restrict: [ { grant: ['*'], to : 'PriceAdminInternal' }, { grant: ['READ'], to : 'PriceViewerInternal' }, { grant: ['READ'], to : 'PriceAdminExternal' } ]);

Below are the snapshots from the url from where I am able to access changes by expanding the url.
Uploading Screenshot 2024-10-29 at 11.29.22 PM.png…

@mvoros-rs
Copy link

Hi,

isn't this a standard limitation of SAP documented here?
https://cap.cloud.sap/docs/guides/security/authorization#limitation-deep-authorization

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants