<?xml version="1.0" encoding="UTF-8"?>
<?xml-stylesheet href="https://shkspr.mobi/blog/wp-content/themes/edent-wordpress-theme/rss-style.xsl" type="text/xsl"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	    xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	     xmlns:dc="http://purl.org/dc/elements/1.1/"
	   xmlns:atom="http://www.w3.org/2005/Atom"
	     xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	  xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>
<channel>
	<title>firefox &#8211; Terence Eden’s Blog</title>
	<atom:link href="https://shkspr.mobi/blog/tag/firefox/feed/" rel="self" type="application/rss+xml" />
	<link>https://shkspr.mobi/blog</link>
	<description>Regular nonsense about tech and its effects 🙃</description>
	<lastBuildDate>Fri, 27 Mar 2026 16:10:05 +0000</lastBuildDate>
	<language>en-GB</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>https://wordpress.org/?v=6.9.4</generator>

<image>
	<url>https://shkspr.mobi/blog/wp-content/uploads/2023/07/cropped-avatar-32x32.jpeg</url>
	<title>firefox &#8211; Terence Eden’s Blog</title>
	<link>https://shkspr.mobi/blog</link>
	<width>32</width>
	<height>32</height>
</image> 
	<item>
		<title><![CDATA[Better TTS on Linux]]></title>
		<link>https://shkspr.mobi/blog/2026/04/better-tts-on-linux/</link>
					<comments>https://shkspr.mobi/blog/2026/04/better-tts-on-linux/#comments</comments>
				<dc:creator><![CDATA[@edent]]></dc:creator>
		<pubDate>Tue, 21 Apr 2026 11:34:07 +0000</pubDate>
				<category><![CDATA[/etc/]]></category>
		<category><![CDATA[accessibility]]></category>
		<category><![CDATA[firefox]]></category>
		<category><![CDATA[linux]]></category>
		<category><![CDATA[tts]]></category>
		<guid isPermaLink="false">https://shkspr.mobi/blog/?p=68497</guid>

					<description><![CDATA[The venerable eSpeak is a mainstay of Linux distributions. It is a clever Text-To-Speech (TTS) program which will read aloud the written word using a phenomenally wide variety of languages and accents.  The only problem is that it sounds robotic. It has the same vocal fidelity as a 1980s Speak &#039;n&#039; Spell toy. Monotonous, clipped, and painful to listen to. For some people, this is a feature, not a…]]></description>
										<content:encoded><![CDATA[<p>The venerable eSpeak is a mainstay of Linux distributions. It is a clever Text-To-Speech (TTS) program which will read aloud the written word using a phenomenally wide variety of languages and accents.</p>

<p>The only problem is that it sounds robotic. It has the same vocal fidelity as a 1980s Speak 'n' Spell toy. Monotonous, clipped, and painful to listen to. For some people, this is a feature, not a bug. I have blind friends who are so used to eSpeak that they can crank it up to hundreds of words per minute and navigate through complex documents with ease.</p>

<p>For the rest of us, it is a steep and unpleasant learning curve.</p>

<p>There are lots of modern TTS programs using all sorts of advanced AI. Many of them are paywalled or require you to post your text to a webserver - with all the privacy and latency problems that causes. Some are restricted to high-powered GPUs or other expensive equipment.</p>

<p><a href="https://github.com/OHF-Voice/piper1-gpl">Piper</a> is different. It is local first, runs quickly on modest hardware, and is open source.</p>

<p>The easiest way to install it on Linux is to use <a href="https://pied.mikeasoft.com/">Pied</a> - a simple GUI which allows you to select languages, listen to accents, and then install them.</p>

<img src="https://shkspr.mobi/blog/wp-content/uploads/2026/03/pied.webp" alt="GUI showing various British English languages." width="594" height="695" class="aligncenter size-full wp-image-68498">

<p>It will change your <code>speech-dispatcher</code> to use the new Piper voice. That means it is immediately available to your Linux DE's accessibility service and to apps like Firefox.</p>

<p>I now have a <a href="http://news.bbc.co.uk/1/mobile/scotland/7754111.stm">reassuring Scottish lady</a> speaking out everything on my computer.</p>
<img src="https://shkspr.mobi/blog/wp-content/themes/edent-wordpress-theme/info/okgo.php?ID=68497&HTTP_REFERER=RSS" alt="" width="1" height="1" loading="eager">]]></content:encoded>
					
					<wfw:commentRss>https://shkspr.mobi/blog/2026/04/better-tts-on-linux/feed/</wfw:commentRss>
			<slash:comments>2</slash:comments>
		
		
			</item>
		<item>
		<title><![CDATA[An odd font rendering bug in Firefox and Safari]]></title>
		<link>https://shkspr.mobi/blog/2026/03/an-odd-font-rendering-bug-in-firefox-and-safari/</link>
					<comments>https://shkspr.mobi/blog/2026/03/an-odd-font-rendering-bug-in-firefox-and-safari/#comments</comments>
				<dc:creator><![CDATA[@edent]]></dc:creator>
		<pubDate>Fri, 13 Mar 2026 12:34:09 +0000</pubDate>
				<category><![CDATA[/etc/]]></category>
		<category><![CDATA[bug]]></category>
		<category><![CDATA[css]]></category>
		<category><![CDATA[firefox]]></category>
		<category><![CDATA[font]]></category>
		<guid isPermaLink="false">https://shkspr.mobi/blog/?p=68692</guid>

					<description><![CDATA[First up, you should go and watch The Importance of Being Earnest with Ncuti Gatwa. It is a brilliant set of performances and a joy to see.  While perusing the programme on the National Theatre website I stumbled upon a little bug.  The incredible Ronkẹ Adékọluẹ́jọ́ has her name rendered in a most unusual style:    It rendered just fine in Chrome - but both Firefox and Safari misrendered some of t…]]></description>
										<content:encoded><![CDATA[<p>First up, you should go and watch <a href="https://www.youtube.com/watch?v=obX-HGs-PS8">The Importance of Being Earnest</a> with Ncuti Gatwa. It is a brilliant set of performances and a joy to see.</p>

<p>While perusing the <a href="https://www.nationaltheatre.org.uk/productions/the-importance-of-being-earnest/#cast">programme on the National Theatre website</a> I stumbled upon a little bug.  The incredible Ronkẹ Adékọluẹ́jọ́ has her name rendered in a most unusual style:</p>

<img src="https://shkspr.mobi/blog/wp-content/uploads/2026/03/ronke.webp" alt="Screenshot of a website. Contains a phone of a black woman next to her name. Any characters with accents in her name are rendered without boldface." width="2953" height="1798" class="aligncenter size-full wp-image-68694">

<p>It rendered just fine in Chrome - but both Firefox and Safari misrendered <em>some</em> of the accented characters.</p>

<p>Here's a minimum viable demo to show what's happening:</p>

<iframe height="300" style="width: 100%;" scrolling="no" title="FF Font Rendering Issue?" src="https://codepen.io/edent/embed/qEaRyrz?default-tab=html%2Cresult" frameborder="no" loading="lazy" allowtransparency="true">
  See the Pen <a href="https://codepen.io/edent/pen/qEaRyrz">
  FF Font Rendering Issue?</a> by Terence Eden (<a href="https://codepen.io/edent">@edent</a>)
  on <a href="https://codepen.io">CodePen</a>.
</iframe>

<h2 id="fonts-are-hard-ok"><a href="https://shkspr.mobi/blog/2026/03/an-odd-font-rendering-bug-in-firefox-and-safari/#fonts-are-hard-ok">Fonts are hard, OK?!?!</a></h2>

<p>Broadly speaking<sup id="fnref:complicated"><a href="https://shkspr.mobi/blog/2026/03/an-odd-font-rendering-bug-in-firefox-and-safari/#fn:complicated" class="footnote-ref" title="It is a lot more complicated than that." role="doc-noteref">0</a></sup>, accented characters can be made in two way.</p>

<ol>
<li>Pre-composed. There is a separate code for the character <code>é</code></li>
<li>Combining. The plain letter <code>e</code> is immediately followed by the <em>combining</em> character <code>◌́</code> and the computer smushes them together.</li>
</ol>

<p>Similarly, a font file can have separate little drawings for each accented character or it can have separate accents.</p>

<p>In this case, the National Theatre is using the font "Helvetica Now Display W04".</p>

<p>The web font contains <code>é</code> (U+00E9) and both <code>◌́</code> (U+0301) &amp; <code>̣◌</code> (U+0323).</p>

<p>But doesn't include <code>ẹ</code> (U+1EB9) or <code>ọ</code> (U+1ECD).</p>

<p>So the ẹ́  and ọ́  have to be made by combining characters in the font.</p>

<p>On Chrome this works. On Firefox and Safari, it seems to break when the CSS is set to <code>font-weight: normal;</code>. This causes the browser to render those characters in the default fallback font - hence the slightly weird look.</p>

<h2 id="next-steps"><a href="https://shkspr.mobi/blog/2026/03/an-odd-font-rendering-bug-in-firefox-and-safari/#next-steps">Next Steps</a></h2>

<p>I've raised <a href="https://bugzilla.mozilla.org/show_bug.cgi?id=2023126">a bug with Firefox</a> and one with <a href="https://bugs.webkit.org/show_bug.cgi?id=309889">WebKit</a>.</p>

<p>Of course, it might be that they're doing the right thing and Chrome is in the wrong - but I think that's unlikely.</p>

<p>Now, time to fix the font I use on this website to prevent any rendering errors!</p>

<div id="footnotes" role="doc-endnotes">
<hr aria-label="Footnotes">
<ol start="0">

<li id="fn:complicated">
<p>It is a <em>lot</em> more <a href="https://www.youtube.com/watch?v=5NPBIwQyPWE">complicated</a> than that.&nbsp;<a href="https://shkspr.mobi/blog/2026/03/an-odd-font-rendering-bug-in-firefox-and-safari/#fnref:complicated" class="footnote-backref" role="doc-backlink">↩︎</a></p>
</li>

</ol>
</div>
<img src="https://shkspr.mobi/blog/wp-content/themes/edent-wordpress-theme/info/okgo.php?ID=68692&HTTP_REFERER=RSS" alt="" width="1" height="1" loading="eager">]]></content:encoded>
					
					<wfw:commentRss>https://shkspr.mobi/blog/2026/03/an-odd-font-rendering-bug-in-firefox-and-safari/feed/</wfw:commentRss>
			<slash:comments>3</slash:comments>
		
		
			</item>
		<item>
		<title><![CDATA[Disable JavaScript on Specific Sites using Firefox for Android and uBlock Origin]]></title>
		<link>https://shkspr.mobi/blog/2024/07/disable-javascript-on-specific-sites-using-firefox-for-android-and-ublock-origin/</link>
					<comments>https://shkspr.mobi/blog/2024/07/disable-javascript-on-specific-sites-using-firefox-for-android-and-ublock-origin/#comments</comments>
				<dc:creator><![CDATA[@edent]]></dc:creator>
		<pubDate>Wed, 10 Jul 2024 11:34:11 +0000</pubDate>
				<category><![CDATA[/etc/]]></category>
		<category><![CDATA[AdBlocking]]></category>
		<category><![CDATA[adverts]]></category>
		<category><![CDATA[android]]></category>
		<category><![CDATA[firefox]]></category>
		<category><![CDATA[uBlock]]></category>
		<guid isPermaLink="false">https://shkspr.mobi/blog/?p=51058</guid>

					<description><![CDATA[Sometimes, you want to stop scripts running only on specific domains. The best way to do that, I think, is with uBlock Origin - a free and fast ad-blocker.  On the desktop version, it&#039;s simple to block scripts. Click the plugin icon, then click the disable scripts button.    But on mobile it&#039;s a little more complicated. Here&#039;s how to do it on the Android version of Firefox.  Install Firefox. Then …]]></description>
										<content:encoded><![CDATA[<p>Sometimes, you want to stop scripts running only on specific domains. The best way to do that, I think, is with <a href="https://ublockorigin.com/">uBlock Origin</a> - a free and fast ad-blocker.</p>

<p>On the desktop version, it's simple to block scripts. Click the plugin icon, then click the disable scripts button.</p>

<img src="https://shkspr.mobi/blog/wp-content/uploads/2024/07/FF-desktop-fs8.png" alt="Desktop version of uBlock. There's a button to disable JS on a site." width="600" height="480" class="aligncenter size-full wp-image-51068">

<p>But on mobile it's a little more complicated. Here's how to do it on the Android version of Firefox.</p>

<p>Install <a href="https://play.google.com/store/apps/details?id=org.mozilla.firefox">Firefox</a>. Then open it and install the <a href="https://addons.mozilla.org/en-US/android/addon/ublock-origin/">uBlock Origin extension for Android</a>.</p>

<p>In Firefox, press the <code>⋮</code> button and press "Settings":</p>

<img src="https://shkspr.mobi/blog/wp-content/uploads/2024/07/1-Settings-fs8.png" alt="The settings menu." width="1008" height="684" class="aligncenter size-full wp-image-51073">

<p>Press "Extensions":
<img src="https://shkspr.mobi/blog/wp-content/uploads/2024/07/2-Extensions-fs8.png" alt="The word &quot;Extensions&quot; is highlighted." width="1008" height="756" class="aligncenter size-full wp-image-51072"></p>

<p>In the list of Extensions is uBlock. Guess what? Press it!</p>

<img src="https://shkspr.mobi/blog/wp-content/uploads/2024/07/3-uBlock-fs8.png" alt="uBlock is highlighted." width="1008" height="505" class="aligncenter size-full wp-image-51071">

<p>Press "Settings"
<img src="https://shkspr.mobi/blog/wp-content/uploads/2024/07/4-uBlock-Settings-fs8.png" alt="The settings menu item is highlighted." width="1008" height="756" class="aligncenter size-full wp-image-51070"></p>

<p>Finally! You come to a page with lots of complex options. I recommend putting your device in landscape mode. Along the top, scroll to "My Rules":</p>

<img src="https://shkspr.mobi/blog/wp-content/uploads/2024/07/5-My-Rules-fs8.png" alt="The my rules sub-page." width="1040" height="376" class="aligncenter size-full wp-image-51069">

<p>The "<a href="https://github.com/gorhill/uBlock/wiki/Dashboard:-My-rules">My Rules</a>" allows you great power over your uBlock.</p>

<p>To block all JavaScript on example.com, type in this line:</p>

<p><code>no-scripting: example.com true</code></p>

<p>Then hit the save button.</p>

<p>You have now disabled JS from running on that specific site. Enjoy!</p>
<img src="https://shkspr.mobi/blog/wp-content/themes/edent-wordpress-theme/info/okgo.php?ID=51058&HTTP_REFERER=RSS" alt="" width="1" height="1" loading="eager">]]></content:encoded>
					
					<wfw:commentRss>https://shkspr.mobi/blog/2024/07/disable-javascript-on-specific-sites-using-firefox-for-android-and-ublock-origin/feed/</wfw:commentRss>
			<slash:comments>1</slash:comments>
		
		
			</item>
		<item>
		<title><![CDATA[DMCA as a vector for pornographic spam?]]></title>
		<link>https://shkspr.mobi/blog/2024/07/dmca-as-a-vector-for-pornographic-spam/</link>
					<comments>https://shkspr.mobi/blog/2024/07/dmca-as-a-vector-for-pornographic-spam/#comments</comments>
				<dc:creator><![CDATA[@edent]]></dc:creator>
		<pubDate>Mon, 08 Jul 2024 11:34:05 +0000</pubDate>
				<category><![CDATA[/etc/]]></category>
		<category><![CDATA[copyright]]></category>
		<category><![CDATA[DMCA]]></category>
		<category><![CDATA[firefox]]></category>
		<category><![CDATA[google]]></category>
		<guid isPermaLink="false">https://shkspr.mobi/blog/?p=51055</guid>

					<description><![CDATA[There&#039;s a law in the USA called the DMCA - Digital Millennium Copyright Act. Amongst its myriad provisions is the ability for copyright holders to send takedown notices to service providers. If someone has ripped off your content, you can send them a legal letter saying &#34;take that down&#34;.  People often send DMCA requests to Google saying &#34;this site has stolen my copyrighted content - please remove …]]></description>
										<content:encoded><![CDATA[<p>There's a law in the USA called the DMCA - Digital Millennium Copyright Act. Amongst its myriad provisions is the ability for copyright holders to send takedown notices to service providers. If someone has ripped off your content, you can send them a legal letter saying "take that down".</p>

<p>People often send DMCA requests to Google saying "this site has stolen my copyrighted content - please remove that page from Google."</p>

<p>Google, to their credit, let me know that they'd recently received a complaint about me 😢</p>

<img src="https://shkspr.mobi/blog/wp-content/uploads/2024/07/Notice-of-DMCA-removal-from-Google-Search-fs8.png" alt=" To: Webmaster of https://shkspr.mobi/, Google has been notified, according to the terms of the Digital Millennium Copyright Act (DMCA), that some of the material found on your site allegedly infringes upon the copyrights of others. We’re in the process of removing the allegedly unlawful materials from Google Search results. The notice that we received, with any personally identifying information removed, may be found on the website of Lumen, a third-party aggregator of legal complaint notices, at https://lumendatabase.org/notices/42788513. " width="920" height="566" class="aligncenter size-full wp-image-51080">

<p>Ah, dammit! What photo had I inadvertently copied?<sup id="fnref:copy"><a href="https://shkspr.mobi/blog/2024/07/dmca-as-a-vector-for-pornographic-spam/#fn:copy" class="footnote-ref" title="I try to use Creative Commons or copyright-free images where possible. But I'm only human and sometime slip up." role="doc-noteref">0</a></sup>  Here's what Google said:</p>

<img src="https://shkspr.mobi/blog/wp-content/uploads/2024/07/URLs-fs8.png" alt="Two URls from my blog. Both relate to CSS." width="920" height="194" class="aligncenter size-full wp-image-51079">

<p>Huh? Back in 2020, I wrote a blog post called "<a href="https://shkspr.mobi/blog/2020/04/this-blog-strips-off-for-css-naked-day/">This blog strips off for CSS Naked Day</a>". It contains a single image:</p>

<img src="https://shkspr.mobi/blog/wp-content/uploads/2020/04/Firefox-menu-fs8.png" alt="Firefox menu. Go to View, the Page Style, then No Style." width="518" height="239" class="aligncenter size-full wp-image-34632">

<p>That's a screenshot that I took of Firefox.  My use of my image on my site isn't a copyright infringement.</p>

<p>WTAF?</p>

<p>Scrolling through the <a href="https://lumendatabase.org/notices/42788513">legal complaint</a> I found I was in illustrious company.</p>

<img src="https://shkspr.mobi/blog/wp-content/uploads/2024/07/adulturls-fs8.png" alt="A long list of adult or explicit URls. My domain name is snugly nestled in the middle." width="599" height="600" class="aligncenter size-full wp-image-51078">

<p>After accessing the full report, I discovered that the complaint was made on behalf of an OnlyFans user called "<strong>firefoxs</strong>"  who has - to quote her bio - the "#1 Nicest Tits On OF"<sup id="fnref:qual"><a href="https://shkspr.mobi/blog/2024/07/dmca-as-a-vector-for-pornographic-spam/#fn:qual" class="footnote-ref" title="A claim which I am unable to substantiate." role="doc-noteref">1</a></sup>.</p>

<p>Needless to say, I dispute the allegation and I've filed a DMCA Counter Notification.</p>

<p>Perhaps this is just a case of an overzealous lawyer hitting every website which contains an image called "Firefox"? Or perhaps it is a ploy to get a bunch of irate webmasters to visit an OnlyFans page to assess the evidence?</p>

<p>Either way, I think the biggest pair of tits on the Internet are firefoxs' copyright lawyers!</p>

<div id="footnotes" role="doc-endnotes">
<hr aria-label="Footnotes">
<ol start="0">

<li id="fn:copy">
<p>I try to use Creative Commons or copyright-free images where possible. But I'm only human and sometime slip up.&nbsp;<a href="https://shkspr.mobi/blog/2024/07/dmca-as-a-vector-for-pornographic-spam/#fnref:copy" class="footnote-backref" role="doc-backlink">↩︎</a></p>
</li>

<li id="fn:qual">
<p>A claim which I am unable to substantiate.&nbsp;<a href="https://shkspr.mobi/blog/2024/07/dmca-as-a-vector-for-pornographic-spam/#fnref:qual" class="footnote-backref" role="doc-backlink">↩︎</a></p>
</li>

</ol>
</div>
<img src="https://shkspr.mobi/blog/wp-content/themes/edent-wordpress-theme/info/okgo.php?ID=51055&HTTP_REFERER=RSS" alt="" width="1" height="1" loading="eager">]]></content:encoded>
					
					<wfw:commentRss>https://shkspr.mobi/blog/2024/07/dmca-as-a-vector-for-pornographic-spam/feed/</wfw:commentRss>
			<slash:comments>7</slash:comments>
		
		
			</item>
		<item>
		<title><![CDATA[Firefox might remember old 2FA logins]]></title>
		<link>https://shkspr.mobi/blog/2023/10/firefox-might-remember-old-2fa-logins/</link>
					<comments>https://shkspr.mobi/blog/2023/10/firefox-might-remember-old-2fa-logins/#comments</comments>
				<dc:creator><![CDATA[@edent]]></dc:creator>
		<pubDate>Thu, 19 Oct 2023 11:34:21 +0000</pubDate>
				<category><![CDATA[/etc/]]></category>
		<category><![CDATA[2fa]]></category>
		<category><![CDATA[firefox]]></category>
		<guid isPermaLink="false">https://shkspr.mobi/blog/?p=48407</guid>

					<description><![CDATA[I&#039;m big enough to admit when I make a mistake.  A few days ago I had a bit of a rant on Mastodon about how PayPal was encouraging browsers to remember 2FA codes.  I&#039;d tried to log in to PayPal, went to enter my 2FA code and was presented with this:      But, this isn&#039;t PayPal&#039;s fault! Let&#039;s take a look at the code behind each input:  &#60;input name=&#34;otpCode-0&#34;         id=&#34;ci-otpCode-0&#34;        …]]></description>
										<content:encoded><![CDATA[<p>I'm big enough to admit when I make a mistake.</p>

<p>A few days ago I had <a href="https://mastodon.social/@Edent/111206844871406102">a bit of a rant on Mastodon</a> about how PayPal was encouraging browsers to remember 2FA codes.</p>

<p>I'd tried to log in to PayPal, went to enter my 2FA code and was presented with this:</p>

<img src="https://shkspr.mobi/blog/wp-content/uploads/2023/10/PayPal-1-fs8.png" alt="Screenshot of the PayPal login screen. The 2FA login has individual inputs for each number. The first input has a dropdown featuring 3 single numbers." width="510" height="508" class="aligncenter size-full wp-image-48410">

<img src="https://shkspr.mobi/blog/wp-content/uploads/2023/10/PayPal-2-fs8.png" alt="The third number has a dropdown featuring3 single numbers." width="510" height="508" class="aligncenter size-full wp-image-48409">

<p>But, this <em>isn't</em> PayPal's fault! Let's take a look at the code behind each input:</p>

<pre><code class="language-html">&lt;input name="otpCode-0" 
       id="ci-otpCode-0" 
       aria-invalid="false" 
       placeholder=" " 
       aria-label="1-6" 
       role="textbox" 
       aria-describedby="otpCode" pattern="[0-9]*" 
       for="securityCodeInput" 
       autocomplete="one-time-code" 
       type="number" 
       value=""&gt;
</code></pre>

<p>It's correctly using <a href="https://developer.mozilla.org/en-US/docs/Web/HTML/Attributes/autocomplete"><code>autocomplete="one-time-code"</code></a> which means that browsers shouldn't remember any entered codes.  Indeed, <a href="https://bugzilla.mozilla.org/show_bug.cgi?id=1547294">Firefox has support this for nearly a year</a>.</p>

<p>So why was I seeing the remnants of old codes?</p>

<p>I was set straight by <a href="https://mastodon.social/@yoasif/111224131353201346">Asif Youssuff</a> who knows a heck of a lot about Firefox. He pointed out that the values might have been saved from <em>prior</em> to the fix. And, he was right!</p>

<p>Firefox doesn't remember new codes - but it will regurgitate old codes it had previously remembered.</p>

<p>I'm not sure if that's desirable or sensible. But it isn't the bug I thought it was!</p>

<p>I went through and manually deleted the old codes - they haven't since re-appeared.</p>
<img src="https://shkspr.mobi/blog/wp-content/themes/edent-wordpress-theme/info/okgo.php?ID=48407&HTTP_REFERER=RSS" alt="" width="1" height="1" loading="eager">]]></content:encoded>
					
					<wfw:commentRss>https://shkspr.mobi/blog/2023/10/firefox-might-remember-old-2fa-logins/feed/</wfw:commentRss>
			<slash:comments>1</slash:comments>
		
		
			</item>
		<item>
		<title><![CDATA[How to fix an upgraded Firefox profile]]></title>
		<link>https://shkspr.mobi/blog/2021/10/how-to-fix-an-upgraded-firefox-profile/</link>
					<comments>https://shkspr.mobi/blog/2021/10/how-to-fix-an-upgraded-firefox-profile/#comments</comments>
				<dc:creator><![CDATA[@edent]]></dc:creator>
		<pubDate>Thu, 07 Oct 2021 11:34:34 +0000</pubDate>
				<category><![CDATA[/etc/]]></category>
		<category><![CDATA[firefox]]></category>
		<category><![CDATA[linux]]></category>
		<category><![CDATA[ubuntu]]></category>
		<guid isPermaLink="false">https://shkspr.mobi/blog/?p=40549</guid>

					<description><![CDATA[I&#039;m an idiot. I ran a new version of Firefox nightly without creating a new profile. When I went to run my regular Firfox, I got this error message:    Here&#039;s how I fixed it.   Close down Firefox Open a terminal and run: firefox --allow-downgrade Let Firefox start up and create a new profile. Then go to: about:profiles You&#039;ll see something like this: Select &#34;Set as default profile&#34; and click…]]></description>
										<content:encoded><![CDATA[<p>I'm an idiot. I ran a new version of Firefox nightly <em>without</em> creating a new profile. When I went to run my regular Firfox, I got this error message:</p>

<img src="https://shkspr.mobi/blog/wp-content/uploads/2021/10/Screenshot-from-2021-10-04-21-32-37.png" alt="Using an older version of Firefox can corrupt bookmarks and browsing history already saved in your existing FireFox profile. To protect your information, create a new profile for this installation of firefox." width="605" height="212" class="aligncenter size-full wp-image-40550">

<p>Here's how I fixed it.</p>

<ol>
<li>Close down Firefox</li>
<li>Open a terminal and run:</li>
<li><code>firefox --allow-downgrade</code></li>
<li>Let Firefox start up and create a new profile. Then go to:</li>
<li><code>about:profiles</code></li>
<li>You'll see something like this:<br><img src="https://shkspr.mobi/blog/wp-content/uploads/2021/10/profiles.png" alt="Screenshot of the profiles screen." width="916" height="292" class="aligncenter size-full wp-image-40551"></li>
<li>Select "Set as default profile" and click through any warnings</li>
<li>Close Firefox.</li>
<li>Once again, run <code>firefox --allow-downgrade</code></li>
</ol>

<p>That should do it! Next time you start Firefox normally, everything should be fine. Probably.</p>

<p>In the future, make backups of your <code>$HOME</code> directory, and create a new profile for your Nightlies!</p>
<img src="https://shkspr.mobi/blog/wp-content/themes/edent-wordpress-theme/info/okgo.php?ID=40549&HTTP_REFERER=RSS" alt="" width="1" height="1" loading="eager">]]></content:encoded>
					
					<wfw:commentRss>https://shkspr.mobi/blog/2021/10/how-to-fix-an-upgraded-firefox-profile/feed/</wfw:commentRss>
			<slash:comments>2</slash:comments>
		
		
			</item>
		<item>
		<title><![CDATA[Change how fast your cursor blinks in Firefox]]></title>
		<link>https://shkspr.mobi/blog/2021/10/change-how-fast-your-cursor-blinks-in-firefox/</link>
					<comments>https://shkspr.mobi/blog/2021/10/change-how-fast-your-cursor-blinks-in-firefox/#respond</comments>
				<dc:creator><![CDATA[@edent]]></dc:creator>
		<pubDate>Sat, 02 Oct 2021 11:34:45 +0000</pubDate>
				<category><![CDATA[/etc/]]></category>
		<category><![CDATA[browser]]></category>
		<category><![CDATA[firefox]]></category>
		<category><![CDATA[HowTo]]></category>
		<guid isPermaLink="false">https://shkspr.mobi/blog/?p=40494</guid>

					<description><![CDATA[(Mostly written to prevent me forgetting)  In about:config add this setting ui.caretBlinkTime of type integer. Then set the number to how many milliseconds between blinks.    250 is very quick, 500 is about normal. I tend to go for about 400. Set it to 0 if you don&#039;t want it to blink at all.  Click the ✅ button and your caret blink speed will immediately change.  You can see more configuration o…]]></description>
										<content:encoded><![CDATA[<p>(Mostly written to prevent me forgetting)</p>

<p>In <a href="about:config"><code>about:config</code></a> add this setting <code>ui.caretBlinkTime</code> of type <code>integer</code>. Then set the number to how many milliseconds between blinks.</p>

<img src="https://shkspr.mobi/blog/wp-content/uploads/2021/09/dontblink.png" alt="" width="895" height="143" class="aligncenter size-full wp-image-40496">

<p><code>250</code> is very quick, <code>500</code> is about normal. I tend to go for about <code>400</code>. Set it to <code>0</code> if you don't want it to blink at all.  Click the ✅ button and your caret blink speed will immediately change.</p>

<p>You can see more configuration options <a href="https://searchfox.org/mozilla-release/source/widget/LookAndFeel.h#48">in the source code</a>.</p>
<img src="https://shkspr.mobi/blog/wp-content/themes/edent-wordpress-theme/info/okgo.php?ID=40494&HTTP_REFERER=RSS" alt="" width="1" height="1" loading="eager">]]></content:encoded>
					
					<wfw:commentRss>https://shkspr.mobi/blog/2021/10/change-how-fast-your-cursor-blinks-in-firefox/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
		<item>
		<title><![CDATA[Howto: Stop Firefox Forcing Dark Mode on Websites]]></title>
		<link>https://shkspr.mobi/blog/2021/09/howto-stop-firefox-forcing-dark-mode-on-websites/</link>
					<comments>https://shkspr.mobi/blog/2021/09/howto-stop-firefox-forcing-dark-mode-on-websites/#comments</comments>
				<dc:creator><![CDATA[@edent]]></dc:creator>
		<pubDate>Mon, 20 Sep 2021 11:18:43 +0000</pubDate>
				<category><![CDATA[/etc/]]></category>
		<category><![CDATA[css]]></category>
		<category><![CDATA[firefox]]></category>
		<category><![CDATA[HowTo]]></category>
		<category><![CDATA[linux]]></category>
		<guid isPermaLink="false">https://shkspr.mobi/blog/?p=40409</guid>

					<description><![CDATA[Here&#039;s how to stop Firefox automatically turning on dark-mode for websites.  In the address bar, type in about:config and press ⏎ and accept the warning it gives you.  Add a new value ui.systemUsesDarkTheme set it to type number and pick one of the following:   0 to tell websites to always use the light theme. 1 to tell websites to always use the dark theme. 2 to tell websites you have no p…]]></description>
										<content:encoded><![CDATA[<p>Here's how to stop Firefox automatically turning on dark-mode for websites.</p>

<p>In the address bar, type in <code>about:config</code> and press <kbd>⏎</kbd> and accept the warning it gives you.</p>

<p>Add a new value <code>ui.systemUsesDarkTheme</code> set it to type <code>number</code> and pick one of the following:</p>

<ul>
<li><code>0</code> to tell websites to <em>always</em> use the <strong>light</strong> theme.</li>
<li><code>1</code> to tell websites to <em>always</em> use the <strong>dark</strong> theme.</li>
<li><code>2</code> to tell websites you have no preference.</li>
</ul>

<img src="https://shkspr.mobi/blog/wp-content/uploads/2021/09/Screenshot-from-2021-09-13-13-29-57.png" alt="Firefox config screen." width="638" height="190" class="aligncenter size-full wp-image-40412">

<h2 id="dev-tools"><a href="https://shkspr.mobi/blog/2021/09/howto-stop-firefox-forcing-dark-mode-on-websites/#dev-tools">Dev Tools</a></h2>

<p>If you want to do this on a one-off basis, open up the Dev Tools and click on the colour simulation icon to change your preferences.</p>

<img src="https://shkspr.mobi/blog/wp-content/uploads/2021/09/dev-tools.png" alt="Firefox dev tools. A pop up informs you that the colour scheme can be toggled." width="639" height="185" class="aligncenter size-full wp-image-40411">

<p>It only works on a per-page basis and disappears when you refresh.</p>

<h2 id="why"><a href="https://shkspr.mobi/blog/2021/09/howto-stop-firefox-forcing-dark-mode-on-websites/#why">Why</a></h2>

<p>I use dark mode on my laptop and most of my Linux apps. But I find most websites' dark mode to look a bit rubbish.  By setting <code>ui.systemUsesDarkTheme</code> to <code>0</code>, I get a nice looking light theme, which I can switch to dark if I want using the website's own controls.</p>

<p>I wish Firefox implemented this as an easy to use toggle switch - but this method works if you're happy to fiddle around in Firefox's guts.</p>
<img src="https://shkspr.mobi/blog/wp-content/themes/edent-wordpress-theme/info/okgo.php?ID=40409&HTTP_REFERER=RSS" alt="" width="1" height="1" loading="eager">]]></content:encoded>
					
					<wfw:commentRss>https://shkspr.mobi/blog/2021/09/howto-stop-firefox-forcing-dark-mode-on-websites/feed/</wfw:commentRss>
			<slash:comments>2</slash:comments>
		
		
			</item>
		<item>
		<title><![CDATA[What's the window size of a background tab?]]></title>
		<link>https://shkspr.mobi/blog/2021/09/whats-the-window-size-of-a-background-tab/</link>
					<comments>https://shkspr.mobi/blog/2021/09/whats-the-window-size-of-a-background-tab/#comments</comments>
				<dc:creator><![CDATA[@edent]]></dc:creator>
		<pubDate>Sat, 04 Sep 2021 11:06:12 +0000</pubDate>
				<category><![CDATA[/etc/]]></category>
		<category><![CDATA[bug]]></category>
		<category><![CDATA[chrome]]></category>
		<category><![CDATA[css]]></category>
		<category><![CDATA[firefox]]></category>
		<category><![CDATA[HTML5]]></category>
		<category><![CDATA[javascript]]></category>
		<guid isPermaLink="false">https://shkspr.mobi/blog/?p=40166</guid>

					<description><![CDATA[Whenever I open Twitter in a new tab on my phone, the page layout looks weird for a few seconds. It starts out looking like the desktop view and then, after a few seconds, it  snaps back to the mobile view.  What&#039;s causing this?  Try opening this link to a window size detector in a background tab. Then visit that tab.  On Chrome, this is what I see.    If I hit the refresh button on that tab, the …]]></description>
										<content:encoded><![CDATA[<p>Whenever I open Twitter in a new tab on my phone, the page layout looks weird for a few seconds. It starts out looking like the desktop view and then, after a few seconds, it  snaps back to the mobile view.</p>

<p>What's causing this?</p>

<p>Try opening <a href="https://www.rapidtables.com/web/tools/window-size.html">this link to a window size detector</a> in a background tab. Then visit that tab.</p>

<p>On Chrome, this is what I see.</p>

<img src="https://shkspr.mobi/blog/wp-content/uploads/2021/09/zero-size.png" alt="The Outer window size is zero by zero." width="400" class="aligncenter size-full wp-image-40169">

<p>If I hit the refresh button on that tab, the  Outer window size snaps back:</p>

<img src="https://shkspr.mobi/blog/wp-content/uploads/2021/09/full-size.png" alt="The Outer window size is 1413 by 768." width="400" class="aligncenter size-full wp-image-40168">

<p>What's going on?</p>

<p>According to the specification:</p>

<blockquote><p><a href="https://drafts.csswg.org/cssom-view/#dom-window-outerwidth">The <code>outerWidth</code> attribute must return the width of the client window. If there is no client window this attribute must return zero.</a></p></blockquote>

<p>This is where I get confused.  The <em>inner</em> width &amp; height are the amount of space the the browser has to display web content - so ignores the browser bar, menu bars, window decorations etc. The <em>outer</em> width &amp; height are the total amount of space the browser window has.</p>

<p>How can a browser window have no outer size, but simultaneously have an inner size???!?!</p>

<video class="aligncenter" id="video-40166-1" loop="1" autoplay="1" preload="metadata" muted="" width="268" height="250">
   <source type="video/mp4" src="https://shkspr.mobi/blog/wp-content/uploads/2021/09/bigger-on-the-inside.mp4?_=1">
</video>

<p>There <em>is</em> a client window. The tab may be rendering away in the background - but its parent still has a non-zero size.</p>

<p>There has been a <a href="https://bugs.chromium.org/p/chromium/issues/detail?id=719296">bug report open on Chrome about this since <strong>2017</strong></a>.</p>

<p>Firefox takes a different approach. On desktop, both outer and inner are reported correctly for background tabs. On mobile, both outer and inner dimensions are set to zero.  This may change as it is a <a href="https://bugzilla.mozilla.org/show_bug.cgi?id=1579584">potential fingerprinting target</a>.</p>

<p>So, web developers, please don't rely on <code>window.innerHeight</code> and <code>window.outerHeight</code> - users may be opening your site in the background, which causes the browser to lie to you.</p>
<img src="https://shkspr.mobi/blog/wp-content/themes/edent-wordpress-theme/info/okgo.php?ID=40166&HTTP_REFERER=RSS" alt="" width="1" height="1" loading="eager">]]></content:encoded>
					
					<wfw:commentRss>https://shkspr.mobi/blog/2021/09/whats-the-window-size-of-a-background-tab/feed/</wfw:commentRss>
			<slash:comments>1</slash:comments>
		
		
			</item>
		<item>
		<title><![CDATA[Invisible Pink Unicorns - a Firefox emoji rendering bug]]></title>
		<link>https://shkspr.mobi/blog/2019/05/invisible-pink-unicorns-a-firefox-emoji-rendering-bug/</link>
					<comments>https://shkspr.mobi/blog/2019/05/invisible-pink-unicorns-a-firefox-emoji-rendering-bug/#comments</comments>
				<dc:creator><![CDATA[@edent]]></dc:creator>
		<pubDate>Mon, 27 May 2019 18:42:32 +0000</pubDate>
				<category><![CDATA[/etc/]]></category>
		<category><![CDATA[bug]]></category>
		<category><![CDATA[emoji]]></category>
		<category><![CDATA[firefox]]></category>
		<category><![CDATA[linux]]></category>
		<category><![CDATA[unicode]]></category>
		<guid isPermaLink="false">https://shkspr.mobi/blog/?p=32176</guid>

					<description><![CDATA[Here&#039;s a curious bug I just discovered in Firefox 67 for Linux.  Can you see this unicorn: →🦄 ←  What happens if you use CSS to change the opacity of an emoji?  Here&#039;s a unicorn, with a pink font colour:  🦄 Unicorn  Let&#039;s wrap that in this scrap of CSS to make it 50% opaque.  color: rgba(255, 105, 180, 0.5);   🦄 Unicorn  Hopefully, you see a semi-transparent philosophical argument. What if we set …]]></description>
										<content:encoded><![CDATA[<p>Here's a curious bug I just discovered in Firefox 67 for Linux.  Can you see this unicorn: <br>→<span style="font-size:1em;color: rgba(255, 105, 180, 0); text-shadow: .2em .2em .2em rgba(255, 105, 180, 0);
">🦄</span> ←</p>

<p>What happens if you use CSS to change the opacity of an emoji?</p>

<p>Here's a unicorn, with a pink font colour:</p>

<p><span style="font-size:3em;color: rgba(255, 105, 180);">🦄 Unicorn</span></p>

<p>Let's wrap that in this scrap of CSS to make it 50% opaque.</p>

<pre><code class="language-_">color: rgba(255, 105, 180, 0.5);
</code></pre>

<p><span style="font-size:3em;color: rgba(255, 105, 180, 0.5);">🦄 Unicorn</span></p>

<p>Hopefully, you see a semi-transparent <a href="https://en.wikipedia.org/wiki/Invisible_Pink_Unicorn">philosophical argument</a>. What if we set the opacity to <code>0.0</code> - that is, completely transparent?</p>

<p><span style="font-size:3em;color: rgba(255, 105, 180, 0.0);">🦄 Unicorn</span></p>

<p>There's a shunicorn there. If you don't believe me, try highlighting it!</p>

<p>Now, let's try a see-though beastie, but this time adding a drop-shadow:</p>

<pre><code class="language-_">color: rgba(255, 105, 180, 0.5); text-shadow: .2em .2em .2em #000;
</code></pre>

<p><span style="font-size:3em;color: rgba(255, 105, 180, 0.5); text-shadow: .2em .2em .2em #000;
">🦄 Unicorn</span></p>

<p>Good!  And now <em>fully</em> transparent text plus a drop-shadow:</p>

<pre><code class="language-_">color: rgba(255, 105, 180, 0); text-shadow: .2em .2em .2em #000;
</code></pre>

<p><span style="font-size:3em;color: rgba(255, 105, 180, 0); text-shadow: .2em .2em .2em #000;
">🦄 Unicorn</span></p>

<p>On Firefox, the text is invisible, but the emoji is completely visible - like this...</p>

<img src="https://shkspr.mobi/blog/wp-content/uploads/2019/05/Screenshot_2019-05-27-Invisible-Pink-Unicorns-a-Firefox-rendering-bug.png" alt="The upper image is partially transparent. The lower image is completely opaque." width="604" height="239" class="aligncenter size-full wp-image-32189">

<p>This bug is not present on Firefox for Android, nor Chromium for Linux.</p>

<p>The only way on Firefox, to get a completely invisible pink unicorn plus a drop shadow is to use:</p>

<pre><code class="language-_">color: rgba(255, 105, 180, 0.002); text-shadow: .2em .2em .2em #000;
</code></pre>

<p><span style="font-size:3em;color: rgba(255, 105, 180, 0.002); text-shadow: .2em .2em .2em #000;
">🦄 Unicorn</span></p>

<pre><code class="language-_">color: rgba(255, 105, 180, 0.001); text-shadow: .2em .2em .2em #000;
</code></pre>

<p><span style="font-size:3em;color: rgba(255, 105, 180, 0.001); text-shadow: .2em .2em .2em #000;
">🦄 Unicorn</span></p>

<p><code>0.002</code> is invisible, but <code>0.001</code> is visible.</p>

<p>I've <a href="https://bugzilla.mozilla.org/show_bug.cgi?id=1554753">raised this as a bug on Mozilla's Bugzilla</a>.</p>

<p>In the meantime, if you can see the invisible pink unicorn, please let me know. Or contact a theologian.</p>
<img src="https://shkspr.mobi/blog/wp-content/themes/edent-wordpress-theme/info/okgo.php?ID=32176&HTTP_REFERER=RSS" alt="" width="1" height="1" loading="eager">]]></content:encoded>
					
					<wfw:commentRss>https://shkspr.mobi/blog/2019/05/invisible-pink-unicorns-a-firefox-emoji-rendering-bug/feed/</wfw:commentRss>
			<slash:comments>7</slash:comments>
		
		
			</item>
		<item>
		<title><![CDATA[textarea placeholder bug in Firefox]]></title>
		<link>https://shkspr.mobi/blog/2017/11/textarea-placeholder-bug-in-firefox/</link>
					<comments>https://shkspr.mobi/blog/2017/11/textarea-placeholder-bug-in-firefox/#respond</comments>
				<dc:creator><![CDATA[@edent]]></dc:creator>
		<pubDate>Wed, 15 Nov 2017 19:00:55 +0000</pubDate>
				<category><![CDATA[/etc/]]></category>
		<category><![CDATA[bug]]></category>
		<category><![CDATA[firefox]]></category>
		<category><![CDATA[HTML5]]></category>
		<category><![CDATA[NaBloPoMo]]></category>
		<guid isPermaLink="false">https://shkspr.mobi/blog/?p=28757</guid>

					<description><![CDATA[The new Firefox is out! Powered by the ludicrous-speed quantum engine - it really is a marvel to behold.  Unfortunately, there&#039;s a rather annoying bug in the way it renders placeholder text.  Consider the following HTML:  &#60;textarea placeholder=&#34;In loving memory of Buffy Anne Summers She saved the world A lot...&#34;&#62;&#60;/textarea&#62;   This should render a textarea (a multi-line input box) pre-filled with…]]></description>
										<content:encoded><![CDATA[<p>The new Firefox is out! Powered by the ludicrous-speed quantum engine - it really is a marvel to behold.</p>

<p>Unfortunately, there's a rather annoying bug in the way it renders placeholder text.  Consider the following HTML:</p>

<pre><code class="language-_">&lt;textarea placeholder="In loving memory of
Buffy Anne Summers
She saved the world
A lot..."&gt;&lt;/textarea&gt;
</code></pre>

<p>This should render a <code>textarea</code> (a multi-line input box) pre-filled with placeholder text. The text should be over multiple lines.  Instead, it renders like this:</p>

<img src="https://shkspr.mobi/blog/wp-content/uploads/2017/10/inscription-fs8.png" alt="Screenshot - the text is rendered on a single line" width="574" height="186" class="aligncenter size-full wp-image-28758">

<p>Is that right? No! Let's see what the spec says (disclaimer - I'm an editor on the HTML 5.3 spec).</p>

<blockquote><p>User agents should present this hint to the user when the element’s value is the empty string and the control is not focused (e.g., by displaying it inside a blank unfocused control). All U+000D CARRIAGE RETURN U+000A LINE FEED character pairs (CRLF) in the hint, as well as all other U+000D CARRIAGE RETURN (CR) and U+000A LINE FEED (LF) characters in the hint, must be treated as line breaks when rendering the hint.</p>

<p><a href="https://www.w3.org/TR/html52/sec-forms.html#element-attrdef-textarea-placeholder">HTML 5.2 - 4.10.11. The textarea element</a></p></blockquote>

<p>Amusingly, Mozilla's <em>own</em> documentation corroborates this:</p>

<blockquote><p>placeholder</p>

<p>A hint to the user of what can be entered in the control. Carriage returns or line-feeds within the placeholder text must be treated as line breaks when rendering the hint.</p>

<p><a href="https://developer.mozilla.org/en-US/docs/Web/HTML/Element/textarea#attr-placeholder">MDN <code>&lt;textarea&gt;</code></a></p></blockquote>

<p>I've <a href="https://bugzilla.mozilla.org/show_bug.cgi?id=1391044">raised this as a bug with Mozilla</a> - sadly, my C++ is too rusty to contribute a patch!</p>
<img src="https://shkspr.mobi/blog/wp-content/themes/edent-wordpress-theme/info/okgo.php?ID=28757&HTTP_REFERER=RSS" alt="" width="1" height="1" loading="eager">]]></content:encoded>
					
					<wfw:commentRss>https://shkspr.mobi/blog/2017/11/textarea-placeholder-bug-in-firefox/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
		<item>
		<title><![CDATA[RTL Bugs]]></title>
		<link>https://shkspr.mobi/blog/2014/02/rtl-bugs/</link>
					<comments>https://shkspr.mobi/blog/2014/02/rtl-bugs/#respond</comments>
				<dc:creator><![CDATA[@edent]]></dc:creator>
		<pubDate>Mon, 24 Feb 2014 12:02:16 +0000</pubDate>
				<category><![CDATA[linux]]></category>
		<category><![CDATA[bugs]]></category>
		<category><![CDATA[chrome]]></category>
		<category><![CDATA[chromium]]></category>
		<category><![CDATA[firefox]]></category>
		<category><![CDATA[unicode]]></category>
		<guid isPermaLink="false">http://shkspr.mobi/blog/?p=9988</guid>

					<description><![CDATA[Take a look at the following text, looks normal enough doesn&#039;t it?  &#34;Harry ‮&#34;.draziw a si ‭Potter  Now, try to select the text and see what happens.  WHAT WITCHCRAFT IS THIS?!  If you examine the source code for this page, you&#039;ll see that I&#039;m using the Unicode Bi-Directional characters.  &#34;Harry &#38;#x202e;&#34;.draziw a si &#38;#8237;Potter  These characters are useful when writing text that includes, say, E…]]></description>
										<content:encoded><![CDATA[<p>Take a look at the following text, looks normal enough doesn't it?</p>

<h2 id="harry-draziw-a-si-potter"><a href="https://shkspr.mobi/blog/2014/02/rtl-bugs/#harry-draziw-a-si-potter">"Harry ‮".draziw a si ‭Potter</a></h2>

<p>Now, try to select the text and see what happens.</p>

<p>WHAT WITCHCRAFT IS THIS?!</p>

<p>If you examine the source code for this page, you'll see that I'm using the <a href="https://en.wikipedia.org/wiki/Unicode_character_property#Bidirectional_writing">Unicode Bi-Directional characters</a>.</p>

<pre>"Harry &amp;#x202e;".draziw a si &amp;#8237;Potter</pre>

<p>These characters are useful when writing text that includes, say, English and Arabic - but <a href="http://krebsonsecurity.com/2011/09/right-to-left-override-aids-email-attacks/">they can also be used for malicious purposes</a>.</p>

<p>On a more mundane level, they can cause all sorts of UI bugs.  I've just <a href="http://code.google.com/p/chromium/issues/detail?id=345691">filed a bug against the Chrome browser for how it handles these characters</a>.</p>

<p>If you right click on text with mixed direction, you'll notice that the UI behaves oddly.</p>

<img src="https://shkspr.mobi/blog/wp-content/uploads/2014/02/Chrome-RTL-fs8.png" alt="Chrome RTL-fs8" width="480" height="330" class="aligncenter size-full wp-image-9996">

<p>In Firefox, the behaviour is correct - although one could argue whether "Potter" ought to be reversed.</p>

<img src="https://shkspr.mobi/blog/wp-content/uploads/2014/02/Firefox-RTL-fs8.png" alt="Firefox RTL-fs8" width="480" height="430" class="aligncenter size-full wp-image-9995">

<h2 id="searching"><a href="https://shkspr.mobi/blog/2014/02/rtl-bugs/#searching">Searching</a></h2>

<p>So, what happens when we run these searches?</p>

<p><img src="https://shkspr.mobi/blog/wp-content/uploads/2014/02/Chromium-RTL-Search-fs8.png" alt="Chromium RTL Search-fs8" width="640" height="165" class="aligncenter size-full wp-image-9999"><br>
<img src="https://shkspr.mobi/blog/wp-content/uploads/2014/02/Firefox-RTL-Search-fs8.png" alt="Firefox RTL Search-fs8" width="640" height="165" class="aligncenter size-full wp-image-9998"></p>

<p>Neither Firefox nor Chrome do particularly well.  I'm not sure if the reversed text in the window title and URL bar are bugs in Ubuntu - or whether it's the fault of the app itself.</p>

<p>On Windows and Mac, we see this happen:</p>

<p><img src="https://shkspr.mobi/blog/wp-content/uploads/2014/02/Safari-RTL-fs8.png" alt="Safari RTL-fs8" width="818" height="155" class="aligncenter size-full wp-image-10002"><br>
<img src="https://shkspr.mobi/blog/wp-content/uploads/2014/02/IE-RTL-fs8.png" alt="IE RTL-fs8" width="606" height="145" class="aligncenter size-full wp-image-10003"></p>

<p>This would suggest that Google isn't correcting the direction of the text and that is deforming its own title tags.</p>

<h2 id="are-these-bugs"><a href="https://shkspr.mobi/blog/2014/02/rtl-bugs/#are-these-bugs">Are These Bugs?</a></h2>

<p>Ok, so having the title reversed isn't the worst problem in the world.  But do these examples count as bugs and, if so, who is responsible for them?</p>

<p>Every search engine I tried passed through the right-to-left-over-ride unscathed - so that's the fault of the search engine, right?  How the hell do you a report a bug to Google?</p>

<p>The title bar could either be a problem with the browser - <a href="https://bugzilla.mozilla.org/show_bug.cgi?id=814030">Firefox has a bug report over a year old on the issue</a> - or the problem could be with the underlying operating system.  How would one find out?</p>

<h2 id="thanks"><a href="https://shkspr.mobi/blog/2014/02/rtl-bugs/#thanks">Thanks</a></h2>

<p>Thanks to <a href="https://www.linkedin.com/in/yuanphoon/">Yuan Phoon</a> for asking the questions which prompted this discovery.</p>
<img src="https://shkspr.mobi/blog/wp-content/themes/edent-wordpress-theme/info/okgo.php?ID=9988&HTTP_REFERER=RSS" alt="" width="1" height="1" loading="eager">]]></content:encoded>
					
					<wfw:commentRss>https://shkspr.mobi/blog/2014/02/rtl-bugs/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
		<item>
		<title><![CDATA[Malicious Use of the HTML5 Vibrate API]]></title>
		<link>https://shkspr.mobi/blog/2014/01/malicious-use-of-the-html5-vibrate-api/</link>
					<comments>https://shkspr.mobi/blog/2014/01/malicious-use-of-the-html5-vibrate-api/#comments</comments>
				<dc:creator><![CDATA[@edent]]></dc:creator>
		<pubDate>Fri, 10 Jan 2014 11:49:08 +0000</pubDate>
				<category><![CDATA[mobile]]></category>
		<category><![CDATA[android]]></category>
		<category><![CDATA[api]]></category>
		<category><![CDATA[chrome]]></category>
		<category><![CDATA[firefox]]></category>
		<category><![CDATA[HTML5]]></category>
		<category><![CDATA[opera]]></category>
		<category><![CDATA[scam]]></category>
		<category><![CDATA[vibrate]]></category>
		<guid isPermaLink="false">http://shkspr.mobi/blog/?p=9496</guid>

					<description><![CDATA[There is a new API in town!  HTML5 will (soon) let you make the user&#039;s device vibrate.  What fun!  Obviously, it&#039;s useful for triggering alerts, improved immersivness during gameplay, and all sorts of other fun things like sending Morse Code messages via vibration.  At the moment, Chrome (and other Android browsers) ask for permission before accessing features such as geo-location, camera,…]]></description>
										<content:encoded><![CDATA[<p>There is a new API in town!  HTML5 will (soon) let you make the user's device vibrate.  What fun!  Obviously, it's useful for triggering alerts, improved immersivness during gameplay, and all sorts of other fun things like <a href="http://www.smartjava.org/content/html5-remotely-vibrate-phone-morse-code-using-web-sockets-and-vibrate-api">sending Morse Code messages via vibration</a>.</p>

<p>At the moment, Chrome (and other Android browsers) ask for permission before accessing features such as geo-location, camera, address book etc.  This is a security measure to prevent your private information leaving your hands without your knowledge.</p>

<p>At the moment, <a href="http://shapeshed.com/html5-vibrate-api/">accessing the HTML5 Vibrate API</a> doesn't trigger an on-screen warning. Its use is seen as pretty innocuous.  Because, realistically, the worst it can do is prematurely drain your battery. Right?</p>

<p>I'm not so sure.</p>

<h2 id="evil-thoughts"><a href="https://shkspr.mobi/blog/2014/01/malicious-use-of-the-html5-vibrate-api/#evil-thoughts">Evil Thoughts</a></h2>

<p>We've all seen those scummy adverts designed to look like Windows pop-ups.  They usually pose as a legitimate system request - "Update Java" or similar.</p>

<p>Suppose a malicious web page pops up a fake system notification and vibrates at the same time. How confident would you be of telling the difference between a legitimate pop-up and a .png on the web page you're viewing.  After all, the phone buzzed - so it <em>must</em> be genuine.</p>

<p><img src="https://shkspr.mobi/blog/wp-content/uploads/2014/01/Fake-Airdrop.jpg" alt="Fake Airdrop" width="319" height="651" class="aligncenter size-full wp-image-9499">
Are you really receiving an "AirDrop" - or is this page trying to trick you?</p>

<p>Autoplaying sound on adverts in annoying - auto-vibration could be just as irritating.  Imagine searching through tabs until you found the single advert which was pulsing away trying to get you to buy new insurance.</p>

<p>For now, the <strong>intensity</strong> of the vibration cannot be controlled - only the duration.  It is not impossible to conceive of malicious code being able to exploit an unpatched browser flaw and overdrive the motor to destruction.</p>

<h3 id="faking-telephone-calls"><a href="https://shkspr.mobi/blog/2014/01/malicious-use-of-the-html5-vibrate-api/#faking-telephone-calls">Faking Telephone Calls</a></h3>

<p>When combined with HTML5 Audio, it would be possible to create a fairly realistic "Incoming Call" screen which vibrated and played a ringtone.  Once "answered", the page could play some audio which says "Hi, can you call me back urgently - my number is [premium rate line]" and then, perhaps, automatically open up the dialer using the tel: URI.
<a href="https://shkspr.mobi/vibratescam/"><img src="https://shkspr.mobi/blog/wp-content/uploads/2014/01/Phone-call-in-browser-scam-fs8-175x300.png" alt="Phone call in browser scam" width="175" height="300" class="aligncenter size-medium wp-image-9504"></a>
Could you tell if the above was a real phone call? If you looked closely, probably, but when the browser is playing your phone's default ringtone and the handset is vibrating, it would be pretty easy to be confused.  Combine it with a WebRTC call and you're looking at a <em>very</em> convincing scam.</p>

<h2 id="video-demo"><a href="https://shkspr.mobi/blog/2014/01/malicious-use-of-the-html5-vibrate-api/#video-demo">Video Demo</a></h2>

<iframe width="360" height="640" src="//www.youtube.com/embed/VqsRya3ZNoE?feature=player_embedded" frameborder="1" allowfullscreen=""></iframe>

<h2 id="source-code"><a href="https://shkspr.mobi/blog/2014/01/malicious-use-of-the-html5-vibrate-api/#source-code">Source Code</a></h2>

<p>Here's a basic example which you can try on your own phone - <a href="https://shkspr.mobi/vibratescam/">demo site</a>.</p>

<pre><code>&lt;body&gt;
   &lt;script type="text/javascript"&gt;
      navigator.vibrate = navigator.vibrate || navigator.webkitVibrate || navigator.mozVibrate || navigator.msVibrate;
      navigator.vibrate([1000, 500, 1000, 500, 1000, 500, 1000, 500, 1000, 500, 1000, 500, 1000, 500]);
   &lt;/script&gt;
   &lt;img width="100%" src="phone.png" onclick="window.location.href='tel:09098790815';" /&gt;
   &lt;audio autoplay="autoplay"&gt;
      &lt;source src="ring.mp3" /&gt;
   &lt;/audio&gt;
&lt;/body&gt;
</code></pre>

<p>At the moment, the auto-vibrate and auto-ring only work on Firefox for Android. But no doubt other browsers will follow suite soon.</p>

<h2 id="warnings"><a href="https://shkspr.mobi/blog/2014/01/malicious-use-of-the-html5-vibrate-api/#warnings">Warnings</a></h2>

<p>Firefox was the only browser I found which supported Vibrate - on Android, neither Samsung's browser, Chrome, or Opera did - iPhone also doesn't yet support it.  No one cares about Windows Phone or BlackBerry - so I didn't test them*.</p>

<p>Firefox <strong>doesn't</strong> currently ask for permission when a <a href="http://davidwalsh.name/demo/vibrate.php">page requests access to vibrate</a>.</p>

<p>Do you think browsers should warn before a page vibrates - or is the risk too low?  I guess we'll have to see if the scammers take advantage of it - and whether there is a user backlash.</p>

<p><ins datetime="2014-01-11T14:57:24+00:00">*Update</ins>: thanks to the <a href="http://www.reddit.com/r/programming/comments/1uvlwt/malicious_use_of_the_html5_vibrate_api/">comments on Reddit</a> and on <a href="https://news.ycombinator.com/item?id=7036181">HackerNews</a> it would appear that BB10 <em>does</em> support the vibrate API, Windows Phone doesn't.</p>
<img src="https://shkspr.mobi/blog/wp-content/themes/edent-wordpress-theme/info/okgo.php?ID=9496&HTTP_REFERER=RSS" alt="" width="1" height="1" loading="eager">]]></content:encoded>
					
					<wfw:commentRss>https://shkspr.mobi/blog/2014/01/malicious-use-of-the-html5-vibrate-api/feed/</wfw:commentRss>
			<slash:comments>43</slash:comments>
		
		
			</item>
		<item>
		<title><![CDATA[Browser Statistics of 10 Downing Street]]></title>
		<link>https://shkspr.mobi/blog/2009/10/browser-statistics-of-10-downing-street/</link>
					<comments>https://shkspr.mobi/blog/2009/10/browser-statistics-of-10-downing-street/#comments</comments>
				<dc:creator><![CDATA[@edent]]></dc:creator>
		<pubDate>Fri, 02 Oct 2009 10:58:32 +0000</pubDate>
				<category><![CDATA[politics]]></category>
		<category><![CDATA[browser]]></category>
		<category><![CDATA[firefox]]></category>
		<category><![CDATA[internet explorer]]></category>
		<category><![CDATA[stats]]></category>
		<guid isPermaLink="false">http://shkspr.mobi/blog/?p=583</guid>

					<description><![CDATA[It&#039;s really difficult cutting through the hype to see which browsers one should support when designing a website.  There are many different measures of popularity - but many sites are only visited by techies, or only ever visited when at work, or are skewed towards the young or the old.  Yesterday morning I asked the Number 10 Downing Street web team if they could provide their statistics.  I…]]></description>
										<content:encoded><![CDATA[<p>It's really difficult cutting through the hype to see which browsers one should support when designing a website.  There are many different measures of popularity - but many sites are only visited by techies, or only ever visited when at work, or are skewed towards the young or the old.</p>

<p>Yesterday morning <a href="http://twitter.com/edent/status/4529469389">I asked the Number 10 Downing Street web team if they could provide their statistics</a>.  I figured that the <a href="http://www.number10.gov.uk/"> PM's website</a> gets enough readers from a wide selection of the web community to give a fairly impartial measure of the popular web browsers.</p>

<p>Here's their (very quick) reply</p>

<blockquote class="social-embed" id="social-embed-4549222839" lang="cy" itemscope="" itemtype="https://schema.org/SocialMediaPosting"><blockquote class="social-embed" id="social-embed-4529469389" lang="en" itemscope="" itemtype="https://schema.org/SocialMediaPosting"><header class="social-embed-header" itemprop="author" itemscope="" itemtype="https://schema.org/Person"><a href="https://twitter.com/edent" class="social-embed-user" itemprop="url"><img class="social-embed-avatar social-embed-avatar-circle" src="data:image/webp;base64,UklGRkgBAABXRUJQVlA4IDwBAACQCACdASowADAAPrVQn0ynJCKiJyto4BaJaQAIIsx4Au9dhDqVA1i1RoRTO7nbdyy03nM5FhvV62goUj37tuxqpfpPeTBZvrJ78w0qAAD+/hVyFHvYXIrMCjny0z7wqsB9/QE08xls/AQdXJFX0adG9lISsm6kV96J5FINBFXzHwfzMCr4N6r3z5/Aa/wfEoVGX3H976she3jyS8RqJv7Jw7bOxoTSPlu4gNbfXYZ9TnbdQ0MNnMObyaRQLIu556jIj03zfJrVgqRM8GPwRoWb1M9AfzFe6Mtg13uEIqrTHmiuBpH+bTVB5EEQ3uby0C//XOAPJOFv4QV8RZDPQd517Khyba8Jlr97j2kIBJD9K3mbOHSHiQDasj6Y3forATbIg4QZHxWnCeqqMkVYfUAivuL0L/68mMnagAAA" alt="" itemprop="image"><div class="social-embed-user-names"><p class="social-embed-user-names-name" itemprop="name">Terence Eden is on Mastodon</p>@edent</div></a><img class="social-embed-logo" alt="Twitter" src="data:image/svg+xml,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%0Aaria-label%3D%22Twitter%22%20role%3D%22img%22%0AviewBox%3D%220%200%20512%20512%22%3E%3Cpath%0Ad%3D%22m0%200H512V512H0%22%0Afill%3D%22%23fff%22%2F%3E%3Cpath%20fill%3D%22%231d9bf0%22%20d%3D%22m458%20140q-23%2010-45%2012%2025-15%2034-43-24%2014-50%2019a79%2079%200%2000-135%2072q-101-7-163-83a80%2080%200%200024%20106q-17%200-36-10s-3%2062%2064%2079q-19%205-36%201s15%2053%2074%2055q-50%2040-117%2033a224%20224%200%2000346-200q23-16%2040-41%22%2F%3E%3C%2Fsvg%3E"></header><section class="social-embed-text" itemprop="articleBody"><small class="social-embed-reply"><a href="https://twitter.com/10DowningStreet/status/4528243248">Replying to @10DowningStreet</a></small><a href="https://twitter.com/downingstreet">@downingstreet</a> can you tell us how many Firefox/IE/Safari users visit the Number 10 website? Would be really helpful to UK web developers</section><hr class="social-embed-hr"><footer class="social-embed-footer"><a href="https://twitter.com/edent/status/4529469389"><span aria-label="0 likes" class="social-embed-meta">❤️ 0</span><span aria-label="0 replies" class="social-embed-meta">💬 0</span><span aria-label="0 reposts" class="social-embed-meta">🔁 0</span><time datetime="2009-10-01T17:10:55.000Z" itemprop="datePublished">17:10 - Thu 01 October 2009</time></a></footer></blockquote><header class="social-embed-header" itemprop="author" itemscope="" itemtype="https://schema.org/Person"><a href="https://twitter.com/10DowningStreet" class="social-embed-user" itemprop="url"><img class="social-embed-avatar social-embed-avatar-circle" src="data:image/webp;base64,UklGRugAAABXRUJQVlA4INwAAABQBgCdASowADAAPrVGoEmnI6MhLjgMyOAWiWkABRAe255KmcvngTIHZUZBs7q+gBls3fOCafekoFoRAAD++fsTk7Rl64MygtEv7WfR+YvwKawSuOB34F76rSTwynqUi4e2s52811JwS6k6w5xaP90fx+/gCgEdHTmIEDTtSYi2J86lXj1RTOB/HfXJ9y/+qi5oKgkFt3TsGTzoBxfTjAx6S1VWeCy3jYbtBusa2YuTW8fOOzY+7G07555Mula3+V5pNC8fVL5WUMBbZM8/1jxXJp/z/vAzIxNqIAAA" alt="" itemprop="image"><div class="social-embed-user-names"><p class="social-embed-user-names-name" itemprop="name">UK Prime Minister</p>@10DowningStreet</div></a><img class="social-embed-logo" alt="Twitter" src="data:image/svg+xml,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%0Aaria-label%3D%22Twitter%22%20role%3D%22img%22%0AviewBox%3D%220%200%20512%20512%22%3E%3Cpath%0Ad%3D%22m0%200H512V512H0%22%0Afill%3D%22%23fff%22%2F%3E%3Cpath%20fill%3D%22%231d9bf0%22%20d%3D%22m458%20140q-23%2010-45%2012%2025-15%2034-43-24%2014-50%2019a79%2079%200%2000-135%2072q-101-7-163-83a80%2080%200%200024%20106q-17%200-36-10s-3%2062%2064%2079q-19%205-36%201s15%2053%2074%2055q-50%2040-117%2033a224%20224%200%2000346-200q23-16%2040-41%22%2F%3E%3C%2Fsvg%3E"></header><section class="social-embed-text" itemprop="articleBody"><small class="social-embed-reply"><a href="https://twitter.com/edent/status/4529469389">Replying to @edent</a></small><a href="https://twitter.com/edent">@edent</a> Top are: IE7 22%, IE8 20%, IE6 12%, Firefox3.5.3 9%, FF3.5.2 7%, FF3.0.14 5%, FF3.0.13 4%, Safari 4.0.3 4%, Chrome 2.0.172.43 2%</section><hr class="social-embed-hr"><footer class="social-embed-footer"><a href="https://twitter.com/10DowningStreet/status/4549222839"><span aria-label="2 likes" class="social-embed-meta">❤️ 2</span><span aria-label="0 replies" class="social-embed-meta">💬 0</span><span aria-label="0 reposts" class="social-embed-meta">🔁 0</span><time datetime="2009-10-02T09:46:44.000Z" itemprop="datePublished">09:46 - Fri 02 October 2009</time></a></footer></blockquote>

<p>Or, to express it graphically...</p>

<p></p><div style="width: 410px" class="wp-caption aligncenter"><img src="https://shkspr.mobi/blog/wp-content/uploads/2009/10/chart.png" alt="Pie chart of the above statistics." width="400" height="256" class="aligncenter size-full wp-image-47406"><p class="wp-caption-text">Chart Showing Browser Stats</p></div><p></p>

<p>Firefox overall accounts for 25% - a fairly strong showing.  But with IE6 stubbornly stuck at 12%, it will be a while before we can consign it to the dustbin of web history.
Opera is languishing in the 15% marked as "Other" along with my browser of choice, <a href="http://lynx.isc.org/">Lynx</a>.</p>
<img src="https://shkspr.mobi/blog/wp-content/themes/edent-wordpress-theme/info/okgo.php?ID=583&HTTP_REFERER=RSS" alt="" width="1" height="1" loading="eager">]]></content:encoded>
					
					<wfw:commentRss>https://shkspr.mobi/blog/2009/10/browser-statistics-of-10-downing-street/feed/</wfw:commentRss>
			<slash:comments>8</slash:comments>
		
		
			</item>
	</channel>
</rss>
