I hate asking for a reference, but I'm having a hard time finding this.

The iana page on tls extensions just links me back to rfc5246 where it only has the following values:

enum {
    none(0), md5(1), sha1(2), sha224(3), sha256(4), sha384(5),
    sha512(6), (255)
} HashAlgorithm;

enum { anonymous(0), rsa(1), dsa(2), ecdsa(3), (255) }

I've got a client hello that I'm looking at here with the following signature and hash extension:

000d 0014 0012 0403 0804 0401 0503 0805 0501 0806 0601 0201

Where can I find a reference for what these refer to?

  • 1
    $\begingroup$ Can you please ASN.1 decode the values you posted? $\endgroup$ – SEJPM Jun 15 '18 at 9:07
  • 1
    $\begingroup$ @SEJPM It's not ASN.1! $\endgroup$ – Thomas Pornin Jun 15 '18 at 11:27

Some of these values are sort-of defined in drafts that should become RFC at some point. For instance, the latest (as of today) draft of TLS 1.3 lists in section 4.2.3 the values 0x0804, 0x0805 and 0x0806 (these designate RSA signatures with the new-style "PSS" padding, used with SHA-256, SHA-384 and SHA-512, respectively).

The "000d 0014 0012" values are actually the header of the extension:

  • 000d is the identifier for the "signature algorithm" extension.
  • 0014 is the extension contents length (in bytes).
  • 0012 is the length of the list of values in the extension (because the extension is defined as a list of values, and lists in TLS message encodings take an explicit header that gives the list length in bytes).

Note that while the 16-bit values were initially designed as two successive bytes (first for the hash algorithm, second for the signature algorithm), they now tend to be defined as full 16-bit values that cover the whole signature algorithm with no specific sub-structure.

| improve this answer | |
  • $\begingroup$ This is exactly what I was looking for. Thanks for your help. $\endgroup$ – martin Jun 15 '18 at 14:31

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.