openlp-core team mailing list archive
-
openlp-core team
-
Mailing list archive
-
Message #28749
[Bug 1548014] Re: Remotes API calls using authentication return strange response body
Yes, the box is checked and the two fields (user id and password) are
filled.
Try reproduce this:
1. Run OpenLP with Remotes enabled;
2. Call the method: http://localhost:4316/api/songs/live?data={"request": {"id": "3"}} for example
3. Note that the program show the song 3 in live and the response body is empty;
4. Configure OpenLP to require an authentication user and password;
5. Call http://localhost:4316/api/songs/live?data={"request": {"id": "3"}} again;
6. Note that the header content's response is in body response, but it was to be empty.
I'm not a Python programmer, but analyzing the code, I noted that the function do_htttp_success() is being called two times (here http://bazaar.launchpad.net/~openlp-core/openlp/trunk/view/head:/openlp/plugins/remotes/lib/httprouter.py#L193 and here http://bazaar.launchpad.net/~openlp-core/openlp/trunk/view/head:/openlp/plugins/remotes/lib/httprouter.py#L679).
I'm supposing that this is the problem.
--
You received this bug notification because you are a member of OpenLP
Core, which is subscribed to OpenLP.
https://bugs.launchpad.net/bugs/1548014
Title:
Remotes API calls using authentication return strange response body
Status in OpenLP:
New
Bug description:
Any calls to API using HTTP authentication returns a strange response
body. Its looks like that the HTTP header returns as body.
Example of BODY RESPONSE using authentication:
HTTP/1.0 200 OK
Server: BaseHTTP/0.6 Python/3.4.3
Date: Sun, 21 Feb 2016 06:31:43 GMT
Content-type: text/html
Cache-Control: no-cache, no-store, must-revalidate
Pragma: no-cache
Expires: 0
Without authentication none body is returned, as expected.
OpenLP 2.2.1
Mac OS 10.11.3
To manage notifications about this bug go to:
https://bugs.launchpad.net/openlp/+bug/1548014/+subscriptions
Follow ups
References