4 $ if f$getsyi("cpu") .ge. 128 then -
5 __arch := f$edit( f$getsyi( "ARCH_NAME"), "UPCASE")
6 $ if __arch .eqs. "" then __arch := UNK
8 $ line_max = 255 ! Could be longer on modern non-VAX.
9 $ temp_file_name = "certs_"+ f$getjpi( "", "PID")+ ".tmp"
10 $ exe_dir := sys$disk:[-.'__arch'.exe.apps]
11 $ cmd = "mcr ''exe_dir'openssl verify ""-CAfile"" ''temp_file_name'"
12 $ cmd_len = f$length( cmd)
13 $ pems = "[-.certs...]*.pem"
15 $! Concatenate all the certificate files.
17 $ copy /concatenate 'pems' 'temp_file_name'
19 $! Loop through all the certificate files.
25 $ if ((f .nes. "") .and. (f .nes. old_f))
29 $! If this file name would over-extend the command line, then
30 $! run the command now.
32 $ if (cmd_len+ f$length( args)+ 1+ f$length( f) .gt. line_max)
34 $ if (args .eqs. "") then goto disaster
38 $! Add the next file to the argument list.
41 $! No more files in the list
47 $! Run the command for any left-over arguments.
54 $! Delete the temporary file.
56 $ if (f$search( "''temp_file_name';*") .nes. "") then -
57 delete 'temp_file_name';*
62 $ write sys$output " Command line too long. Doomed."