Thank you, that worked perfect with one big problem: it seems that only smaller files are being downloaded.
When trying to download a file with around 350MB the request takes a while to finally throw this error in console: Failed to load resource: Frame load interrupted
I tested other files up to 100MB which all work fine. What can cause this?