summaryrefslogtreecommitdiff
path: root/app/openvpn/contrib/pull-resolv-conf/client.down
diff options
context:
space:
mode:
authorParménides GV <parmegv@sdf.org>2015-06-04 19:20:15 +0200
committerParménides GV <parmegv@sdf.org>2015-06-04 19:20:15 +0200
commit27594eeae6f40a402bc3110f06d57975168e74e3 (patch)
treecdabf6571e6f4ff07205fd6921d8095539a1fcdc /app/openvpn/contrib/pull-resolv-conf/client.down
parent8dc4f58d96892fbfd83094fb85b1d17656035290 (diff)
ics-openvpn as a submodule! beautiful
ics-openvpn is now officially on GitHub, and they track openssl and openvpn as submodules, so it's easier to update everything. Just a git submodule update --recursive. I've also set up soft links to native modules from ics-openvpn in app, so that we don't copy files in Gradle (which was causing problems with the submodules .git* files, not being copied). That makes the repo cleaner.
Diffstat (limited to 'app/openvpn/contrib/pull-resolv-conf/client.down')
-rw-r--r--app/openvpn/contrib/pull-resolv-conf/client.down47
1 files changed, 0 insertions, 47 deletions
diff --git a/app/openvpn/contrib/pull-resolv-conf/client.down b/app/openvpn/contrib/pull-resolv-conf/client.down
deleted file mode 100644
index 05f2d4d5..00000000
--- a/app/openvpn/contrib/pull-resolv-conf/client.down
+++ /dev/null
@@ -1,47 +0,0 @@
-#!/bin/sh
-
-# Copyright (c) 2005-2010 OpenVPN Technologies, Inc.
-# Licensed under the GPL version 2
-
-# First version by Jesse Adelman
-# someone at boldandbusted dink com
-# http://www.boldandbusted.com/
-
-# PURPOSE: This script automatically removes the /etc/resolv.conf entries previously
-# set by the companion script "client.up".
-
-# INSTALL NOTES:
-# Place this in /etc/openvpn/client.down
-# Then, add the following to your /etc/openvpn/<clientconfig>.conf:
-# client
-# up /etc/openvpn/client.up
-# down /etc/openvpn/client.down
-# Next, "chmod a+x /etc/openvpn/client.down"
-
-# USAGE NOTES:
-# Note that this script is best served with the companion "client.up"
-# script.
-
-# Tested under Debian lenny with OpenVPN 2.1_rc11
-# It should work with any UNIX with a POSIX sh, /etc/resolv.conf or resolvconf
-
-# This runs with the context of the OpenVPN UID/GID
-# at the time of execution. This generally means that
-# the client "up" script will run fine, but the "down" script
-# will require the use of the OpenVPN "down-root" plugin
-# which is in the plugins/ directory of the OpenVPN source tree
-
-# A horrid work around, from a security perspective,
-# is to run OpenVPN as root. THIS IS NOT RECOMMENDED. You have
-# been WARNED.
-PATH=/bin:/usr/bin:/usr/local/bin:/sbin:/usr/sbin:/usr/local/sbin
-
-if type resolvconf >/dev/null 2>&1; then
- resolvconf -d "${1}" -f
-elif [ -e /etc/resolv.conf.ovpnsave ] ; then
- # cp + rm rather than mv in case it's a symlink
- cp /etc/resolv.conf.ovpnsave /etc/resolv.conf
- rm -f /etc/resolv.conf.ovpnsave
-fi
-
-exit 0