Terence Eden. He has a beard and is smiling.

Terence Eden’s Blog

Theme Switcher:

What the UK Government gets wrong about QR codes

· 12 comments · 700 words · Viewed ~962 times


A leaflet for Childcare with a prominent QR code.

One of my most memorable experiences in the Civil Service was discussing link shortening services with a very friendly person from the Foreign and Commonwealth Office. I was trying to explain why link shortners like bit.ly and ow.ly weren't sensible for Government use. They didn't seem to particularly care about the privacy implications or the risk of phishing. I needed to take a different…

I made a mistake in verifying HTTP Message Signatures

· 5 comments · 400 words · Viewed ~203 times


A pet cat typing on a computer keyboard.

It's never great to find out you're wrong, but that's how learning and personal growth happens. HTTP Message Signatures are hard. There are lots of complex parts and getting any aspect wrong means certain death. In a previous post, I wrote A simple(ish) guide to verifying HTTP Message Signatures in PHP. It turns out that it was too simple. And far too trusting. An HTTP Message Signature is a…

O2 UK's Weird MSISDN Lookup API

· 7 comments · 250 words · Viewed ~269 times


Sorry, we don’t recognise this number. Please try again.

It's always fun keeping your network inspector tab open. While looking around the O2 UK website, I found this page all about eSIMs. For some reason, it wants to know the user's phone number. I put in a random number, and it refused to let me in. Putting in a genuine O2 number let me through. So what is it doing to validate numbers? It is making an API call to this URl: …

A simple(ish) guide to verifying HTTP Message Signatures in PHP

· 2 comments · 1,200 words · Viewed ~414 times


Screenshot of JSON. As described in text.

Mastodon makes heavy use of HTTP Message Signatures. They're a newish almost-standard which allows a server to verify that a request made to it came from the person who sent it. This is a quick example to show how to verify these signatures using PHP. I don't claim that it covers every use-case, and it is no-doubt missing some weird edge cases. But it successfully verifies messages sent by…

It's a process; not a product

· 3 comments · 400 words · Viewed ~623 times


A pet cat typing on a computer keyboard.

Sometimes a client asks me a question and I'm a little stunned by their mental model of the world. A few weeks ago, we were discussing the need for better cybersecurity in their architecture. We spoke about several aspects of security, then they asked an outstanding question. "What should I buy to be secure?" It took a few moments to tease out exactly what they thought they were asking. In…

A quick look inside the HSTS file

· 3 comments · 450 words · Viewed ~959 times


Glowing computer text showing dot com dot info etc.

You type in to your browser's address bar example.com and it automatically redirects you to the https:// version. How does your browser know that it needed to request the more secure version of a website? The answer is... A big list. The HTTP Strict Transport Security (HSTS) list is a list of domain names which have told Google that they always want their website served over https. If the user …

An open(ish) redirect on Mastodon

· 1 comment · 950 words · Viewed ~268 times


Cartoon of a tusked mastodon holding a phone.

I've responsibly disclosed a small security issue with Mastodon (GHSA-8982-p7pm-7mqw). It allows a sufficiently determined attacker to use any Mastodon instance to redirect unwary users to a malicious site. What do you think happens if you visit: https://mastodon.social/@PasswordReset/111285045683598517/admin? If you aren't logged in to that instance, it will redirect you to a 3rd party site.…

Using disposable phone numbers for better security

· 8 comments · 500 words · Viewed ~2,175 times


A pair of SIM cards.

Last night I received a call from my bank. They'd detected an unusual transaction and wanted to make sure that it was legitimate. Had I recently purchased £10,000 worth of crypto in the Maldives? What?!!? No! ARGH! I started to panic. All my apes money gone! No. Wait. The other thing. I knew it was a scam from the moment "James from your bank's fraud team" started his patter. You see, I have …

Please don't give away your Twitter API keys to Cloudinary

· 2 comments · 700 words · Viewed ~242 times


Hi Terence, We don't have a way for customers to configure this on their own currently. Our team will handle the configurations for you. Here are the details needed for us to do the required changes: API Key and Secret. Access Token and Secret.Best Regards

My CDN just asked me for all my Twitter API keys... WTF? This would give them complete access to my app's Twitter account, the ability to send and receive messages, and anything else that my API key allows. Giving them - or anyone - the entire set of credentials would be a very bad idea. What's going on? Twitter's slow-motion collapse and hostility to developers is causing a whole bunch of…

An eInk, Wrist-Mounted, TOTP Generator

· 4 comments · 500 words · Viewed ~3,317 times


A chunky wristwatch showing the time and a selection of 6 digit codes and their corresponding entities.

Behold! Thanks to the power of the Watchy development platform, I now have all my 2FA codes available at the flick of my wrist! HOWTO This uses Luca Dentella's TOTP-Arduino library. You will need a pre-shared secret which is then converted into a Hex array. Use the OTP Tool for Arduino TOTP Library to get the Hex array, Base32 Encoded Key, and a QR Code to scan into your normal TOTP…

On the usability of number pads

· 3 comments · 450 words · Viewed ~773 times


Computer number pad with the number 7 in the top left.

I'm not thick. I know it doesn't sound like much of a boast, but I'm pretty competent at this whole adulting lark. But it appeared that I had forgotten a 4 digit number I'd set up less than a minute ago! The security guard smiled wearily at me, "It happens to everyone!" She said. Which, I'll admit was of small comfort. Work had taken the (sensible) decision that our entry cards weren't secure…

The limits of General Purpose Computation

· 9 comments · 600 words · Viewed ~1,335 times


A pet cat typing on a computer keyboard.

Should my bank be able to block me from using their Android app, just because my phone is rooted? I'm reluctantly coming to the conclusion that... yeah, it's fair that they get to decide their own risk tolerance. Sage of the Internet, and general Sooth Sayer, Cory Doctorow once gave an impassioned speech on "The Coming War on General Computation". I'll let you read the whole thing but, I…