--- ImageSourceServer.lua.orig +++ ImageSourceServer.lua @@ -178,14 +178,16 @@ -- Bug 13937, if URL references a private IP address, don't use imageproxy -- Tests for a numeric IP first to avoid extra string.find calls - if string.find(urlString, "^http[s]?://%d") and ( - string.find(urlString, "^http://192%.168") or - string.find(urlString, "^http://172%.16%.") or - string.find(urlString, "^http://10%.") + if string.find(urlString, "^https?://%d") and ( + string.find(urlString, "^https?://192%.168") or + string.find(urlString, "^https?://172%.1[6-9]%.") or + string.find(urlString, "^https?://172%.2[0-9]%.") or + string.find(urlString, "^https?://172%.3[0-1]%.") or + string.find(urlString, "^https?://10%.") ) then -- use raw urlString - elseif not string.find(urlString, "^http://") then + elseif not string.find(urlString, "^https?://") then -- url on current server local server = SlimServer:getCurrentServer() @@ -211,7 +213,7 @@ else --use SN image proxy for resizing - urlString = 'http://' .. jnt:getSNHostname() .. '/public/imageproxy?w=' .. screenWidth .. '&h=' .. screenHeight .. '&f=' .. '' .. '&u=' .. string.urlEncode(urlString) + urlString = 'https://' .. jnt:getSNHostname() .. '/public/imageproxy?w=' .. screenWidth .. '&h=' .. screenHeight .. '&f=' .. '' .. '&u=' .. string.urlEncode(urlString) end self.currentImageFile = urlString