Many of the scripts in the openvpn source have their shell set to
/bin/bash, but only two use bash features. The attached patch (against
openvpn-2.1_rc9) sets the shell on the rest of the scripts to /bin/sh for
better portability. The only scripts that actually require bash are
contrib/pull-resolv-conf/client.{up,down} ; they use the ${!var} variable
indirection feature.
sf.net tracker:
<https://sourceforge.net/tracker/?func=detail&aid=
2040296&group_id=48978&atid=454721>
Discussed on the IRC meeting March 4, 2010 in #openvpn-discussions.
<http://thread.gmane.org/gmane.network.openvpn.devel/3242>
Signed-off-by: David Sommerseth <dazo@users.sourceforge.net>
Acked-by: James Yonan <james@openvpn.net>
-#!/bin/bash
+#!/bin/sh
#
# Build a root certificate
-#!/bin/bash
+#!/bin/sh
# Build Diffie-Hellman parameters for the server side
# of an SSL/TLS connection.
-#!/bin/bash
+#!/bin/sh
# Make an intermediate CA certificate/private key pair using a locally generated
# root certificate.
-#!/bin/bash
+#!/bin/sh
# Make a certificate/private key pair using a locally generated
# root certificate.
-#!/bin/bash
+#!/bin/sh
# Similar to build-key, but protect the private key
# with a password.
-#!/bin/bash
+#!/bin/sh
# Make a certificate/private key pair using a locally generated
# root certificate and convert it to a PKCS #12 file including the
-#!/bin/bash
+#!/bin/sh
# Make a certificate/private key pair using a locally generated
# root certificate.
-#!/bin/bash
+#!/bin/sh
# Build a certificate signing request and private key. Use this
# when your root certificate and key is not available locally.
-#!/bin/bash
+#!/bin/sh
# Like build-req, but protect your private key
# with a password.
-#!/bin/bash
+#!/bin/sh
# Initialize the $KEY_DIR directory.
# Note that this script does a
-#!/bin/bash
+#!/bin/sh
# Build a new PKI which is rooted on an intermediate certificate generated
# by ./build-inter or ./pkitool --inter from a parent PKI. The new PKI should
-#!/bin/bash
+#!/bin/sh
# list revoked certificates
-#!/bin/bash
+#!/bin/sh
# revoke a certificate, regenerate CRL,
# and verify revocation
-#!/bin/bash
+#!/bin/sh
# Sign a certificate signing request (a .csr file)
# with a local root certificate and key.
-#!/bin/bash
+#!/bin/sh
# A Sample OpenVPN-aware firewall.
-#!/bin/bash
+#!/bin/sh
#################################
# Set up Ethernet bridge on Linux
-#!/bin/bash
+#!/bin/sh
####################################
# Tear Down Ethernet bridge on Linux