October 2011 - Posts

NCSAM/2011–Post 20–Is SSL broken?

It seems like a strange question for me to ask, given that in a number of my National Cyber Security Awareness Month posts to date, I have been advising you to use SSL or TLS to protect your communications. [Remember: TLS is the new name for SSL, but most people refer to it still as SSL, so I will do the same below]

But it’s a question I get asked on a fairly regular basis, largely as a result of news articles noting that there has been some new attack or other on SSL that breaks it in some way.

To be fair, I’m not sure that I would expect a journalist – even a technology journalist – to understand SSL in such a way that they could give a good idea as to how broken it may or may not be after each successful attack. That means that the only information they’re able to rely on is the statement given to them by the flaw’s discoverers. And who’s going to go to the press and say “we’ve found a slight theoretical flaw in SSL, probably not much, but thought you ought to know”?

The good news

First, the good news.

SSL is a protocol framework around cryptographic operations. That means that, rather than describing a particular set of cryptography that can’t be extended, it describes how to describe cryptography to be used, so that it can be extended when new algorithms come along.

So, when a new algorithm arrives, or a new way of using an existing algorithm (how can you tell the difference?), SSL can be updated to describe that.

So, in a sense, SSL will never be broken for long, and can always be extended to fix issues as they are detected.

Now for the bad news

Of course, SSL is really only a specification, and it has to be implemented before it can actually be used. That means that when SSL is updated to fix flaws, theoretical or practical, every implementation has to be changed to catch up to the new version.

And implementers don’t like to change their code once they have it working.

So when a new theoretical flaw comes along, the SSL designers update the way SSL works, increasing the version number when they have to.

The implementers, on the other hand, tend to wait until there is a practical flaw before updating to support the new version.

This means that whenever a practical break is found, you can bet it will be at least several weeks before you can see it fixed in the versions you actually use.

In moderation

The presence of SSL assumes that your communications may be monitored, intercepted and altered. As such, don’t ever rely on a statement to the effect that “this breach of SSL is difficult to exploit, because you would have to get between the victim and his chosen site”. If that wasn’t possible, we wouldn’t need SSL in the first place.

Having said that, on a wired network, you are less likely to see interception of the type that SSL is designed to prevent. As such, even a broken SSL on wired networks is probably secure for the time it takes everyone to catch up to fixing their flaws.

On a wireless network, any flaws in SSL are significant – but as I’ve noted before, if you connect immediately to a trusted VPN, your wireless surfing is significantly safer, pretty much to the same level as you have on your home wired network.

The bottom line

In summary then:

SSL is frequently, and in some senses never, broken. There are frequently attacks, both theoretical and physical, on the SSL framework. Theoretical attacks are fixed in the specifications, often before they become practical. Practical attacks are fixed in implementations, generally by adopting the tack that had been suggested in the specifications while the attack was still theoretical. At each stage, the protocol that prevents the attack is still SSL (or these days, strictly, TLS), but it requires you keep your computers up to date with patches as they come out, and enable new versions of SSL as they are made available.

If you’re on a wired network, the chances of your being attacked are pretty slim. If you’re on a wireless network, your chances of being attacked are high, so make sure you are using SSL or an equivalent protocol, and for extra protection, use a VPN to connect a trusted wired network.

NCSAM/2011–Post 19–Is it safe to give out my keys?

There are some people who seem to get this right away, and others to whom I seem to have been explaining this concept for years. [And you know who you are, if you’re reading this!]

Whenever you talk about keys used for encryption, you have to figure out how you’re going to keep those keys, and whether or not you need to protect them.

And the answer depends (doesn’t everything?) – and depends on what kind of encryption algorithm you are using.

Let’s start with the easy kind, the one we’re all familiar with.

Symmetric (aka shared-key) cryptography

This is the sort of code that I’m sure we all played with as children. The oh-so-secret code (well, we didn’t know about frequency counting or cryptanalysis back then), where you and your best friend knew the secret code and the secret key. [Probably a Caesar cipher, although I used a Vigenere cipher, myself]

Well, those codes, like us, have grown up. The category of shared-key cryptography, also known as symmetric cryptography, so that the same keys (and sometimes the same operations) are used to encrypt and decrypt the data, has been enhanced hugely since those old and simple ciphers.

Now we have AES to contend with, and for all practical purposes, with reasonable keys, it’s unbreakable in usable time. [But if you have a spare universe to exhaust, perhaps you can crack my files]

For symmetric key cryptography, you do have to give out your key – to the party with whom you plan to exchange data. Of course, you have to protect this key as if it was as important as the data it protects, because it is all that protects your data. [Your attacker can tell what algorithm you use, and if you develop your own algorithm, well, they can tell what that is, too, because crypto algorithm inventors are generally doomed to fail to recognise the flaws in their own algorithm.]

That’s kind of a catch-22 situation – there’s really no way using cryptography to protect a key-sized piece of data outside of encrypting it with another key.

Asymmetric (aka public key) cryptography

That’s why the British had to invent public key cryptography.

Of course, unlike the Americans, the British managed to keep this a secret – so much so that to this day, many Americans believe their country invented public key cryptography (along with apple pie, mothers and speaking English loudly to foreigners).

With public key cryptography, there are two keys for every cryptographic operation – the public key, and the private key.

Here’s the tricky part

OK, I don’t think this part is very tricky, but there are several people I’ve had to explain this to over and over again, so I’ll try to take it really slowly.

Of the two keys, there is one key that you are supposed to share with anyone and everyone. To some of you it may come as a surprise that this is the PUBLIC key.

Again, the PUBLIC key is something you can share with anyone and everyone with no known danger to date. You can print it on billboards, put it on your business cards, include it in your email, really you can do anything with it that distributes it to anyone who might want it.

In a pinch, you might want to make sure that you distribute the public key in a way that allows the recipients to associate it with their opinion of your identity.

But the PRIVATE key – no, no, no, no, no, you do not ever distribute that. You don’t even let someone else create it for you. You generate your private key for yourself, and you don’t ever tell it to anyone.

The simple reason is that anyone who has your private key can pretend to be you – in fact, for cryptographic purposes, they are you.

So, really simply now:

  • You generate your own keys. Nobody else ever does this for you (otherwise they aren’t your keys)
  • The public key can be given to anyone, but has to be associated with your identity in the recipient’s mind.
  • The private key cannot be given to anyone. It must be held by you, and you alone.

If you think this is confusing, apparently you are right – even Microsoft’s official curriculum for the Windows Server 2003 training courses says that “Alice encrypts the message using Bob’s private key” – if Alice has Bob’s private key, she can exchange any secret message with Bob while they are in bed together that night.

Actually, scratch that – even my wife doesn’t have access to my private key, and I don’t have access to hers.

What do you do with these two keys?

There are two operations that you can do with your private key. You can decrypt data, and you can sign data.

Reversing this, there are two operations that you can do with a public key – that would be someone else’s public key, not yours. You can encrypt data, and you can verify a signature.

Hybrid cryptography

In many cryptographic exchanges, such as SSL / TLS, and other modern equivalents, asymmetric cryptography is used briefly at the start of each session, so that two parties can identify each other and exchange (or, more commonly, derive) a shared key. This shared key is then used to encrypt the subsequent communications for some time using symmetric key cryptography.

A quick summary

For shared-key (aka symmetric) cryptography, you do have to share your keys – but you share them secretly with only the person to whom you are communicating. If you are trying to protect a communication between you and a partner, you cannot send the keys down the same line that you are going to send the communication down, because an attacker who can steal your communication can also steal your keys.

For asymmetric cryptography, you also have to share your keys – but only your public keys. Again, that’s only your public keys that you share. And you have to share those public keys. Your private keys are used by the various applications that encrypt data on your behalf, or to sign data to prove it came from you. Anything outside of that realm that asks you for your private keys is not to be trusted.

Any questions?

Ask an expert if you still have concerns. Because if you give out your private keys, then you have to generate new ones, and distribute new public keys.

NCSAM/2011–Post 18–Know what security you want from your network

In yesterday’s post, we talked about how SSL and HTTPS don’t provide perfect security for your web surfing needs. You need to make sure that a site is also protecting its applications and credentials.

This can be generalised

One of my favourite interview questions for security engineer candidates is to ask what an application developer could use to protect a networked application if SSL wasn’t available.

It’s an open ended question – what parts of SSL is the interviewee looking to match, and what parts are they willing to throw away with an alternative (and do they even know what they are throwing away?); and it asks the interviewee to think about how else they can achieve those goals.

I like to hear answers that cover a number of options. I won’t provide a perfect answer here, because I’m sure I’ll miss something, but here are some of the considerations I would give:

Can we use network layer security?

There are a number of different ways to secure network communications, providing for encryption, integrity and authentication – IPsec and VPN are just two methods that should spring immediately to mind. These are not universally suitable, as they tend to be all-or-nothing solutions, rather than per-application, but if you expect to see only one application running on the communicating pair of systems (this is relatively common in business communications), this can be acceptable. These are also a considerable effort to set up, and don’t always scale to inter-networked situations.

What about application layer security?

Hey, what’s wrong with encrypting and signing a file with PGP or S/MIME, or even WinZip, and sending it through email?

Not a whole lot, surely. We can get into discussions of key distribution and so on, but essentially, this is a solid technique. Maybe not easy to automate, and probably not accepted by everyone the world over, but from a “protected by encryption” standpoint, this is actually fairly defensible.

So what’s my point?

What I’m really trying to say here is that your application’s security rests on an understanding of what protections you can ask from your network – and from your network staff, and which you will have to implement in the application itself. For every protection that is available in the network, that’s maybe some less work you have to do in your application; and for every protection the network does not provide, that’s one more thing you have to write into the app itself.

Without knowing what security your network provides between you and all your communicating partners, you can’t truly know or guess what security you need to provide in your application. Without knowing what security your application provides, you can’t describe what network environment is appropriate to host that application.

We split the world into infrastructure and application so frequently, that it’s important to remember that we each have to understand a little of the other’s world in order to safely operate.

NCSAM/2011–Post 17–SSL does not make your web site secure

I know, it sounds like complete heresy, but there it is – SSL and HTTPS will not make your web site secure.

Even more appropriate (although I queued the title of this topic up almost a month ago) is this recent piece of news: Top FBI Cyber Cop Recommends New Secure Internet, which appears to make much the opposite point, that all our problems could be fixed if we were only to switch to an Internet in which everyone is identified (something tells me the FBI is not necessarily looking for us to use strong encryption).

HTTPS is just one facet of your web site security

There are a number of ways in which an HTTPS-only website, or HTTPS-only portion of a site, can be insecure. Here’s a list of just some of them:

Application vulnerabilities

It’s been a long time since web servers provided only static content in their pages. Now it’s the case that pretty much every web site has to serve “applications”, in which inputs provided by the visitor to the site get processed and involved in outputs.

There are any number of ways in which those inputs can produce bad outputs – Cross Site Scripting (XSS), on which I’ve posted before; Cross Site Request Forgery, allowing an attacker to force you to take actions you didn’t intend; SQL injection, where data behind a web site can be extracted and/or modified – these are just the most commonly known.

Applications can also fail to check credentials, fail to apply access controls, and even fail in some old-fashioned ways like buffer overflows leading to remote code execution.

Path vulnerabilities

Providing sensitive information in an application’s path, or through parameters passed in a URL, is another common means by which application authors, who think they are protected by using HTTPS, come a significant cropper. URLs – even HTTPS protected URLs – are often read, logged, and processed at both ends of the connection, and sometimes even in the middle!

Egress filtering in enterprises is often carried out by interrupting the HTTPS communication between client and server, using a locally-deployed trusted root certificate. This quite legitimately allows the egress filtering system to process URLs to determine what’s a safe request, and what’s a dangerous one. This can also cause information sent in a URL to be exposed. This is one reason why an application developer should avoid using GET requests to perform and data exchange for user data, or for data that the site feels is sensitive.

Other path vulnerabilities – mostly fixed these days, but still something that attackers and scanning suites alike feel is worth trying – are those where the path can be changed by embedding extra slash or double-dot characters or sequences. Enough “..” entries in a path, and if the server isn’t properly written or managed, an attacker can escape out of the web server’s restrictions, and visit the operating system disk. The official term for this is a “path traversal attack”.

Credential vulnerabilities

The presence of a padlock – or whatever your web browser shows to indicate an HTTPS, rather than HTTP, connection, indicates a few things:

  • Your communication is encrypted (This can be overcome, but it takes so much work at both client and server for most implementations that I think it’s fair to say you will not be in the situation where you see a padlock without the use of encryption.)
    • That doesn’t mean to say you will always have the best encryption around, but if you didn’t go and enable weaker encryption than that supplied in a recent and patched browser, you’re fairly well guaranteed to be safe.
  • The web site you are connecting to is at least trying to give some indication of security.
  • The web site to which you connected has convinced your browser – or you – that it is who it claims to be in the address bar.
    • Note that this may not mean that it passes a test of its identity that you really want. You could be in an enterprise with an SSL-interrupting egress filter, as explained above, you could have been convinced fraudulently to accept the site’s certificate, or you could have installed an inappropriate certificate authority’s root certificate.

If you’re the sort of person who clicks through browser warnings, all you’ve managed to confirm is that your communication is encrypted, and the site you’ve connected to is trying to convince you it is secure. Note that this is exactly what a fraudulent site will try to do. The padlock isn’t everything.

Then think about where your secret information goes. If you’re like a lot of users, you’ll be using the same password on every site you connect to, or some variation thereof. Just because the site uses SSL does not mean that you

But at least it’s a start.

If your bank doesn’t use HTTPS when accepting your logon information, it’s a sign that they really aren’t terribly interested in protecting that transaction. Maybe you should ask them why.

Many web sites will use HTTPS on parts of the site, and HTTP on others. Observe what they choose to protect, and what they choose to leave public. Is the publicly-transmitted information truly public? Is it something you want other people in the coffee shop or library to know you’re browsing?

NCSAM/2011–Post 16–FTP is secure

Week 4 of National Cyber Security Awareness Month, and I’m getting into the more advanced topics of secure communications and protocols.

I figured I couldn’t start this topic without something that’s very near and dear to me – the security of FTP.

The good/bad old days

FTP is one of the oldest application protocols for the Internet. You can tell because it has a very low assigned port number (21).

You can also tell, because it actually has two assigned port numbers – 20 for ftp-data and 21 for ftp.

In many ways the old days of the Internet were really good, and in much the same ways, those days were bad. From a security perspective, for instance, those days were bad because none of the protocols considered security very much, if at all. Of course, you could look at this as ‘good’ and note that there weren’t really a whole lot of reasons to include security protections. Most of the original users were government, military or academic, and in each of these situations there were pretty good sanctions to use against evil-doers.

The Middle Ages

In the middle ages of the Internet, the security was still missing from many protocols, and people took advantage of them a lot. Additions like SSL were invented, and we are all familiar with using HTTPS on a web site to protect traffic to and from it.

Other protocols were simply shunned, as was the case with FTP, on the basis that no one was interested in updating them – after all, what with the web and all, who needs FTP?

Modern Day

Fast forward to modern day, and we find that FTP has a poor reputation for security. But is it deserved?

In some respects, yes – FTP has had its fair share of security badness in the past. But it’s also had its share of updates.

First, there was RFC 1579, Firewall Friendly FTP. Not much of a security advance, using PASV (passive) mode to open connections, so that it’s the server’s responsibility to be compatible with its firewall.

Then came RFC 2228, FTP Security Extensions, dealing with additions to FTP to manage encrypted and integrity-protected connections for data and control channel. Good, but the only protocol supported is Kerberos, and nobody really uses that on the open Internet.

Next, RFC 2577, which addresses some of the common areas where FTP implementations suffer from security failings – a definite huge step forward, because finally even new FTP implementations could get things right in terms of many of the security issues seen in older versions.

And recently (OK, so it’s six years old this month in RFC form, and has been developed for a few years before then), RFC 4217, on Securing FTP with TLS – applies the usual SSL and TLS network protection layers to FTP, basing it on the work defined in RFC 2228.

Are we done yet?

I don’t know, but I’m fairly certain that you will find FTP as it exists today is a far more secure protocol than the one described in, say, the PCI DSS requirements. In fact, if you’ve implemented an RFC 4217 compliant FTP server, enabled its protections, and made sure it implements the suggestions in RFC 2577, you can make a good case to your PCI Auditors (QSA, to use the technical term) that this is an acceptable and secure method of transferring data.

So, what’s holding you back from using FTP in your secure environment now? Anything?

NCSAM/2011–Week 3 summary–names and addresses

So, what did we learn this week?

Your user name is not a secret

Because the operating system doesn’t bother to help you hide user names, and because those user names are used in countless protocols as if they were public information, you’re backing a loser if you want to try and act as if the user name is some kind of secret. There is nothing wrong with having predictable user names. If you need more security, make the passwords longer.

Don't bother renaming the Administrator account

Arguments from other security luminaries notwithstanding, I’m still of the opinion that there really is no benefit to renaming the Administrator account, and it’s going to cause plenty of irritation.

What is a fingerprint?

Despite being used as both a claim and proof of identity, it really needs to be seen as one or the other, along with other biometrics. Also worth noting are the ADA and other considerations that some people just don’t have readable fingerprints, if any at all.

An IP address as an authenticator

Don’t do it. Just don’t do it. Use IP addresses as a filter, to cut out the noise, but don’t rely on that as your only authentication measure, because an IP address doesn’t have sufficient rigour to use as an authenticator.

What's the better firewall - black-hole or RFC compliant?

While it’s tempting to think that a black-hole firewall is the best, because it sits silently not responding to unwanted traffic, there are some times when it’s important to respond to unwanted traffic with a “go away, I’m not talking to you”.

Up next week – Communication Protocols

And do, please, leave comments or email to let me know if you’re enjoying this series, which is published because October is “National Cyber Security Awareness Month”.

NCSAM/2011–Post 15–What’s the better firewall–black-hole, or RFC compliant?

So, given the information we have so far, you should be able to answer the question.

Background info

There are two schools of thought when it comes to how a firewall should behave in some situations.

The one school says that a firewall should ignore all traffic that reaches it, unless it is traffic that should be passed on. This is known as a “black hole”, or “fully stealthed” firewall, because it refuses to send any packets in response to communications it didn’t request.

The other school says that a firewall should respond to unexpected traffic exactly like a router that knows it is unable to reach the host being requested. This is the RFC-compliant firewall, because it looks to the RFC documents to decide what should be done in response to each packet it receives.

First, consider the ‘black hole’

Black hole firewalls are named after the cosmological entity of the same name, because they suck packets in and never send them back out again.

Much like a black hole, however, their existence can be deduced by the simple absence of light passing through them – a range of IPs that should be responding with reset packets (aka “go away, not listening”) to incoming TCP requests, are instead simply ignoring them. If the intent of the firewall was to make the attacker lose interest, you’ve already failed.

And now the RFC compliant firewall

The RFC compliant firewall replies to every unwanted TCP connection request with a RST packet, to indicate that the targeted address is not interested in talking.

To a well-behaved TCP connection partner, this is a request to stop all communications and close the connection, without processing any further data.

Which is fine, except all unexpected traffic at a firewall is an attack, right?

Not every packet is an attack

OK, I really telegraphed that one.

Some unwanted TCP packets are actually very informative, and the RST message sent in response is a useful part of keeping your systems safe.

Let’s suppose someone was able to predict, or otherwise get a hold of, the Initial Sequence Numbers we talked about in yesterday’s post. That someone, an attacker, would be able to spoof, or forge, a connection coming from your system, and connect to a targeted server. Even if they couldn’t see what information was coming back, they might be able to make an attack look like it came from you.

The classic example of “what can I do with a spoofed TCP connection” is that of sending email – spam, usually – from the user of an ISP.

But those packets from the server, that the attacker can’t see (but can guess), do go somewhere – and if the Internet is working properly, they go to your computer, or the firewall sitting in front of your computer.

If your firewall is an RFC-compliant firewall, those packets will be seen by the firewall as unexpected and unwanted – and the firewall will send back a RST packet, demanding that your mail server stop trying to communicate with you. This may be the only indication to the server that anything is amiss. Your RST packet, if it arrives quickly enough, will prevent the spam run being done in your name.

If your firewall is a black-hole router, on the other hand, no RST packets will be sent, and the communication between spoofer and server will continue uninterrupted, unabated, and with you potentially on the hook for emails sent “from your IP address”.

[Note that the same argument can be made for a network where the attacker is a man in the middle who can read and inject packets, but is unable to remove packets from the stream between you and the server.]

Not really settled

As with many of the other issues I’ve been talking about this month, there are differing views on this. I’m generally a fan of following the RFCs, because they’ve usually been arrived at by smart people persuading other smart people to a consensus. I’m sure that you’ll run into people with other opinions on this issue, so please feel free to ask more questions and share different opinions. The really fun topics in computing are those where there are multiple answers that could all be right.

NCSAM/2011–Post 14–An IP address as an authenticator?

So we’ve talked a little about names as claims of identities and passwords as proofs of those identities, continuing on to describe a fingerprint as a reasonable proof of identity, but perhaps not so useful when it has to be a claim and proof of identity at the same time.

So, how about an IP address?

A number of applications offer you the ability to accept or deny connections / requests from outsiders, based on their IP address. Good connections / requests from IP addresses that you know are allowed; bad connections / requests from IP addresses that you don’t know (or from IP addresses that you know are bad) are blocked.

Since this looks rather like an authentication scheme, let’s ask the question:

What is the claim of identity, and what is the proof?

UDP – User Datagram Protocol (or “Unreliable”)

Well, for UDP, the claim appears to be the IP address in the “source address” component.

Is this IP address also a proof of identity?

Since I can forge a UDP datagram for any source IP address, I think that means that it can’t possibly be a proof of identity.

So, for UDP traffic, using the source IP address as any kind of authenticator is clearly a bad idea.

TCP – Transmission Control Protocol

TCP is a little stronger of a case, because there’s a connection to be made, and some protections to be had. One of the protections to be had is that the handshake at the beginning of the connection exchanges a couple of random numbers – known as initial sequence numbers (ISNs) – one from the client, and one from the server. The client then has to send packets with a sequence number starting at the ISN the server sent, and the server has to send packets with a sequence number starting at the ISN the client sent. This means that it’s harder to forge TCP connections than UDP requests, because the client has to see the ISN from the server, and vice versa.

Are these ISNs and subsequent sequence numbers a proof of identity?

Not really, because of a number of factors.

  • In early days of TCP implementations, the ISN was easily guessed by a spoofing client, who didn’t actually have to see their connection handshake. It’s always possible that a flawed TCP implementation in the future will also generate predictable ISNs.
  • The ISN is essentially echoed back, rather than being a secret held by the owner of the identity (IP address) being claimed as the source identity.

All that the ISNs really do is provide a reasonable protection against massive floods of forged connection attempts, by requiring that the client be able to receive and respond to the server’s messages. Some schemes even make use of this further, and don’t create the actual connection object until receiving the first packet with the correct sequence number.

If they aren’t a proof of identity, how can someone spoof me?

There is always the possibility of a third party who can listen to your conversations, and spoof portions of your communications. They can know your ISN, and use it to initiate or continue connections you make to other servers.

This usually requires the attacker to be a “man in the middle” (MITM), and remember, an attacker can do that through a wireless connection.

The only protection you have is if you also are a part of this conversation and can send a quick message along the lines of “stop, don’t trust him, he’s not really me”.

This would be the RST, or reset, message, that aborts a TCP connection, usually because inappropriate (out-of-standard) traffic has been detected. We’ll touch on that more in the next post.

Bottom line: IP address is not an authenticator

So, while it might be a good filter for convenience and traffic reduction, filtering by source IP address is not something you can consider as a security measure, because there is no authentication involved.

Rather like the “TCP evil flag”, it does require that someone be truthful when attacking you, so that you can repel them.

NCSAM/2011–Post 13–What’s a fingerprint–name or password?

I’ve given a couple of arguments about names and why they shouldn’t be treated like passwords now, and because I always like to turn problems into classes of problems to be solved (the “meta-approach”), I figured a long time ago that I should decide what it is that makes a name different from a password, and whether I could apply that to the security world as a whole.

A Name is a Claim

A name is a claim of your identity. “Hello, I’m Bob,” says the badge – but anyone could wear that badge, much to the consternation of any real Bobs who happen to be bobbing around in the background. [Another name for a claim is an “assertion”, but the term “claim” seems to have won out in recent security discussions.]

An identity claim is best when it’s unique – so that claiming to be “Bob” is only useful if no one other than the one, true “Bob” gets to use that name.

A Password is a Proof

Your password, by comparison, is a proof of your identity.

Your password is not unique – which is good, because if you set your password to “frebbot”, and the system told you “that password is not unique”, you’d have a relatively easy time of going through each user on the system to find out who had that password.

Occasionally, systems are proposed where the entry of a password is all that is required to establish an identity – the proof is needed, but the claim is not. This is an example of a truly pathological case of unique passwords, in which you don’t even need to guess whose account has the password that you’ve just been denied.

So, what’s a fingerprint?

I’ll readily admit to enjoying using a fingerprint reader as a convenience device on my home computer. It’s a great way of quickly logging on to a system that no more than about four legitimate users are registered on, so I’m not going to say that fingerprints are unusable in all cases.

However, by the descriptions above, your fingerprint serves as both a claim of an identity, and a proof of that identity.

This alone rings alarm bells, and is a reason not to use it in an environment such as an enterprise, where hundreds, maybe thousands, of people are registered, and where a relatively simple few mistakes in reading a fingerprint could result in being identified as an entirely different user.

Other reasons to distrust fingerprints

There are, of course, further reasons why I would discourage security practitioners in business to avoid fingerprints as a security measure.

  • Hygiene. Fingers are dirty appendages, thrust into ears, mouths and noses on regular occasions, and having a shared device whose designed purpose is to wipe fingers across seems to be a problem, even if you are far from being a germophobe. The only device I have with that purpose in mind is a hanky, and I wash those after each day in which I use them.
  • Bad matches. False negatives are inconvenient, but not greatly so. False positives are disastrous, as you cannot predict who is going to be hit by them. There are a number of high profile cases of individuals who have been misidentified in criminal cases by partial fingerprints, or rotated fingerprints (imagine, a supposedly unique identifier that becomes non-unique when you add a consideration of rotation by right-angles)
  • Revocation. If you ever do find two people whose fingers match, you can’t replace them with non-matching fingers. OK, so you can, but fewer than a dozen times.
  • Failure. Some individuals don’t register as having fingerprints. As with any biometric, there will be people who can’t use it – whether because they have no fingers, or simply no recognisable fingerprints.
  • Theft. Steal a Mercedes S-class and realise you need a fingerprint to unlock it. OK, so kidnap the owner so that you can steal the car. Then realisation dawns that you don’t need all of the owner. Just the finger.
  • Mathematical rigour – or lack of it. We really don’t know how fingerprints form, and there aren’t sufficiently large studies to back up the use of a fingerprint as an entirely unique identifier. There are cases of mistaken conviction from fingerprint evidence that demonstrate fingerprints can be matched to people who didn’t plant the prints.
  • Scientific rigour – lack of. Addressing the issue of the theft of a finger, some fingerprint readers claim to not be fooled by excised fingers. To make such a claim with any scientific rigour, they would have to have tested a finger several times for low false reject rate while attached, and then tested it for false accept rate once detached. I can’t see anyone volunteering for that study.

NCSAM/2011–Post 12–Don’t bother renaming Administrator

My argument here is much in the same vein as my previous post on choosing random usernames.

I’ve met a number of people who argue that renaming the built-in Windows Administrator account is a great security measure, because an attacker now has to guess the name of the Administrator account as well as its password.

Or they put it a little more scientifically, and say that renaming the Administrator account increases the entropy already present in the password.

If you want more entropy in the password, put more entropy in the password

Seems pretty obvious to me, really.

If your passwords don’t have enough entropy (more or less equivalent to “random” in the everyday sense of the word), add more entropy – use a wider range of characters, or simply make the minimum password length that much longer.

The system works against you

If you make the name of the Administrator account a secret, that’s really no good, because the system works against you. It does absolutely nothing to protect you. A simple call to “NET USER” will list the local users, including the local administrator, and a relatively simple ICACLS command will apply rights to the local administrator – no matter its name – on a file. And then you can list the file’s permissions – again using ICACLS – to see what the name is for that administrator.

The one argument in its favour

There is one argument I accept as moderately valid for renaming the Administrator – now you can go ahead and treat every attempt to use the “Administrator” account as an attack, because none of the valid uses of the renamed-Administrator account will use that user name.

But so many arguments against

So now for some arguments against – unlike the “doesn’t really add entropy” point above, these are areas in which renaming the Administrator account does actual harm:

  • You can’t reuse scripts and applications without having to reconfigure them so as not to use the Administrator name, but your “NotReallyTheAdministrator” account.
    • If that’s even possible for the app you want to use – I know, that would be a bad app, but when’s the last time you went a week without having to use an app with some bad behaviour?
  • You have to supply the new Administrator name to each person who has to use the account. [Re-training]
  • Your single Administrator account should already be treated as if every use is an attack, because individual administrators should have their own account, to allow for auditing and revocation. The Administrator account should be rarely used.
  • You have to change the Administrator account as soon as anyone who knows it leaves (and because anyone can find it out, that’s fairly frequently!)

And my favouritest argument of all:

  • There are very many things, more important than renaming the Administrator account in securing your systems, that you have not yet done, and which will take less time to do than implementing all the infrastructure and operational procedures required to rename your Administrator account and keep it correctly monitored and managed.

NCSAM/2011–Post 11–Your user name is not a secret

It always amuses me when I receive an email where the “From” line reads something like this:

From: mo95213@example.com (Davis McTeague)

Because what this means to me is that some well-meaning security practitioner has decided that giving users random names “adds to the entropy in the password” – meaning that it’s harder to guess the user’s name and their password at the same time, than just guessing the password, because the user name is clear and obvious.

Of course, the email kind of gives it all away.

Lockout policies and the random username

I had one of these usernames at one point in my past career. “us43792”, I think it was. Or “us43972”, or “us42793”. Maybe.

Every Monday morning, I did the same dance, of trying to remember my username. And, because the well-meaning security practitioners had also decided that the “three bad logon requires lockout” policy was a great idea, every Monday, I managed to lock some other user out of his or her account, because instead of getting my password wrong, I’d get my username wrong.

I really felt bad for whoever it was that I was locking out of their account. They probably had a hell of a time every Monday, calling up tech support, and asking to have their account unlocked, and tech support treating them like they were idiots for messing up their password every week.

I suppose I could have simply written down my username, but that was as much against the spirit of the policy on random usernames as it would have been to write down my password. So each Monday, I caused a lockout event to some other person in the company, wasting their time, and that of whoever they called in tech support.

The random username and entropy

While it’s true in some ways that a random username adds entropy (you might think of this as “randomness”) to the whole logon sequence, it’s not lasting entropy, because even when the user changes their password, they aren’t changing their username as well, so that part isn’t getting updated. And as time goes by, a lot of people know the user’s name. Everyone they email, everyone they hand their business card to (which includes every lunch establishment around the neighbourhood), now has that information.

It doesn’t matter any more that the username isn’t predictable, because it’s known by fundamentally everyone.

It’s public information.

The system is working against you

My final point against random usernames is that the whole system – and not just the operating system – is working against you in keeping this entropy secret.

Email messages aren’t the only way in which usernames are exposed. Every time you authenticate to a networked application, although challenge-response techniques allow you to keep your password secure from that application, your username is still passed to that application unaltered. File sharing requests are made using the same sort of technology, meaning that your username is sent there. Many other networking protocols carry the username around, and users themselves have all sorts of outlets for sharing their username, from home directories named after them, to instructions on contacting them through email or messaging.

My username is “alun”

I think that says enough.

NCSAM/2011–Week 2 summary–wireless networking (Wi-Fi)

So, what did we learn this week?

Don't disable SSID broadcast

While it may sound like it helps you secure your network, it doesn’t really do anything of the sort. About the only argument in favour of this feature is that it causes casual users to select a different SSID to connect to when they’re looking to leech free WiFi. Not a security feature, because your SSID is broadcast by every device as it searches to connect to your router.

Don't use WEP or WPA

These encryption protocols are flawed and take seconds to break. WPA2 is the only current strong encryption mode for wireless traffic, and for enterprises, you can look to 802.1x as an alternative.

Beware Rogue Access Points

Whether it’s “HPSetup”, “Free Public Wi-Fi”, “attwifi”, “Starbucks” or a number of other SSIDs, there are people out there who set up their computer to look like a wireless router, and to offer free Internet, in the hope that they can steal your credentials, your traffic, your transactions, your money. Make sure you connect to the right access point for the environment you’re in, and take other measures to protect yourself.

Use a VPN

Connect back home to your own VPN. Ask if your ISP has a VPN you can connect through when you don’t trust the local network.

WiFi is MITM Central

Although we used to say that the Internet was somewhat safe – even if not secured – that isn’t true when the medium you connect over is a public, broadcast and interceptable signal such is Wi-Fi. On a wireless network, everyone can read your packets, everyone can write packets pretending to be from you, and anyone can pretend to be the local Wireless Access Point (WAP).

Up next week: Names and Addresses

And do, please, leave comments or email to let me know if you’re enjoying this series, which is published because October is “National Cyber Security Awareness Month”.

NCSAM/2011–Post 10–WiFi is MITM central

So, why all the fuss about securing Wi-Fi?

And what’s this “MITM” you talk about in the title of this post?

MITM is a common abbreviation for “Man In The Middle”, a type of computer security attack, in which the attacker sits between the two ends of a conversation. As you can imagine, if you call your bank, and there’s someone in between you and your bank, they can pretend at the same time to be both you and the bank.

You

Attacker (in the middle)

Bank

    <Good morning, welcome to Berkley’s Bank
  <Good morning, welcome to Berkley’s Bank  
>Hi, I’d like to transfer $100 from my account into account XYZ    
  >Hi, I’d like to transfer $1000 from my account into account ABC  
    <Sure, please identify yourself.
  <Sure, please identify yourself  
>[Secret code]    
  >[Secret code]  
    <Thanks, it’s a pleasure doing business with you.
  >Likewise.  

So, as you can see, it’s a bad idea to let an attacker get in between you and your bank – or your job, or your home, or anything to which you are communicating where it is important to be sure that you get uninterrupted and unintercepted communication.

In the old days, this was hard

For the longest time, security had an easy out – you could actually tell people “sure, someone could listen into that conversation and/or alter it, but they’d have to be in a position of responsibility, such as the network provider, the telephone company, the bank, etc”. Which was pretty much true, because it was really unlikely that someone could actually steal your communications without already being in the sort of position that allowed them full and trusted access to the sort of information you might want to keep from an attacker.

You already trust the phone company, the ISP, the bank, etc, that you use, so you’re not in a worse position by continuing to trust them.

The wrinkle in all of that is when you are in a situation where you cannot trust the communications medium that you use.

Public – really public – networking

You may think you’re on a public network whenever you use the Internet, and to a limited extent this is true – you can reach other people on the Internet (if they let you), and they can reach you (if you let them).

When you’re using Wi-Fi, however, by definition the medium over which you communicate is a public medium in the truest sense – it is broadcast, as if everyone were bellowing over megaphones. And when your computer receives a message from the coffee shop’s wireless router, inviting it to connect, it has no means of distinguishing that from a similar message sent by the attacker sat at the next table over.

Is an attacker really likely to be sitting in your coffee shop?

It depends – if you were an attacker, would you hang out there? Certainly coffee shops where employees go to talk about secret projects are going to be targets. Is it worth taking that risk, when there are some relatively simple measures you can take to protect yourself?

What about the other places you connect to for wireless Internet and then conduct your business (whether personal or work) – I’ll bet there’s an attacker sitting in range of the airport Wi-Fi, in the library, at the University book store, at the school.

And the attackers have tools that make it dreadfully easy to hijack your traffic if you aren’t taking good measures – such as always connecting to your ‘home’ VPN. Sadly, the attackers don’t even need to be all that bright to intercept your traffic any more, if you aren’t using a VPN.

Are there any other public networks?

There can be – we have certainly seen that some cable TV providers, when they added Internet connectivity as a service, forgot to prevent your traffic from being seen by your neighbours. They should be mostly over that by now, certainly if you have a big name cable provider like Comcast. But if you can’t trust your cable company to provide you with quality TV, you can’t really trust them to have your security in mind when provisioning Internet service.

NCSAM/2011–Post 9–Use a VPN

Not everyone has the option of a VPN (Virtual Private Network), so I’m feeling somewhat naughty even suggesting it.

Where possible, use a VPN

When using a Wi-Fi network, if possible, connect to a secure VPN before doing anything.

Getting a VPN

If you have a Windows Server system, it’s really quite easy setting up a VPN for your domain. You have the choice of IPsec, PPTP, or SSTP – all of which are perfectly adequate. IPsec and PPTP are going to be compatible with the majority of systems, including non-Windows systems, but if you’re using only Windows machines, my favourite is the SSTP (Secure Sockets Tunneling Protocol) VPN, simply because it works through most firewall configurations, as it uses the Secure Universal Firewall Tunneling Protocol, on port 443.

That’s a little geek humour, as 443 is supposed to be for HTTPS – secured web traffic – but is used for all manner of other secured protocols, as firewalls generally allow it to pass through unmolested.

Connecting to your VPN

Most enterprise VPNs come with custom software to connect – but for home VPNs, you generally can use the software built in to your operating system.

On Windows, connecting to a VPN is as simple as creating the connection (which you only do once), and then connecting to it every time you roam from your home network.

For Windows 7, the steps are as follows:

  1. Open the Control Panel’s Network and Sharing Center
    • You can do this either from the Control Panel => Network and Internet => Network and Sharing Center, or from right-clicking the network icon in your system tray, and selecting “Open Network and Sharing Center”.
  2. Click on “Set up a new connection or network”
  3. Choose “Connect to a workplace”; click Next.
  4. If asked about using an existing connection, select “No, create a new connection”, then click Next.
  5. When asked “How do you want to connect”, select “Use my Internet connection (VPN)”.
  6. SNAGHTMLa6f6e81For the Internet address, enter the IP address that you use to reach your home router from the Internet.
    • I like to use a free dynamic DNS service to register a domain name, so that my server can always be reached even when my ISP decides I need to have a new IP address. <sigh>Roll on IPv6!</sigh>
  7. Give it a destination name that means something to you.
  8. If you’re not ready to connect yet, select the “Don’t connect now” option. Click Next.
  9. Supply username and password – this is so that you can log on to the VPN server, and bad guys can’t. Click Create.
  10. You’re done.

For the future

I think it would be appropriate for home router manufacturers and home server operating systems to come with simple configuration options for VPN, to allow users to more safely use even hostile wireless environments.

Let me know what you use for your home VPN.

NCSAM/2011–Post 8–Beware Rogue Access Points

Everywhere we go, it’s tempting to hunt for Wi-Fi service; especially to find free Wi-Fi service.

I do it all the time, and mostly I’m happy to find a local Starbucks or other Wi-Fi provider with which I am familiar.

Every so often, however, I come across unusual sites.

“HPSetup” is one I see commonly, as is “Free Public WiFi”.

Usually, these are benign, but useless. They simply don’t give you the free access to the Internet you’re hoping for.

Sometimes, these and other apparently free public Wi-Fi networks are bait, designed for the hapless user to connect and transact their business over, but in a way that allows an attacker to read and alter that traffic. Imagine if your bank transactions are being read, or your personal emails, or your purchases. Your credit card information can be stolen, and you’d never know it.

So, what’s the advice here?

Fairly simple advice, I’m afraid.

Connect only to those networks that you expect to be in place. In Starbucks, go and visit the area with all the leaflets on Fair Trade Coffee, and read the leaflet on connecting to free Wi-Fi. Make sure you connect only to the correctly-named wireless network. Similar advice works for other free wireless networks – and any that you already pay for, you should already have good instructions for using.

For better security still, make sure that you have a Virtual Private Network (VPN) at home, to which you connect after you have established your connection to the Wi-Fi. This significantly reduces (to almost nothing) the chance that a Wi-Fi attacker on a rogue access point is able to steal your traffic.

You can’t do a better example than DefCon

Finally, on this topic, here’s a list of the open WiFi endpoints (Access Points and Ad-Hoc connections) that were available for use at DefCon. Note that the official networks were called “DefCon” and “DefConSecure”.

List of visible access point(s): 46 item(s) total, 46 item(s) displayed
        BSSID        BSS Type PHY    Signal(dB)    Chnl/freq    SSID
-------------------------------------------------------------------------
02-1A-11-FF-D2-09    Infra     g            -69        6      anarchism
02-1A-11-FB-9A-F0    Infra     g            -53        6      tardisnet
00-15-FF-05-1D-F3    Infra     <unknown>    -56        4      53796e6572436f6d6d
54-9B-12-C1-38-57    Infra     g            -73        5      Verizon SCH-LC11 3857 Secure
00-0B-86-CC-29-61    Infra     g            -61        6      DefConSecure
00-0B-86-CC-29-60    Infra     g            -62        6      DefCon
00-26-CB-79-C2-60    Infra     <unknown>    -67        6      v&ctf (hidden ssid)
02-1A-11-F6-56-26    Infra     g            -76        6      fone
00-15-FF-06-D3-38    Infra     <unknown>    -57        4      (Unnamed Network)
5C-DA-D4-73-66-3A    Infra     g            -73        6      (Unnamed Network)
00-18-84-26-20-E1    Infra     g            -75        5      stgm2
00-21-E8-42-5B-D9    Infra     g            -79        7      Vacalulu
00-14-06-31-4B-50    Infra     g            -76        9      (Unnamed Network)
00-12-CF-8E-6A-BB    Infra     g            -72        10     Pineapple
60-33-4B-E0-2F-A1    Infra     <unknown>    -69        11     (Unnamed Network)
44-A7-CF-4A-CF-83    Infra     g            -81        9      Verizon MiFi2200 CF83 Secure
7C-61-93-10-75-DE    Infra     g            -81        11     n3kt0n
00-21-E8-56-07-DA    Infra     g            -86        11     Verizon MiFi2200 07DA Secure
00-0B-86-CC-33-40    Infra     g            -54        1      DefCon
00-0B-86-C4-0B-20    Infra     g            -62        1      DefCon
00-0B-86-C4-0B-21    Infra     g            -62        1      DefConSecure
02-21-6A-00-FE-9E    Ad hoc    g            -84        1      Roberto
00-0B-86-CC-33-41    Infra     g            -55        1      DefConSecure
C0-C1-C0-F4-5C-F4    Infra     <unknown>    -72        1      netgear
00-14-06-11-4B-50    Infra     g            -69        3      _Travelers WiFi
00-14-06-11-4B-51    Infra     g            -82        3      TravelCity PDQ
00-0B-6C-BD-C1-B4    Infra     g            -87        3      NotYourWifi
38-16-D1-96-F9-88    Infra     g            -75        4      d4s_mobile
CA-E6-51-95-8C-AB    Ad hoc    g            -82        5      allwhitemales
00-24-A5-D7-8D-94    Infra     <unknown>    -79        11     Verizon MiFi A6AD Secure
00-0B-86-C3-FF-00    Ad hoc    g            -78        11     (Unnamed Network)
00-0B-86-C3-FE-C1    Infra     g            -77        11     DefConSecure
00-0B-86-C3-FF-03    Infra     g            -78        11     DefConSecure
90-21-55-0B-11-4E    Infra     g            -75        1      LVPS
00-16-C8-66-82-10    Infra     g            -86        1      Palms-Rooms-Cox
00-03-52-B6-49-10    Infra     g            -88        7      777LasVegasWi-Fi
7C-61-93-9B-35-8A    Infra     g            -79        6      goaway
00-60-B3-07-11-4D    Infra     g            -87        11     Guest Internet Access
00-0B-86-C3-FE-C0    Infra     g            -84        11     DefCon
00-0B-86-C4-0B-80    Infra     g            -78        1      DefCon
00-26-E8-3F-3E-6E    Infra     g            -69        10     Verizon MiFi2200 3E6E Secure
00-0B-6C-C3-04-7B    Infra     g            -87        3      vagabond
00-30-44-10-2D-26    Infra     <unknown>    -87        11     TOOOL-LPV-SEC
00-C0-23-6B-99-81    Infra     g            -88        1      (Unnamed Network)
5C-DA-D4-15-23-D3    Infra     g            -75        6      AndroidAP1259
00-0B-86-C3-FF-02    Infra     g            -79        11     DefCon

NCSAM/2011–Post 7–Don’t use WEP or WPA

When setting up your wireless router at home or at work, there’s a dizzying array of options to choose, and most of them are, quite frankly, set at perfectly adequate defaults when the router leaves the shop, even if you’ve got quite an old router. Or if not, they affect basic functioning, so you’ll be able to tell if you need them anywhere else.

The exceptions to this are the authentication and encryption protocol choices. Each Wi-Fi router is a little different, so I’m only going to talk in the most basic terms, and illustrate from my own router’s settings.

These are the choices offered in my router’s Security Mode:

image

As you can see, I’ve selected “WPA2 Personal”, because this is my home router. This is a synonym for “WPA2 PSK Mode”, where PSK stands for “Pre-Shared Key”. So, every device in my house uses the exact same password – perhaps this is less than ideal, but it’s relatively secure – certainly compared to the other home-targeted options, of WPA2/WPA Mixed Mode, WPA Personal, WEP, or (shudder) Disabled.

So, why not those others?

I’d hope that, by now, “Disabled” seems like a really bad choice, when applied to Security. Please tell me you didn’t even consider that.

WEP – that one sounds like a really good idea, since “WEP” stands for “Wired Equivalent Privacy” (not “Wireless Encryption Protocol”). It sounds like it ought to protect you as much as if you were connecting through a piece of wire. As with many names, however, it describes an aspiration, rather than any guarantee. In fact, WEP has been significantly broken for some years now.

How “broken”?

An attacker can gain full access to service and traffic on a WEP-protected router in a minute or two.

WPA is a significant advance on WEP, but has itself been broken in a few ways that make it a far better idea to stick with WPA2.

Since this is Security Awareness Month, and I’m dealing more with small companies and home users than my usual enterprisey crowd, I’m going to leave it there, and not dig into RADIUS or the WPA2 Enterprise modes. Maybe a later article.

NCSAM/2011–Post 6–Don’t disable SSID broadcast

The check-box is there on every wireless (or Wi-Fi) router I’ve ever seen:

image

Often the implication is that this is some kind of security option. Sometimes, articles in news outlets will even tell you that it is a security option worth setting!

[The SSID – Service Set IDentifier – is essentially the name of your router – or, more precisely, the name of one set of configuration at your wireless router to which you allow computers and other devices to connect]

As with many security options that involve a check-box that sounds like “less secure” versus “more secure”, it’s worth knowing what the two options do.

With SSID Broadcast Enabled

If you enable SSID Broadcast, your wireless router will occasionally broadcast its presence and its name – for instance, mine will clearly tell all computers in range that it is called “texis”.

This invites connections – but only from people who can authenticate to the server over WPA2, using my choice of keying method.

With SSID Broadcast Disabled

If you disable SSID Broadcast, your wireless router will still occasionally broadcast its presence, but not its name. Depending on your operating system, this will result in some form of “Unnamed Network” connection being offered to you – and if you can name it, and provide it with the correct authentication, you can get online to that wireless setup.

So, Disabled means no one knows my router’s name, right?

Well, not really.

First, let’s look at your devices. Most users will want to configure their computers, laptops, or other Wi-Fi-capable devices so that they will automatically connect to their ‘home’ networks. This option, when enabled (and it’s often enabled by default) means that your devices will essentially spend most of their time when not at ‘home’ shouting out the names of the wireless networks they know but can’t see. Instead of one device in a fixed and protected location broadcasting the name of your network, you now have all your devices, while mobile (and in untrusted locations), broadcasting that network name.

Now, let’s look at the router. Wireless traffic is, by its very nature, always a broadcast stream. So, when a device tries to connect to that router, it’s going to send the SSID of the router it wants to talk to. Any attacker looking for your SSID will see this, just as easily as they would if your router was broadcasting it.

It might seem like there’s still an advantage, in that the SSID isn’t being sent out several times a minute, but only when a connection is needed. As with most such suggestions, it turns out that there’s a way for an attacker to get the information they’re after. All the attacker has to do is monitor a little bit of wireless communications between a device and its router, and then the attacker can inject a disconnection (“disassociation frame”) message, which makes the device try and reconnect, in order to read the SSID at any time it wants.

SSID is a name, not a security measure, for your network

Names are not by themselves authenticators, they are identifiers. They are a claim of identity, and not a proof. Never rely on the knowledge or obscurity of a name to protect you. SSID Broadcast is nothing more than the broadcast of a name. It is no more a security measure than hiding your house number would be.

Your protection for your wireless router and its traffic is the authentication and encryption protocol you use – WPA2 is generally the standard to use, or if you are in an enterprise, 802.11x is another means of ensuring that only valid computers and devices are allowed to connect.

NCSAM/2011–Week 1 summary–passwords

So, what did we learn this week?

Write your passwords down

You can remember more complex passwords that way, more different passwords, and ensure that you have a backup in case you forget, or someone needs to handle the password for you in the event of your death or some similar emergency (note, going on vacation is not an emergency!).

Length is better than strength

You can improve your password’s entropy far quicker by adding characters to it – making it longer – than by using an extended set of characters. So take advantage of the concept of a pass phrase, rather than a password. Even if spaces aren’t allowed by your provider, you can simply type a sentence without the spaces.

Don’t share your passwords with other people

Other people should not know your password. Ever. There are other ways to achieve the sort of things you think require you to share your passwords.

Don’t share your passwords with other services

Even if you don’t think about the “rouge admin problem”, there’s always the possibility that the web site or other service you are using is poorly written, and/or it gets hacked, and your password gets exposed. Don’t rush off to change your password on every other site you own – because they already have different passwords, right?

Make your passwords recoverable

The important passwords – those that have unique access to something, so nobody else can get that access without the password – should always be backed up in some way, so that in the event of your demise, or some accident less significant but memory-impairing (most significant accidents cause short to long term memory loss), you, or your loved ones, can recover.

NCSAM/2011–Post 5–Make sure you can recover your passwords

Make sure you can recover your passwords – or that you can recover from a lost password.

Consider what happens if you get run over by a train – and you don’t die. It happens.

You lose your memory of every password you set in the last six months, and you aren’t in any condition anyway to be telling people what they were.

If you have enabled redundant accounts with appropriate access for recovery purposes, those left to deal with your loose ends will be more likely to thank you when you do come around, your servers will be working, your data will be current, and all will be fine.

If you have written down your passwords in a safe place (and told someone responsible where that is), those passwords can be used while you are temporarily absent.

A good friend of mine found this out first hand. I’d rather no one else did.

NCSAM/2011–Post 4–Don’t share your passwords across services

Using the same password on multiple different accounts or services – it’s something that security professionals have decried for years, and it’s something that most policies forbid as well.

Why is this?

Surely it’s easier to remember one password and use it everywhere?

Well, yes, but then your password isn’t just about what’s easy – it’s a protective measure by which you not only assert your identity, but also by which you prevent other people from asserting it for you.

For instance, the old “rogue administrator” problem – so old that it’s often referred to as the “rouge admin”, because so many people can’t spell “rogue”. It’s so old, XKCD has a cartoon about it.

The rouge administrator problem

The theory behind this problem is that you can’t be completely sure that your own administrators are trustworthy – and so you are even less sure that some other website’s administrators are trustworthy. So, it’s a fair bet that some of the sites that you log onto are actually engaged in some nefarious activity, either as a part of the business of the website, or as a personal interest on the part of one of its administrators.

What can they do?

Well, they can intercept your logon information – the user name and password that you have provided – and turn around to use that same information at another site.

What other site?

They can make a pretty good guess. Half the known world appears to access Facebook, Twitter, YouTube, along with any number of blogs, forums, or other locations. So they’ll try your username and password at some of these sites, and maybe get lucky. I’m sure many of us know a ‘friend’ whose account at some site has been ‘taken over’ by a hacker, and this is one of the ways in which that could have happened. [Another is the simple possibility of guessing your password if you didn’t choose a good one]

But there’s an even better site for them to guess at, because if you’re like oh-so-many people, you took the invitation to enter your email address as your username. And then, because it’s an association that’s embedded firmly in your brain, you used the same password creating this account as you use when accessing your email.

So now the only question is which of the several websites you’re logging onto has control of your account this week, as they each fight one another for dominance.

But it doesn’t require a rogue administrator. Sometimes it can just be a matter of really bad website design – combined with your own bad password choice.

Your password got hacked

Yeah, I’m generalising here, but your password probably has been hacked at some point, or at least its hash has been stolen.

Sidebar: a password hash is an obscured version of your password. Kind of like creating mince from meat – you can tell what animal it came from, whether that be chicken, beef or pork, but you can’t actually put it back together to create the animal. So, a hash allows you to confirm that the password being presented by the user is the same as the original password used to create the account, but it does not allow you to turn the hash back into the password easily.

Note that catch-all “easily” – that means there’s a difficult way, right? Sure, and it’s simply the idea that you can try every possible password until you get one that matches the hash. This is called “brute forcing”. There are some shortcuts, and someone will no doubt mention “rainbow tables”, but in many cases, this is little more than having someone actually do much of the brute forcing for you already. This can be made even harder by adding a random number called a “salt” into each password, but then I’m getting into too much of the implementation detail to be interesting.

So, the point is that if you have a good password, the hash of it is pretty darn hard to get the password from. You are mostly protected by your good choice of password.

Of course, that means you’re really not protected if you have a common or short password.

That’s why every time we see a news story of hackers stealing a password database – or often, the database of password hashes – there’s usually a list that comes along of the common passwords that people used at that site.

One relatively recent example is that of the password theft from Gawker. Note that this was a simple database of unhashed passwords. That’s bad website design. But then when you go and look at the list of passwords, you discover that the most common was “123456”, and the second most common was “password”. That’s simply bad password choice.

Protect yourself – choose different passwords

Again, passphrases come to your help here – “password for Cousin Huey’s favourite site” might be a good passphrase, perhaps. Or “I like this site for its crazy cartoon wit”. And writing them down will help you not to forget which password goes with which site.

OK, so that won’t help you if the password database is in plain text – but if that’s the case, you will at least find that only the exposed site’s account is taken over, rather than every other account you own.

More Posts Next page »