Stavros' Stuff

On programming and other things.

Thomson/SpeedTouch routers and WPA keys

In case you didn’t know, the default WPA key in Thomson/SpeedTouch routers is generated from the router’s serial. By some strange coincidence, so is the router’s SSID, which means that if you know the SSID (which is public knowledge), you can brute-force the serial.

There are programs to do this already, but they were not future-proof or open enough to work now, so I wrote a small Python script t

Continue reading…

Custom model field validation in Django

These days I am trying my hand at a rewrite of Dead Man’s Switch, to add more features and generally improve the service.

One of these features was being able to add multiple emails in the “recipients” field, and I wanted to do this as cleanly as possible, so I decided to create a Django model with custom validation. This was not immediately obvious, as the docs

Continue reading…

Hard disk/partition migration in OS X and Linux.

Well, I just got an Intel X25-M 160 GB SSD for my laptop (a MacBook), and I wanted to migrate all my partitions (I was triple-booting OS X, Ubuntu Linux and Windows 7) to the new disk.

This turned out to be less than a breeze, since there are a few caveats and the entire process takes time, but I will detail it here and maybe save some of you some time.

**WARNING: Don’t try any of this if you do

Continue reading…

GitHub and open source development

A while ago I stumbled upon GitHub, which calls itself a “social coding” website. Initially, it seemed to me a code repository like all others (Google code, Launchpad, Sourceforge, etc), but using it more and more I came to realize there’s a pretty interesting twist to it.

You see, with the advent of distributed VCSes, people don’t need to work on a central server any more. T

Continue reading…

How to safely run programs under Windows

As you are probably aware, there is a lot of Windows malware that makes your PC load more slowly, have annoying popup windows or even steal your data and files.

Recently, I discovered a fantastic program that can help you get rid of all this. It is Sandboxie. Sandboxie allows you to run programs in a protected area of your computer (a sandbox), so they can’t write a

Continue reading…

Web design/software development

Those of you who have been following this blog know that I like web development, so it was only natural for me to start my own company. Together with a friend, we founded Spoon ltd.

Spoon is a design company that specialises in web/print design and software development. We’re just starting off, so we’re only now getting our first jobs. We’re expecting to h

Continue reading…

ContentTypes and unit testing problems in Django

I’m working on a new Django project at the moment, and it uses the ContentTypes framework to refer to any model in the project. The problem with doing this is that the ContentType objects that are created have random IDs, so if you dump your database objects into a fixture, the ContentType objects those refer to will not be what you initially expected.

After a few days of searching and finding no

Continue reading…

Supported by Ninjas

These past few days I have been working hard setting up a new business venture, and it is almost complete. Without further ado, I present to you…

Ninja Support!

If you need stuff supported, Ninjas can do it. Small servers, big servers, backups, maintenance, setup, you name it, we handle it all. Give us a try, I am su

Continue reading…