IMPORTANT NOTIFICATION

This site is an archive of Simon's first blog.
Current writing and commentary is now published at
simonedwards.com.
Showing posts with label personal privacy. Show all posts
Showing posts with label personal privacy. Show all posts

Friday, 2 August 2013

Choosing a secure PIN

Credit, debit and ATM cards are usually protected by a four-digit number.

This Personal Identification Number (PIN) is supposed to prevent an unauthorised person from using the card.

Choosing a good PIN makes a great deal of sense. Here's how to pick a good one, or at least how to avoid a bad one.

It seems that good sense is lacking with many people, who use predictable PINs such as 1234, 1111 and 0000.

How do we know this? Nick Berry, from DataGenetics, analysed passwords that had been leaked onto the internet. He concentrated on the four-digit passwords, working on the fair assumption that if people are using four-digit passwords for internet services then there will be some correlation between their choices and the numbers people choose for bank cards and other systems that use four-digit PINs.

He discovered that, out of 3.4 million records, the three sequences above were by far the most common. They were almost certainly chosen with intent, rather than being generated randomly.

The top 20 PINs accounted for 26.83 per cent of all passwords in the database, which means that a bad guy would only need to try 20 codes to achieve success in one quarter of sessions.

Within the top 20 you will find all repeated sequences of a single number: 0000, 1111, 2222, 3333, 4444, 5555, 6666, 7777, 8888, 9999.

So in other words, if you want to guess someone's PIN try each of the above sequences in turn and you stand a very good chance of success.

The least popular choice was 8068. So we should all start using that one, right? Definitely not. As Nick writes:
Warning - Now that we’ve learned that, historically, 8068 is (was?) the least commonly used password 4-digit PIN, please don’t go out and change yours to this! Hackers can read too! They will also be promoting 8068 up their attempt trees in order to catch people who read this (or similar) articles.
The key to a secure PIN is to choose one that is not predictable. So maybe looking at the most- and least-used ones published in such articles is a good idea so that they can be avoided. You want your PIN to be lost in the middle ground.

One quite amusing part of Nick's research is that the number 2580 crops up fairly high on the list, at #22 Look at your telephone key pad to discover why this is a popular choice.

I know of at least one PIN-protected door to which no-one who uses it can tell you the PIN. They have all memorised the combination using a visual pattern (e.g. top left, bottom-right, middle-right, middle-left) rather than by the numbers (1964).

Tuesday, 23 July 2013

Smartphone security

In 1999 a PC this powerful
would cost twice as much and
be 100 times bigger
At the moment we are, in terms of mobile malware development, in 1998.

Remember when we all used Windows 95 and connected with modems? The threats of the day were Trojans that would dial premium numbers to generate/steal money from victims.

As far as I can tell, that’s where we are today with smartphones.

Modern, powerful mobile handsets are essentially PCs with a modem, run by users who access banks and other financially-connected sites. I've yet to see any evidence of iOS or Android-compatible drive-by attacks so right now social engineering seems to be the most significant threat.

As such, a slight variation on the advice we used to give in the late 1990s is probably suitable:

  1. Keep your phone’s firmware up to date (updates from vendor, via Android Settings).
  2. Keep your software up to date (via Google Play updates). These updates can be set to run automatically.
  3. Only install from official stores such as Google Play. Don’t side-load (i.e. install from removable media).
  4. Ensure the software comes from the original developer. Google Play lists the developer and highlights very popular ones with the ‘Top Developer’ label.
  5. Check the reviews of each application you want.
  6. Check the permissions that each application requires and reject it if it wants too much (in your opinion).
  7. When updating manually, review any new permissions the updated application requires.
  8. Avoid pirated/cracked software, whatever the source.
  9. Install an anti-malware product. After all, even the official stores have been found to host malicious files.

While all this will help, I doubt that normal people will neither bother nor be able to fully understand or remember the details. That's not their fault, though. It's the fault of the mobile industry. It should be easier to be more secure.

This article updates last year's notes on Android security tips.

Thursday, 14 March 2013

Secure your home network for £10

This wireless broadband router cost
less than a tenner
If you want to share your internet connection safely, separating guests' computers from your own, here's a very simple and cheap way to do it.

Essentially it involves adding a second router to your existing network and using that to create two networks - a guest zone and a private zone. Both provide wired and wireless internet connections, but guests are unable to connect to the private PCs, tablets or whatever.

I've found it increasingly common for friends and visiting family to ask to use my wireless broadband - as if it's an essential resource such as running water or access to a toilet.

While wanting to accommodate their needs, I don't want to expose my home network to the security issues that come when allowing connections from other people's systems.

These computers could be infected with malware, which in turn could capture network traffic, attempt to spread malware to other systems on the network and so on.

One answer is to create a second, secure network that only you will use. Everyone else will be restricted to a 'guest' network that is locked away from your own systems but that provides wired and wireless internet access.

Here's how you can do this for around £10.

Essentially what we're going to do is create a classic DMZ using two firewalls. Each firewall will also have its own wireless network. Those systems connecting to the 'outer' firewall can only see each other and the internet. Those connecting to the 'inner' firewall are invisible to those on the outer one.

Thus we have a guest network running on the outer firewall and an extra-secure network running on the inner one. For a basic diagram that 'explains' this idea, see far below.

In addition to your existing network you will need:

1. A wireless broadband router.
2. An Ethernet cable.

I recently picked up a new Dynamode broadband cable router for less than £9 from Amazon.co.uk.

Ensure that your new router is *not* an ADSL model. You want the internet (WAN) port to be an RJ45 Ethernet socket and not the RJ11 type that you find on ADSL modems and routers.

Before you start, check the following details from your existing systems and router:

1. What is the router's (gateway) IP address? (e.g. 192.168.1.1)
2. What is the netmask? (e.g. 255.255.255.0)
3. What are the DNS settings? (e.g. 8.8.8.8 and 8.8.4.4)
4. If you use DHCP, what is the range of addresses in the pool? (e.g. 192.168.1.2 - 254)

Decide what IP address you want to allocate to your second, private network. Let's say we'll use 192.168.1.200. You should remove this address from the DHCP pool or face potential (but unlikely) problems later.

Allow your existing broadband router (cable or ADSL) to run as usual, leaving the wireless network active. However, unplug all computers, switches and other devices from the router. We'll call this router the 'original' router.

Turn on the 'new' router and connect its WAN port to any one of the available Ethernet ports on the original router. Plug a computer into the new router using an Ethernet cable and configure it, turning on and securing the wireless network. You'll want to check the following, at least:

1. Check the router's LAN IP address. It should be in a different range to that of your original router.

(e.g. if your original router's IP address is 192.168.1.1 you could set your new router to use 192.168.0.1. Then your secure network will use the 192.168.0.x range, while your guest network will use the 192.168.1.x range. It's important that they use different ranges to each other.)

2. Change the default password. Use a strong password.

3. Disable remote management, if enabled by default. This is optional but recommended.

4. Set the WAN IP address to be 'static' and use the value you excluded from the DHCP pool earlier (e.g. 192.168.1.200).

5. Set the ISP address to match your original router's IP address (e.g. 192.168.1.1).

6. Set the DNS settings either to the IP address of the original router (e.g. 192.168.1.1) or just re-use the ones you discovered above (e.g. 8.8.8.8 and 8.8.4.4).

7. Enable the wireless network and use a strong password. Ensure that the SSID is different to the one you are using on the guest network.

8. Check that the firewall is enabled.

Additionally you'll probably want to enable DHCP on your new router.

You should now have something that, conceptually at least, looks like this (yes, the internet looks like a small cloud with an 'i' on it):

The guest network is above the red line. Its systems cannot
connect to anything in the 'private' zone beneath the red line.
What that basic diagram is trying to show is that the guest systems can access the internet freely but cannot connect to the systems in the private network, which is below the red line. Systems on the private network can connect to anything that they like.

If you really want to treat your guests you could provide a networked printer. This would have to go onto the guest network. Your private systems would still be able to use it, though.

In this example we've protected an internet-connected Personal Video Recorder (PVR) on the private network. It's only a matter of time before these types of devices are targeted by attackers. And I for one could not tolerate my telly viewing being interrupted.

Thursday, 31 January 2013

Howto: Secure Java in three easy steps

Java has had a poor security reputation for some years now but January 2013 saw spectacular failures. Despite numerous fixes internet threats continue to break into victims' computers using security holes in Java.

If you uninstall Java you will be significantly safer than if you don't, but is that really the answer? After all, you may need to use Java to run some important piece of software. Or Minecraft.

The Java attacks that everyone is talking about are varied but occur when the victim browses an infected website. You can increase your computer's security massively by disabling Java in the browser, rather than throwing the baby out with the bathwater and ditching Java entirely.

Here's how you do it.

1. Open the Windows Control Panel and select the Java section.
2. Click on the Security tab.
3. Untick the option called 'Enable Java content in the browser' and click OK.

3. Untick the option called 'Enable Java content in the browser'
These instructions won't work if you are using a version of Java earlier than Java 7 Update 10. You should always update Java as a matter of course so, if you don't have the option listed in step three above, update and then try again.

Monday, 21 January 2013

Howto: Bullet-proof your email account

Usernames and passwords can be guessed or stolen. You can add additional layers of security that significantly reduce the chances of an attacker accessing your account.

First of all, always use encrypted connections when using your email service. If you don't know about HTTPS/SSL, please read Howto: Handle a hacked email account first.

Popular web-based email services, such as Gmail and Yahoo! Mail, secure accounts using a username and password. Some, including both Gmail and Yahoo! Mail, allow you to use an additional security measure called two-factor authentication (aka two-step verification).

Two-factor authentication

Using two-factor authentication is easier than the system's name suggests.

You may already have used two-factor authentication if you bank online with certain banks. Essentially you log in with your username and password, but must then type in a code that changes on a regular basis.

Every time you or someone else tries to access your account from a new system (PC, Mac, phone, tablet etc.), a code is required. You may also have to re-enter a code after a period of time.

A bank may require a code every time you log in. Google Mail will ask you once every 30 days.

The code may be generated by a small handheld device; by software installed on a smartphone; or it may even be sent by text (SMS) message to your phone.

Google provides a free Android app called Google Authenticator, which generates the code. Alternatively you can use one of the other options provided by Google, such as text messaging or even a voice call.

Other services

Some other web services allow users to add this optional secondary level of security. Following an embarrassing compromise, which potentially exposed users' files, Dropbox offered a two-step verification option to users.

Dealing with an extra log-in step once every few weeks is only slightly inconvenient and the level of additional security makes it well worthwhile.

Delhi scammers bypass two-factor authentication

Although using two-factor authentication is much more secure than relying only on passwords, it is possible for sneaky people to trick their way into obtaining the code.

A pair of Indian criminals were caught recently, having conned a mobile phone company into sending them 'replacement' SIM cards belonging to customers.

They were then able to log into victims' bank accounts, using the SIMs to receive security codes sent by SMS.

Saturday, 19 January 2013

Howto: Handle a hacked email account

If your friends complain that you have sent them spam, your email account has probably been compromised.

First I'll explain what has happened, then what hasn't and, finally, what you should do about it.

What has happened?

Someone has obtained the password to your web-based email account. They have logged in and sent spam, quite possibly in the form of links to dubious or even dangerous websites, to contacts you have saved in your online address book.

Your password may have been stolen when you logged into your email account, possibly because you used a public wireless service at some stage. If so you almost certainly were not logged in using an encrypted connection.

An alternative way in which an attacker can acquire your email password is to send you a fake email that purports to come from your email service (e.g. Yahoo!). Such 'phishing' emails ask that you log into a fake website. When you type in your password it saves it and the person operating the site now has your details.

Sometimes an email service will be hacked and user's passwords stolen. This happened to Yahoo! last summer. In Yahoo!'s case the passwords appear to have been stored unencrypted, which is surprisingly unprofessional if true.

What has not happened?

The attacker has not just written emails and labelled them with your email address. While such 'spoofing' is possible, the fact that the spam was sent to your contacts indicates that the attacker has accessed your account.

There is no reason to assume that a hacker or a virus has compromised your personal computer. You can discover if the email was sent by your computer or someone else's by comparing email messages you sent yourself to the spam messages received by your contacts.

To find out how to do this, see Who sent the email? below.

What can you to to fix the problem?

1. Log into your email service and enable encrypted connections if available. The setting may be labelled HTTPS or SSL. Yahoo! Mail only offered this option in January this year, and it's not on by default. This article shows how to secure a Yahoo! Mail account.

2. Once you have addressed step one, and not before, change your password to something new and not obvious. For password tips, and a reason not to re-use the same one on different sites, see here.

(If you change your password before enabling encryption your new password will travel over the internet in plain text, which increases the chance that it could be stolen.)

3. Some email accounts let you specify an associated email account. If you lock yourself out of your main email service access may be granted via this secondary account. Check that the attacker has not changed this address to one that he controls.

4. Continue to be aware of phishing email threats and avoid falling for their tricks.

5. Be wary of using public WiFi just as a general rule.

6. To guard against having your details stolen or leaked change your passwords regularly.

Who sent the email?

All email messages contain technical details about the systems that they touch, from their origin to their destination. Look at the 'headers' to see who really sent the message.

In the following example message #1 was sent by the spammer, while message #2 was sent legitimately by the victim. I've trimmed out a lot of unnecessary headers below. Look at the underlined parts. I have changed some details to protect the innocent.

MESSAGE #1
Delivered-To: simon@h@k.me
...
Received: from [77.255.73.226] by web162906.mail.bf1.yahoo.com via HTTP; Mon, 14 Jan 2013 04:15:46 PST


MESSAGE #2
Delivered-To: simon@h@k.me
...
Received: from [64.40.54.xxx] by web162904.mail.bf1.yahoo.com via HTTP; Mon, 14 Jan 2013 10:44:51 PST

What these tell us is that both the attacker and the victim used Yahoo! Mail using the web (HTTP) interface.

We can also see that the spammer was operating from an IP address of 77.255.73.226, while the victim was using 64.40.54.xxx.

Using an online tool like http://whois.domaintools.com we can find out where these people are based.

At the time of the attack the spammer was based in Warsaw. The tool reports the following (and more):

IP Information for 77.255.73.226
IP Location: Poland Warsaw Netia Sa
ASN: AS12741
Resolve Host: 77-255-73-226.adsl.inetia.pl
IP Address: 77.255.73.226

The victim's IP address, on the other hand, leads us to believe (correctly) that he was working from Seattle.

Thus we can conclude that the spammer was accessing the compromised email account using a web interface from Poland, rather than via the victim's PC in Seattle.

Sunday, 6 January 2013

Film scanner bundled with botnet

German coffee chain Tchibo has admitted to selling a film slide scanner that is infected with malware.

The company, which carries a range of gadgets alongside hot drinks, distributed a Hama scanner, the drivers for which were infected with the Conficker worm.


The is not the first time that consumer electronics have been accompanied by malicious code:

18/03/2010 Energizer Trojan keeps going

Sunday, 30 December 2012

Security advice can expire

Mark Russinovich has drawn my attention to some security advice just published on USA Today. It seems a little dated and is probably more appropriate for someone operating a PC in 1999, not 2013.

There are five sections, the third (security-related) one being related to, "3. The zombie spyware plague".

This makes reference to fake anti-virus malware, which is certainly a current threat, although less so than a couple of years ago.

The solution?
"... running a real antivirus program probably won't help. To stop the pop-ups, you must run an anti-spyware program. There are a number of good ones — I'd start with Ad-Aware."
I'd be interested to see why author Kim Komando thinks that "real antivirus" software can't remove malware, while Ad-Aware can. Especially as Ad-Aware is a real anti-virus product.

It didn't used to be, though. Back in the late 1990s Ad-Aware was labelled as an anti-spyware tool. It was much more limited than fully-featured anti-malware suites. That said, it was often better than regular anti-virus software when handling certain types of threats, such as information-stealing malware like modem diallers.

It is now described by its developer Lavasoft as, "super fast anti-virus combined with our legendary anti-spyware".

The distinction between anti-virus and anti-spyware no longer exists, and has not done so for years.

Anti-malware vendors cannot afford to ignore certain specific types of internet threat, such as Trojans, diallers and so on. They use the umbrella term "anti-virus" just to keep things simple for normal users.

Ad-Aware looks like an effective anti-malware (anti-virus) tool. It's certainly scored well in AV-Test and Virus Bulletin tests in the past.

Registry backups

The initial section, which includes advice on using a tool to clean the Registry, contains the advice of:
"Just make sure you allow it to backup the registry before making changes."
It's a small point but I'd probably want to back up the Registry manually, rather than rely on the tool that could cause the corruption in the first place.

How do you do that on a PC running any version of Windows later than Windows 98?

The author does not tell you how, but the answer is usually to use System Restore. The Windows Backup tool does not make a copy of the Registry, so don't rely on that.

For more information on backing up the entire Registry for your version of Windows, use the following links:
Windows XP
Windows 7
Windows 8 (it appears to be the same as for Windows 7, above)

This Wikipedia entry examines some further Registry backup options.

Thursday, 27 December 2012

Store web passwords safely

Too many complex passwords to remember? Make your New Year's resolution to write them all down somewhere safe. Here's a tip to automate the process.

If you use Google Chrome to browse the web you may well have lots of user names and passwords already saved in the Saved passwords list.

You could go through this and manually write down each set of URL, user name and password, or you can run a handy utility that dumps the entire list to a text file.

ChromePass is a great little application that you can run without installing it. It will enumerate all of the security details saved in Chrome and display them.

It can export selected entries (Ctl-A to select all) to a text file and can even rip out passwords from non-bootable disks.

Print the exported list and then delete the file securely (using Eraser or some similar file wiping utility), possibly encrypting it first if you want a safe digital copy.


Of course, such password recovery tools may be abused, which is possibly why Chrome claims that ChromePass is malicious (see below).


Cheerful thought for 2013: Having a physical archive of your passwords could be useful for your next of kin, after you die.

Thursday, 20 December 2012

Popular disk encryption systems cracked

If you want your laptop's data to remain secure, even when stolen, one excellent solution is to encrypt the hard disk's partitions or even the whole disk.

Popular options include Microsoft's BitLocker, Symantec's PGP Whole Disk Encryption and the open source TrueCrypt software.

Elcomsoft has just announced that all of these encryption systems can be cracked by its new product, Elcomsoft Forensic Disk Decryptor.

Elcomsoft Forensic Disk Decryptor
That news sounds frightening for those who use the above products to secure their data.

For those who work in digital forensics, however, the arrival of this tool will be welcome.

Until now data protected by these products was essentially unrecoverable without a suspect's cooperation.

It is important to note that the decrypting software will only be able to access the data under the following conditions:
  1. The target PC is running and...
  2. ...the attacker/investigator is able to obtain a memory dump.
Actually, there is an exception. If the computer was powered off, but had been put into hibernation mode while the encrypted disks/partitions were mounted, the investigator can also recover the necessary encryption keys.

Elcomsoft's blog post reminds us that it is possible to take a memory dump via a Firewire port.

There is a brute-forcing option available via the company's distributed processor cracking system (think SETI@home for password breaking).

If you use these encryption tools the safe option is to either shut down your computer completely, when leaving it unattended, or to unmount encrypted volumes before putting the computer into hibernation mode.

Thursday, 27 September 2012

GnuPG cheat sheet

The PGP and GnuPG encryption programs are excellent but not all that intuitive. I use GPG a lot, on both Windows and Linux command lines, and I still have to refer to the documentation from time to time.

Here is a cheat sheet of commands I use frequently.

GPG QUICK REFERENCE

  1. Encrypting
  2. Decrypting
  3. Importing keys
  4. Exporting keys
  5. Listing keys

1. Encrypting

a) Encrypt with a password:

gpg -c -o file.txt.gpg file.txt

[use conventional encryption;
output to file.txt.gpg;
encrypt file.txt]

b) Encrypt multiple files with the same password (Linux):

Create a bash script containing at least the following.
#batch-encrypt.sh
for a
do
echo "Encrypting $a..."
echo password123 | gpg --batch -q -c --passphrase-fd 0 --cipher-algo AES256 $a
done
$ ./batch-encrypt.sh files/*

The above command will encrypt all files in the 'files' directory, using conventional encryption with the password of password123

c) Encrypt using a public key:

gpg -e -r simon file.txt

[encrypt to a recipient called simon;
encrypt file.txt]

d) Encrypt using multiple public keys:

gpg -e -r simon -r john file.txt

[encrypt to recipients simon and john;
encrypt file.txt]

e) Encrypt multiple files with one or more public keys:

gpg --encrypt-files -r simon -r john *.txt

[encrypt multiple files;
encrypt to recipients simon and john;
encrypt all files in the current directory with the file extension .txt]

2. Decrypting

a) Decrypt with a password:

gpg -d file.txt.gpg

[decrypt file.txt.gpg to the terminal]

b) Decrypt with a password:

gpg -d file.txt.gpg > file.txt

[decrypt file.txt.gpg to file.txt]


3. Importing keys

a) Import a third-party's public key

gpg --import john.txt



4. Exporting keys

a) Export your public key

gpg --export -a > pub.txt

[export in ascii format;
save to pub.txt]

b) Export someone else's public key

gpg --export -a "john" > john.txt

[export in ascii format;
use john's public key;
save to john.txt]


5. Listing keys

a) List public keys

gpg --list-keys

b) List secret keys

gpg --list-secret-keys

Wednesday, 26 September 2012

Office 2013 encryption cracked

Password recovery firm Elcomsoft claims to have cracked the encryption system included in Microsoft Office 2013.

According to Elcomsoft's researchers, Microsoft has done a great job beefing up the encryption of its Office documents. This has forced those who want to break it to move from brute forcing techniques to more advanced methods.

In a blog post the company says,
"Brute force becomes less and less efficient with every new release of Microsoft Office even with full-blown hardware acceleration in place. Office 2013 sets a new standard in document encryption, pretty much taking brute force out of the question. This is why we continue relying on a variety of smart attacks that include a combination of dictionary attacks, masks and advanced permutations."
For now users of Elcomsoft's password cracking recovery software will have to depend on the work of their computer's main processor(s). There is currently no way to use efficient graphics chips to accelerate the breaking of security systems.

However...
"Support for additional hardware accelerators such as ATI and NVIDIA video cards [is] scheduled for a later date."

Monday, 17 September 2012

Malware on new PCs not installed at factory

Microsoft has reported that some new computers are infected with malware.

The mainstream and technical media has taken up this disturbing story and published nearly identical versions, complete with the same quotes.

Sadly they often miss the main point of this incident.

What most stories on this subject claim: malware is pre-installed on new computers at the factory.

What Microsoft's document actually states: malware was found on a computer bought from a shop.

In the report's own words:
"Microsoft’s researchers purchased a Windows laptop computer from computer reseller in Shenzhen, China, which had been carelessly or intentionally infected with Nitol.A."
The Guardian's story uses the headline, "Malware being installed on computers in factories, warns Microsoft" and opens with, "Criminals are installing malware on PCs before they leave the factory, according to Microsoft."

The BBC's version of events claims that, "Malware inserted on PC production lines, says study" continuing with the same flawed statement, "Several new computers have been found carrying malware installed in the factory, suggests a Microsoft study."

The Daily Mail's over-long headline warns that, "Hacker warning as research finds malware installed on computers before they even leave the production line". The report then uses the now-familiar, albeit grammatically incorrect, opening gambit of, "Criminals are installed malware on PCs before they even leave the factory."

There are a vast number of cookie cutter stories very similar to those above on the web.

Microsoft never made this claim, though. In fact its initial research was into the security of supply chains, rather than the internal security of factories. It is far more likely for a small business on the low-margin retail end of the line to engage in this sort of criminal activity than it is for a major manufacturer to compromise itself in this way.

Only one in 20 computers bought by Microsoft was infected.

In its report Microsoft claims to have found a copy of malware known as Nitol on just one of 20 computers that a researcher purchased. Three other PCs contained a few files that (unspecified) anti-virus software detected as being malware. This does not necessarily equate to an infection, though. In fact, as Microsoft notes, "The computer that contained the Nitol virus was the only one that was actively running."

Microsoft has published an article about its findings, which links to the document mentioned above, on its blog.

While this particular piece of research has been misrepresented, there have been verified cases of malware being installed at factories in the past:


18/03/2010 Energizer Trojan keeps going

Friday, 3 August 2012

Sharing passwords with Tesco

"Every little helps," says the Tesco motto. Well, it seems that the UK's largest supermarket needs a little help with securing online customers' passwords.

Tesco's online shopping site does not protect customer passwords as thoroughly as it should. This in turn puts customers at risk because they probably use the same password with Tesco and other online services.

It is not realistic to expect people to have a unique password for every online service that they use. Normal people are not interested in security and have neither the time nor the energy to maintain (let alone memorise) a long list of strong passwords.

There are all sorts of clever solutions to this problem, including software that generates passwords that are impossible to memorise and then handle the passwords for you, providing access to the password-protected web sites. LastPass is just one example.

Realistically, though, the vast majority are going to use a handful of passwords for everything that they do. Quite likely some of these passwords will be on the list of common passwords published by ZDNet.

Another problem with managing passwords using applications is that increasingly people are accessing websites with multiple devices, such as smartphones. Windows and Mac applications and browser plugins don't transfer easily to all of the available mobile handsets.

If you have a small selection of passwords then I have some urgent advice for you.

  • Do you have a Tesco online shopping account?
  • Do you have any other online accounts for which you have used the same password as your Tesco account?
  • Are these accounts in any way connected to important personal information or services, such as your email account(s) and financial services?
If you answered 'yes' to all of the above questions then it would be wise to log into every one of those services, except the Tesco site, and change your password immediately.

It is completely understandable, if not advisable, that you might want to use the same password for all of these services. If you do, do not then change your Tesco password to match this new one.

The reason for this urgent advice is that Tesco does not handle passwords in a particularly secure way. This has been publicised by Troy Hunt, who highlighted some problems with Tesco's website on his own site a few days ago.

There is an interesting list of sites that send users' passwords over email in cleartext on the Plain Text Offenders website.

---

If you are concerned about this type of problem you could create a short list of passwords, including some very strong ones as well as some very easy to remember ones. Use the strong ones for your most important services, possibly using a small variation for each. Use the less strong versions for less important services.

Is this ideal? Definitely not, but until online security moves away from simple username and password authentication regular users have little other choice.

Friday, 20 April 2012

Free encryption tools

Encrypting personal data is a sensible thing to do. If you computer is lost or stolen then at least your sensitive files are not at risk of being abused.

There are a number of common ways to do this:

  1. Encrypt each file, one file at a time, manually.
  2. Create a bundle of files in one archive and encrypt the archive.
  3. Automatically encrypt all files placed into a specific folder/directory.
  4. Automatically encrypt all files placed into a virtual hard disk.
  5. Encrypt the entire hard disk, or portions of it.

Each of those options has its benefits and downsides. All can be achieved for free. Free encryption has been available for a long time but it is frequently hard to use.

PGP/GPG

Pretty Good Privacy (PGP) and GnuPG (GPG) aren't suitable for consumers simply because, even with the optional graphical interfaces, the very concepts that they rely on are not trivial to understand. They also usually involve both the sender of secrets and the receiver being equally competent.

Anyone can understand the idea that you can password-protect a file. Public key encryption is a little harder to understand and explaining it usually involves analogies involving Bob, Alice and Eve.

PGP/GPG are really useful tools. They just aren't that easy for regular users to handle.

PGPdisk

This fantastic tool allows you to create an encrypted archive that appears as an extra hard disk e.g. F:\

Any files placed into this disk are encrypted automatically and transparently. The user can act as if using a standard internal or USB drive. In fact you can place the archive on an external drive, which is quite a sensible thing to do.

Unmount the disk and the files are locked. Unlocking the files involves entering a password for the archive or for the private key (if you used it to create the archive).

You can also create self-decrypting archives. This means that the files are bundles into one Exe file. Send this to someone who knows the password and they can extract the files without owning a copy of PGPdisk. The downside to this is that you have to let them know the password in a secure way.

PGPdisk used to be free but this changed and you had to buy the commercial version of PGP to obtain it. Since Symantec bought PGP it's not clear to me whether or not it is still available at all. Free versions for Windows and Mac are still available from the PGPi website, but these are pretty ancient versions.

Windows EFS

Windows Encrypting File System, which is available on the more expensive versions of Windows XP, Vista, 7 and (soon) 8 is very easy to use but it has some significant problems too.

These include the ease with which users can lock themselves out of their computers and data, the complication of backing up an encryption certificate and the fact that the files are not protected while the user is logged in. This means that malware can steal data, even if the thief who stole your laptop cannot.

There is also some confusion over what happens when you copy encrypted files to other disks.

Here's an example of EFS going horribly wrong in a home environment. I encrypt some folders on my laptop. The laptop is shut down and the files are safe. I forget my password and boot the laptop using a password reset tool such as the Offline NT Password & Registry Editor. While I can access all of the unencrypted files, I have sadly lost access to the encrypted ones forever (unless I made a backup of my encryption certificate).

In a similar way, a vandal with access to the laptop could reset the password using the bootdisk mentioned above and then just walk away, having locked me out of my encrypted files.

Businesses and technical users will be aware of the need to backup the encryption certificate and should be able to cope with corrupted systems. They probably also have full, unencrypted backups. The same is unlikely of most home users.

TrueCrypt

The TrueCrypt software provides a relatively easy way to encrypt files, and has some very advanced features. However, it's interface is not as intuitive as some would like.

One really useful feature is its ability to fully encrypt the hard disk, including the boot partition. Anyone who does this will have some technical knowledge and interest, which is just as well because forgetting your password would be disastrous!

Sophos Free Encryption

Sophos Free Encryption provides a similar feature to to one that is provided in PGPdisk. This allows you to create self encrypted archives, a bit like password-protected Zip files.

Winzip, 7z and other password-protected archive tools

It is perfectly possible to store files in password-protected Zip files. This is the quick and easy way to achieve some level of privacy, although it is less convenient that using more transparent tools such as PGPdisk, TrueCrypt or EFS.

For example, finding files on your hard disk is easy when you can use Windows' search tools, Google Desktop or some other method. Searching inside encrypted Zip files, or creating catalogues of them, is a non-trivial task for regular home users.

Some older versions of Zip tools have a vulnerability that allows passwords to be recovered very easily using a variety of free or inexpensive tools.

Thursday, 12 April 2012

OS X security (2002)

Ten years ago I wrote an article about OS X security for Mac User magazine.

The article noted that Mac users were now using a new operating system that was far more likely to face threats such as malware.

In light of the recent Flashback threat, and the resultant interest in Mac threats, I've pasted it below. Most of it is still relevant today.

[Note: If you are worried about the Flashback threat, you can check and clean your system using one or more of these tools.]

Securing Mac OS X

by Simon Edwards

Mac OS X opens more potential security holes to hackers. So how do you protect yourself?

Your Mac is at risk from hacker attacks, now more than ever. And if you don't take active steps to secure it you will be used as a Spam gateway, an unwitting accomplice of further hacker attacks or even a stooge in a bank robbery.

This isn't hype, it's reality. When Apple started shipping Macs loaded with OS X it was making a very powerful operating system available to thousands of users. But while people rejoiced in a new user interface and greater stability, many have not realised that by adopting a well-known operating system (UNIX) they have also opened themselves up to a raft of old and new security vulnerabilities.

The reason that Macs have been relatively free of remotely exploitable security holes is because the people who find and use such holes are only interested in the operating systems that they will commonly find on the Internet. Mac OS 9 is not common in comparison with Solaris, AIX, Windows NT and Linux operating systems, which is why the latter have been plagued by hackers for what feels like forever.

But OS X works in much the same way as Linux, Solaris and other UNIX-based systems. It can use the same software and, therefore, inherits the same benefits and vulnerabilities. The solution is not to revert to OS9, though. Instead, read this feature and you'll be able to lock down your Mac OS X machine against the most prevalent attacks.

First line of defence

OS X is a multi-user operating system, which means that many different people can use the computer at different times. Their application settings, e-mail and other files are kept separate so that one user cannot delete another's important data, or read his e-mail. While this means that the system is potentially more secure than a Mac OS 9 system, with regards to local users, the level of that security is only as good as the users' passwords. A recent survey found that 25 per cent of users believe that 'banana' is a strong password. This is incorrect for a number of reasons.

Firstly, banana is a real word that can easily be guessed by a password-cracking tool. Cracking tools work using dictionaries, and only resort to the very slow method of brute-forcing after all dictionary words have been tried. The brute force approach works like this: the cracker starts at 'a' and works through the alphabet, then adds another letter and continues through every permutation of letters, numbers and punctuation marks. This can take months, and it took our 700MHz system 28 days to crack the simple password 'rumble9'.

If you insist on using passwords of less than eight characters (not recommended), at least change them every month. That way you will foil this kind of attack most of the time. You should also use a mixture of capital and lower-case letters, numbers and punctuation marks. 'Mac_+Us3r01' is a good password but 'macuser' is not.

Service included

Programs such as a Web server, FTP server or a remote access utility are known as services. An Internet host is of little use unless if provides at least one service, but by doing so it is exposing itself to attack. A hacker needs something to hack at, and an old SMTP (mail), DNS, or Web server is sometimes all that is necessary. The trick is to run only those services that are really necessary.

Allowing remote access with older versions of Mac OS X meant enabling Telnet. This service lets you log in from a terminal on another computer, be it a Mac, PC or even PDA, and control the server as if using its own keyboard.

While this may seem like a very useful feature, Telnet is not a secure method of working. The problem is that when you log on using Telnet you have to enter your username and password, which is sent across the network (and maybe even the Internet, if you are logging in to a Web server installed in another building). Telnet sends these details in plain text, which can be intercepted by a hacker using a network sniffer. He will see 'user fred.bloggs' followed by 'password BaNa_na9'. Even though Fred has used a strong password, the hacker now knows it and can hack the system.

Mac OS X v.10.0.1 has replaced Telnet with SSH (Secure Shell), which is much better. It encrypts the connection so that instead of seeing the username and password, the hacker just sees digital garbage instead.

FTP also suffers from the same plaintext vulnerability as Telnet. You can replace FTP with the SSH equivalent, SFTP (Secure FTP) or SCP (Secure Copy). For details on setting up and using SSH, see the walkthrough below.

Updates

As we've already seen, updating your software can avoid some major problems. But even if you have a perfectly working Web server with SSH installed, things are not always as safe as they seem. New security holes emerge all the time and you'd be wise to subscribe to the main security mailing lists if you intend your Internet-connected Mac to survive. The best ones include the large selection at SecurityFocus (www.securityfocus.com).

For example, during the month in which this article was written, security updates were released to fix holes found in the Apache Web server, SSH, the Web scripting language PHP, the printing system, Internet Explorer 5.1, crontab, fetchmail, the firewall software ipfw, Telnet and a whole load of others. Failing to updates any of these packages could result in a hacker taking remote control of your computer, which is the ultimate goal for them and the ultimate nightmare for you.

The best way to update your software is to set the Software Update program to check for updates every day, or every week if you only connect to the Internet sporadically. To run this utility open the System Preferences and select Software Update option.

Buffer overflows

Security holes come in a number of shapes and sizes, and you can even create your own if you're not careful. The most common threat comes from buffer overflow attacks. The principle behind these is that a program installed on your system is written in such a way that when an attacker feeds it too much information it crashes.

In an analogy where the computer's memory is an empty glass and the incoming data is a flow of milk, a buffer overflow would occur if you tried to pour a pint of milk into a half-pint glass. Obviously some milk is going to spill onto the table, which results in a mess - or a crash, in the case of a computer system. But a clever hacker can cause the overflowing data to move into another part of the computer's memory, where it will be run. This is how they gain access to your system without even bothering about cracking your passwords.

Firewalls

One way to restrict a hacker's access to your system is by using a firewall. This program decides which information can flow out of and into your system. You can use a firewall to allow Internet users to access your Mac on port 80, which is the networking port used by most Web servers, but to deny access to any other port. SSH usually runs on port 22, so you'll probably want to allow external access to this port as well, if you want to administer the Web server from any Internet-connected location in the world.

But your file sharing ports, networked printer port and ports for other services that should only be available to the local network, not the Internet, need to be blocked off. Disallow all but the most necessary ports for outbound traffic too. That way you prevent malicious applications from sending important data out to an attacker on the Internet (see Viruses and backdoors below).

For a detailed description of setting up the firewall supplied with Mac OS X, see Configuring Mac OX X's firewall with BrickHouse, 19 April 2002, p79.

Wireless networks

While wireless networks are doubtless very cool and quite useful, remember that they increase the range of your network beyond your office. If you don't use encrypted networking (such as with SSH) you might as well stick a network port on the wall outside and wait for the hackers to jack in. There are plenty of tools that hackers can use to locate and crack your wireless network, but with a little care you can make it not worth their while to try.

If you're running a seriously expensive business over a wireless network consider setting up a virtual private network (VPN) to provide the encryption, and place dedicated firewalls between the wireless section of the network and other workstations. By treating the wireless part as an untrusted network, just as you would treat the Internet, you reduce the risk of a wireless attack massively.

Viruses and backdoors

While there are not many viruses that can affect UNIX operating systems directly, they are more than capable to moving through UNIX mail servers and onto the Mac and PC systems further down the chain. If your Mac is being used as an e-mail server you should consider installing an anti-virus program, which will strip out viruses intend on damaging your users' OS 9 Macs and Windows PCs. McAfee and Symantec have released Mac OS X anti-virus programs that will do the job.

The direct danger to Mac OS X systems is that once a hacker has compromised the security, using a buffer overflow attack or by exploiting some other weakness, he will install a backdoor that will allow him to return more easily. You can patch your system until you're blue in the face, but if you don't know about the backdoor you might as well give up.

When a hacker installs a backdoor he may replace some of your useful files with doctored versions that seem to behave properly but are actually helping to hide the hacker's files and activities. For example, he might have placed a stash of useful files in a directory called /hacks. The less command would display this directory, but a doctored version could be made that displayed every directory except this one.

We need a way to discover if files have been changed. CheckMate is a program that can scan essential files and create a special index of them, using checksums (see the Jargon box). If an important file is replaced the checksum will change and CheckMate will notify you that something is up. Knowing that your system has been compromised this heavily will help you save time when trying to work out what's wrong. If you find your basic files have been replaced there is only one thing to do - reinstall. Then install every possible update and run CheckMate again before connecting to the Internet.

File encryption

When you send an e-mail across the Internet it can be read by a large number of people, whether you know it or not. E-mail is created, sent and received in plain text, and passes through a number of systems on its journey to the intended recipient. Hackers with snuffer programs, mail system administrators and people with access to the computer used by your contact can all read the message, which is why sensitive information should always be encrypted.

Files stored on your hard disk should also be encrypted if they are sufficiently important. For example, if you've used CheckMate to generate an index of checksums you'll need to be sure that the hacker hasn't edited it to avoid an alert. Encrypt it and he's locked out. To encrypt e-mail and local files you'll need a good encryption package like PGP or GnuPG. The former is very easy to use and comes with a graphical installer, the latter is free but needs to be loaded from the Terminal command line.

To do this you'll need to download the GNU Privacy Guard file (GnuPGOSX1.0.6r6.dmg.gz) from http://macgpg.sourceforge.net, as well as the Darwin patch, which is called gnupg-1.0.6-darwin. Next, type:

tar -ax gnupg-1.0.6.tar.gz
To copy the Darwin patch into the folder that this creates, patch the software and install it type the following lines in order:

cp gnupg-1.0.6-darwin.diff gnupg-1.0.6/
cd gnupg-1.0.6/
patch -p 1 < gnupg-1.0.6-darwin.diff
./configure
make
sudo make install
You can now download the plethora of GUI helper tools from the same site. Or download the non-commercial version of PGP from pgpi.com.

Conclusion

If this article has started you worrying about Internet security, it has done its job. But while the Internet can be a hostile place, taking the simple steps listed here will make you almost invulnerable to the most common attacks. Just being aware of the risks puts you in a minority, and it's a good club to join.

Talk the talk

Buffer overflow A common but highly technical type of hacker attack, that is avoided by keeping software on the computer as up-to-date as possible. A successful attack allows the hacker to run commands on your system at the highest possible level of authority.

Checksum A checksum is a code that can be generated to represent a file. It is virtually impossible for two different files to have the same checksum, so it can be thought of as a fingerprint or DNA profile. This makes check summing an ideal technique for detecting if a file has been changed by a hacker.

Encryption The scrambling of a file or message so that it is readable only by the person for which it is intended. Encryption can be used for Internet traffic too (see SSH below), and is most commonly encountered when buying from a Web site - those yellow padlocks are indicative of an encrypted Web session.

Firewall A software program or hardware device that controls the type of network traffic able to pass through it. Usually used to protect computers or even whole networks from the Internet, they are now being installed by some to keep wireless networks safe.

Ports Different Internet services running on the same computer use different ports. This means that someone trying to connect to a system using FTP won't interfere with the Web server on the same machine. FTP uses port 21 whereas Web servers usually run on port 80. Services: A server is a computer that provides services to other users. Examples included POP3 mail, telnet or SSH remote access and Domain Name Services (DNS). Services are controlled by a file called /etc/inetd.conf.

SSH The Secure Shell creates an encrypted connection to your Mac, which means that hackers cannot see what you're up to, or what your password is. SSH can also be used to create virtual private networks (VPNs) across the very unprivate Internet.

Trojan A file that looks like something you want to run, but carries a less pleasant payload such as a computer virus or backdoor that creates a secret entry point for a hacker into your system.

UNIX These days UNIX is considered to mean a type of operating system, rather than a specific one. Solaris, Linux, FreeBSD and AIX are all types of UNIX, or are based on UNIX. Mac OS X is based on Darwin, which in turn is a version of BSD UNIX.

Using SSH

For security purposes, a server is any computer hooked up to the Internet that's capable of providing network services such as Web, FTP or mail. If you want to control your Mac OS X server remotely you'll need to use SSH, which has replaced the less secure Telnet originally shipped with the operating system. If you've never updated your installation you won't have SSH. You are strongly advised to download the very latest updates as soon as possible, particularly if your system spends any time at all connected to the Internet - even using a dial-up modem connection.

In this walkthrough we are assuming that your system is fully up to date and that you want to administer your computer from somewhere else on the local network. There is no real difference between doing this and coming in from the Internet. If you want to do connect from the Net you will need to ensure that any protective firewalls between you and the Internet will allow connections through port 22 or it won't work.

STEP ONE

Enabling remote access

Go to the Sharing System Preferences panel and choose the Sharing option from the Internet and Network section. Tick the Allow Remote Login box, which enables the Secure Shell (SSH) service. This operates on port 22, which is the default used by just about everybody. You absolutely must ensure that you are using Mac OS X version 10.0.1 or later, otherwise your remote access will be provided via Telnet, which is significantly less safe to use. We are using version 10.1.4 here.

STEP TWO

Establish a connection

Here we are assuming that you have two computers connected to the same network, one allowing remote access and that has an IP address of 10.0.0.1. You can determine the IP address of your remote server by going to System Preferences, choosing Network and viewing the settings for Built-in Ethernet. Start a terminal session on the non-remote access Mac (Terminal is available from the Utilities folder) Type: 'ssh username@10.0.0.1'. Use your own username and enter your password when prompted. Answer 'yes' when asked if you want to connect.

STEP THREE

Run commands

You can now administer your computer over the network, or even over the Internet. You'll need to have administrator rights to be able to change the system. These are provided in System Preferences from the Users option. Running 'top' will show you what processes (programs and background operations) are running. You can use the sudo command to run critical commands that require the ultimate level of authority. To reboot the Mac type 'sudo shutdown -r'.

STEP FOUR

Copying a file

Use the scp to copy a file from the server. Here we typed 'scp spge@10.1.22.23:backup backup', which has the effect of running scp, connecting to the server at 10.1.22.23, grabbing a file called backup and saving it as 'backup' on our system. The following line in the screenshot lists all files beginning with the letter 'b'. Using the list command (ls) with the -l switch shows more information, such as the file size, the date of its creation and who has permission to read or edit it.

Further information

Pretty Good Privacy (PGP) E-mail and general file encryption utility that can make your files unreadable to everyone but yourself
Free, for personal use
http://www.pgpi.com

GNU Privacy Guard Essentially a free version of PGP, you'll also need to download some other utilities to make it extra friendly to use.
Freeware, even for commercial use
http://macgpg.sourceforge.net

CheckMate Generate and compare checksums of essential files to discover if a hacker has altered your system.
Free, while in beta
http://personalpages.tds.net/~brian_hill/checkmate.html

Hints and tips

Watch your logs!

When a hacker takes over you system is won't be quietly, but unless you look through your log files you'll never know what's happened. It is necessary to know how a hacker broke in, even if you are going to reinstall your whole system, because that way you can fix the problem. Reinstalling will just reset your computer and the hacker can come back in the same way he did before. You'll find your logs in the directory called /var/log. Type 'last' from the terminal to see who's been logging in, and when.

Keep an eye on your users

If only you and a couple of other people are using the Mac there should only be a handful of names in the user list accessible from System Preferences - Users. If odd entries appear you can be sure that someone has administrator-level control of your system. If you want to know who's logged in at any one time type: w from the terminal command line to see a list. You should also check the /Users directory to see if any extra sub-directories have been created. This would indicate that someone has gained access to your system.

First Published in MacUser, Vol 18 No 13, 28 June 2002.

The above article is © Dennis Publishing Limited 2002. UK property of Dennis Publishing Ltd. This article may not be reproduced or transmitted in any form in whole or in part without the written consent of the publishers.

Monday, 2 April 2012

Military grade data protection

Miliitary-grade
Garibaldi biscuits
Have you ever been impressed by software that claims to offer military-grade protection?

It's fairly common practice for disk wiping and encryption software to make such claims. But what does 'military grade' actually mean?

The short answer is, it doesn't really mean anything.

At best it could mean that, at some stage in the past, a military organisation has approved the use of an item. This could be an encrypted USB drive or a packet of Garibaldi biscuits (aka Biscuits Fruit AB).

Another possibility is that the military has some standards in place, to which all equipment that it uses must comply.

Bullets are one good example. The British Army uses a standard sized bullet that works in its regular rifles and machine guns. In fact, this ammunition is compatible with the US Army's M16 rifle and with other weapons used by NATO countries.

File/disk encryption

The sort of software and hardware that consumers have access to is not equivalent to the high-end equipment that the military uses for important tasks.

However, even specialist chips are not invulnerable so 'military-grade' does not mean uncrackable.

Disk wiping

One classic claim made by disk wiping software is that it conforms to the Department of Defense's standards for data sanitisation. In fact you may often see reference to an impressive-looking 'standard' called DoD 5220.22-M.

This claim has always been fairly meaningless and, since mid-1997, it's been entirely irrelevant. Here's why:
  1. Not all data is equally sensitive. Highly secret data is treated quite differently to that which is less important. DoD 5220.22-M doesn't cover a specific security level of data.
  2. An old standard is not necessarily the best practice today. It possibly wasn't even that great an idea when it was first formalised. Governments and the military do not always use the best equipment on the market.
Governmental organisations may have to destroy disks physically if they contain certain levels of sensitive data. In less sensitive cases they may use strong magnetic fields to wipe data. Currently PC software is unable to achieve either of these goals.

Imagine you see an advert for disk-wiping software that promises military-grade data destruction. It invokes DoD 5220.22-M to support its claim. It's fair to assume that if the US Department of Defense has formalised a standard, and if this software conforms to it, then its users would be about as secure as anyone in the world.

This is an incorrect assumption.

Disk wiping software overwrites data one or more times to make it hard to recover. Before June 1997 DoD 5220.22-M supported this technique as a valid one - although it didn't specify whether or not this was appropriate for secret or unimportant files.

After June 1997 the only supported methods of disk sanitisation was either using magnetic fields or physical destruction. If you download the current DSS Clearing and Sanitization Matrix you'll see that magnetic disks must be degaussed (a/b) or physically destroyed (l).

An example

There are plenty of developers that market their tools in this rather misleading way. I'll demonstrate this using LSoft Technologies' Active@ KillDisk, but there are plenty of others that do the same.

[Possibly the most honest I've seen is the Linux utility scrub, which has documentation including caveats.]

The KillDisk site claims that:
"If you use FDISK, FORMAT utilities, or DELETE standard operating system command for data removal, there is always a chance to recover deleted files (using undelete or unformat tools) and use against the owner's will."
Directly under this correct statement is this line:
→ DoD 5220.22 M compliant ←
The clear implication is that by using this tool you remove the aforementioned chance of data recovery.

The above link leads to an outdated Clearing and Sanitization Matrix, which permits the use of overwriting on magnetic disks when sanitising. It does, however, note that:
"THIS METHOD IS NOT APPROVED FOR SANITIZING MEDIA THAT CONTAINS TOP SECRET INFORMATION."
On another page the site lists some useful definitions, without providing any context:
3 - US DoD 5220.22-M
The write head passes over each sector three times. The first time with zeros (0x00), second time with 0xFF and the third time with random characters. There is one final pass to verify random characters by reading.
4 - US DoD 5220.22-M (ECE)
The write head passes over each sector seven times. The first time with zeros (0x00), second time with 0xFF and the third time with random characters, the fourth time with 0x96, and then first three passes repeated again. There is one final pass to verify random characters by reading.
So what should you do?

If you want to wipe your hard disk before selling it, then a disk wiping program is probably good enough. However, if it contained data that you never, ever want anyone to discover then destruction is the only real answer.

If you want to destroy the data on a hard disk, so that it can never be recovered, you might want to explore the following options:

Destroy the platters:



Destroy the entire disk:


UK mass internet monitoring

There are plans for new laws that will allow the UK government to monitor its citizens' phone calls, web site visits and email (incoming and outgoing).

This will, I predict, cost a lot of money and will fail to deliver what you might expect.

Let's put aside the possibly massive abuse of civil liberties that such a scheme invites and focus on how useful it will be for its intended purpose.

Who will pay?

It looks like the Internet Service Providers (ISPs) will be doing the bulk of the work. The additional work will cost money, which will almost certainly be passed to the customers (us).

What will be tracked?

According to the BBC, the system will:
"enable intelligence officers to identify who an individual or group is in contact with, how often and for how long."
My understanding of this is that ISPs will track who receives emails from who, but not the content. So if Individual A (Alan) sends an email to individual B (Brian) then the government can discover this fact, although without necessarily knowing the content of that email.

No doubt IP addresses will be tracked too, adding to the likelihood that Alan really is Alan, and that Brian is Brian.

From the sketchy information available so far it seems that this will allow the government to track fairly low-level criminals who have the technical naivety of Luddites.

Organised criminals have been using 'burner' mobile phones for years, treating their devices as disposable. Buy a phone for cash, set up a free webmail account and it would be tough for anyone to work out if you were Alan, Brian or Ayman Al-Zawahiri.

Rik Ferguson from Trend Micro agrees that dangerous criminals have at least a semblance of security sense:
"If national governments and law enforcement organisations truly believe that online criminals and international terrorists don’t know how to hide their online traces, then we have a bigger problem than we thought (sending an encrypted email with spoofed sender address from an Internet café is only lesson one)."

Thursday, 29 March 2012

Why even experts need antivirus

[This article is written in response to Wired's recent article, Is Antivirus Software a Waste of Money? As is usually the case, when you see a headline posed as a question, the answer is usually "no".]
"I don't run anti-virus, actually," he said, "and I've never had a virus."

"Really?" I asked. "How do you know?"

"I think I'd know," he scoffed.

I had that conversation with the UK head of marketing for an anti-virus company that, while not one of the top brands, is certainly quite well known in Europe. We probably spoke around 2008.

Scroll back to the eighties and possibly even early nineties and he'd probably be at least half right. Viruses might hide for a while but they usually gave away their presence at some stage, possibly by deleting or encrypting files, sending a cheeky message or producing a graphic effect that was hard to ignore.

In the later parts of the nineties things started to change. Malware began to commercialise, and it made sense for these malicious programs to be more subtle. Dialers were one of the first such threats. They resided silently on victims' systems and made phone calls to premium numbers.

Once malware started to hide, the game changed. Without appropriate tools even an expert would not know that a system was infected. Even then, sensible behaviour, such as avoiding pirated software, license key generators and pornography websites was sufficient to avoid most problems.

Halfway through the noughties (around 2005-6) a new approach rendered the classic advice of "be careful" fairly useless.

Criminals started compromising legitimate websites, loading malware from otherwise innocent sites onto visitors' computers. In many cases users would have no idea that this was happening. Even a paranoid expert would have a tough time using the internet in a useful way without exposing their computer to such threats.

Rootkits are also now prevalent. It is hard to detect these threats even with specialised software, let alone some sort of tuned-in, Jedi-like human virus-detector sense.

In Wired's article Is Antivirus Software a Waste of Money? a startup CEO called Dan Guido was quoted as saying, "If it weren’t for [compliance] nobody in the security industry would run [anti-virus]."

I contacted Dan to see if he was happy with the angle of the article. He was, by and large, and claimed that,
"The issue with AV is that their virus detection capabilities only become effective after tens of thousands of people have been compromised with the same virus and days or weeks after that virus was first observed."
Having seen how some anti-malware tackles new attacks, sometimes involving zero day exploits, I don't agree with his blanket statement. He went on to make other very general assumptions about how anti-virus software works. One notable point of view was,
"At the time of infection, every major attack group has procedures that allow it to avoid all the known checks that AV runs through."
In other words, criminals check their malicious software before releasing it, checking to see if anti-virus will catch it. This is certainly true.

Underground versions of VirusTotal-style services exist but I find it hard to believe even the most advanced attacker is capable of running a full end-to-end test to ensure success without alerting the anti-virus vendors.

For example, they must either allow or block cloud service queries. Block these queries and the test is not complete. Allow them and information is fed back about the new threat to the vendor.

I polled a few security professionals, in an admittedly unscientific study, and found that they all used anti-virus. No one believes that anti-virus is a panacea. It's just daft to run without it.

Despite this Lance Spitzner sent me a Twitter message, guessing that maybe experts don't use anti-virus "because most security professionals use a Mac :)" Having been to very many security conferences I have to admit that he has a point.

How the police crack smart phones

It is easy for law enforcement and security services to pull data from a PC, unless the owner has taken some fairly advanced privacy measures. The same is not the case for smart phones.

Smart phones, such as Android handsets and Apple's iPhone, run operating systems that work in a fairly secure way. The user is unable to gain low-level access to the system, which also makes it hard for hackers and malware to gain a foothold.

This in-built security poses a significant challenge to the police, who have legitimate reasons for cracking open phones belonging to criminals. So how do the instruments of law gain access to phones? By hacking them, of course.

Hacking a phone, by which I mean using one or more tools to exploit a security hole (vulnerability) in the operating system or other low-level software, can be tricky. To make life easier some businesses have made automatic tools available.

Both Micro Systemation and Elcomsoft offer tools to law enforcement that achieve the same goal. They work in essentially the same way, which is to exploit a security hole in order to gain full access to the system. They then dump information down to a computer for analysis.

Micro Systemation published a very clear video that demonstrated its slick system but today (29/03/2012) the video was no longer available. You could try the original link to see if it has been put up again.

Elcomsoft has published a video demonstration that shows its system to be more command-line based. This video is also available below.


[This week there were reports in the mainstream media that new rules proposed by the EU would outlaw hacking tools. Cue security experts complaining that this will prevent legitimate security work.

This argument emerges every time the law changes to catch up with modern crime and terror techniques. I remember unsuccessful predictions being made in 2006 when the Computer Misuse Act was revamped.

My prediction is that penetration testing will not be outlawed, security research will continue unabated and companies like Micro Systemation and Elcomsoft will continue to sell their services to the police.

And the criminals will also continue with their activities too.]