Project

General

Profile

Bug #4800

api error with username-password

Added by edit4ever ! almost 4 years ago. Updated almost 4 years ago.

Status:
New
Priority:
Normal
Assignee:
-
Category:
API
Target version:
-
Start date:
2017-12-16
Due date:
% Done:

0%

Estimated time:
Found in version:
4.3-788
Affected Versions:

Description

When attempting to access the api, I'm getting a login error when including a filter.
For example this url returns the complete channels list:

http://test:[email protected]:9981/api/channel/grid?all=1&limit=999999999&sort=name

but this one fails with an unauthorized error:

http://192.168.29.171:9981/api/channel/grid?all=1&limit=999999999&sort=name&filter=[{%22type%22:%22boolean%22,%22value%22:true,%22field%22:%22enabled%22}]

Am I missing something in the way the api works or is this a bug?

History

#1

Updated by Jaroslav Kysela almost 4 years ago

The second url does not contain the user/password.

#2

Updated by edit4ever ! almost 4 years ago

sorry - typo on my copy/paste

http://test:[email protected]:9981/api/channel/grid?all=1&limit=999999999&sort=name&filter=[{%22type%22:%22boolean%22,%22value%22:true,%22field%22:%22enabled%22}]

is failing. It triggers a sign in window - which when using the api from python causes a fail.

#3

Updated by Jaroslav Kysela almost 4 years ago

https://tools.ietf.org/html/rfc3986#section-2.2

':' is a reserved character - it must be escaped..

Do you use uriparser library for tvh? (configure)? If not - the simple regex parser is probably confused by many ':'.

It's better to use HTTP POST for those data.

Also available in: Atom PDF