I just realised that simply using Prey would probably put you within some walkable distance of your stolen/lost laptop, but if the place was say a shopping centre, then you would be screwed. Then I remembered this xkcd comic, and decided to do something similar.

SSH into the system using the IP address generated by Prey. Raise the volume to maximum.

[damascus:~] sudo osascript -e “set Volume 10″

And then play some music file.

[damascus:~] afplay ~/Desktop/Symphony_IX_IV.mp3

Hopefully, the music should be loud enough for you to locate the laptop, even if through people’s reaction to a sudden loud orchestra amongst them.

But if you are not satisfied with this, then just use the say to speech synthesise words from the command line after you have raised the volume.

[damascus:~] say “This laptop is stolen! Help! Call the Cops!”

Sometime ago, a friend of mine lost his laptop in a taxi and never saw it again. And today, Humpy showed me this video, and I decided time had come to do something about my laptop and my iPhone.

The iPhone was easy, ever since tracking your iPhone came free with the iOS 4.2 through the Mobile Me subscription. I set up a Mobile Me account on my iPhone, and then simply went to MobileMe and then checked the map for my phone.

I highly approve of the fact that I can send a message, lock and even wipe my phone in case its stolen or lost, but one thing I would have loved, would have been to get a picture of the person holding it. But this is a good start. Onto securing my laptop. I initially thought a daemon running in the background would be enough. And I even wrote a small one :

#!/bin/bash
PING=/sbin/ping
CURL=/opt/local/bin/curl
MAIL=/usr/bin/mail

output=`${PING} -t1 google.com`

connected=`echo $output | grep ‘unable’`
curr_date=`date`
email_address=”ipaddress.of.mujtaba.laptop@gmail.com”

if [ "x$connected" = "x" ]; then
ip=`${CURL} -s http://checkip.dyndns.org | sed ‘s/[a-zA-Z/<> :]//g’`
echo “Your IP = $ip” | mail -s “IP on $curr_date” $email_address
fi

And then I realised I am probably not the first person to have thought of securing my laptop and a quick google search proved that. A post on teknobites caught my attention and I was directed onto Prey. Installation was easy and setting up the daemon happened quickly. I went to the panel, logged in and marked my laptop as missing, set report duration and waited patiently.

Lo and Behold :) there was my laptop.

And what the scallywag was doing, and what he was logged in as :

And the best thing, it even takes the picture of the scallywag. :)

Me likey!

Hats off to guys at Prey.