Add blake range codes

Blake2s and Blake2b have different initial vectors states for different lengths, this means that for each chosen output length it looks like completely different hash function.

This proposal allocated 64 values for Blake2b and 32 values for Blake2s as those are the ranges the outputs can be chosen from.

The codes will require 3 bytes to write down as varints.
This commit is contained in:
Jakub Sztandera 2016-12-09 13:37:49 +01:00 committed by GitHub
parent d6e0ec1b94
commit bf8824efbc

View File

@ -46,8 +46,8 @@ keccak-256, , 0x1B
keccak-384, , 0x1C
keccak-512, , 0x1D
,, Note: keccak has variable output length. The number specifies the core length
blake2b, , 0x40
blake2s, , 0x41
blake2b-lenX, , 0xb201-0xb240
blake2s-lenX, , 0xb241-0xb260
reserved for apps, appl specific range, 0x4000-0x40f0
multiaddrs,,

1 codec description code
46 reserved for apps appl specific range 0x4000-0x40f0
47 multiaddrs
48 ip4 0x04
49 ip6 0x29
50 tcp 0x06
51 udp 0x0111
52 dccp 0x21
53 sctp 0x84