aboutsummaryrefslogtreecommitdiffstats
path: root/tests/tls-rsa+ecdsa/t
diff options
context:
space:
mode:
Diffstat (limited to 'tests/tls-rsa+ecdsa/t')
-rw-r--r--tests/tls-rsa+ecdsa/t9
1 files changed, 5 insertions, 4 deletions
diff --git a/tests/tls-rsa+ecdsa/t b/tests/tls-rsa+ecdsa/t
index c9f5b96..16ec9d9 100644
--- a/tests/tls-rsa+ecdsa/t
+++ b/tests/tls-rsa+ecdsa/t
@@ -2,11 +2,12 @@ doveconf_remote() {
doveconf -c "$HOME_remote/.dovecot/config" -hx "$1"
}
pkey_sha256() {
- openssl x509 -pubkey | openssl pkey -pubin -outform DER \
+ openssl x509 -in /dev/stdin -pubkey \
+ | openssl pkey -in /dev/stdin -pubin -outform DER \
| openssl dgst -sha256 | sed -rn "/^.*=\\s*/ {s///p;q}"
}
x509_sha256() {
- openssl x509 -noout -fingerprint -sha256 \
+ openssl x509 -in /dev/stdin -noout -fingerprint -sha256 \
| sed -rn "/^.*=\\s*/ {s///p;q}" | tr -d : | tr "[A-Z]" "[a-z]"
}
@@ -28,7 +29,7 @@ interimap_init
check_mailbox_status "INBOX"
interimap --debug || error
-# which peer certificate is used is up to libssl
+# which peer certificate is used is up to libssl
grep -Fx -e "remote: Peer certificate fingerprint: sha256\$$X509_SHA256" \
-e "remote: Peer certificate fingerprint: sha256\$$X509_ALT_SHA256" \
<"$STDERR" || error
@@ -53,4 +54,4 @@ interimap --debug || error
grep -Fx "remote: Peer certificate fingerprint: sha256\$$X509_ALT_SHA256" <"$STDERR" || error
grep -Fx "remote: Peer certificate matches pinned SPKI digest sha256\$$PKEY_ALT_SHA256" <"$STDERR" || error
-# vim: set filetype=sh :
+# vim: set filetype=bash :