openvpn connect how android

2023-03-17

安卓访问openvpn,需要将这四个文件(ca.crt, client.crt, client.key and client3.ovpn) 合并为一个单一的 .ovpn 文件。

1、打开client3.ovpn文件并添加以下内容:

For example, a traditional OpenVPN profile might specify certs and keys as follows: ca ca.crt cert client.crt key client.key tls-auth ta.key 1.

You can convert this usage to unified form by pasting the content of the certificate and key files directly into the OpenVPN profile as follows using an XML-like syntax:


-----BEGIN CERTIFICATE-----
MIIBszCCARygAwIBAgIE... . . .
NygscQs1bxBSZ0X3KRk... Lq9iNBNgWg==
-----END CERTIFICATE-----


-----BEGIN CERTIFICATE----- . . .


-----BEGIN RSA PRIVATE KEY----- . . .

key-direction 1

-----BEGIN OpenVPN Static key V1----- . . .

2、Another approach to eliminate certificates and keys from the OpenVPN profile is to use the Android Keychain. For information about this, refer to the section on using the Android Keychain below.

Note: When converting tls-auth to unified format, check for a second parameter after the filename (usually a 0 or 1). This parameter is also known as the key-direction parameter and must be specified as a standalone directive when tls-auth is converted to a unified format. For example, if the parameter is 1, add this line to the profile: key-direction 1. If there is no second parameter to tls-auth, you must add this line to the profile: key-direction bidirectional.

3、err:行太长

4、参考:
https://openvpn.net/vpn-server-resources/faq-regarding-openvpn-connect-android/#how-to-get-started-with-openvpn-connect

分类:Linux | 标签: |

相关日志

评论被关闭!