Connection Not Secure
-
@qgp9 ah! thanks!
-
You are welcome
Actually this is highly tricky way. This works because
nodebb-plugin-iframely
is only working when a url and contents are exactly same without trim.For my forum, I use of course my
nodebb-plugin-magicblock
-
@accalia said:
Ah, that's what it is.
I was confused as to what could be causing it so fired up firefox to check. confirmed that /recent is currently displaying insecure content.
Using Dev tools in Chrome i've identified that it was loading these images over regular http instead of https:
http://i.imgur.com/oDYNb6S.png
http://i.imgur.com/9EC7UPE.png.... anyway, the post with the images is: https://community.nodebb.org/topic/8218/change-nodebb-homepage-to-blocks/5
looks like this is caused by the "teaser" column loading the full post and having CSS styling applied to it to make the images not display and to prevent the content from spilling over the provided area.
Thanks for testing on your end! Glad it's not only me. Sounds like a bug that will need to be fixed in the next release.
-
@charles said:
Sounds like a bug that will need to be fixed in the next release.
i'm not sure how it could be fixed to be honest. These are user generated links.
yes the teaser could be collapsed to not load the images on
/recent
but that won't stop the warning from occurring when visiting the topic itself.In this case a user posted content that included links to imgur that were over
http
these links were automatically turned into images, which is easy to do. What's harder to do and probably more trouble than it's worth is figuring out that that imgur serves the same content over http and https and upgrade the links to https.one could upgrade all image links to https, but then you have the issue of sites that don't exist in both http and https.
And then there's the issue of altering user provided content. That's always a touchy subject for some forum users, and something that should be considered carefully when implemented.
One could also take the approach that Discourse did where by default the forum downloads remote images and serves them up from the forum itself. This does neatly bypass the issue of the missing HTTPS connection, however it did land several installs of discourse into legal hot water regarding rehosting images without proper attribution, so there's that downside... not to mention the additional storage required for the cached images.
You're welcome to open an issue on github for this if you want to, but i would not expect it to gain much traction given the level of thought and effort that would be required to fix this issue, and given that plugins like the aforementioned https everywhere exist and are easy to install.
Security is important, yes but HTTPS is far from universal yet and so there aren't any simple answers that i can think of to user provided content.
Maybe someone smarter than I can come up with something though, so there's no harm in asking.
-
This post is deleted!
-
camo is probably the best solution for serving images. I'm not really an expert on it or how it works, but it seems to be popular.
https://community.nodebb.org/topic/7927/install-camo-for-nodebb-plugin-iframely -
-
Imgur support boths of
https
andhttp
for same image. Actually best way to put an image is an using of//i.imgur.com/oDYNb6S.png
withouthttp
orhttps
. -
Like the imgur, if image sites which support both protocols are listed, a simple filtering plugin will not be difficult.
-
After those, an solid solution will be a proxy by nodeBB. But I don't don't think that NodeBB need this feature. Already there are many ( with anticipation ) independent standalone solutions. So I would say, it will be really good to NodeBB if somebody check and research open source solutions, or free services.
-
-
@qgp9 said:
- Imgur support boths of
https
andhttp
for same image. Actually best way to put an image is an using of//i.imgur.com/oDYNb6S.png
withouthttp
orhttps
.
I agree with that suggestion as google did the same several years ago.
nodebb can simply strip (or have an option to turn off) http and https and allow urls to just have // www. example. com is better than forcing.
- Imgur support boths of
-
@charles said:
// www. example. com is better than forcing.
while i agree with this in principle it won't solve the issue of www.myrandomblogaboutsocks.com only serving content over http. if you try to link
http://www.myrandomblogaboutsocks.com/public/images/uploads/mine/some/path/image0457239.png
as//www.myrandomblogaboutsocks.com/public/images/uploads/mine/some/path/image0457239.png
and you are currently on https, what you'll get is a broken image.which is not something users expect.
i think ultimately the best solution for most forums is to have a whitelist of image hosts to use that support https, inline images via
//domain.example.com/path
and just leave all other images as links.it's not the prettiest nor the best user experience, but i think it strikes a nice balance between ease of implementation, ease of use, and ease of understanding for non technical people.
-
@qgp9 said:
Frankly, I clicked this link
hmm.... i'm now tempted to buy the domain name and put a markov chain generated blog there....
maybe if i remember after i finish getting version 3.0 of SockBot out the door.
-
@accalia said:
@charles said:
// www. example. com is better than forcing.
while i agree with this in principle it won't solve the issue of www.myrandomblogaboutsocks.com only serving content over http. if you try to link
http://www.myrandomblogaboutsocks.com/public/images/uploads/mine/some/path/image0457239.png
as//www.myrandomblogaboutsocks.com/public/images/uploads/mine/some/path/image0457239.png
and you are currently on https, what you'll get is a broken image.which is not something users expect.
i think ultimately the best solution for most forums is to have a whitelist of image hosts to use that support https, inline images via
//domain.example.com/path
and just leave all other images as links.it's not the prettiest nor the best user experience, but i think it strikes a nice balance between ease of implementation, ease of use, and ease of understanding for non technical people.
the result would be:
if a visitor visits http site and the image is using // then it will serve the image with http:// url
if a visitor visits https site and the image is using // then it will serve the image with https:// urlso using url path without http or https is the advantage.
am I understanding it incorrectly?
-
@charles said:
if a visitor visits https site and the image is using // then it will serve the image with https:// url
which is a problem if the webserver does not respond to https requests
if the server supports http and https then the
//
prefix is correct but if the server only supports http then the//
prefix is brokenthat was my point. you can't know ahead of time if a random webserver supports both http and https, and https is not yet ubiquitus enough to assume there is https support (but hopefully initiatives such as letsencrypt fix that soon)
-
@charles said:
I'm guessing most large sites have ssl so using // should be non issue.
but here's the thing. that's guessing, and users, particularly non technical users who post images found on some random blog that only serves via HTTP will complain when the picture works fine on their machine, but is broken when they view it on the forum.
yes, for the big sites it will mostly be a non issue, but just because the big sites have SSL does not mean that it is by any stretch of the imagination safe to assume that all sites do.
The thing about making decisions like this is to think of things from the point of view of the end users, and any behavior that breaks their images will be seen as broken by the end users.
Torvalds was right when he said you do not break userspace (warning: uncouth language ahead. Linus is not known for being subtle nor for being politically correct)
So, while i agree that the secure connection issue is important it needs to be solved in a way that end users will not perceive as broken.
of the discussions put forth so far i think the two best solutions are:
- use of a transparent proxy for unsecure images, such as camo (suggesteb first by @yariplus)
and - use of a plugin that rewrites links for known image hosts to use HTTPS and turns HTTP images into links for non whitelisted domains
Both of these solutions would offer behavior that removes the Connection Not Secure warning as well as maintaining what end users would consider working behavior.
- use of a transparent proxy for unsecure images, such as camo (suggesteb first by @yariplus)
-
-
nodebb-plugin-camo just got released which should make this whole issue a lot easier to solve. You can find the explanation post here.
-
@lenovouser thanks for sharing! will check it out.