From patchwork Fri Oct 2 09:29:40 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jeffery To X-Patchwork-Id: 525437 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from arrakis.dune.hu (arrakis.dune.hu [78.24.191.176]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 13FB41402B6 for ; Fri, 2 Oct 2015 19:30:13 +1000 (AEST) Authentication-Results: ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=gmail.com header.i=@gmail.com header.b=urB9Cxnt; dkim-atps=neutral Received: from arrakis.dune.hu (localhost [127.0.0.1]) by arrakis.dune.hu (Postfix) with ESMTP id 86FB32843AC; Fri, 2 Oct 2015 11:28:36 +0200 (CEST) X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on arrakis.dune.hu X-Spam-Level: X-Spam-Status: No, score=-1.5 required=5.0 tests=BAYES_00,FREEMAIL_FROM, T_DKIM_INVALID autolearn=unavailable version=3.3.2 Received: from arrakis.dune.hu (localhost [127.0.0.1]) by arrakis.dune.hu (Postfix) with ESMTP id DB7882843AC for ; Fri, 2 Oct 2015 11:28:25 +0200 (CEST) X-policyd-weight: using cached result; rate: -8.5 Received: from mail-pa0-f53.google.com (mail-pa0-f53.google.com [209.85.220.53]) by arrakis.dune.hu (Postfix) with ESMTPS for ; Fri, 2 Oct 2015 11:28:25 +0200 (CEST) Received: by pacex6 with SMTP id ex6so102583716pac.0 for ; Fri, 02 Oct 2015 02:29:47 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=from:to:cc:subject:date:message-id; bh=xfDrmIk+zpb/4XNDmRdPmAIuonnRKYWazC/GXANoYpg=; b=urB9CxntWyJ5vNhUxFbZRkNVw0ghSudwltv8XyXqVvtK/n9VDfO/ml1eVfh+sF2XMc +opkdx+EG65c3F3HzTo209blBUP7lJNHe84a796fEXRKGrYcc4aFUWe0LQY4nAs3bYyl Amxd1lQCr9azB6Cmaux7/+UZx46LD+5y4JNlvKWstn+I6YcFiMyvGkn7LbFpNpa3n7rF EZjAojoa54x/DjDX/oS93lSxg2oDeOkBzFh1jZ722HxaE8+7WBBSfPuKEWNrH2iooqbI vBRt7rq6THzOJxn5jS6mcl/FQ0UoQ6r4KXlMYUIM//6nKi1wYWWgeIkVozMekXg09myd y6dQ== X-Received: by 10.66.141.199 with SMTP id rq7mr18929174pab.140.1443778187238; Fri, 02 Oct 2015 02:29:47 -0700 (PDT) Received: from localhost.localdomain (tswc3023.netvigator.com. [218.102.4.23]) by smtp.gmail.com with ESMTPSA id su3sm11013486pbc.83.2015.10.02.02.29.44 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Fri, 02 Oct 2015 02:29:46 -0700 (PDT) From: Jeffery To To: Mirko Vogt Date: Fri, 2 Oct 2015 17:29:40 +0800 Message-Id: <1443778180-7512-1-git-send-email-jeffery.to@gmail.com> X-Mailer: git-send-email 2.1.0 Cc: openwrt-devel@lists.openwrt.org Subject: [OpenWrt-Devel] [PATCH] openvpn: add handling for route-pre-down option X-BeenThere: openwrt-devel@lists.openwrt.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: OpenWrt Development List List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: openwrt-devel-bounces@lists.openwrt.org Sender: "openwrt-devel" (resending as I wasn't subscribed to the list before, my apologies) OpenVPN 2.3 added a route-pre-down option, to run a command before routes are removed upon disconnection. Signed-off-by: Jeffery To --- package/network/services/openvpn/files/openvpn.init | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package/network/services/openvpn/files/openvpn.init b/package/network/services/openvpn/files/openvpn.init index 861d0d6..994973b 100644 --- a/package/network/services/openvpn/files/openvpn.init +++ b/package/network/services/openvpn/files/openvpn.init @@ -120,7 +120,7 @@ start_instance() { redirect_gateway remap_usr1 remote remote_cert_eku remote_cert_ku remote_cert_tls \ reneg_bytes reneg_pkts reneg_sec \ replay_persist replay_window resolv_retry route route_delay route_gateway \ - route_metric route_up rport script_security secret server server_bridge setenv shaper sndbuf \ + route_metric route_pre_down route_up rport script_security secret server server_bridge setenv shaper sndbuf \ socks_proxy status status_version syslog tcp_queue_limit tls_auth \ tls_cipher tls_remote tls_timeout tls_verify tmp_dir topology tran_window \ tun_mtu tun_mtu_extra txqueuelen user verb down push up \