Warning: Input variables exceeded 1000

后端 未结 8 2033
不知归路
不知归路 2020-12-25 13:29

I\'m building a RESTS like service in PHP that should accept a large JSON post as main data (I send and read the data much like discussed here: http://forums.laravel.io/view

8条回答
  •  一向
    一向 (楼主)
    2020-12-25 14:05

    According to php manual max_input_vars in php.ini role is:

    How many input variables may be accepted (limit is applied to $_GET, $_POST and $_COOKIE superglobal separately). Use of this directive mitigates the possibility of denial of service attacks which use hash collisions. If there are more input variables than specified by this directive, an E_WARNING is issued, and further input variables are truncated from the request. This limit applies only to each nesting level of a multi-dimensional input array.

    You just have to attribute greater number to max_input_vars in your php.ini.

提交回复
热议问题