]> git.saurik.com Git - apple/security.git/blob - SecurityTests/clxutils/sslScripts/authDoncio
Security-57031.1.35.tar.gz
[apple/security.git] / SecurityTests / clxutils / sslScripts / authDoncio
1 #! /bin/csh -f
2 #
3 # run client-side authenticaiton tests on external servers. These
4 # servers will undoubtedly change their behavior some day.
5 #
6 #
7 set SSL_KEYCHAIN=localcert
8 #
9 # use this to explicitly open the keychain
10 #
11 # not yet
12 #set KEYCHAIN_PWD=
13 set KEYCHAIN_PWD="z=localcert"
14 #
15 # doncio root; we'll implicitly trust it for now
16 #
17 set DONCIO_ROOT="a doncioRoot.cer"
18 #
19 set TEST_HOST=doncio.net
20 set TEST_PATH=/secure/DoD_soft_cert
21 echo =====
22 echo ===== $TEST_HOST/$TEST_PATH requests authentication
23 set cmd="sslViewer $TEST_HOST $TEST_PATH 3 $DONCIO_ROOT T=r"
24 echo $cmd
25 $cmd || exit(1)
26 set cmd="sslViewer $TEST_HOST $TEST_PATH t $DONCIO_ROOT T=r"
27 echo $cmd
28 $cmd || exit(1)
29 echo ===== Try with our bogus cert, expect fail
30 set cmd="sslViewer $TEST_HOST $TEST_PATH k=$SSL_KEYCHAIN $KEYCHAIN_PWD t $DONCIO_ROOT T=j"
31 echo $cmd
32 $cmd
33 if($status != 1) then
34 echo @@@@@@ expected one error from sslViewer, got $status, aborting.
35 exit(1)
36 endif
37 set cmd="sslViewer $TEST_HOST $TEST_PATH k=$SSL_KEYCHAIN $KEYCHAIN_PWD 3 $DONCIO_ROOT T=j"
38 echo $cmd
39 $cmd
40 if($status != 1) then
41 echo @@@@@@ expected one error from sslViewer, got $status, aborting.
42 exit(1)
43 endif
44
45 echo =====
46 echo ===== authExtern success
47 echo =====