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

[QA] tests for exceeding thumbnails max_input configs #10725

Open
3 tasks
saw-jan opened this issue Dec 4, 2024 · 0 comments
Open
3 tasks

[QA] tests for exceeding thumbnails max_input configs #10725

saw-jan opened this issue Dec 4, 2024 · 0 comments
Assignees
Labels

Comments

@saw-jan
Copy link
Member

saw-jan commented Dec 4, 2024

Bug report: #10589

Required envs: (change values if necessary)

THUMBNAILS_MAX_INPUT_IMAGE_FILE_SIZE=1MB
THUMBNAILS_MAX_INPUT_WIDTH=100
THUMBNAILS_MAX_INPUT_HEIGHT=100

Test cases:

Pre-conditions:

  • run ocis with above thumbnails configs
  • upload image that exceeds one or more of the above values

Test:

  • download the 32x32 thumbnail of that image
  • try to download the 200x200 (exceeding config value) thumbnail of that image
    • assert 403 Forbidden
    • assert response body
      <?xml version="1.0" encoding="UTF-8"?>
      <d:error xmlns:d="DAV" xmlns:s="http://sabredav.org/ns">
        <s:exception></s:exception>
        <s:message>thumbnails: image is too large</s:message>
      </d:error>
  • upload a .txt file and download thumbnail
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants