jeremycollake / x-wrt

Automatically exported from code.google.com/p/x-wrt
3 stars 0 forks source link

option auth not set correctly for PEM auth /etc/config/openvpn #80

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1. Install OpenVPN package.
2. Enable OpenVPN in x-wrt.
3. Set Authnetication Method to PEM
4) Save Changes
5) Upload CA.crt
6) Save changes
7) Upload client.crt
8) Save changes
9) Upload client.key
10) Save changes
11) Apply changes.

What is the expected output? What do you see instead?
I would expect /etc/config/openvpn to look like:
config openvpn general
        option mode     'client'
        option proto    'udp'
        option port     '1194'
        option auth     'pem'

config openvpn client
        option ipaddr   '81.137.171.17'
        option auth "pem"

Instead the confi openvpn client bit is wrong and is set as
config openvpn client
        option ipaddr   '81.137.171.17'
        option auth ""

What version of the product are you using? On what operating system and web
browser?
Browser: Mozilla Firefox 3 Beta 5 (opensuse 11).
OpenWRT for Kamikaze version: OpenWrt Kamikaze - With X-Wrt Extensions 7.09

Please provide any additional info below.

It is easy to work around as you can use the file editor to change the
entry by hand.

Original issue reported on code.google.com by smiths...@gmail.com on 14 Sep 2008 at 11:18

GoogleCodeExporter commented 9 years ago
The easiest fix for this is to modify /etc/init.d/webifopenvpn

Line 32 of the start() function should be changed from
case "$CONFIG_client_auth" in

to

case "$CONFIG_general_auth" in

Original comment by smiths...@gmail.com on 14 Sep 2008 at 11:33

GoogleCodeExporter commented 9 years ago
In addition the following changes are needed to 
/www/cgi-bin/webif/vpn-openvpn.sh

Change line 37-38 from

        FORM_openvpn_cli_auth="$CONFIG_client_auth"
        FORM_openvpn_cli_auth=${FORM_openvpn_general_auth:-cert)}

to

        FORM_openvpn_cli_auth="$CONFIG_general_auth"
        #FORM_openvpn_cli_auth=${FORM_openvpn_general_auth:-cert)}

Original comment by smiths...@gmail.com on 14 Sep 2008 at 12:32

GoogleCodeExporter commented 9 years ago
this has been fixed in trunk

Original comment by kemen04@gmail.com on 16 Oct 2008 at 10:42

GoogleCodeExporter commented 9 years ago

Original comment by kemen04@gmail.com on 19 Aug 2009 at 5:49