Skip to content

Commit

Permalink
fix(sztp): fix SC2129 shellcheck errors
Browse files Browse the repository at this point in the history
Signed-off-by: Mark Sanders <[email protected]>
  • Loading branch information
sandersms authored and glimchb committed Oct 7, 2024
1 parent 1714549 commit 96cc8f6
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions sztp/key.sh
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
#!/usr/bin/bash
# shellcheck disable=SC2129

set -euo pipefail

Expand All @@ -9,9 +8,11 @@ trap 'rm -rf -- "$MYTMPDIR"' EXIT
curl -kL https://watsen.net/support/sztpd-simulator-0.0.11.tgz | tar -zxvf - -C "${MYTMPDIR}"/
pushd "${MYTMPDIR}"/sztpd-simulator/pki
# SBI Port certificates
echo "DNS.2 = bootstrap" >> sztpd1/sbi/end-entity/openssl.cnf
echo "DNS.3 = web" >> sztpd1/sbi/end-entity/openssl.cnf
echo "DNS.4 = redirecter" >> sztpd1/sbi/end-entity/openssl.cnf
{
echo "DNS.2 = bootstrap"
echo "DNS.3 = web"
echo "DNS.4 = redirecter"
} >> sztpd1/sbi/end-entity/openssl.cnf
make -C sztpd1/sbi pki
cat sztpd1/sbi/end-entity/my_cert.pem sztpd1/sbi/intermediate2/my_cert.pem > "${MYTMPDIR}"/sztpd-simulator/cert_chain.pem
openssl crl2pkcs7 -nocrl -certfile "${MYTMPDIR}"/sztpd-simulator/cert_chain.pem -outform DER -out "${MYTMPDIR}"/sztpd-simulator/cert_chain.cms
Expand Down

0 comments on commit 96cc8f6

Please sign in to comment.