# Bug NEX-213 - Direct upload with big files (exceeding NC limit) cause CORS error

Project: Stream Nextcloud app "OpenProject Integration"
Status: closed
URL: https://community.openproject.org/work_packages/NEX-213

## Open points

_No work packages_

## Details

| Attribute | Value |
| --- | --- |
| Date |  |
| Priority | Medium |
| Module |  |
| Target versions | Nextcloud Integration 2.3.0 |
| Observed in versions |  |
| Bug found in version (deprecated) |  |
| Requires doc change | No |
| Accessibility | No |
| Pull preview |  |
| List |  |
| Labels |  |

## People

| Attribute | Value |
| --- | --- |
| Assignee |  |
| Accountable |  |
| Product manager |  |
| Developers |  |
| Designer |  |
| Signed off by |  |
| Interest by |  |

## Planning

| Attribute | Value |
| --- | --- |
| Relevance |  |

## Costs

| Attribute | Value |
| --- | --- |
| Votes |  |
| Work |  |
| Labor costs |  |

## Description

### Steps to reproduce

1.  Use branch `implementation/45772-use-direct-upload-tokens-as-provided-by-the-nc-app`
2.  Open work package full view
3.  Click on `Upload files`
4.  Select a file that exceeds file size limit of your NC instance
5.  Select location

### What is the buggy behavior?

*   The browser states, a CORS error has happened

### What is the expected behavior?

1.  We get an error message, that we can interpret as &quot;File size exceeded&quot;

### **Logs**

```text
Cross-Origin Request Blocked: The Same Origin Policy disallows reading the remote resource at https://nextcloud.local/apps/integration_openproject/direct-upload/FTTfwoazfzPnbXKaY7Nic8DdZb5JbGSW7FAg3xBYdnQbnzRjRF4Cwzd8Ppnn2sCb. (Reason: CORS header ‘Access-Control-Allow-Origin’ missing). Status code: 200.
```

### Screenshots and other files

none

### Environment information

none

**OpenProject installation type**

*   [ ] Hosted cloud edition
*   [ ] Packaged installation
    *   What distribution?
*   [ ] Docker All-in-one container
*   [x] Docker-compose installation
*   [ ] Other (please specify)

**OpenProject version**

unreleased/dev

**Browser**

*   [x] Chrome
*   [x] Firefox
*   [ ] Safari
*   [ ] Mobile Safari
*   [ ] Other (please specify)

**Language**

en-US
