Beyond the KRACK attack: a look at the standardisation of security protocols

The KRACK attack has given a blow to the WPA2 protocol, which secures the connection between clients and WiFi access points. We want to give some insights into how this happened and how to prevent it from happening again in the future.

How bad is the attack?

Despite the vulnerability being quite critical, we need to put it in perspective. The attack requires the presence of the adversary and cannot be exploited remotely. In principle, one should always use an end-to-end secure channel (e.g. HTTPS) for any connection, as WPA2 provides no security beyond the access point. So, when properly using TLS, you should be fine. However, even with end-to-end security you will still leak information (e.g. IP addresses of the servers you connect to) to an attacker that breaks WPA2.

How could this happen?

The lack of unambiguous client and server state machines (and hence state diagrams) in the protocol standard is the root cause of this vulnerability. Such an underspecification and lack of formalism makes it hard for the security community to scrutinize standards and leaves a lot of room for interpretation to the developers, leading to different implementation behaviour.

We have already complained on this issue before (check under ‘the ugly’), in the case of TLS. TLS lacks a clear state diagram since long and relies solely on vague, informal textual descriptions spread throughout the standard. Often the authors of networking standards tend to focus on specifying the format of network messages. For the behaviour of the parties you typically only see textual descriptions, without any formal specification of steps to be executed.

Do we need a WPA3?

We do need a WPA3, contrary to Mathy’s statement, which focuses only on fixing the KRACK attack.

WPA2 is already quite old (2004) and does not meet some of the most common security criteria. Besides a state diagram, it especially lacks forward secrecy. Forward secrecy guarantees that even when a key leaks, past communications cannot be decrypted. TLS has had forward secrecy as a design goal since long before WPA2 came along and is moving firmly towards making forward secrecy mandatory.

If we want to move security forwards, it’s time to start working on new standards that do take into account both technical and editorial insights into how to properly formulate a standard. A standard takes many years to develop, so we better start sooner than later.

The future of security protocol standards

It’s time to put forward some of our lessons for future security protocol standards development:

  1. Every security standard should start from a clear description of the (security) goals that the protocol wants to achieve and which assumptions it relies on. This allows the security community to properly check the protocol. Without goals and assumptions, the community can only offer educated guesses on security. Before starting the actual development of the standard, the goals should be clearly fixed to avoid constant fights between stakeholders.
  2. A standard needs a solid development process, that provides a long review period (> 6 months) for the proposed standard, without constant changes being made during the review. One needs to create the right environment for people to get involved in the evaluation.
  3. Think about the implementer. Someone will implement the standard without ever being involved in the development of the standard. So whatever is written down needs to be clear and unambiguous to avoid developers from making interpretations. This means having clear state machines, algorithmic descriptions of entity behaviour and limiting the number of options.
  4. Make the standard future proof and dare to throw away backward compatibility. A system that is broken should not be in a standard anymore and one should not care about how to fall back to it.
  5. Don’t let the standard rot away. It takes maintenance and updating to keep up to par with developments in security research. The goal should be to have a new version at least every ten years. If there are no improvements to be made, the standard has probably become obsolete.

About the authors

Dr. Jens Hermans and Dr. Roel Peeters are post-doctoral researchers at COSIC and the founders of nextAuth. Both have obtained a PhD in cryptographic protocol development and acquired extensive experience in designing, breaking, specifying and implementing cryptographic protocols. Furthermore, Jens Hermans is the current editor of three standards on entity authentication: ISO/IEC 9798-2, 9798-3 and 9798-5.