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 42 43 44 45 46
|
load_lib vomstest.exp
testheader "See if voms-proxy-init --bits 0 works."
proc mytest {} {
_activateCert mycert2
_vomsStart voms1
set res [log_exec outname {voms-proxy-init --voms voms1 --bits 0}]
_vomsStop voms1
if $res then {
addlog $outname
testmessage "voms-proxy-init failed."
return $::FAILTEST
}
if [log_exec outname {voms-proxy-info}] then {
addlog $outname
testmessage "voms-proxy-info failed."
return $::FAILTEST
} else {
#match against known (correct) output
set correct "subject : /C=IT/CN=001/CN=proxy
issuer : /C=IT/CN=001
identity : /C=IT/CN=001
type : proxy
strength : 2048 bits
path : /tmp/x509up_u\[0-9\]*
timeleft : \[0-9\]*:\[0-9\]*:\[0-9\]*"
loadvar out2 $outname
if [regexp $correct $out2 dummy] then {
testmessage "voms-proxy-init --bits 0 worked successfully."
return $::PASSTEST
} else {
logvar correct
addlog $outname
testmessage "Unexpected output in voms-proxy-info"
return $::FAILTEST
}
}
}
do_test
|