summaryrefslogtreecommitdiff
path: root/inc/fetch.functions.php
diff options
context:
space:
mode:
authorAnika Henke <anika@selfthinker.org>2013-08-04 10:41:00 +0100
committerAnika Henke <anika@selfthinker.org>2013-08-04 10:41:00 +0100
commit71c1143e8785954ea00a62aeb755ca7d8fa47e56 (patch)
treec813b1fe3590314fcb1f20a30811d5de92871583 /inc/fetch.functions.php
parentd637819dca760b20f6e53e5847a92d08d8d15b8c (diff)
parent90d5fa676926189b265430239dca3b7ba668b30b (diff)
downloadrpg-71c1143e8785954ea00a62aeb755ca7d8fa47e56.tar.gz
rpg-71c1143e8785954ea00a62aeb755ca7d8fa47e56.tar.bz2
Merge remote-tracking branch 'origin/master' into video-audio
Diffstat (limited to 'inc/fetch.functions.php')
-rw-r--r--inc/fetch.functions.php4
1 files changed, 2 insertions, 2 deletions
diff --git a/inc/fetch.functions.php b/inc/fetch.functions.php
index 53ade3555..207ad9e5f 100644
--- a/inc/fetch.functions.php
+++ b/inc/fetch.functions.php
@@ -101,8 +101,8 @@ function checkFileStatus(&$media, &$file, $rev = '', $width=0, $height=0) {
//media to local file
if(media_isexternal($media)) {
- //check hash
- if(substr(PassHash::hmac('md5', $media, auth_cookiesalt()), 0, 6) !== $INPUT->str('hash')) {
+ //check token for external image and additional for resized and cached images
+ if(media_get_token($media, $width, $height) !== $INPUT->str('tok')) {
return array(412, 'Precondition Failed');
}
//handle external images