Project

General

Profile

Actions

action #65702

open

[functional][y] 200 HTTP response status code is returned even though invalid filter type is used

Added by oorlov about 4 years ago. Updated 5 months ago.

Status:
New
Priority:
Low
Assignee:
-
Target version:
-
Start date:
2020-04-16
Due date:
% Done:

0%

Estimated time:

Description

libyui-rest-api returns 200 HTTP response status code, when sending request with the invalid/unsupported filter type (Other than id, label, type).

Steps to reproduce:

  1. Run any app with libyu-rest-api (e.g. xdg-su -c "env YUI_HTTP_PORT=9999 /sbin/yast2 timezone");
  2. Send GET request with wrong filter type (e.g. curl -s -o /dev/null -w "%{http_code}" http://localhost:9999/v1/widgets?idzzz=manuals).
  3. Note the response code.

Expected result:
404 or other error response code is returned.
Actual result:
200 (Success) response code is returned.

Actions

Also available in: Atom PDF