Title: I was using the HN front page to test a library I was writing when I noticed some links that probably should be HTTPS are in plain HTTP. This piqued my interest a bit so I did a little analysis on how prevalent plain HTTP links are on HN. I probably don&#x27;t need to rehash the harm of using plain HTTP, even for personal blogs -- they can be snooped, and they can be modified to inject either ads or more sinister payloads. In fact, years ago I once disabled my ad blocker by accident and saw an ISP-injected ad on my personal site; never again, I swore.<p>The methodology is simple. I gathered all links from https:&#x2F;&#x2F;news.ycombinator.com&#x2F;front (&quot;past&quot; on the navigation bar) for each day from 2020-01-01 to 2020-07-09. These are the top stories of each day. This is a trivial task and resulted in 17566 links (raw data [0][1][2]). There are &lt;100 duplicates, which I kept. Among these are 1112 plain HTTP links, amounting to ~6.3% out of 17566.<p>Next I analyzed how many of the 1112 plain HTTP links are available over HTTPS. Methodology:<p>1. Check if the HTTP version redirects to the HTTPS version; if so, done, otherwise record the HTTP response;<p>2. Replace http:&#x2F;&#x2F; with https:&#x2F;&#x2F; and see if the HTTPS URL works; if so, record the HTTPS response;<p>3. Compare the HTTP and HTTPS responses. If they&#x27;re identical, done. If not, compare the length of the responses; if they differ by &lt;=1%, record this as HTTPS response almost identical as HTTP, and assume the HTTPS version works (the page may not use relative URLs or omit the protocol, so the HTTPS response may be subtly different while having the exact same rendered output).<p>The analysis script is available at [3].<p>---<p>To be continued in a comment since I&#x27;m hitting the 2000 char limit: https:&#x2F;&#x2F;news.ycombinator.com&#x2F;item?id=23802522
Upvote: