Hi,
I have been looking around at different server configs and while I can connect to my server with a manually configured .ovpn file. I can't seem to find anything that'll do what the Access Server does. Like the documentation for linux client assumes:
http://openvpn.net/index.php/access-server/docs/admin-guides/182-how-to-connect-to-access-server-with-linux-clients.html
Running the OpenVPN client with the downloaded client config file:
Usually, the easiest way to install an OpenVPN client is to use the --config argument to specify the location of the downloaded client config file:
openvpn --config client.ovpn
That statement asumes that the user has already acquired the configuration file in question: client.ovpn and then changed it/modified it as necessary to connect to whatever server he requires.
Apparently there's no way to configure the OpenVPN package in
server mode to do what the Access Server:
http://openvpn.net/index.php/access-server/docs/quick-start-guide.html
does which is to automatically supply connecting clients with an .ovpn config file for the client to connect to it. This works for example with OpenVPN access server and "OpenVPN Connect" client under windows.
Is there any way to do this with OpenVPN for linux Both server and client?
Notice that if I use the OpenVPN Connect client AND the Linux server I cannot even "import" a profile from the server. This is what leads me to believe it can't be done on linux server.
The logs for both follow:
OpenVPN Server
Fri Jan 10 00:20:34 2014 us=13563 MULTI: multi_create_instance called
Fri Jan 10 00:20:34 2014 us=13709 Re-using SSL/TLS context
Fri Jan 10 00:20:34 2014 us=13777 LZO compression initialized
Fri Jan 10 00:20:34 2014 us=13795 WARNING: normally if you use --mssfix and/or --fragment, you should also set --tun-mtu 1500 (currently it is 6000)
Fri Jan 10 00:20:34 2014 us=14427 Control Channel MTU parms [ L:6044 D:140 EF:40 EB:0 ET:0 EL:0 ]
Fri Jan 10 00:20:34 2014 us=14516 Data Channel MTU parms [ L:6044 D:1450 EF:44 EB:135 ET:0 EL:0 AF:3/1 ]
Fri Jan 10 00:20:34 2014 us=14666 Local Options String: 'V4,dev-type tun,link-mtu 6044,tun-mtu 6000,proto TCPv4_SERVER,comp-lzo,cipher BF-CBC,auth SHA1,keysize 128,key-method 2,tls-server'
Fri Jan 10 00:20:34 2014 us=14684 Expected Remote Options String: 'V4,dev-type tun,link-mtu 6044,tun-mtu 6000,proto TCPv4_CLIENT,comp-lzo,cipher BF-CBC,auth SHA1,keysize 128,key-method 2,tls-client'
Fri Jan 10 00:20:34 2014 us=14732 Local Options hash (VER=V4): '29ca2407'
Fri Jan 10 00:20:34 2014 us=14754 Expected Remote Options hash (VER=V4): 'b08abd47'
Fri Jan 10 00:20:34 2014 us=14817 TCP connection established with [AF_INET]204.147.92.34:59313
Fri Jan 10 00:20:34 2014 us=14841 TCPv4_SERVER link local: [undef]
Fri Jan 10 00:20:34 2014 us=14857 TCPv4_SERVER link remote: [AF_INET]204.147.92.34:59313
Fri Jan 10 00:21:33 2014 us=999625 204.147.92.34:59313 Connection reset, restarting [0]
Fri Jan 10 00:21:33 2014 us=999710 204.147.92.34:59313 SIGUSR1[soft,connection-reset] received, client-instance restarting
Fri Jan 10 00:21:33 2014 us=999884 TCP/UDP: Closing socket
OpenVPN Connect
2014-01-09 16:20:28-0800 [HTTPChannel,27523,127.0.0.1] *** API CALL f=xmlrpc_Connect args=[{'ret_profile_id': True, 'non_interactive': False, 'host': 'research-openvpn.boingodev.com', 'cookie': 'TRAY_CLIENT_ZWNvdXRpbg==_2z2HQoLe', 'new_only': True, 'type': 'universal'}, ['STATE', 'PASSWORD', 'ACTIVE', 'CERT_APPROVAL', 'INFO', 'CONNECTED_USER', 'FATAL', 'SCRIPT', 'CHALLENGE', 'DELETE_PENDING', 'NOTIFY', 'RSA_SIGN', 'CONNECT_TIMEOUT', 'BYTECOUNT'], {}] kw={} ret=('sess_research_openvpn_boingodev_com_u6279_GsET5J9jaOSe4m9Q_1', 'research_openvpn_boingodev_com_u6279')
2014-01-09 16:20:28-0800 [HTTPChannel,27524,127.0.0.1] *** API CALL f=xmlrpc_Poll args=['sess_TrackActiveProfiles_eUBeTiltOKxpT8LU_1', 10] kw={} ret=[{'type': 'PROFILE', 'state': 'connect', 'profile_id': 'research_openvpn_boingodev_com_u6279', 'cookie': 'TRAY_CLIENT_ZWNvdXRpbg==_2z2HQoLe', 'timestamp': 1389313228}]
2014-01-09 16:20:29-0800 [HTTPChannel,27525,127.0.0.1] *** API CALL f=xmlrpc_ProfileProperties args=['research_openvpn_boingodev_com_u6279'] kw={} ret={'access_allowed': True, 'global': False, 'host': 'research-openvpn.boingodev.com', 'snapshot': {'password': {'status': 'need', 'timestamp': 1389313228, 'need': ('username', 'password'), 'type': 'PASSWORD', 'auth_type': 'Dynamic'}, 'cookie': 'TRAY_CLIENT_ZWNvdXRpbg==_2z2HQoLe'}, 'owner': u'ecoutin', 'type': ['universal'], 'id': 'research_openvpn_boingodev_com_u6279', 'name': 'research-openvpn.boingodev.com/Universal'}
2014-01-09 16:20:29-0800 [HTTPChannel,27527,127.0.0.1] *** API CALL f=xmlrpc_Poll args=['sess_research_openvpn_boingodev_com_u6279_GsET5J9jaOSe4m9Q_1', 10] kw={} ret=[{'status': 'need', 'timestamp': 1389313228, 'need': ('username', 'password'), 'type': 'PASSWORD', 'auth_type': 'Dynamic'}]
2014-01-09 16:20:34-0800 [HTTPChannel,27528,127.0.0.1] *** API CALL f=xmlrpc_SubmitCreds args=['sess_research_openvpn_boingodev_com_u6279_GsET5J9jaOSe4m9Q_1', {'username': 'qamobile', 'password': '[redacted]'}, 'Dynamic', True] kw={} ret=None
2014-01-09 16:20:34-0800 [-] <class 'twisted.names.dns.DNSDatagramProtocol'> starting on 33654
2014-01-09 16:20:34-0800 [-] Starting protocol <twisted.names.dns.DNSDatagramProtocol object at 0x025CD790>
2014-01-09 16:20:34-0800 [-] (Port 33654 Closed)
2014-01-09 16:20:34-0800 [-] Stopping protocol <twisted.names.dns.DNSDatagramProtocol object at 0x025CD790>
2014-01-09 16:21:34-0800 [-] Unhandled Error
Traceback (most recent call last):
File "win32serviceutil.pyo", line 806, in SvcRun
File "capiws.pyo", line 57, in SvcDoRun
File "twisted\internet\base.pyo", line 1166, in run
File "twisted\internet\base.pyo", line 1178, in mainLoop
--- <exception caught here> ---
File "twisted\internet\selectreactor.pyo", line 104, in doSelect
File "twisted\internet\selectreactor.pyo", line 40, in win32select
exceptions.ValueError: file descriptor cannot be a negative integer (-1)
2014-01-09 16:21:34-0800 [-] Malformed file descriptor found. Preening lists.
2014-01-09 16:21:34-0800 [-] bad descriptor <<class 'twisted.internet.tcp.TLSConnection'> to ('54.215.38.82', 443) at 2685f70>
2014-01-09 16:21:44-0800 [-] DynamicClientBase: Unable to obtain Session ID from research-openvpn.boingodev.com, port(s)=(443, 943): XML-RPC: TimeoutError. (twisted.internet.error.TimeoutError): client/dyncli:90,internet/defer:744,python/failure:338,client/dyncli:128,internet/defer:744,python/failure:338,client/asxmlcli:102,client/asxmlcli:81,internet/defer:744,python/failure:338,client/asxmlcli:124,internet/defer:744,python/failure:338,client/asxmlcli:190,client/asxmlcli:174
2014-01-09 16:21:44-0800 [-] *** API CALL f=xmlrpc_Poll args=['sess_research_openvpn_boingodev_com_u6279_GsET5J9jaOSe4m9Q_1', 10] kw={} ret=[{'timestamp': 1389313304, 'info_type': 'twisted.internet.error.TimeoutError', 'type': 'INFO', 'severity': 'error', 'value': 'Unable to obtain Session ID from research-openvpn.boingodev.com, port(s)=(443, 943): XML-RPC: TimeoutError.'}]
2014-01-09 16:21:44-0800 [-] *** API CALL f=xmlrpc_Poll args=['sess_TrackActiveProfiles_eUBeTiltOKxpT8LU_1', 10] kw={} ret=[{'timestamp': 1389313304, 'state': 'disconnect', 'profile_id': 'research_openvpn_boingodev_com_u6279', 'type': 'PROFILE'}]
2014-01-09 16:21:44-0800 [HTTPChannel,27544,127.0.0.1] *** API CALL f=xmlrpc_Poll args=['sess_research_openvpn_boingodev_com_u6279_GsET5J9jaOSe4m9Q_1', 10] kw={} ret=[{'timestamp': 1389313304, 'type': 'DELETE_PENDING'}]
Thanks!