File tree Expand file tree Collapse file tree
src/main/java/eu/openanalytics/containerproxy Expand file tree Collapse file tree Original file line number Diff line number Diff line change 3030import eu .openanalytics .containerproxy .util .LoggingConfigurer ;
3131import eu .openanalytics .containerproxy .util .ProxyMappingManager ;
3232import io .undertow .Handlers ;
33+ import io .undertow .UndertowOptions ;
3334import io .undertow .server .handlers .SameSiteCookieHandler ;
3435import io .undertow .servlet .api .ServletSessionConfig ;
3536import io .undertow .servlet .api .SessionManagerFactory ;
@@ -338,6 +339,12 @@ public UndertowServletWebServerFactory servletContainer() {
338339 throw new IllegalArgumentException ("Invalid bind address specified" , e );
339340 }
340341 factory .setPort (Integer .parseInt (environment .getProperty ("proxy.port" , "8080" )));
342+ factory .addBuilderCustomizers (builder -> {
343+ // allow uploads of unlimited size
344+ builder .setServerOption (UndertowOptions .MAX_ENTITY_SIZE , -1L );
345+ // limit parsing of multipart requests to 2MB (see #36099), multipart requests are not used in ShinyProxy
346+ builder .setServerOption (UndertowOptions .MULTIPART_MAX_ENTITY_SIZE , 2097152L );
347+ });
341348 return factory ;
342349 }
343350
You can’t perform that action at this time.
0 commit comments