openvpn: fix arguments passing to wrapped up and down scripts
authorJo-Philipp Wich <jo@mein.io>
Wed, 5 Aug 2020 07:25:41 +0000 (09:25 +0200)
committerJo-Philipp Wich <jo@mein.io>
Thu, 6 Aug 2020 06:34:31 +0000 (08:34 +0200)
commitb92f54b919e925cf27105c22f8ffdd7585937bb1
treecd30324d0591c56cd61668140f00a3005a4a7686
parent34553e8cc9ad4530d3f52c3423e5c52fdacac539
openvpn: fix arguments passing to wrapped up and down scripts

With the introduction of the generic OpenVPN hotplug mechanism, wrapped
--up and --down scripts got the wrong amount and order of arguments passed,
breaking existing configurations and functionality.

Fix this issue by passing the same amount of arguments in the same expected
order as if the scripts were executed by the OpenVPN daemon directly.

Ref: https://github.com/openwrt/openwrt/pull/1596#issuecomment-668935156
Fixes: 8fe9940db6 ("openvpn: add generic hotplug mechanism")
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
package/network/services/openvpn/Makefile
package/network/services/openvpn/files/etc/hotplug.d/openvpn/01-user