X-Git-Url: http://git.grml.org/?a=blobdiff_plain;f=sbin%2Fgrml-pptp-vcgraz;h=b1fe498705d25583425ec39a96e29d31311372a1;hb=6491538dd1b832fcae56d058b2a0685f2e643460;hp=902a2ab1df91b21b8a5a1bced5f0d274ee6eb6aa;hpb=a83e3825511532c96dd400447f2e0cc5e89600dd;p=grml-network.git diff --git a/sbin/grml-pptp-vcgraz b/sbin/grml-pptp-vcgraz index 902a2ab..b1fe498 100755 --- a/sbin/grml-pptp-vcgraz +++ b/sbin/grml-pptp-vcgraz @@ -4,7 +4,6 @@ # Authors: grml-team (grml.org), (c) Michael Prokop # Bug-Reports: see http://grml.org/bugs/ # License: This file is licensed under the GPL v2. -# Latest change: Sam Mai 27 15:12:52 CEST 2006 [mika] ################################################################################ ################################################################################ @@ -13,10 +12,10 @@ # by Wolfgang Scheicher. ################################################################################ -LANG=C -LC_ALL=C +export LANG=C +export LC_ALL=C -if [ "$UID" != 0 ]; then +if [ $(id -ru) -ne 0 ] ; then sudo $0 exit fi @@ -52,7 +51,7 @@ chmod 600 /etc/ppp/chap-secrets # don't overwrite existing files - so just append: echo "${VPNUSERNAME} PPTP ${VPNPASSWORD} *" >> /etc/ppp/chap-secrets -echo -e "#!/bin/sh\nLANG=C\nVPNSERVER=\"${VPNSERVER}\"\nDORMITORY=\"${DORMITORY}\"" > /etc/init.d/pptp-vcgraz +printf "#!/bin/sh\nLANG=C\nVPNSERVER=\"${VPNSERVER}\"\nDORMITORY=\"${DORMITORY}\"" > /etc/init.d/pptp-vcgraz cat >> /etc/init.d/pptp-vcgraz << "EOF" # connect to vc-graz via pptp case "$1" in