diff options
Diffstat (limited to 'src/lib/libssl/test/tx509.com')
-rw-r--r-- | src/lib/libssl/test/tx509.com | 83 |
1 files changed, 83 insertions, 0 deletions
diff --git a/src/lib/libssl/test/tx509.com b/src/lib/libssl/test/tx509.com new file mode 100644 index 0000000000..7b2592f773 --- /dev/null +++ b/src/lib/libssl/test/tx509.com | |||
@@ -0,0 +1,83 @@ | |||
1 | $! TX509.COM -- Tests x509 certificates | ||
2 | $ | ||
3 | $ __arch := VAX | ||
4 | $ if f$getsyi("cpu") .ge. 128 then __arch := AXP | ||
5 | $ exe_dir := sys$disk:[-.'__arch'.exe.apps] | ||
6 | $ | ||
7 | $ cmd := mcr 'exe_dir'openssl x509 | ||
8 | $ | ||
9 | $ t := testx509.pem | ||
10 | $ if p1 .nes. "" then t = p1 | ||
11 | $ | ||
12 | $ write sys$output "testing X509 conversions" | ||
13 | $ if f$search("fff.*") .nes "" then delete fff.*;* | ||
14 | $ if f$search("ff.*") .nes "" then delete ff.*;* | ||
15 | $ if f$search("f.*") .nes "" then delete f.*;* | ||
16 | $ convert/fdl=sys$input: 't' fff.p | ||
17 | RECORD | ||
18 | FORMAT STREAM_LF | ||
19 | $ | ||
20 | $ write sys$output "p -> d" | ||
21 | $ 'cmd' -in fff.p -inform p -outform d -out f.d | ||
22 | $ if $severity .ne. 1 then exit 3 | ||
23 | $ write sys$output "p -> n" | ||
24 | $ 'cmd' -in fff.p -inform p -outform n -out f.n | ||
25 | $ if $severity .ne. 1 then exit 3 | ||
26 | $ write sys$output "p -> p" | ||
27 | $ 'cmd' -in fff.p -inform p -outform p -out f.p | ||
28 | $ if $severity .ne. 1 then exit 3 | ||
29 | $ | ||
30 | $ write sys$output "d -> d" | ||
31 | $ 'cmd' -in f.d -inform d -outform d -out ff.d1 | ||
32 | $ if $severity .ne. 1 then exit 3 | ||
33 | $ write sys$output "n -> d" | ||
34 | $ 'cmd' -in f.n -inform n -outform d -out ff.d2 | ||
35 | $ if $severity .ne. 1 then exit 3 | ||
36 | $ write sys$output "p -> d" | ||
37 | $ 'cmd' -in f.p -inform p -outform d -out ff.d3 | ||
38 | $ if $severity .ne. 1 then exit 3 | ||
39 | $ | ||
40 | $ write sys$output "d -> n" | ||
41 | $ 'cmd' -in f.d -inform d -outform n -out ff.n1 | ||
42 | $ if $severity .ne. 1 then exit 3 | ||
43 | $ write sys$output "n -> n" | ||
44 | $ 'cmd' -in f.n -inform n -outform n -out ff.n2 | ||
45 | $ if $severity .ne. 1 then exit 3 | ||
46 | $ write sys$output "p -> n" | ||
47 | $ 'cmd' -in f.p -inform p -outform n -out ff.n3 | ||
48 | $ if $severity .ne. 1 then exit 3 | ||
49 | $ | ||
50 | $ write sys$output "d -> p" | ||
51 | $ 'cmd' -in f.d -inform d -outform p -out ff.p1 | ||
52 | $ if $severity .ne. 1 then exit 3 | ||
53 | $ write sys$output "n -> p" | ||
54 | $ 'cmd' -in f.n -inform n -outform p -out ff.p2 | ||
55 | $ if $severity .ne. 1 then exit 3 | ||
56 | $ write sys$output "p -> p" | ||
57 | $ 'cmd' -in f.p -inform p -outform p -out ff.p3 | ||
58 | $ if $severity .ne. 1 then exit 3 | ||
59 | $ | ||
60 | $ backup/compare fff.p f.p | ||
61 | $ if $severity .ne. 1 then exit 3 | ||
62 | $ backup/compare fff.p ff.p1 | ||
63 | $ if $severity .ne. 1 then exit 3 | ||
64 | $ backup/compare fff.p ff.p2 | ||
65 | $ if $severity .ne. 1 then exit 3 | ||
66 | $ backup/compare fff.p ff.p3 | ||
67 | $ if $severity .ne. 1 then exit 3 | ||
68 | $ | ||
69 | $ backup/compare f.n ff.n1 | ||
70 | $ if $severity .ne. 1 then exit 3 | ||
71 | $ backup/compare f.n ff.n2 | ||
72 | $ if $severity .ne. 1 then exit 3 | ||
73 | $ backup/compare f.n ff.n3 | ||
74 | $ if $severity .ne. 1 then exit 3 | ||
75 | $ | ||
76 | $ backup/compare f.p ff.p1 | ||
77 | $ if $severity .ne. 1 then exit 3 | ||
78 | $ backup/compare f.p ff.p2 | ||
79 | $ if $severity .ne. 1 then exit 3 | ||
80 | $ backup/compare f.p ff.p3 | ||
81 | $ if $severity .ne. 1 then exit 3 | ||
82 | $ | ||
83 | $ delete f.*;*,ff.*;*,fff.*;* | ||