-
Notifications
You must be signed in to change notification settings - Fork 257
/
Copy pathsignaturealgorithm.go
41 lines (36 loc) · 1.24 KB
/
signaturealgorithm.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
package dicttls
// Note: values in this file was used in TLS 1.2's signature_algorithms extension
// in combination with the values in hashalgorithm.go.
// signature_algorithms extension in TLS 1.3 uses values in signaturescheme.go
// source: https://www.iana.org/assignments/tls-parameters/tls-parameters.xhtml#tls-parameters-16
// last updated: March 2023
const (
SigAlg_anonymous uint8 = 0 // deprecated in TLS 1.3
SigAlg_rsa uint8 = 1
SigAlg_dsa uint8 = 2 // deprecated in TLS 1.3
SigAlg_ecdsa uint8 = 3
SigAlg_ed25519 uint8 = 7
SigAlg_ed448 uint8 = 8
SigAlg_gostr34102012_256 uint8 = 64 // value changed in TLS 1.3, to 0x0709-0x070C
SigAlg_gostr34102012_512 uint8 = 65 // value changed in TLS 1.3, to 0x070D-0x070F
)
var DictSignatureAlgorithmValueIndexed = map[uint8]string{
0: "anonymous",
1: "rsa",
2: "dsa",
3: "ecdsa",
7: "ed25519",
8: "ed448",
64: "gostr34102012_256",
65: "gostr34102012_512",
}
var DictSignatureAlgorithmNameIndexed = map[string]uint8{
"anonymous": 0,
"rsa": 1,
"dsa": 2,
"ecdsa": 3,
"ed25519": 7,
"ed448": 8,
"gostr34102012_256": 64,
"gostr34102012_512": 65,
}