One way to avoid the mess around Certification Authorities (who do you trust to check that a certificate is indeed correct for a given website?) would be to let the end user systematically check the fingerprint of the certificate himself. This is at least the model used by PGP/GPG when you verify the fingerprint of a public key before signing it with your own key. One could imagine a simple way so that anybody can easily check such a fingerprint.

Of course, the most obvious (and currently only) way is to check letter by letter the fingerprint. But if the fingerprint is a bit long, it becomes quickly boring and error-prone.

Another approach would be to show the fingerprint in a representation which is visually explicit and strongly tied to the value of the fingerprint. In other words, represent the fingerprint as a picture so that it is easy to compare two fingerprints.

For displayed characters, one could play on:

  • their sizes;
  • their colours;
  • their shapes.

For example, suppose we want to represent the fingerprint D3:10:0F:7A:F6:C5:94:0B:15:D5:65:8B:78:6D:0A:7C:EE:45:EB:6B.

We could:

  • Group each octet in a group of three and associate to them a web colour. For example, D3:10:0F is associated to the web colour #D3100F;
  • Take each letter and represent them with a size proportional to the value of the letter: 0 is 100%, 1 is 110%, ..., F is 250%.

For the above fingerprint, we would have following result (the fingerprint is patted with zeros to have a multiple of three octets):

D 3 1 1 0 F
7 A F 6 C 5
9 4 0 B 1 5
D 5 6 5 8 B
7 8 6 D 0 A
7 C E E 4 5
E B 6 B 0 0

I seems to me that with such a visual representation, it is easier to check that two fingerprints are identical. This visual clue could be displayed next to an HTTPS URL, for example in a pop-up. The user would have to compare this visual fingerprint with the original one given to him, for example on a business card or in an email.

One left point is how secure is such a visual representation? In other words, is it possible to make too fingerprints that are visually similar but have a different value?

The lower bits of a group of three octets might be the easier to change. For example, the colour of D3:10:0E is very close to D3:10:0F, the shape of E is close to F and the size is nearly identical. One approach to solve that issue would be, for one dimension of the visual representation, e.g. the size of characters, to inverse the 4 bits. For example, F would stay F but E would become 7, thus the size of the last character would not be 240% but 170%. Graphically, we would have (notice that the colours appear visually the same even if their values are different):

D 3 1 1 0 F
D 3 1 1 0 E

The result is not entirely convincing. A more elaborate scheme might be necessary, so that colours and shapes change a lot if a single character is modified in the fingerprint. That's said, as the visual representation is directly tied to the value of the fingerprint, which is itself computed with a cryptographic hash or similarly suited method, it might be quite difficult to produce a wrong certificate with a visual fingerprint close to representation of the correct certificate.

Another issue is that some people are visually impaired, for example might not distinguish certain colours. But in that case, the textual value of the fingerprint might be more useful for such people.

I have not made a detailed analysis of the proposed scheme and more attacks might be possible. This post is just made to give the general idea. ;-) What do you think of it?

PS: As usual, it appears that other people had the same idea before me. :-) Like using fractal images to represent a fingerprint or the visual ASCII representation of an SSH fingerprint that is used in recent SSH 5.1.