DSMLTools 1.2 Released

Hardly earth-shattering, but I’ve released version 1.2 of the DSMLTools, one of my more obscure bits of software, which helps you manipulate directory (LDAP) data as XML. This release fixes the three bugs that have been found since the last release in 2002 and, more significantly, introduces a new make-based build system. The release packages now conform to the Software Release Practice HOWTO.

It’s a measure of how busy I am that 90% of the work for the release was done in April 2004…

HOSTS File Risks

There are several sites on the Internet which offer Windows HOSTS files for download, together with installation instructions. The HOSTS file is part of the DNS configuration; the ones offered for download divert any requests to a long list of ad and spyware servers into a black hole, meaning that your browser can never contact those machines.

This is all fine in theory, but how long would it take someone to notice if one of those popular files (and some of them are very large) had the following lines buried somewhere in the middle, either deliberately or because the site had been hacked?

87.65.43.21 www.paypal.com
87.65.43.21 www.bankofamerica.com
87.65.43.21 www.ebay.com
...

Phish City. I suggest that, however much you may not like advertising, encouraging people to download and install HOSTS files from the net is rather irresponsible.

Mapping Innovation

Shock – some innovation in mapping which doesn’t come from Google! Head over to this aerial photo of Westminster Abbey and mouse over it. This trick appears to be the dynamic updating of the CSS clip property, so it’ll work in most modern browsers.

By the way, I’m singing Evensong there today at 3pm with the Friends of Morland Choristers Camp if anyone wants to stop by. The anthem is “Greater Love” by Ireland, and the Magnificat and Nunc Dimittis are Bairstow in D.

Freedom Is Important

This is why software Freedom is important, and why the “use the best tool, whether it’s open source or not” attitude gets you in trouble in the long run.

We need to be prepared to use inferior but Free applications and, scratching itches, make them better. And we need to gently persuade other community members to do the same. The Open Source movement has reduced the talk about software freedom and we need to value and promote it again before we get taught more nasty lessons like this one.

Update: Random example of what I mean:

I know that binary-only drivers are a sore spot with free software purists, but I’d rather have a fully functional, if closed, Nvidia driver than a reverse-engineered one that limps along.

With a basic level of driver stability, Linux could become as easy as Windows to support.
— The State of Laptop Linux 2005

Security Writings Summary

I’ve created an index page to my writings on security, having written up and added a few things that initially started life as blog posts and are now much improved by your kind input :-) It includes stuff on Phishing and Cross-Site Scripting. More to come as I find time to write it; feel free to comment here or by email.

Keeping Email Addresses From The Spambots

Here’s an interesting approach to the problem of making your email address easily available to people but not spambots – hide the page with the mailto: link behind a form POST. See comment #2 in that discussion for the most slick method – return the mailto: link as the location in the response headers. For extra points, you could disguise the submit button to look like a URL…

My personal attitude is that spam is a price you have to pay for being contactable. You’ll find my email addresses, unobfuscated, all over the web.

Oh, and I’ve updated the newsgroups list. Please have another look and see if the changes are to your liking.

Dodgy Network Simulator

Does anyone know of gateway or proxy software you can install on a machine to simulate a bad network – i.e. it routes packets from one interface to another but drops, delays or rearranges them in a configurable way at the same time? I know Squid can do bandwidth limiting, but ideally I need the other things too.

Unsurprisingly, it’s for testing a product over a dodgy network connection.

Cross-Site Scripting – The Final Solution

This is the last of my ideas for prevention of Cross-Site Scripting, and in a way the most radical. I was having a shower this morning, when I was struck by a great idea. What if the entire Internet was under the same domain? This radical move would prevent Cross-Site Scripting at a stroke! We could change the DNS servers of the world to only resolve a single domain, and move all other websites under it. There’s be no way to do cross-site anything at all.

So, which company or group is worthy of the honour and responsibility of watching over such a valuable community resource? Much as I’d like to suggest mozilla.org, I’m not sure we have the bandwidth. So, having seen the good job they’ve done with newsgroups, I think it’s time that we recognised that inevitability of GWorld Domination and handed over control of the entire Internet to Google, Inc. Instead of “The Internet”, we’d have “G-Internet” (catchy, huh?). It would give all websites a new subdomain of the main google.com domain – for example, www.gerv.net.g-internet.google.com. No more Cross-Site Scripting!

Putting the entire Internet under Google’s control has a number of great side benefits. For a start, it would be a lot easier to search – Google having the master copy of the web would help them to spider it much more quickly, and keep their index up to date. Then, of course, all web apps would be automatically upgraded by Google’s New Service Gnomes to use XmlHttpRequest and other modern web application technology. I can certainly see a lot of people appreciating Hotmail getting such a makeover.

But lastly and most importantly, it would be a great help in the War on Terror. (This is a clinching argument because no-one can object because they’ll get accused of being soft on terrorists, and therefore it requires no justification.) I, for one, look forward to this brave new world! Viva G-Internet!

FreeDownloadZone.com Are Scuzzballs

Jed: “Hey, I know a great business model! Let’s profit from the hard work of others by selling what they are giving away for free!”

Ted: “Er, Jed, isn’t making money from people’s ignorance a bit unethical?”

Jed: “Unwhat, sorry?”

Ted: “Unethical.”

Jed: <looks concerned> “Ted, are you feeling OK?”

Ted: <shakes head> “Sorry, don’t know what came over me there. Let’s sign up for Google ads for the ‘firefox‘ keyword. That’ll be sure to bring the suckers in…”

Link Fingerprints

I’ve noticed that some organisations, particularly Microsoft, have been releasing security updates where the download URL contains some form of checksum for the file. Here’s an example, which is the download for this security vulnerability in Windows 2000.

The page doesn’t explain which algorithm they use to generate the hash. It’s a 128-bit value, but it’s not straight MD5 (wrong values), or SHA1 (wrong length). It also doesn’t say why it’s there, or give you any way to use that information to verify the download, so I assume it’s designed for automated tools like Windows Update or similar. If anyone has more info, please comment. [Update: apparently, it’s just a GUID – basically a random number. So all the stuff below is my invention rather than being copied from anyone else.]

This is a great idea in principle, because it means that no-one can break into the server and trojan the file – if they do, then the checksum doesn’t match any more. And if they change the name of the directory it’s in to match the new checksum, all the published links break and users still don’t get the trojaned file. But it’s no use if the checksum isn’t checked.

So I started thinking. It must be fairly common that users download files where they are given the URL by a trusted source – or, at least, get it from another location or server which would also have to be compromised.

So what’s to stop any user agent verifying a downloaded file against its path-based checksum, or ‘Link Fingerprint’? It would work like this: if the user agent downloaded a file whose URL had a path component matching a particular pattern (perhaps /md5[0-9a-zA-Z]{16}/), the user agent would checksum the file, compare it to the URL, and put up a nasty scary “don’t trust this file” warning if they were different. I’m assuming it’s fairly unlikely that many files will have paths like that where the relevant path component isn’t an md5sum.

Yes, files may be digitally signed with the distributing company’s key, as most Linux distributions do with their RPMs, but verifying that often involves a lot of PKI hassle which is currently out of the reach of many users. The idea of this would be a simple way for a software distributor to reduce the likelihood of their download being successfully trojaned, with no need for the user to be made to perform verification steps.

There are implementation details, of course – you’d need to watch out for redirects, for a start – but is the basic idea useful, or are there too many potential problems with it? Or perhaps it’s solving an issue that isn’t a problem in practice?

Simple Curvy Corners

Rounded corners are the bane of a website designer’s life. I can take them or leave them; for some reason, graphic designers seem to swoon at the slightest hint of revealed shoulder. And, while Mozilla has a CSS extension which does them, and CSS 3 standardises it, if you want them cross-browser then you used to be stuck with tables, or wrapping your divs in up to three others and using background images.

However, another alternative is script. If your site already requires JS, then you can now have lovely rounded corners in all modern browsers using a simple script and CSS include without the need for extra markup.

IDN Update

I was asked yesterday about the current status of the work on IDN homograph spoofing. Here’s what’s being done.

  1. The Unicode Consortium are writing a Technical Report (TR) called “Security Considerations in the Implementation of Unicode and Related Technology”, which includes a section on the homograph problem. This report is currently under active development. It includes the start of a very useful list of ASCII confusables, which should be useful to the registries in point 3).
  2. A working group of the IAB, which is part of the IETF, is looking at revisions to stringprep and nameprep, two of the standards underlying IDN. These standards define what characters are permitted, string canonicalisation and so on. We hope to be able to reduce the number of permitted characters without affecting legitimate usage, thereby reducing the scope for spoofing.
  3. Registries which are issuing IDN domains are being asked to put in place appropriate policies to prevent two homographic domains being registered to different entities. Such a policy would probably involve a permitted character table (a subset of the characters defined by 1) and a method of dealing with homographic domains using characters within that table, such as aggregation or blocking.
  4. Browser manufacturers are putting in place temporary measures (mozilla.org, Opera, Apple) to protect users while a long-term strategy is devised. The core of that strategy is likely to be based around a black or whitelist of TLDs, allowing IDN to be rolled out for each registry once they have appropriate policies in place (see point 3). We hope to achieve consensus on which registries have such policies, and eventually to have a neutral body keep the list.

As you can see, this is a hard problem to solve, and work at every level is necessary. However, I hope that once all of it is completed, we will be able to achieve the goal of making legal IDN domains first-class citizens on the Internet, deployable and usable with only the same risks as ASCII domains.

Visual Basic 6

Another example of people getting stuffed by proprietary lockin: Visual Basic 6 developers are petitioning Microsoft not to end support.

I can’t imagine, though, why anyone would choose to program in VB if they’d had experience of any other programming language. The last three days I’ve been programming in VB 6, and it has caused me more stress recently than I’ve had in months. One particularly irritating thing is that it’s impossible to get good online VB 6 documentation any more, because Microsoft has replaced it all with VB.NET docs, and forgotten the very existence of VB 6. Oceania has always been at war with Eastasia.

IP over VoIP, Anyone?

Having seen someone actually using IP-over-DNS in a pub in the centre of Brussels at FOSDEM, could the next move be IP over VoIP?

UK Wi-Fi hotspot users are being offered free Skype calls. “Broadreach hopes that after making free Voice over Wi-Fi calls consumers will be more likely to pay to check their email or surf the web at its hot spots.”

QuickText Extension

This is an update on my search for a Thunderbird extension to help me deal with large volumes of email, most of which requires the same response because people don’t read FAQs.

For the past few weeks, I’ve been happily using Emil Hesslow’s QuickText extension, which does exactly what I need. Many thanks and kudos to Emil. I’d recommend QuickText to anyone else who finds themselves repeating the same things in email after email.