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

[TC-550] TO API - fetch deliveryservices for a user should have tenancy hooked in #884

Closed
limited opened this issue Aug 29, 2017 · 0 comments
Labels
bug something isn't working as intended high impact impacts the basic function, deployment, or operation of a CDN Traffic Ops related to Traffic Ops

Comments

@limited
Copy link
Contributor

limited commented Aug 29, 2017

The following api route does not take into consideration the tenancy of the specified user:

get( "/api/$version/users/:id/deliveryservices

it currently does the following:

1. it checks the tenancy of the specified user vs. the tenancy of the current user to ensure the current user can see the specified user <-- this is good
2. it queries the deliveryservice_tmuser table to find the delivery services associated to the tm_user and then if finally filters the results based on the current user's tenancy <-- it should not query this table if use_tenancy = 1

if use_tenancy = 0, it should work the way it does now

if use_tenancy = 1, it should not query the deliveryservice_tmuser table but instead query the deliveryservice table and filter the results against the specified user's tenant AND the current user's tenant.

Author: Jeremy Mitchell
JIRA Link: https://issues.apache.org/jira/browse/TC-550
Found Version: 2.1.0

@limited limited added bug something isn't working as intended high impact impacts the basic function, deployment, or operation of a CDN Traffic Ops API labels Aug 29, 2017
@mitchell852 mitchell852 added the Traffic Ops related to Traffic Ops label Aug 31, 2017
hbeatty added a commit that referenced this issue Sep 12, 2017
@hbeatty hbeatty closed this as completed Sep 12, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug something isn't working as intended high impact impacts the basic function, deployment, or operation of a CDN Traffic Ops related to Traffic Ops
Projects
None yet
Development

No branches or pull requests

3 participants