nextcloud / nextcloud/files_accesscontrol

File upload limited by size is blocked after assembling chunks

Open
#580 6 comments 0 reactions 1 assignee View on GitHub

@st3iny is already working on this.

Since Aug 14, 2024.

2. developing bug
Dominant language
PHP
Stars
60
Forks
22
Avg merge
2d 11h
Merged PRs (30d)
34

Description

Steps to reproduce
  1. Configure a rule to block uploads greater than 4 MB.
  2. Set the chunk size to 5 MB: occ config:app:set files max_chunk_size --value 5242880
  3. Upload a file bigger than 5 MB in the web interface, e.g. 10 MB.
  4. Observe the network log.
Configured flow

grafik

Only the last request is blocked, not the chunks

grafik

Expected behaviour

The upload should be blocked on the first chunk instead of wasting storage and bandwidth resources.

Actual behaviour

The upload is blocked after a large file has been uploaded and assembled on the server.

This is a regression of https://github.com/nextcloud/files_accesscontrol/issues/211.

Server configuration

Operating system: Linux

Web server: Apache

Database: MariaDB

PHP version: 8.1

Nextcloud version: master

Where did you install Nextcloud from: Git

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.