{"action":"created","issue":{"url":"https://api.github.com/repos/azure-openvpn/azure-openvpn.github.io/issues/4","labels_url":"https://api.github.com/repos/azure-openvpn/azure-openvpn.github.io/issues/4/labels{/name}","comments_url":"https://api.github.com/repos/azure-openvpn/azure-openvpn.github.io/issues/4/comments","events_url":"https://api.github.com/repos/azure-openvpn/azure-openvpn.github.io/issues/4/events","html_url":"https://github.com/azure-openvpn/azure-openvpn.github.io/issues/4","id":97209915,"number":4,"title":"No CA Certificate to connect with","user":{"login":"awalGarg","id":9100409,"avatar_url":"https://avatars.githubusercontent.com/u/9100409?v=3","gravatar_id":"","url":"https://api.github.com/users/awalGarg","html_url":"https://github.com/awalGarg","followers_url":"https://api.github.com/users/awalGarg/followers","following_url":"https://api.github.com/users/awalGarg/following{/other_user}","gists_url":"https://api.github.com/users/awalGarg/gists{/gist_id}","starred_url":"https://api.github.com/users/awalGarg/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/awalGarg/subscriptions","organizations_url":"https://api.github.com/users/awalGarg/orgs","repos_url":"https://api.github.com/users/awalGarg/repos","events_url":"https://api.github.com/users/awalGarg/events{/privacy}","received_events_url":"https://api.github.com/users/awalGarg/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":2,"created_at":"2015-07-25T08:58:53Z","updated_at":"2015-08-15T06:04:18Z","closed_at":"2015-08-13T11:16:42Z","body":"Hi there,\r\n\r\nThanks for the guide. I have set up an OpenVPN server as described, have a username and password. But when trying to connect to it from the client (Ubuntu 14.04 LTS), it asks for a CA Certificate file. Without it, it won't allow me to connect. How can I generate that file?\r\n\r\nThanks, <3"},"comment":{"url":"https://api.github.com/repos/azure-openvpn/azure-openvpn.github.io/issues/comments/131305625","html_url":"https://github.com/azure-openvpn/azure-openvpn.github.io/issues/4#issuecomment-131305625","issue_url":"https://api.github.com/repos/azure-openvpn/azure-openvpn.github.io/issues/4","id":131305625,"user":{"login":"awalGarg","id":9100409,"avatar_url":"https://avatars.githubusercontent.com/u/9100409?v=3","gravatar_id":"","url":"https://api.github.com/users/awalGarg","html_url":"https://github.com/awalGarg","followers_url":"https://api.github.com/users/awalGarg/followers","following_url":"https://api.github.com/users/awalGarg/following{/other_user}","gists_url":"https://api.github.com/users/awalGarg/gists{/gist_id}","starred_url":"https://api.github.com/users/awalGarg/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/awalGarg/subscriptions","organizations_url":"https://api.github.com/users/awalGarg/orgs","repos_url":"https://api.github.com/users/awalGarg/repos","events_url":"https://api.github.com/users/awalGarg/events{/privacy}","received_events_url":"https://api.github.com/users/awalGarg/received_events","type":"User","site_admin":false},"created_at":"2015-08-15T06:04:18Z","updated_at":"2015-08-15T06:04:18Z","body":"Hey @lilianmoraru sorry for the late reply.\r\n\r\nThe standard CLI based OpenVPN client doesn't ask you for anything, it just expects you to pass stuff along.\r\n\r\nThe link you gave is for the OpenVPN Web admin area's SSL certificates which is not quite what I was looking for.\r\n\r\nHowever I found that by going to `https://<your-vpn-address>:<vpnport>/` (see no `/admin` path), and logging in to the `openvpn` account, you will get an option to download a userlocked `.ovpn` profile which contains the details, certificates and everything. Then you can execute this command:\r\n\r\n```sh\r\nsudo openvpn --config <path/to/.ovpn>\r\n```\r\nthe `sudo` part is important. It will connect with that `.ovpn` file and ask for a username and password.\r\n\r\nIf you don't wanna type your username/password everytime, you can do the following: put them in a new file in the following format:\r\n```\r\n<username>\r\n<password>\r\n```\r\n\r\n(without the `<` and `>` ofcourse). No trailing slashes or extra newlines, no quotes. just the username and password separated by a newline, in that order. Then save it as `credentials.conf` and do the following:\r\n\r\n```sh\r\nsudo openvpn --config <path/to/.ovpn> --auth-user-pass <path/to/credentials.conf>\r\n```\r\n\r\nand it won't ask for the password. If you don't wanna save your password in plaintext like me, you can setup a quick python script that allows you to enter/update/remove the credentials in a file in encrypted format, and also allows you to connect to the vpn and disconnect as a service without having to dedicate a shell. It was quite easy to do for me.\r\n\r\nHope that helps future readers!"}}