diff --git a/CHANGELOG.md b/CHANGELOG.md index af6c7a096f..0559f1e90a 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -86,7 +86,7 @@ The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/). - [#7814](https://github.com/apache/trafficcontrol/issues/7814) All Go components: Updated the module path to [`github.com/apache/trafficcontrol/v8`](https://pkg.go.dev/github.com/apache/trafficcontrol/v8). Module https://pkg.go.dev/github.com/apache/trafficcontrol will not receive further updates. ### Fixed -- [#7891](https://github.com/apache/trafficcontrol/pull/7891) *Traffic Ops*: Created clause to distinguish api versions < 5 when handling 403 in middleware wrappers and updated job routes for v4 and v5 +- [#7891](https://github.com/apache/trafficcontrol/pull/7891) *Traffic Ops*: Updated job routes for v4 and v5. - [#7890](https://github.com/apache/trafficcontrol/pull/7890) *Traffic Ops*: Fixed missing changelog entries to v5 routes. - [#7887](https://github.com/apache/trafficcontrol/pull/7887) *Traffic Ops*: Limit Delivery Services returned for GET /servers/{id}/deliveryservices to ones in the same CDN - [#7885](https://github.com/apache/trafficcontrol/pull/7885) *Traffic Portal*: Fixed the issue where Compare Profiles page was not being displayed. diff --git a/traffic_ops/traffic_ops_golang/routing/middleware/wrappers.go b/traffic_ops/traffic_ops_golang/routing/middleware/wrappers.go index 6f1fc71c1c..4785916036 100644 --- a/traffic_ops/traffic_ops_golang/routing/middleware/wrappers.go +++ b/traffic_ops/traffic_ops_golang/routing/middleware/wrappers.go @@ -120,11 +120,9 @@ func (a AuthBase) GetWrapper(privLevelRequired int) Middleware { return } } else { - if v.Major < 5 { - if !cfg.RoleBasedPermissions && user.PrivLevel < privLevelRequired { - api.HandleErr(w, r, nil, http.StatusForbidden, errors.New("Forbidden."), nil) - return - } + if !cfg.RoleBasedPermissions && user.PrivLevel < privLevelRequired { + api.HandleErr(w, r, nil, http.StatusForbidden, errors.New("Forbidden."), nil) + return } } api.AddUserToReq(r, user)