ini - Allowing large file uploads in PHP (security) -
ini - Allowing large file uploads in PHP (security) -
are there security and/or performance implications consider when allowing big file uploads in php? example, these php ini settings have set.
memory_limit = 950m upload_max_filesize = 950m post_max_size = 950m max_execution_time = 0
what, if anything, go wrong these settings?
the security considerations not alter changing these settings. performance next valid:
the fine art of serving users in performing way offer plenty ressources requested sum of users. translating examples upon settings like:
10 users uploading 950 mb require serve 9.5 gb of bandwidth , i/o throughput (which eg. ipacted disk speed) in performing manner. user live uploading 950 mb in 1 minute, dissatisfied taking me hour.
100 users uploading 950 mb require serve 95 gb...
1000 users uploading 950 mb reuire serve 950 gb... ...
of cause not of users go max @ time , concurrent uploads might limited. these max-settings add together risk stack. depending on usage characteristics , ressource stuffing these settings valid.
however assume gave extreme examples , want larn implications.
when google "optimize php memory_limit" this: http://programmers.stackexchange.com/questions/207935/benefits-of-setting-php-memory-limit-to-lower-value-for-specific-php-script
obviously can same other settings.
in forums can find lot of swear against setting config-values such high. having in environments, ressource utilization managed on other access layers (eg. restrict number of upload-users via in-app permissions) did work out me in past well.
php ini
Comments
Post a Comment