pkcs2pem: Handle quoting properly.
authorAnders Kaseorg <andersk@mit.edu>
Thu, 24 Sep 2009 15:06:33 +0000 (11:06 -0400)
committerAnders Kaseorg <andersk@mit.edu>
Thu, 24 Sep 2009 15:06:33 +0000 (11:06 -0400)
Signed-off-by: Anders Kaseorg <andersk@mit.edu>
certs/pkcs2pem

index 5b9caaad8b3951b655479d7b446da3cebefa7325..513b32ec05cd22733fddf879adfce5c8f35dfe3d 100755 (executable)
@@ -1,4 +1,4 @@
-#!/bin/sh
+#!/bin/bash
 
 set -e
 
@@ -40,7 +40,6 @@ EOF
 
 pem=$(readlink -f "$pem")
 
-# No, this doesn't handle quoting properly.
-echo HTTPS_CERT_FILE="$pem"
-echo HTTPS_KEY_FILE="$pem"
+printf 'HTTPS_CERT_FILE=%q\n' "$pem"
+printf 'HTTPS_KEY_FILE=%q\n' "$pem"