Friday, January 21, 2005

Security through obscurity

Recently, I posted a link to papers by Matt Blaze on master-key systems and safecracking. I mentioned that the locksmithing community was upset over Blaze's work. An acquaintance responded in another forum, defending the locksmiths' position. He writes:
One aspect of locksmithing that was taught to us early on was that in order to maintain the integrity of the industry there was an explicit understanding that the secrets of the trade were to be kept within a limited membership of those who had committed themselves to the trade, or in our case in a closely related trade that had need for this knowledge.

And later:
Smart people can figure all this out [referring to security vulnerabilities in lock systems] if they want. That is not the point that makes locksmiths angry. It has always been understood that pinned locks are only used to keep the honest people honest and the average person from even thinking about attempting something dishonest. Posting trade secrets on the internet for the general public to view is tantamount to the destruction of the prime pillar of lock security - ignorance. We will have to wait and see how much damage this professor's posting will do to the industry. My guess is that it will not be as widely read or utilized as is feared and therefore we can continue to use pinned locks and other reasonable priced security devices for the function they are meant to provide. If not then we are going to have a major problem on our hands and a very expensive retrofit will be needed.

The good professor should be punished and the punishment should be of sufficient magnitude that others who care to be so irresponsible will take notice. This is no triffling matter he has dallied into, it is highly irresponsible of him to post this information.

In information security (and in particular, in cryptography) there is a widely-recognized principle called Kerckhoffs' law, which states that "a cryptosystem should be secure even if everything about the system, except the key, is public knowledge." This can be contrasted with "security by obscurity." The latter is used all the time; the former less so. The locksmithing community has made security through obscurity its watchword. As my acquaintance put it, "Posting trade secrets on the internet for the general public to view is tantamount to the destruction of the prime pillar of lock security - ignorance." This is correct. However, he would lay responsibilty for this act on Blaze, when the problem lies with the locksmiths.

First, some general arguments for the superiority of openness in security over obscurity. Another way of phrasing the principle is to say that every secret which must remain a secret is a potential point of failure. Security through obscurity introduces new and unnecessary secrets, thus introducing more points of failure. Further, these points of failure are typically such that the system will fail poorly if they are exploited. The example in wikipedia is leaving a key under your doormat when you go on vacation. If an attacker looks under the doormat, your security system fails completely. The attacker has unfettered access to your home. Once a secret has been discovered, it never again becomes a secret under normal conditions. Failing well is one of the cardinal virtues of security systems (since no system is impenetrabl). Finally, obscurity prevents consumers from making intelligent security decisions.

In the case of locks, it is relatively easy for any interested party to acquire a copy of any particular lock system they want to study. The potential attacker can waltz into Home Depot and waltz out with any number of locks to pick apart at his or her leisure. This means that obscurity will inevitably fail, since the attacker has as much time as needed to plumb the depths of the system for weaknesses. The situation is analogous to DVD encryption. DVDs are encrypted, because DVD manufacturers want to prevent people from pirating DVDs. We all know how well that worked. The problem is that DVD players need to be able to decrypt the DVDs, and so the erstwhile pirates have some 4-odd gigabytes of ciphertext (the encrypted DVD) and the complete plaintext (the unencrypted bitsream coming from the player). In fact, they have several chosen-ciphertexts of similar sizes, each with complete plaintexts. In this scenario, the DVD manufacturers opted to simply hide the algorithm and hope for the best. They would have been better served by using a secure algorithm, which was publicly known. As it happens, DVDs use Content Scrambling System, which is not particularly secure. In much the same way, lock manufacturers rely on the ignorance of the populace to hide their vulnerabilities. This is a mistake.

Suppose I am a security consumer. I want to secure my house against unwanted intruders. Locks will be a fundamental part of my security system. I want to know that my locks are secure. In the current environment, I need to be either a skilled locksmith or a lock enthusiast in order to make considered judgments about security. Blaze's papers make the relevant facts publicly accessible. This means that I can better choose secure locks and safes. In fact, once this information is made public, everyone can make better security decisions, and so security can improve for everyone. Certainly, it would be expensive to replace the crappy locks which lock manufacturers have been selling with decent locks. However, this is due to the lock manufacturer's reliance on a discredited security model, not due to Blaze's efforts to reveal the truth.