diff options
| author | Anatol Belski <ab@php.net> | 2017-05-02 14:47:08 +0200 |
|---|---|---|
| committer | Anatol Belski <ab@php.net> | 2017-05-02 14:47:08 +0200 |
| commit | 627f870161dbee04bdeb4ef0b4b395073812b296 (patch) | |
| tree | 33b9dde4de6844d06057b5fd16074fe9938ef5e1 | |
| parent | efbfeb1a2e4a12674e4c5ccf47fabd813921f829 (diff) | |
| parent | 64adba3b3f245264018e1e4fa8dc8e89d7924315 (diff) | |
| download | php-git-627f870161dbee04bdeb4ef0b4b395073812b296.tar.gz | |
Merge branch 'PHP-7.1'
* PHP-7.1:
Fixed bug #51918 Phar::webPhar() does not handle requests sent through PUT and DELETE method
| -rw-r--r-- | ext/phar/phar_object.c | 13 |
1 files changed, 12 insertions, 1 deletions
diff --git a/ext/phar/phar_object.c b/ext/phar/phar_object.c index f5973b5b27..f94aa19de7 100644 --- a/ext/phar/phar_object.c +++ b/ext/phar/phar_object.c @@ -573,7 +573,18 @@ PHP_METHOD(Phar, webPhar) } /* retrieve requested file within phar */ - if (!(SG(request_info).request_method && SG(request_info).request_uri && (!strcmp(SG(request_info).request_method, "GET") || !strcmp(SG(request_info).request_method, "POST")))) { + if (!(SG(request_info).request_method + && SG(request_info).request_uri + && (!strcmp(SG(request_info).request_method, "GET") + || !strcmp(SG(request_info).request_method, "POST") + || !strcmp(SG(request_info).request_method, "DELETE") + || !strcmp(SG(request_info).request_method, "HEAD") + || !strcmp(SG(request_info).request_method, "OPTIONS") + || !strcmp(SG(request_info).request_method, "PATCH") + || !strcmp(SG(request_info).request_method, "PUT") + ) + ) + ) { return; } |
