Jump to content

4.1 - Ability to cache remote images


OctoDev

Recommended Posts

Sorry....I meant what is the image url that the editor is attempting to parse, not the actual image's url. See my post above for what I mean - first code box is for the direct url, the second code box is for the url being processed by the image proxy code:

So, if you could post the url of one that is not working, as it is on your forum, then it might shed some light.

Link to comment
Share on other sites

  • Replies 70
  • Created
  • Last Reply
7 hours ago, Nathan Explosion said:

So, if you could post the url of one that is not working, as it is on your forum, then it might shed some light.

I see what you mean.

To make sure I provide the right information I'll provide it in two ways;

https://revolucion.co.uk/applications/core/interface/imageproxy/imageproxy.php?img=http%3A%2F%2Fg.bf4stats.com%2FAQOvIwiO%2Fpc%2FEvil-Edwina.png&key=11621f39bcb17be0c83b56327a18a4aec11f34edc12c5cf4b73bb3bdb1613048
<img alt="Evil-Edwina.png" src="https://revolucion.co.uk/applications/core/interface/imageproxy/imageproxy.php?img=http%3A%2F%2Fg.bf4stats.com%2FAQOvIwiO%2Fpc%2FEvil-Edwina.png&amp;key=11621f39bcb17be0c83b56327a18a4aec11f34edc12c5cf4b73bb3bdb1613048">

 

Just now, sobrenome said:

A built in rebuild tool for this function would be very apreciated.

I must admit, it's the first thing I wanted. It would have to rebuild every field that could potentially contain a linked image though, for example; (and by no means exhaustive.)

  • Posts
  • Gallery comments
  • Status Updates
  • Forum Descriptions
  • Signatures
Link to comment
Share on other sites

33 minutes ago, sobrenome said:

Synched profile images from facebook, google +, twitter and microsoft are cached?

I'm not sure about those sources.

I've followed a guide provided by Andy Milne, here, and have updated my constants file accordingly. It's fixed some of the images that were broken, but has broken other images that were working. There are still some images not being captured by the proxy at all.

It looks like at least one of my issues relates to changing URL (I went from http to https, so that is a URL change, even though the domain remained the same).

The other issue, with images being missed by the proxy entirely, I don't believe can be related to that.

Link to comment
Share on other sites

37 minutes ago, Evil Edwina said:

I see what you mean.

To make sure I provide the right information I'll provide it in two ways;

Thanks - that's exactly what I wanted to check out. If you access this url:

http://revolucion.co.uk/applications/core/interface/imageproxy/imageproxy.php?img=http%3A%2F%2Fg.bf4stats.com%2FAQOvIwiO%2Fpc%2Fevil-edwina.png&key=11621f39bcb17be0c83b56327a18a4aec11f34edc12c5cf4b73bb3bdb1613048

then you get a white page.

Same target image, on my test site:

http://test.ynwa.tv/applications/core/interface/imageproxy/imageproxy.php?img=http%3A%2F%2Fg.bf4stats.com%2FAQOvIwiO%2Fpc%2FEvil-Edwina.png&key=982cbfb5ae04d8df8664f580933d4efb89292705c602a029677ad3ee0df9fa4e

results in an image.

Unfortunately, through playing around with urls/delete target images, it looks like the imageproxy doesn't log any failures to uploads/logs/ so I'm not able to go much further in looking into this....sorry.

 

Link to comment
Share on other sites

@Nathan Explosion - thanks for looking. :)

The signature image is now loading, following adding an additional line to my constants file, based on the linked guide in my prior post.

https://revolucion.co.uk/applications/core/interface/imageproxy/imageproxy.php?img=http%3A%2F%2Fg.bf4stats.com%2FAQOvIwiO%2Fpc%2FEvil-Edwina.png&key=11621f39bcb17be0c83b56327a18a4aec11f34edc12c5cf4b73bb3bdb1613048

It's broken other images posted since my switch to HTTPS/TLS though. I'm guessing I'll be needing to rebuild those through some mechanism, but I'm waiting for Andy to come back to me.

It doesn't appear to be the case that it's very well explained how to switch to HTTPS and use the image proxy, as you have to do things in a particular order or use the hash generator from the guide. If, like me, there's been a gap of time between the two, it appears more issues are encountered.

Link to comment
Share on other sites

Here's what's come back through the ticket so far:

  1. A new key needed to be generated before I made the change to HTTPS, it wasn't so there is a gap between the point at which I changed to HTTPS, and enabled the image proxy, and the point at which I was notified of the need to generate a key. Any images posted during this period are now broken with no way to fix them but to trawl through posts and edit them. That's a lot of posts.
  2. Images posted before HTTPS and image proxy were in use are still pointing towards insecure connections. I'm therefore getting mixed content warnings on a huge number of topics caused by images in posts and images in signatures. There is no rebuild facility to go back through and correct this. I feel like this defeats the effort of moving to HTTPS and using the image proxy. I want a secure site that does not flood users with mixed content warnings.
  3. Images posted after the key has been updated are working perfectly.

Unless I'm missing something, there are no clear indications in the ACP that I needed to do anything other than 'flick a switch' to enable the local image proxy. Considering the main use of it would be in making sites over HTTPS remain secure, with the nice green padlock, this feels like a significant oversight. It either needed to be clear in the ACP that a procedure need to be followed, or a rebuild facility needs to be provided. Actually, I'd say a rebuild facility does need to be provided, regardless of what documentation there is.

I've asked support to get back to me to confirm whether I can do anything in SQL to replace the incorrect keys on those images already posted. Preferably, I'd like the entire post history rebuilding to make all images be served via the proxy, with the correct key. I'd also like this to be something that I, the admin, can trigger.

Link to comment
Share on other sites

I've been given the workings of an SQL query to test on the forum_posts table, which needless to say will be on a test installation, but have a few queries about it. I've gone back to Andy to query this.

I've got to give thanks to @Andy Millne for the help so far, and to @bfarber for taking it away to discuss options in the background, even though it's not yet resolved. I'm hoping with a little more help from Andy I'll be able to come back with point #1 of my above post resolved, through the use of SQL. Fair warning Andy, I'm going to be asking about point #2 too. :p

Link to comment
Share on other sites

So the SQL query was not as a viable solution. I still therefore have two outstanding issues;

  1. Images posted between the aforementioned dates remain broken
  2. Images posted prior to the image proxy being enabled are insecure.

The ticket has been closed, with my agreement, as it's something they need to take away and work through.

I've been told it's a high priority. :) (So I'm hoping for a 4.1.7/8/9 release.)

Link to comment
Share on other sites

On 12/16/2015 at 6:54 AM, Carl Maltby said:

We are also experiencing issues. These were shared from Dropbox and seem to work for the poster....

http://www.projectguitar.com/forums/topic/48305-knightro-guitars-2015/?do=findComment&comment=547579

 

That's not the same issue, those images are returning 403 which obviously we can't read.

https://photos-3.dropbox.com/t/2/AAB7cE49XX06SeXPLmEkGLCbMZKKaX_8nnG2Ggd1xQGEJQ/12/502428009/jpeg/32x32/1/_/1/2/IMG_20151215_120356.jpg/EKbP64kEGBcgAigC/FGsyx_buHz5mqBdvwAUTxruI34nHfJSytffECUbSGGg?size_mode=5

 

It has to do with hes privacy settings on that folder, I assume. So hes signed in; he can view it. We're not, we can't view it.

Link to comment
Share on other sites

3 hours ago, BigStamp said:

I really hope this is something that is corrected, the proxy should work for all attached images no matter when they were posted.

I reiterated this point in my ticket several times. @Andy Millne acknowledged this and will be including it in their conversations about the issue.

It was pointed out that these are two different issues. I agree that technically they are, but as a feature both of these issues prevent the image proxy from fulfilling its purpose satisfactorily. In not have the image proxy applied to previously posted images this is a feature that only serves new communities with the proxy and HTTPS enabled from launch. It does not serve established communities who enable the image proxy in conjunction with a change of URL or a switch to HTTPS.

Hopefully this gets sorted soon. :) (I have faith in IPS to sort it.)

Link to comment
Share on other sites

So I'm changing my IPS 4.1 install from forum.domain.com to www.domain.com. After putting it all on the test machine, I noticed proxy images are broken and I ran the php file that @Evil Edwina mentioned and it output the following: https://gyazo.com/cb020080d169ea100bd2eb50287c45e8 Now my site was running SSL on the forum.domain.com and continues to do so on the test system. Anyone know a solution to this?

Link to comment
Share on other sites

On 12/17/2015 at 4:03 PM, Evil Edwina said:

I reiterated this point in my ticket several times. @Andy Millne acknowledged this and will be including it in their conversations about the issue.

It was pointed out that these are two different issues. I agree that technically they are, but as a feature both of these issues prevent the image proxy from fulfilling its purpose satisfactorily. In not have the image proxy applied to previously posted images this is a feature that only serves new communities with the proxy and HTTPS enabled from launch. It does not serve established communities who enable the image proxy in conjunction with a change of URL or a switch to HTTPS.

Hopefully this gets sorted soon. :) (I have faith in IPS to sort it.)

+1 for this. I would love to enable HTTPS on my site but it is currently impossible to do so. I've enabled serving up images locally for HTTPS but as you stated, it only works going forward. My community has almost 1.3 million posts so changing all links over to HTTPS isn't going to be so easy. >_<

Link to comment
Share on other sites

1 hour ago, dyelton said:

+1 for this. I would love to enable HTTPS on my site but it is currently impossible to do so. I've enabled serving up images locally for HTTPS but as you stated, it only works going forward. My community has almost 1.3 million posts so changing all links over to HTTPS isn't going to be so easy. >_<

Yeah, some function to check posts / add and remove easily should be nice. Cron job like they have for other stuff.

Link to comment
Share on other sites

  • 1 month later...

Archived

This topic is now archived and is closed to further replies.

  • Recently Browsing   0 members

    • No registered users viewing this page.

×
×
  • Create New...