client.conf 3.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127
  1. ##############################################
  2. # Sample client-side OpenVPN 2.0 config file #
  3. # for connecting to multi-client server. #
  4. # #
  5. # This configuration can be used by multiple #
  6. # clients, however each client should have #
  7. # its own cert and key files. #
  8. # #
  9. # On Windows, you might want to rename this #
  10. # file so it has a .ovpn extension #
  11. ##############################################
  12. # Specify that we are a client and that we
  13. # will be pulling certain config file directives
  14. # from the server.
  15. client
  16. # Use the same setting as you are using on
  17. # the server.
  18. # On most systems, the VPN will not function
  19. # unless you partially or fully disable
  20. # the firewall for the TUN/TAP interface.
  21. ;dev tap
  22. dev tun
  23. # Windows needs the TAP-Win32 adapter name
  24. # from the Network Connections panel
  25. # if you have more than one. On XP SP2,
  26. # you may need to disable the firewall
  27. # for the TAP adapter.
  28. ;dev-node MyTap
  29. # Are we connecting to a TCP or
  30. # UDP server? Use the same setting as
  31. # on the server.
  32. ;proto tcp
  33. proto udp
  34. # The hostname/IP and port of the server.
  35. # You can have multiple remote entries
  36. # to load balance between the servers.
  37. remote my-server-1 1194
  38. ;remote my-server-2 1194
  39. # Choose a random host from the remote
  40. # list for load-balancing. Otherwise
  41. # try hosts in the order specified.
  42. ;remote-random
  43. # Keep trying indefinitely to resolve the
  44. # host name of the OpenVPN server. Very useful
  45. # on machines which are not permanently connected
  46. # to the internet such as laptops.
  47. resolv-retry infinite
  48. # Most clients don't need to bind to
  49. # a specific local port number.
  50. nobind
  51. # Downgrade privileges after initialization (non-Windows only)
  52. ;user nobody
  53. ;group nobody
  54. # Try to preserve some state across restarts.
  55. persist-key
  56. persist-tun
  57. # If you are connecting through an
  58. # HTTP proxy to reach the actual OpenVPN
  59. # server, put the proxy server/IP and
  60. # port number here. See the man page
  61. # if your proxy server requires
  62. # authentication.
  63. ;http-proxy-retry # retry on connection failures
  64. ;http-proxy [proxy server] [proxy port #]
  65. # Wireless networks often produce a lot
  66. # of duplicate packets. Set this flag
  67. # to silence duplicate packet warnings.
  68. ;mute-replay-warnings
  69. # SSL/TLS parms.
  70. # See the server config file for more
  71. # description. It's best to use
  72. # a separate .crt/.key file pair
  73. # for each client. A single ca
  74. # file can be used for all clients.
  75. ca ca.crt
  76. cert client.crt
  77. key client.key
  78. # Verify server certificate by checking that the
  79. # certicate has the correct key usage set.
  80. # This is an important precaution to protect against
  81. # a potential attack discussed here:
  82. # http://openvpn.net/howto.html#mitm
  83. #
  84. # To use this feature, you will need to generate
  85. # your server certificates with the keyUsage set to
  86. # digitalSignature, keyEncipherment
  87. # and the extendedKeyUsage to
  88. # serverAuth
  89. # EasyRSA can do this for you.
  90. remote-cert-tls server
  91. # If a tls-auth key is used on the server
  92. # then every client must also have the key.
  93. tls-auth ta.key 1
  94. # Select a cryptographic cipher.
  95. # If the cipher option is used on the server
  96. # then you must also specify it here.
  97. # Note that v2.4 client/server will automatically
  98. # negotiate AES-256-GCM in TLS mode.
  99. # See also the ncp-cipher option in the manpage
  100. cipher AES-256-CBC
  101. # Enable compression on the VPN link.
  102. # Don't enable this unless it is also
  103. # enabled in the server config file.
  104. #comp-lzo
  105. # Set log file verbosity.
  106. verb 3
  107. # Silence repeating messages
  108. ;mute 20