Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

REST API Returns Information for an Unauthorized Library #1474

Closed
5 tasks done
Kuan-Lun opened this issue Apr 15, 2024 · 1 comment
Closed
5 tasks done

REST API Returns Information for an Unauthorized Library #1474

Kuan-Lun opened this issue Apr 15, 2024 · 1 comment
Labels
bug Something isn't working released

Comments

@Kuan-Lun
Copy link

Kuan-Lun commented Apr 15, 2024

Steps to reproduce

  1. Currently, there is a library A (library_id = aaa).
  2. Create an account [email protected].
  3. Using Edit restrictions, deselect All Libraries, and only select Library A.
  4. Create another library, Library B (library_id = bbb).
  5. Use the Python package requests to execute the command: requests.get("[komga-url]/api/v1/series?library_id=bbb", auth=HTTPBasicAuth("[email protected]", "password")).json(). The response is {'content': [{'id': 'xxx', 'libraryId': 'aaa', 'name'...
    (I think it just returns the information from the first library.)

Expected behavior

The response should be a null dict or raise an error.

Actual behavior

See step 5. This is an error, as the information accessed pertains to Library A instead of Library B.

圖片

Logs

No response

Komga version

v1.10.4-master

Operating system

Linux

Installation method

Docker

Other details

I suspect that this issue and #1470 are caused by the same underlying logic problem in the code, but I am not sure, so I have opened another issue to address it separately.

Acknowledgements

  • I have searched the existing issues (open AND closed) and this is a new ticket, NOT a duplicate or related to another open issue.
  • I have written a short but informative title.
  • I have checked the FAQ.
  • I have updated the app to the latest version.
  • I will fill out all of the requested information in this form.
@gotson gotson added bug Something isn't working and removed triage labels Apr 17, 2024
@gotson gotson closed this as completed in aa0a9b4 Apr 17, 2024
Copy link
Contributor

🎉 This issue has been resolved in 1.11.0 (Release Notes)

@github-actions github-actions bot locked as resolved and limited conversation to collaborators May 19, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug Something isn't working released
Projects
None yet
Development

No branches or pull requests

2 participants