aredn/files/etc/uci-defaults/40_aredn_migrate-httpdconf

21 lines
337 B
Plaintext
Raw Normal View History

#!/bin/sh
IFS="
"
addedpaths="/cgi-bin/vpn
/cgi-bin/vpnc
/cgi-bin/supporttool
"
currentpwd=$(grep "/cgi-bin/setup" /etc/httpd.conf |cut -d ':' -f 3)
for protectedpath in $addedpaths
do
if grep -q "$protectedpath" "/etc/httpd.conf"; then
continue
fi
echo "$protectedpath:root:$currentpwd" >> /etc/httpd.conf
done