Diff

Differences From Artifact [e263a6e534]:

To Artifact [e069950966]:


1
2
3
4
5
6
7
8
9

10
11
12
13
14
15
16
1
2
3
4
5
6
7
8

9
10
11
12
13
14
15
16








-
+







#
# Test Vectors
#

#
# Create test case and output to test file
#
proc do_test {group tail file_num tc digest params} {
    array set config [list Msg "" Repeat 1]
    array set config [list Msg "" Repeat 1 Length ""]
    array set config $params

    # Test info
    set line [format "tcltest::test %s-%d.%d {%s}" $group $file_num $tc $tail]
    append line " \\\n\t"

    # Test constraints
31
32
33
34
35
36
37
38






39
40

41
42
43
44
45
46
47
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45

46
47
48
49
50
51
52
53








+
+
+
+
+
+

-
+








    if {$is_hex} {
	append line [format {-setup {set data [binary decode hex %s]}} $data]
    } else {
	append line [format {-setup {set data %s}} $data]
    }
    append line " \\\n\t"

    if {$config(Length) ne ""} {
	set opts [format " -length %d" $config(Length)]
    } else {
	set opts ""
    }

    # Test body
    append line [format {-body {tls::digest -digest %s -data $data}} $digest]
    append line [format {-body {tls::digest -digest %s -data $data%s}} $digest $opts]
    append line " \\\n\t"

    # Test cleanup

    # Test result
    set result ""
    foreach key [list MD Mac Output] {