aboutsummaryrefslogtreecommitdiff
path: root/core/libressl/files/update-certdata.sh
blob: 3002b05ed82cd1424408bced168c56534610e881 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
#!/bin/sh -e
#
# update-certdata.sh

[ -w /etc/ssl ] || {
    printf '%s\n' "${0##*/}: root required to update cert." >&2
    exit 1
}

cd /etc/ssl && {
    wget https://curl.haxx.se/ca/cacert.pem
    mkdir -p /etc/ssl/certs
    cp -f cacert.pem certs/ca-certificates.crt
    mv -f cacert.pem cert.pem
    printf '%s\n' "${0##*/}: updated cert.pm"
}