File: myproxy-cert-checker

package info (click to toggle)
myproxy 6.2.20-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 3,340 kB
  • sloc: ansic: 24,830; sh: 4,636; perl: 3,675; makefile: 272
file content (16 lines) | stat: -rwxr-xr-x 299 bytes parent folder | download | duplicates (8)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
#!/bin/sh

# example certificate_issuer_checker script

# pull cert from stdin to shell variable
cert=`openssl x509 -text`

# check for MD5 signatures
echo "$cert" | grep 'Algorithm: md5' > /dev/null 2>&1
if [ $? = "0" ]; then
    echo "MD5 signature detected" 1>&2
    exit 1
fi

# all done
exit 0