From e2efcfbb05ff8f5786ce9232b1f26ce1417052e6 Mon Sep 17 00:00:00 2001 From: Zach Borboa Date: Tue, 18 Oct 2016 00:51:37 -0700 Subject: [PATCH] Add additional example where requests with redirection enabled may be unsafe --- SECURITY.md | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/SECURITY.md b/SECURITY.md index d3ee590..9cafbdb 100644 --- a/SECURITY.md +++ b/SECURITY.md @@ -66,6 +66,12 @@ $curl->setOpt(CURLOPT_FOLLOWLOCATION, true); // DANGER! $curl->download('https://www.example.com/image.png', 'my_image.png'); ``` +```php +$curl = new Curl(); +$curl->setOpt(CURLOPT_FOLLOWLOCATION, true); // DANGER! +$curl->get('https://www.example.com/image.png'); +``` + ### Keep SSL protections enabled. * Do not disable SSL protections.