]> git.ipfire.org Git - thirdparty/openvpn.git/commit
down-root plugin: Replaced system() calls with execve()
authorDavid Sommerseth <davids@redhat.com>
Sun, 16 Nov 2014 14:31:02 +0000 (15:31 +0100)
committerGert Doering <gert@greenie.muc.de>
Sat, 6 Dec 2014 13:45:41 +0000 (14:45 +0100)
commit07d61fee2047686e5bec237a6cd7467244f91e13
treebd186163c1c845d72ece23601a15c841b3680c8f
parent77c88554a711f94e81f0a7f74e7e04747a02c85a
down-root plugin: Replaced system() calls with execve()

The system() call is prone to shell expansions and provides far more
environments variables to the executable run than what is usually
preferred.  By moving over to exevce() shell expansions are far more
difficult to achieve and only the OpenVPN provided environment
variables are available.

This is a response to the patch submitted to openvpn-devel ML:
http://article.gmane.org/gmane.network.openvpn.devel/7919

 v2 - Pulling it up again, fixing a few whitespace and spelling issues

Signed-off-by: David Sommerseth <davids@redhat.com>
Acked-by: Steffan Karger <steffan.karger@fox-it.com>
Message-Id: <1416148262-20978-1-git-send-email-openvpn.list@topphemmelig.net>
URL: http://article.gmane.org/gmane.network.openvpn.devel/9238
Signed-off-by: Gert Doering <gert@greenie.muc.de>
(cherry picked from commit f87b1beccb817e1633bc95bd5dd19deec35c7edc)
src/plugins/down-root/down-root.c