As discussed on 2/16 with @noahtalerman @rachaelshaw @getvictor @mostlikelee, to prevent leaking information from higher permissions scopes, we want to display the same generic empty state on these pages in both the cases where the entity doesn't exist and where the user doesn't have access to it. The API will return 404 in both cases.
Manual testing done on endpoints:
Global admin /software/titles/:id does not exist - 404
GET https://localhost:8080/api/v1/fleet/software/titles/99999999
Global admin /software/titles/:id on 'No Team' - 200
GET https://localhost:8080/api/v1/fleet/software/titles/5984
Global admin /software/titles/:id?team_id team does not exist - 404
GET https://localhost:8080/api/v1/fleet/software/titles/5984?team_id=99999
Global admin /software/titles/:id?team_id does not exist on that team - 404
GET https://localhost:8080/api/v1/fleet/software/titles/5984?team_id=1
Global admin /software/titles/:id?team_id does not exist anywhere - 404
GET https://localhost:8080/api/v1/fleet/software/titles/999999?team_id=1
Team admin /software/titles/:id does not exit - 404
GET https://localhost:8080/api/v1/fleet/software/titles/99999999
Team admin /software/titles/:id on 'No Team' - 403
GET https://localhost:8080/api/v1/fleet/software/titles/5984
Team admin /software/titles/:id?team_id team does not exist - 403
GET https://localhost:8080/api/v1/fleet/software/titles/5984?team_id=99999
Team admin /software/titles/:id?team_id does not exist on that team - 404
GET https://localhost:8080/api/v1/fleet/software/titles/5984?team_id=1
Team admin /software/titles/:id?team_id does not exist anywhere - 404
GET https://localhost:8080/api/v1/fleet/software/titles/999999?team_id=1
Team admin /software/titles/:id?team_id another team - 403
GET https://localhost:8080/api/v1/fleet/software/titles/5984?team_id=2
Global admin /software/versions/:id does not exist - 404
GET https://localhost:8080/api/v1/fleet/software/versions/99999999
Global admin /software/versions/:id on 'No Team' - 200
GET https://localhost:8080/api/v1/fleet/software/versions/77568
Global admin /software/versions/:id?team_id team does not exist - 404
GET https://localhost:8080/api/v1/fleet/software/versions/77568?team_id=99999
Global admin /software/versions/:id?team_id does not exist on that team - 404
GET https://localhost:8080/api/v1/fleet/software/versions/77568?team_id=1
Global admin /software/versions/:id?team_id does not exist anywhere - 404
GET https://localhost:8080/api/v1/fleet/software/versions/999999?team_id=1
Team admin /software/versions/:id does not exit - 404
GET https://localhost:8080/api/v1/fleet/software/versions/99999999
Team admin /software/versions/:id on 'No Team' - 403
GET https://localhost:8080/api/v1/fleet/software/versions/77568
Team admin /software/versions/:id?team_id team does not exist - 403
GET https://localhost:8080/api/v1/fleet/software/versions/77568?team_id=99999
Team admin /software/versions/:id?team_id does not exist on that team - 404
GET https://localhost:8080/api/v1/fleet/software/versions/77568?team_id=1
Team admin /software/versions/:id?team_id does not exist anywhere - 404
GET https://localhost:8080/api/v1/fleet/software/versions/999999?team_id=1
Team admin /software/versions/:id?team_id another team - 403
GET https://localhost:8080/api/v1/fleet/software/versions/77568?team_id=2
Global admin /os_versions/:id does not exist - 404
GET https://localhost:8080/api/v1/fleet/os_versions/99999999
Global admin /os_versions/:id on 'No Team' - 200
GET https://localhost:8080/api/v1/fleet/os_versions/5
Global admin /os_versions/:id?team_id team does not exist - 403 (we can change to 404, but this is ok for now)
GET https://localhost:8080/api/v1/fleet/os_versions/5?team_id=99999
Global admin /os_versions/:id?team_id does not exist on that team - 404
GET https://localhost:8080/api/v1/fleet/os_versions/5?team_id=1
Global admin /os_versions/:id?team_id does not exist anywhere - 404
GET https://localhost:8080/api/v1/fleet/os_versions/999999?team_id=1
Team admin /os_versions/:id does not exit - 404
GET https://localhost:8080/api/v1/fleet/os_versions/99999999
Team admin /os_versions/:id on 'No Team' - 200 (should be 403)
GET https://localhost:8080/api/v1/fleet/os_versions/5
Filed bug: #17117
Team admin /os_versions/:id?team_id team does not exist - 403
GET https://localhost:8080/api/v1/fleet/os_versions/5?team_id=99999
Team admin /os_versions/:id?team_id does not exist on that team - 404
GET https://localhost:8080/api/v1/fleet/os_versions/5?team_id=1
Team admin /os_versions/:id?team_id does not exist anywhere - 404
GET https://localhost:8080/api/v1/fleet/os_versions/999999?team_id=1
Team admin /os_versions/:id?team_id another team - 403
GET https://localhost:8080/api/v1/fleet/os_versions/5?team_id=2
As discussed on 2/16 with @noahtalerman @rachaelshaw @getvictor @mostlikelee, to prevent leaking information from higher permissions scopes, we want to display the same generic empty state on these pages in both the cases where the entity doesn't exist and where the user doesn't have access to it. The API will return 404 in both cases.
Manual testing done on endpoints:
Global admin /software/titles/:id does not exist - 404
GET https://localhost:8080/api/v1/fleet/software/titles/99999999
Global admin /software/titles/:id on 'No Team' - 200
GET https://localhost:8080/api/v1/fleet/software/titles/5984
Global admin /software/titles/:id?team_id team does not exist - 404
GET https://localhost:8080/api/v1/fleet/software/titles/5984?team_id=99999
Global admin /software/titles/:id?team_id does not exist on that team - 404
GET https://localhost:8080/api/v1/fleet/software/titles/5984?team_id=1
Global admin /software/titles/:id?team_id does not exist anywhere - 404
GET https://localhost:8080/api/v1/fleet/software/titles/999999?team_id=1
Team admin /software/titles/:id does not exit - 404
GET https://localhost:8080/api/v1/fleet/software/titles/99999999
Team admin /software/titles/:id on 'No Team' - 403
GET https://localhost:8080/api/v1/fleet/software/titles/5984
Team admin /software/titles/:id?team_id team does not exist - 403
GET https://localhost:8080/api/v1/fleet/software/titles/5984?team_id=99999
Team admin /software/titles/:id?team_id does not exist on that team - 404
GET https://localhost:8080/api/v1/fleet/software/titles/5984?team_id=1
Team admin /software/titles/:id?team_id does not exist anywhere - 404
GET https://localhost:8080/api/v1/fleet/software/titles/999999?team_id=1
Team admin /software/titles/:id?team_id another team - 403
GET https://localhost:8080/api/v1/fleet/software/titles/5984?team_id=2
Global admin /software/versions/:id does not exist - 404
GET https://localhost:8080/api/v1/fleet/software/versions/99999999
Global admin /software/versions/:id on 'No Team' - 200
GET https://localhost:8080/api/v1/fleet/software/versions/77568
Global admin /software/versions/:id?team_id team does not exist - 404
GET https://localhost:8080/api/v1/fleet/software/versions/77568?team_id=99999
Global admin /software/versions/:id?team_id does not exist on that team - 404
GET https://localhost:8080/api/v1/fleet/software/versions/77568?team_id=1
Global admin /software/versions/:id?team_id does not exist anywhere - 404
GET https://localhost:8080/api/v1/fleet/software/versions/999999?team_id=1
Team admin /software/versions/:id does not exit - 404
GET https://localhost:8080/api/v1/fleet/software/versions/99999999
Team admin /software/versions/:id on 'No Team' - 403
GET https://localhost:8080/api/v1/fleet/software/versions/77568
Team admin /software/versions/:id?team_id team does not exist - 403
GET https://localhost:8080/api/v1/fleet/software/versions/77568?team_id=99999
Team admin /software/versions/:id?team_id does not exist on that team - 404
GET https://localhost:8080/api/v1/fleet/software/versions/77568?team_id=1
Team admin /software/versions/:id?team_id does not exist anywhere - 404
GET https://localhost:8080/api/v1/fleet/software/versions/999999?team_id=1
Team admin /software/versions/:id?team_id another team - 403
GET https://localhost:8080/api/v1/fleet/software/versions/77568?team_id=2
Global admin /os_versions/:id does not exist - 404
GET https://localhost:8080/api/v1/fleet/os_versions/99999999
Global admin /os_versions/:id on 'No Team' - 200
GET https://localhost:8080/api/v1/fleet/os_versions/5
Global admin /os_versions/:id?team_id team does not exist - 403 (we can change to 404, but this is ok for now)
GET https://localhost:8080/api/v1/fleet/os_versions/5?team_id=99999
Global admin /os_versions/:id?team_id does not exist on that team - 404
GET https://localhost:8080/api/v1/fleet/os_versions/5?team_id=1
Global admin /os_versions/:id?team_id does not exist anywhere - 404
GET https://localhost:8080/api/v1/fleet/os_versions/999999?team_id=1
Team admin /os_versions/:id does not exit - 404
GET https://localhost:8080/api/v1/fleet/os_versions/99999999
Team admin /os_versions/:id on 'No Team' - 200 (should be 403)
GET https://localhost:8080/api/v1/fleet/os_versions/5
Filed bug: #17117
Team admin /os_versions/:id?team_id team does not exist - 403
GET https://localhost:8080/api/v1/fleet/os_versions/5?team_id=99999
Team admin /os_versions/:id?team_id does not exist on that team - 404
GET https://localhost:8080/api/v1/fleet/os_versions/5?team_id=1
Team admin /os_versions/:id?team_id does not exist anywhere - 404
GET https://localhost:8080/api/v1/fleet/os_versions/999999?team_id=1
Team admin /os_versions/:id?team_id another team - 403
GET https://localhost:8080/api/v1/fleet/os_versions/5?team_id=2