-
Notifications
You must be signed in to change notification settings - Fork 67
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[ImageProxy] Domain whitelist #229
Comments
Unless I'm missing something I don't think that would help much. Mixed content is blocked after all. |
The internal domains are using custom certs, things load properly when done directly. |
I'm not opposed to adding a whitelist, but in that case the more obvious solution would seem to be to use the default settings (i.e., don't force proxy HTTPS). |
I'm mainly interested in caching and allowing intranet clients to be able to view articles without requiring internet access. |
I think a simple comma-separated text input (with I mean around here: Along these lines (NB untested pseudocode, might accidentally run correctly :-) $whitelist = "bla.bla,bleep.bla"; // but from userConf
$parsed_url = parse_url($url);
$scheme = isset($parsed_url['scheme']) ? $parsed_url['scheme'] : null;
$host = isset($parsed_url['host']) ? $parsed_url['host'] : null;
if ($host && in_array($host, explode(',', $whitelist))) {
return $url; Please feel free to test and PR; I don't have time to atm and I don't know if I will this week. |
Default behaviour breaks images that load from internal domains, currently there is no way from within FreshRSS to prevent such domains from going through the configured proxy.
The text was updated successfully, but these errors were encountered: