8 ms·
Browsers should limit every webpage to displaying a maximum of two fonts, and should silently ignore any font face rules after the first two. Maybe three if you
by onion2k 5y ago
Browsers should limit every webpage to displaying a maximum of two fonts, and should silently ignore any font face rules after the first two. Maybe three if you're feeling generous. With variable fonts available in every browser it wouldn't impact typography much.
It would stop this sort of privacy attack, and it'd have the additional benefit of making the web look a lot nicer.
- 1vuio0pswjnm7 5y agoWho is behind the web browsers that most people use. Companies whose businesses rely on subjugating user privacy have few if any incentives to make these types of changes. These complex browsers do not exist for their users, they exists for the advertising company or other company that collects user data.
- onion2k 5y agoSure. This isn't coming to Chrome or Safari ever. There are other browsers though.
- watermelon0 5y agoAccording to https://gs.statcounter.com/browser-market-share https://gs.statcounter.com/browser-market-share, Chromium-based/Safari browsers have 93% market share, so I wouldn't really count on other browsers that much.
- hansel_der 5y agothou privacy conscious users are vastly underrepresented in analytics.
- kevingadd 5y agoDifferent languages often require you to use different fonts, there are very few fonts that contain characters for all languages. Ranges using specific languages are tagged with the 'lang' attribute so the browser can use the appropriate font. If you aren't allowed to include any font face rules you lose the ability to handle multiple languages (unless all the languages you care about use codepoints below 255). Italic and Bold are also separate fonts (albeit in the same family).
- onion2k 5y agoInternationalization and localization don't require more fonts, just different fonts. When a user is viewing a site in English they'd see a different font to a user viewing a page in Japanese. That's fine. Just serve one a stylesheet with the English font first, and the other a site with the Japanese font first. They would still work fine. Bold and italic were different fonts in the past, but variable fonts have solved loading separate fonts for different weights and italics. This change would require developers swap to use those in many cases, and to create variable versions of brand fonts if necessary. I don't see that as a problem. The benefit makes it worthwhile.
- kevingadd 5y ago"Viewing a site in English" misunderstands the problem. Mixed-language content is a reality. Not all websites are a single language, because they can host user-generated content or snippets of content in other languages (commentary on translated material, live translations, instructional material, etc.)
- wbobeirne 5y agoThis feels like it's targeted at a very narrow view of what a browser is for. How would a site like fonts.google.com work?
- onion2k 5y agoGiving up resources like Google Fonts in order to increase privacy for the entire web seems like a fair trade off to me. Besides, it'd still work fine, but you'd only be able to view two or three fonts at a time.
- sva_ 5y ago> Besides, it'd still work fine, but you'd only be able to view two or three fonts at a time. That would be trivial to break over a few requests, I think
- getcrunk 5y agoEasy. The limit should be for 2 fonts, unless you load them your self
- noduerme 5y agoYou don't seem to realize that the fingerprinting has nothing to do with what fonts you load from a page. It's what fonts you have installed on your machine.
- onion2k 5y agoThe font-face attack in the article requires loading the font from a remote location. A JS font numeration attack works with local fonts. That would need a different mitigation in the browser, but browsers could, for example, have an array limited to three elements that JS gets when it asks for a font list, or just return the system default fonts, or just say no. A permission to get the full list would be necessary for things like browser-based editors and design software, but it'd still be worth it in my opinion. It would be a huge win for privacy. The fact is very few websites use more than three fonts at a time on any particular page, and most sites than do could rework their design so they don't (swapping icon fonts for an SVG font map, for example), or they could implement a canvas or WebGL alternative.
- dylan604 5y agoYes, let's limit creativity because some asshats have made looking at a list of fonts a negative. Let's just limit fonts altogether and only use emojis or braille like dot patterns.
- judge2020 5y agoObviously the browser must prompt users before displaying non-ascii characters as well. Who wants to do anything other than read mailing lists in their browser?
- spicybright 5y agoEvery webpage should be a 640x480 jpg hosting exclusively through a CDN separate from the originating site. Why can't we make a better web like this that respects your privacy?
- hansel_der 5y agoseriously, rendering websites to image formats is an option and some cdn (cf iirc) have products for this.
- ranger_danger 5y agoNot everyone on Earth uses an ascii-compatible language, though.
- judge2020 5y agoI made the comment in jest, primarily to illustrate how restrictions like limiting pages to 2 fonts are completely arbitrary and likely wouldn't even solve the problems presented in the original comment ("make the web look a lot nicer", "stop this sort of privacy attack").
- onion2k 5y agolet's limit creativity because some asshats have made looking at a list of fonts a negative Yes. Security and privacy come at the expense of other things. It's not totally unreasonable to prioritize them though. It would limit creativity, but not by very much.
- noduerme 5y agoThat's just insane. Sites and apps I build these days usually include FontAwesome and/or another icon library, frequently along with a custom dingbat font for the company's unique logos and iconography (we bundle all relevant vector art as a font). Then you have primary and secondary brand fonts, along with sometimes readability fonts. Not to mention iframed forms coming off credit card gateways. I have no idea how a proposal like this could be implemented, but it definitely would destroy most modern layouts.
- tomthe 5y agoI could live with that and I think many users would agree.
- noduerme 5y agoLive with a 2 font maximum and popups every time a site chose to load another font? It would break every icon on the web. You'd either only load the icons or only load the text fonts. If you want to avoid fingerprinting, and actually think this method remotely works, by all means block those requests. If you actually care about privacy a better place to start would be the fact that chrome logs you in on the browser level whenever you login to anything with a Google password. Some random fingerprinting is not worth shutting down all design for. On that idea we should just go back to dialup because everything is too dangerous for idiots to handle.
- onion2k 5y agoIf you actually care about privacy a better place to start would be the fact that chrome logs you in on the browser level whenever you login to anything with a Google password. Google is not the only company that has no respect for privacy. Privacy protection needs to go further, and stop privacy invasion completely. There is a reasonable balance to strike between privacy, design and usability though. That's why I said 2 or 3 fonts. Maybe 4 at a push. If a site is using more than that then either the developers aren't very good, or the designers aren't very good, or it's trying to attack the user's privacy. Whichever one it is, it should be stopped.
- onion2k 5y agoI can't edit my post now unfortunately, but I have had an idea where websites could use as many fonts as they want - font bundling. If there was a format that could contain any number of fonts, browsers would only need to make one request for specific bundled resource, and then browsers could limit the number of requests and designers could pepper their websites with as many fonts as they want. In essence, do what we do with JS code, but with fonts. You'd lose the parallel request benefits of HTTP2 but nevermind.