MXS-1220: Return 403 Forbidden for invalid requests

The JSON API specification suggests that the API returns the 403 Forbidden
error when the user does an invalid request. The 400 Bad Request isn't the
ideal error for cases where the syntax is correct but the action being
performed is wrong.
This commit is contained in:
Markus Mäkelä
2017-05-05 05:39:23 +03:00
parent 798ee840a8
commit 1d98b4b67b
3 changed files with 21 additions and 11 deletions

View File

@ -35,10 +35,15 @@ describe("Individual Resources", function() {
"/servers/server1",
"/servers/server2",
"/services/RW-Split-Router",
"/services/RW-Split-Router/listeners",
"/monitors/MySQL-Monitor",
"/filters/Hint",
"/sessions/1",
"/maxscale/",
"maxscale/threads",
"maxscale/logs",
"maxscale/tasks",
"maxscale/modules",
]
tests.forEach(function(endpoint) {