diff options
author | miod <> | 2014-04-13 15:25:35 +0000 |
---|---|---|
committer | miod <> | 2014-04-13 15:25:35 +0000 |
commit | 1fb5cf10c3e597dbb1ecc4dd423bba727fd7721a (patch) | |
tree | 74f4ff344980894c7c9ceeab9b81176ac7572566 /src/lib/libssl/test/tests.com | |
parent | 92349eb53934e1b3e9b807e603d45417a6320d21 (diff) | |
download | openbsd-1fb5cf10c3e597dbb1ecc4dd423bba727fd7721a.tar.gz openbsd-1fb5cf10c3e597dbb1ecc4dd423bba727fd7721a.tar.bz2 openbsd-1fb5cf10c3e597dbb1ecc4dd423bba727fd7721a.zip |
Merge conflicts; remove MacOS, Netware, OS/2, VMS and Windows build machinery.
Diffstat (limited to 'src/lib/libssl/test/tests.com')
-rw-r--r-- | src/lib/libssl/test/tests.com | 375 |
1 files changed, 0 insertions, 375 deletions
diff --git a/src/lib/libssl/test/tests.com b/src/lib/libssl/test/tests.com deleted file mode 100644 index a840d5078f..0000000000 --- a/src/lib/libssl/test/tests.com +++ /dev/null | |||
@@ -1,375 +0,0 @@ | |||
1 | $! TESTS.COM -- Performs the necessary tests | ||
2 | $! | ||
3 | $! P1 tests to be performed. Empty means all. | ||
4 | $! P2 Pointer size: "", "32", or "64". | ||
5 | $! | ||
6 | $! Announce/identify. | ||
7 | $! | ||
8 | $ proc = f$environment( "procedure") | ||
9 | $ write sys$output "@@@ "+ - | ||
10 | f$parse( proc, , , "name")+ f$parse( proc, , , "type") | ||
11 | $! | ||
12 | $ __proc = f$element(0,";",f$environment("procedure")) | ||
13 | $ __here = f$parse(f$parse("A.;",__proc) - "A.;","[]A.;") - "A.;" | ||
14 | $ __save_default = f$environment("default") | ||
15 | $ __arch = "VAX" | ||
16 | $ if f$getsyi("cpu") .ge. 128 then - | ||
17 | __arch = f$edit( f$getsyi( "ARCH_NAME"), "UPCASE") | ||
18 | $ if __arch .eqs. "" then __arch = "UNK" | ||
19 | $! | ||
20 | $ __archd = __arch | ||
21 | $ pointer_size = "" | ||
22 | $ if (p2 .eq. "64") | ||
23 | $ then | ||
24 | $ pointer_size = "64" | ||
25 | $ __archd = __arch+ "_64" | ||
26 | $ endif | ||
27 | $! | ||
28 | $ texe_dir := sys$disk:[-.'__archd'.exe.test] | ||
29 | $ exe_dir := sys$disk:[-.'__archd'.exe.apps] | ||
30 | $ | ||
31 | $ set default '__here' | ||
32 | $ | ||
33 | $ ROOT = F$PARSE("sys$disk:[-]A.;0",,,,"SYNTAX_ONLY,NO_CONCEAL") - "A.;0" | ||
34 | $ ROOT_DEV = F$PARSE(ROOT,,,"DEVICE","SYNTAX_ONLY") | ||
35 | $ ROOT_DIR = F$PARSE(ROOT,,,"DIRECTORY","SYNTAX_ONLY") - | ||
36 | - ".][000000" - "[000000." - "][" - "[" - "]" | ||
37 | $ ROOT = ROOT_DEV + "[" + ROOT_DIR | ||
38 | $ DEFINE/NOLOG SSLROOT 'ROOT'.APPS.] /TRANS=CONC | ||
39 | $ openssl_conf := sslroot:[000000]openssl-vms.cnf | ||
40 | $ | ||
41 | $ on control_y then goto exit | ||
42 | $ on error then goto exit | ||
43 | $ | ||
44 | $ if p1 .nes. "" | ||
45 | $ then | ||
46 | $ tests = p1 | ||
47 | $ else | ||
48 | $! NOTE: This list reflects the list of dependencies following the | ||
49 | $! "alltests" target in Makefile. This should make it easy to see | ||
50 | $! if there's a difference that needs to be taken care of. | ||
51 | $ tests := - | ||
52 | test_des,test_idea,test_sha,test_md4,test_md5,test_hmac,- | ||
53 | test_md2,test_mdc2,test_wp,- | ||
54 | test_rmd,test_rc2,test_rc4,test_rc5,test_bf,test_cast,test_aes,- | ||
55 | test_rand,test_bn,test_ec,test_ecdsa,test_ecdh,- | ||
56 | test_enc,test_x509,test_rsa,test_crl,test_sid,- | ||
57 | test_gen,test_req,test_pkcs7,test_verify,test_dh,test_dsa,- | ||
58 | test_ss,test_ca,test_engine,test_evp,test_ssl,test_tsa,test_ige,- | ||
59 | test_jpake,test_srp,test_cms | ||
60 | $ endif | ||
61 | $ tests = f$edit(tests,"COLLAPSE") | ||
62 | $ | ||
63 | $ BNTEST := bntest | ||
64 | $ ECTEST := ectest | ||
65 | $ ECDSATEST := ecdsatest | ||
66 | $ ECDHTEST := ecdhtest | ||
67 | $ EXPTEST := exptest | ||
68 | $ IDEATEST := ideatest | ||
69 | $ SHATEST := shatest | ||
70 | $ SHA1TEST := sha1test | ||
71 | $ SHA256TEST := sha256t | ||
72 | $ SHA512TEST := sha512t | ||
73 | $ MDC2TEST := mdc2test | ||
74 | $ RMDTEST := rmdtest | ||
75 | $ MD2TEST := md2test | ||
76 | $ MD4TEST := md4test | ||
77 | $ MD5TEST := md5test | ||
78 | $ HMACTEST := hmactest | ||
79 | $ WPTEST := wp_test | ||
80 | $ RC2TEST := rc2test | ||
81 | $ RC4TEST := rc4test | ||
82 | $ RC5TEST := rc5test | ||
83 | $ BFTEST := bftest | ||
84 | $ CASTTEST := casttest | ||
85 | $ DESTEST := destest | ||
86 | $ RANDTEST := randtest | ||
87 | $ DHTEST := dhtest | ||
88 | $ DSATEST := dsatest | ||
89 | $ METHTEST := methtest | ||
90 | $ SSLTEST := ssltest | ||
91 | $ RSATEST := rsa_test | ||
92 | $ ENGINETEST := enginetest | ||
93 | $ EVPTEST := evp_test | ||
94 | $ IGETEST := igetest | ||
95 | $ JPAKETEST := jpaketest | ||
96 | $ SRPTEST := srptest | ||
97 | $ ASN1TEST := asn1test | ||
98 | $! | ||
99 | $ tests_i = 0 | ||
100 | $ loop_tests: | ||
101 | $ tests_e = f$element(tests_i,",",tests) | ||
102 | $ tests_i = tests_i + 1 | ||
103 | $ if tests_e .eqs. "," then goto exit | ||
104 | $ write sys$output "---> ''tests_e'" | ||
105 | $ gosub 'tests_e' | ||
106 | $ goto loop_tests | ||
107 | $ | ||
108 | $ test_evp: | ||
109 | $ mcr 'texe_dir''evptest' 'ROOT'.CRYPTO.EVP]evptests.txt | ||
110 | $ return | ||
111 | $ test_des: | ||
112 | $ mcr 'texe_dir''destest' | ||
113 | $ return | ||
114 | $ test_idea: | ||
115 | $ mcr 'texe_dir''ideatest' | ||
116 | $ return | ||
117 | $ test_sha: | ||
118 | $ mcr 'texe_dir''shatest' | ||
119 | $ mcr 'texe_dir''sha1test' | ||
120 | $ mcr 'texe_dir''sha256test' | ||
121 | $ mcr 'texe_dir''sha512test' | ||
122 | $ return | ||
123 | $ test_mdc2: | ||
124 | $ mcr 'texe_dir''mdc2test' | ||
125 | $ return | ||
126 | $ test_md5: | ||
127 | $ mcr 'texe_dir''md5test' | ||
128 | $ return | ||
129 | $ test_md4: | ||
130 | $ mcr 'texe_dir''md4test' | ||
131 | $ return | ||
132 | $ test_hmac: | ||
133 | $ mcr 'texe_dir''hmactest' | ||
134 | $ return | ||
135 | $ test_wp: | ||
136 | $ mcr 'texe_dir''wptest' | ||
137 | $ return | ||
138 | $ test_md2: | ||
139 | $ mcr 'texe_dir''md2test' | ||
140 | $ return | ||
141 | $ test_rmd: | ||
142 | $ mcr 'texe_dir''rmdtest' | ||
143 | $ return | ||
144 | $ test_bf: | ||
145 | $ mcr 'texe_dir''bftest' | ||
146 | $ return | ||
147 | $ test_cast: | ||
148 | $ mcr 'texe_dir''casttest' | ||
149 | $ return | ||
150 | $ test_rc2: | ||
151 | $ mcr 'texe_dir''rc2test' | ||
152 | $ return | ||
153 | $ test_rc4: | ||
154 | $ mcr 'texe_dir''rc4test' | ||
155 | $ return | ||
156 | $ test_rc5: | ||
157 | $ mcr 'texe_dir''rc5test' | ||
158 | $ return | ||
159 | $ test_rand: | ||
160 | $ mcr 'texe_dir''randtest' | ||
161 | $ return | ||
162 | $ test_enc: | ||
163 | $ @testenc.com 'pointer_size' | ||
164 | $ return | ||
165 | $ test_x509: | ||
166 | $ set noon | ||
167 | $ define sys$error test_x509.err | ||
168 | $ write sys$output "test normal x509v1 certificate" | ||
169 | $ @tx509.com "" 'pointer_size' | ||
170 | $ write sys$output "test first x509v3 certificate" | ||
171 | $ @tx509.com v3-cert1.pem 'pointer_size' | ||
172 | $ write sys$output "test second x509v3 certificate" | ||
173 | $ @tx509.com v3-cert2.pem 'pointer_size' | ||
174 | $ deassign sys$error | ||
175 | $ set on | ||
176 | $ return | ||
177 | $ test_rsa: | ||
178 | $ set noon | ||
179 | $ define sys$error test_rsa.err | ||
180 | $ @trsa.com "" 'pointer_size' | ||
181 | $ deassign sys$error | ||
182 | $ mcr 'texe_dir''rsatest' | ||
183 | $ set on | ||
184 | $ return | ||
185 | $ test_crl: | ||
186 | $ set noon | ||
187 | $ define sys$error test_crl.err | ||
188 | $ @tcrl.com "" 'pointer_size' | ||
189 | $ deassign sys$error | ||
190 | $ set on | ||
191 | $ return | ||
192 | $ test_sid: | ||
193 | $ set noon | ||
194 | $ define sys$error test_sid.err | ||
195 | $ @tsid.com "" 'pointer_size' | ||
196 | $ deassign sys$error | ||
197 | $ set on | ||
198 | $ return | ||
199 | $ test_req: | ||
200 | $ set noon | ||
201 | $ define sys$error test_req.err | ||
202 | $ @treq.com "" 'pointer_size' | ||
203 | $ @treq.com testreq2.pem 'pointer_size' | ||
204 | $ deassign sys$error | ||
205 | $ set on | ||
206 | $ return | ||
207 | $ test_pkcs7: | ||
208 | $ set noon | ||
209 | $ define sys$error test_pkcs7.err | ||
210 | $ @tpkcs7.com "" 'pointer_size' | ||
211 | $ @tpkcs7d.com "" 'pointer_size' | ||
212 | $ deassign sys$error | ||
213 | $ set on | ||
214 | $ return | ||
215 | $ test_bn: | ||
216 | $ write sys$output - | ||
217 | "starting big number library test, could take a while..." | ||
218 | $ set noon | ||
219 | $ define sys$error test_bn.err | ||
220 | $ define sys$output test_bn.out | ||
221 | $ @ bctest.com | ||
222 | $ status = $status | ||
223 | $ deassign sys$error | ||
224 | $ deassign sys$output | ||
225 | $ set on | ||
226 | $ if (status) | ||
227 | $ then | ||
228 | $ create /fdl = sys$input bntest-vms.tmp | ||
229 | FILE | ||
230 | ORGANIZATION sequential | ||
231 | RECORD | ||
232 | FORMAT stream_lf | ||
233 | $ define /user_mode sys$output bntest-vms.tmp | ||
234 | $ mcr 'texe_dir''bntest' | ||
235 | $ define /user_mode sys$input bntest-vms.tmp | ||
236 | $ define /user_mode sys$output bntest-vms.out | ||
237 | $ bc | ||
238 | $ @ bntest.com bntest-vms.out | ||
239 | $ status = $status | ||
240 | $ if (status) | ||
241 | $ then | ||
242 | $ delete bntest-vms.out;* | ||
243 | $ delete bntest-vms.tmp;* | ||
244 | $ endif | ||
245 | $ else | ||
246 | $ create /fdl = sys$input bntest-vms.sh | ||
247 | FILE | ||
248 | ORGANIZATION sequential | ||
249 | RECORD | ||
250 | FORMAT stream_lf | ||
251 | $ open /append bntest_file bntest-vms.sh | ||
252 | $ type /output = bntest_file sys$input: | ||
253 | << __FOO__ sh -c "`sh ./bctest`" | perl -e '$i=0; while (<STDIN>) {if (/^test (.*)/) {print STDERR "\nverify $1";} elsif (!/^0$/) {die "\nFailed! bc: $_";} else {print STDERR "."; $i++;}} print STDERR "\n$i tests passed\n"' | ||
254 | $ define /user_mode sys$output bntest-vms.tmp | ||
255 | $ mcr 'texe_dir''bntest' | ||
256 | $ copy bntest-vms.tmp bntest_file | ||
257 | $ delete bntest-vms.tmp;* | ||
258 | $ type /output = bntest_file sys$input: | ||
259 | __FOO__ | ||
260 | $ close bntest_file | ||
261 | $ write sys$output "-- copy the [.test]bntest-vms.sh and [.test]bctest files to a Unix system and" | ||
262 | $ write sys$output "-- run bntest-vms.sh through sh or bash to verify that the bignum operations" | ||
263 | $ write sys$output "-- went well." | ||
264 | $ write sys$output "" | ||
265 | $ endif | ||
266 | $ write sys$output "test a^b%c implementations" | ||
267 | $ mcr 'texe_dir''exptest' | ||
268 | $ return | ||
269 | $ test_ec: | ||
270 | $ write sys$output "test elliptic curves" | ||
271 | $ mcr 'texe_dir''ectest' | ||
272 | $ return | ||
273 | $ test_ecdsa: | ||
274 | $ write sys$output "test ecdsa" | ||
275 | $ mcr 'texe_dir''ecdsatest' | ||
276 | $ return | ||
277 | $ test_ecdh: | ||
278 | $ write sys$output "test ecdh" | ||
279 | $ mcr 'texe_dir''ecdhtest' | ||
280 | $ return | ||
281 | $ test_verify: | ||
282 | $ write sys$output "The following command should have some OK's and some failures" | ||
283 | $ write sys$output "There are definitly a few expired certificates" | ||
284 | $ @tverify.com 'pointer_size' | ||
285 | $ return | ||
286 | $ test_dh: | ||
287 | $ write sys$output "Generate a set of DH parameters" | ||
288 | $ mcr 'texe_dir''dhtest' | ||
289 | $ return | ||
290 | $ test_dsa: | ||
291 | $ write sys$output "Generate a set of DSA parameters" | ||
292 | $ mcr 'texe_dir''dsatest' | ||
293 | $ return | ||
294 | $ test_gen: | ||
295 | $ write sys$output "Generate and verify a certificate request" | ||
296 | $ @testgen.com 'pointer_size' | ||
297 | $ return | ||
298 | $ maybe_test_ss: | ||
299 | $ testss_RDT = f$cvtime(f$file_attributes("testss.com","RDT")) | ||
300 | $ if f$cvtime(f$file_attributes("keyU.ss","RDT")) .les. testss_RDT then - | ||
301 | goto test_ss | ||
302 | $ if f$cvtime(f$file_attributes("certU.ss","RDT")) .les. testss_RDT then - | ||
303 | goto test_ss | ||
304 | $ if f$cvtime(f$file_attributes("certCA.ss","RDT")) .les. testss_RDT then - | ||
305 | goto test_ss | ||
306 | $ return | ||
307 | $ test_ss: | ||
308 | $ write sys$output "Generate and certify a test certificate" | ||
309 | $ @testss.com 'pointer_size' | ||
310 | $ return | ||
311 | $ test_engine: | ||
312 | $ write sys$output "Manipulate the ENGINE structures" | ||
313 | $ mcr 'texe_dir''enginetest' | ||
314 | $ return | ||
315 | $ test_ssl: | ||
316 | $ write sys$output "test SSL protocol" | ||
317 | $ gosub maybe_test_ss | ||
318 | $ @testssl.com keyU.ss certU.ss certCA.ss 'pointer_size' | ||
319 | $ return | ||
320 | $ test_ca: | ||
321 | $ set noon | ||
322 | $ define /user_mode sys$output test_ca.out | ||
323 | $ mcr 'exe_dir'openssl no-rsa | ||
324 | $ save_severity=$SEVERITY | ||
325 | $ set on | ||
326 | $ if save_severity | ||
327 | $ then | ||
328 | $ write sys$output "skipping CA.com test -- requires RSA" | ||
329 | $ else | ||
330 | $ write sys$output "Generate and certify a test certificate via the 'ca' program" | ||
331 | $ @testca.com 'pointer_size' | ||
332 | $ endif | ||
333 | $ return | ||
334 | $ test_aes: | ||
335 | $! write sys$output "test AES" | ||
336 | $! !mcr 'texe_dir''aestest' | ||
337 | $ return | ||
338 | $ test_tsa: | ||
339 | $ set noon | ||
340 | $ define /user_mode sys$output nla0: | ||
341 | $ mcr 'exe_dir'openssl no-rsa | ||
342 | $ save_severity=$SEVERITY | ||
343 | $ set on | ||
344 | $ if save_severity | ||
345 | $ then | ||
346 | $ write sys$output "skipping testtsa.com test -- requires RSA" | ||
347 | $ else | ||
348 | $ @testtsa.com "" "" "" 'pointer_size' | ||
349 | $ endif | ||
350 | $ return | ||
351 | $ test_ige: | ||
352 | $ write sys$output "Test IGE mode" | ||
353 | $ mcr 'texe_dir''igetest' | ||
354 | $ return | ||
355 | $ test_jpake: | ||
356 | $ write sys$output "Test JPAKE" | ||
357 | $ mcr 'texe_dir''jpaketest' | ||
358 | $ return | ||
359 | $ test_cms: | ||
360 | $ write sys$output "CMS consistency test" | ||
361 | $ ! Define the logical name used to find openssl.exe in the perl script. | ||
362 | $ define /user_mode osslx 'exe_dir' | ||
363 | $ perl CMS-TEST.PL | ||
364 | $ return | ||
365 | $ test_srp: | ||
366 | $ write sys$output "Test SRP" | ||
367 | $ mcr 'texe_dir''srptest' | ||
368 | $ return | ||
369 | $ | ||
370 | $ | ||
371 | $ exit: | ||
372 | $ mcr 'exe_dir'openssl version -a | ||
373 | $ set default '__save_default' | ||
374 | $ deassign sslroot | ||
375 | $ exit | ||