Wed, 31 Dec 2014 06:55:50 +0100
Added tag UPSTREAM_283F7C6 for changeset ca08bd8f51b2
1 #!/bin/sh
2 # This Source Code Form is subject to the terms of the Mozilla Public
3 # License, v. 2.0. If a copy of the MPL was not distributed with this
4 # file, You can obtain one at http://mozilla.org/MPL/2.0/.
6 #
7 # A Bourne shell script for running the NIST SHA Algorithm Validation Suite
8 #
9 # Before you run the script, set your PATH, LD_LIBRARY_PATH, ... environment
10 # variables appropriately so that the fipstest command and the NSPR and NSS
11 # shared libraries/DLLs are on the search path. Then run this script in the
12 # directory where the REQUEST (.req) files reside. The script generates the
13 # RESPONSE (.rsp) files in the same directory.
15 sha_ShortMsg_requests="
16 SHA1ShortMsg.req
17 SHA256ShortMsg.req
18 SHA384ShortMsg.req
19 SHA512ShortMsg.req
20 "
22 sha_LongMsg_requests="
23 SHA1LongMsg.req
24 SHA256LongMsg.req
25 SHA384LongMsg.req
26 SHA512LongMsg.req
27 "
29 sha_Monte_requests="
30 SHA1Monte.req
31 SHA256Monte.req
32 SHA384Monte.req
33 SHA512Monte.req
34 "
35 for request in $sha_ShortMsg_requests; do
36 response=`echo $request | sed -e "s/req/rsp/"`
37 echo $request $response
38 fipstest sha $request > $response
39 done
40 for request in $sha_LongMsg_requests; do
41 response=`echo $request | sed -e "s/req/rsp/"`
42 echo $request $response
43 fipstest sha $request > $response
44 done
45 for request in $sha_Monte_requests; do
46 response=`echo $request | sed -e "s/req/rsp/"`
47 echo $request $response
48 fipstest sha $request > $response
49 done