Answer the question
In order to leave comments, you need to log in
How to read more than 16kb from a stream? What directives cut the stream?
Good afternoon.
A POST request is sent to the server, the body of which is a file (not a form with files, but the file itself).
I'm trying to get data on the server
$theStream = fopen('php://input', 'r');
$contents = stream_get_contents($theStream);
var_dump($contents);
file_put_contents('/srv/www/r.txt',$contents,FILE_APPEND);
exit();
Answer the question
In order to leave comments, you need to log in
Maybe client_body_temp_path in nginx is not writable?
To check, you can try adding
client_body_in_file_only clean to the config (at the same time, it seems like any post request should have an error, regardless of size)
or just look at error.log, in theory there should be abuse about this.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question