Topic: Source links getting changed to https, even though source site doesn't support it

Posted under General

Hello all!

I recently tried to add some source links to this post. The site the links go to is old enough that it only supports HTTP, and not HTTPS, so I added them as http:// links. However, e621 seems to auto-edit the links to https://, even though that doesn't work for these particular links - the site just never responds.

I thought that either e621 has an approved list of sites where HTTP -> HTTPS upgrades are known to work, or e621 actually tries to fetch the link as HTTPS before editing the URL. Maybe that is not true, or not working correctly.

Is there some way to tell e621 to not automatically change the links to https://?

For the moment, I put a note in a comment that you need to manually edit the source URLs back to http:// if you want them to work.

Thanks!

forum #287084 topic #26539 forum #295960 forum #313805 forum #317658

A quick search shows this has been brought up since at least 2020. I didn't notice any official response.

As a compromise, I took out the protocol. You don't get a hyperlink, but you can triple click to highlight the URL text and right click to open it with your context menu. That's five clicks instead of one, but at least it opens the page correctly.

Updated

lance_armstrong said:
I didn't notice any official response.

I found one of those older threads, too, but was hopeful that a workaround had been discovered since it was posted. Guess not.

I also tried a couple of variations on what you tried, but mine didn't work either.

(I pondered https^H://foo , but I don't think it works that way anymore...)

Updated

It shouldn't be forcing https on every URL if I'm reading this code correctly so it's kinda strange that it is forcing https on every source. My understanding of this is that it shouldn't be forcing https on any URLs that don't have their own alternates file, like the Fur Affinity one here.

Other than that there's no "approved list of sites where HTTP -> HTTPS upgrades are known to work", but PR #426 proposes to add one.

EDIT: Figured it out - the Pixiv and FurAffinity alternates are being loaded on every source URL, therefore it's setting force_https? to true on every URL.

Updated

faucet said:
It shouldn't be forcing https on every URL if I'm reading this code correctly so it's kinda strange that it is forcing https on every source.

I agree with that reading, but I know very little about Ruby.

The only other way I could interpret that is that the check on line 7 wants to see if force_https? exists, and doesn't care what value it is set to. Since the base class defines force_https?, then it always exists, so line 8 will always s/^http:/https:/ .

I ran a search and the only other semi-related thing I could find was this and its test code , but I think those both go the other way - turning https back into http. I also think that's just for the "URLs" section on the artist pages, where it lists how many times e621 has seen a particular source link for an artist, like "furaffinity.net/user/Artiste 47 weasyl.com/~Artiste 3" - it doesn't have anything to do with the source URLs for each submission. The artist-page code has to standardize on something, so it doesn't end up with URLs that only vary in the protocol.

Other than that there's no "approved list of sites where HTTP -> HTTPS upgrades are known to work", but PR #426 proposes to add one.

Maybe that's what I was thinking of.

EDIT: I didn't see your edit until after my initial reply. Seems weird that it would try to run the FA and Pixiv stuff on every source URL, but what do I know?

  • 1