Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 249693 - net-misc/openvpn - init script should execute /etc/openvpn/${VPN}.sh
Summary: net-misc/openvpn - init script should execute /etc/openvpn/${VPN}.sh
Status: RESOLVED WONTFIX
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: New packages (show other bugs)
Hardware: All Linux
: High enhancement (vote)
Assignee: Cédric Krier
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2008-12-03 10:58 UTC by Michael Wyraz
Modified: 2009-10-10 22:53 UTC (History)
1 user (show)

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Michael Wyraz 2008-12-03 10:58:22 UTC
We changed some VPN servers from fedora/redhat to gentoo. On the old systems the start scripts executed /etc/openvpn/${VPN}.sh as root when openvpn was started. This was extremely usefull to setup VPN specific firewall rules and other things while dropping privileges for the openvpn itself. On gentoo this feature not exists.

It would be very helpfull (and easy to implement) if this would be integrated in the ini scripts.


Reproducible: Always

Steps to Reproduce:
Comment 1 Marcel Pennewiß 2009-07-30 09:00:45 UTC
You sould use /etc/openvpn/${VPN}-up.sh and /etc/openvpn/${VPN}-down.sh where ${VPN} is the name of symlink to the init-script (e.g. openvpn.testvpn). there you can set firewall rules and do other things. the tap/tun-device used for this service is the first parameter ($1) and can also be used in the scripts.
Comment 2 Cédric Krier gentoo-dev 2009-08-01 14:52:47 UTC
Feature already exists as explain in comment #1
Comment 3 Michael Wyraz 2009-08-11 14:26:27 UTC
/etc/openvpn/${VPN}-up.sh is only called when the VPN runs as client. There should be a similar thing when running as server. So the suggested solution does not apply to the scenario described here.
Comment 4 Cédric Krier gentoo-dev 2009-10-10 22:53:24 UTC
You can configure the up script in the configuration file for the server.