0

I'm having a hard time trying to use a Nexus artifact manager for Maven, sitting behind a reverse proxy, which is based on Apache and the ModSecurity module.

The problem is many artifacts have big files to upload (eg, .jar, .zip spawned by the assembly module) and ModSecurity is blocking them for being too much stuff sent in (HTTP 413, "Too large request"). In the default configuration, this happens already at 13MB, we have files as big as 2-4GB, and I've read ModSecurity has a hard limit of 1GB. Worse, I'm told that this restriction cannot be tuned (ie, disabled for requests having a URI pattern like */nexus).

I can't believe nobody has had this same problem before. What could I do? Is there some possibility to tell Maven to upload big files by splitting multiple requests?

Moreover, should we be much concerned of removing that request size restriction altogether? In our organisation, they can happen only for a few well-known and authenticated clients (Maven and maybe some POST-based web app), in the case of Maven, they're HTTP PUT requests, which are only allowed for the */proxy URL pattern and disabled from the rest of the web server, so the large requests can only be initiated by those few well-known clients, and only after Nexus has validated their credentials (ie, only by our few trusted developers or a couple of CI systems).

zakmck
  • 2,715
  • 1
  • 37
  • 53
  • Why is a nexus sitting behind a proxy inside your corporate network? You should off course secure your network to the outside the world but inside? – khmarbaise Feb 19 '20 at 19:29
  • @khmarbaise, because we need to use it from the outside (collaborators and Travis). – zakmck Feb 19 '20 at 23:23

0 Answers0