Help this newbie connect to server
Posted: Tue May 03, 2011 7:19 pm
My company has an Amazon EC2 OpenVPN server instance that I connect to using OpenVPN Connect 1.7.2. I do this by going to https://myvpnhostname.com and entering a username and password, as explained at http://openvpn.net/index.php/access-ser ... lient.html
I'm writing a C# app that requires this VPN connection. I want the app to connect automatically instead of requiring that the user log in by visiting that page. I found some sample code at http://stackoverflow.com/questions/1091861 that shows how to do this, provided you have a client.ovpn file. Unfortunately, I don't have (or can't find) the .ovpn file that OpenVPN Connect is using to make this connection. There is a .ovpn file in C:\Program Files (x86)\OpenVPN Technologies\OpenVPN Client\etc\profile, but when I try to run "openvpn.exe --config <profileovpn>" it says that this is a generic file and fails.
It stands to reason that if I can connect using the OpenVPN Connect web site, I ought to be able to do this programmatically. Any suggestions on the shortest path to success would be greatly appreciated.
Thanks,
-J
I'm writing a C# app that requires this VPN connection. I want the app to connect automatically instead of requiring that the user log in by visiting that page. I found some sample code at http://stackoverflow.com/questions/1091861 that shows how to do this, provided you have a client.ovpn file. Unfortunately, I don't have (or can't find) the .ovpn file that OpenVPN Connect is using to make this connection. There is a .ovpn file in C:\Program Files (x86)\OpenVPN Technologies\OpenVPN Client\etc\profile, but when I try to run "openvpn.exe --config <profileovpn>" it says that this is a generic file and fails.
It stands to reason that if I can connect using the OpenVPN Connect web site, I ought to be able to do this programmatically. Any suggestions on the shortest path to success would be greatly appreciated.
Thanks,
-J