openvpn

centos7部署opensvn

怎甘沉沦 提交于 2020-03-03 19:39:12
OpenVPN 是一个基于 OpenSSL 库的应用层 VPN 实现。和传统 VPN 相比,它的优点是简单易用 OpenVPN允许参与建立VPN的单点使用共享金钥,电子证书,或者用户名/密码来进行身份验证。它大量使用了OpenSSL加密库中的SSLv3/TLSv1 协议函式库。OpenVPN能在Solaris、Linux、OpenBSD、FreeBSD、NetBSD、Mac OS X与Windows 2000/XP/Vista上运行,并包含了许多安全性的功能。它并不是一个基于Web的VPN软件,也不与IPsec及其他VPN软件包兼容。 OpenVPN2.0后引入了用户名/口令组合的身份验证方式,它可以省略客户端证书,但是仍有一份服务器证书需要被用作加密。 OpenVPN所有的通信都基于一个单一的IP端口, 默认且推荐使用UDP协议通讯,同时TCP也被支持。OpenVPN连接能通过大多数的代理服务器,并且能够在NAT的环境中很好地工作。服务端具有向客 户端“推送”某些网络配置信息的功能,这些信息包括:IP地址、路由设置等。OpenVPN提供了两种虚拟网络接口:通用Tun/Tap驱动,通过它们, 可以建立三层IP隧道,或者虚拟二层以太网,后者可以传送任何类型的二层以太网络数据。传送的数据可通过LZO算法压缩。在选择协议时候,需要注意2个加密隧道之间的网络状况

Securi-Pi:使用树莓派作为安全跳板

吃可爱长大的小学妹 提交于 2020-02-29 14:31:10
近来我发现越来越多的网络环境开始屏蔽对外的常用端口比如 SMTP(端口 25),SSH(端口 22)之类的。当你走进一家咖啡馆然后想 SSH 到你的一台服务器上做点事情的时候发现端口 22 被屏蔽了是一件很烦的事情。 不过,我到目前为止还没发现有什么网络环境会把 HTTPS 给墙了(端口 443)。在稍微配置了一下家中的树莓派 2 之后,我成功地让自己通过接入树莓派的 443 端口充当跳板,从而让我在各种网络环境下都能连上想要的目标端口。简而言之,我把家中的树莓派设置成了一个 OpenVPN 的端点和 SSH 端点,同时也是一个 Apache 服务器,所有这些服务都监听在 443 端口上,以便可以限制我不想暴露的网络服务。 备注 此解决方案能搞定大多数有限制的网络环境,但有些防火墙会对外部流量调用 深度包检查 ,它们时常能屏蔽掉用本篇文章里的方式传输的信息。不过我到目前为止还没在这样的防火墙后测试过。同时,尽管我使用了很多基于密码学的工具(OpenVPN,HTTPS,SSH),我并没有非常严格地审计过这套配置方案(LCTT 译注:作者的意思是指这套方案能帮你绕过端口限制,但不代表你的活动就是完全安全的)。有时候甚至 DNS 服务都会泄露你的信息,很可能在我没有考虑周到的角落里会有遗漏。我强烈不推荐把此跳板配置方案当作是万无一失的隐藏网络流量的办法

Centos6 安装 openvpn 使用easy-rsa3.0证书认证

旧巷老猫 提交于 2020-02-26 15:52:33
Centos6 安装 openvpn 使用easy-rsa3.0证书认证 安装openvpn yum install -y epel-release yum install -y openvpn easy-rsa openssl openssl-devel lzo lzo-devel pam pam-devel automake pkgconfig 上述命令执行完成后,会有一个/etc/openvpn的目录,通常我们把配置文件都放在这个目录下。 1.查看openvpn版本: [root@openvpn ~]# openvpn --version |head -n1 OpenVPN 2.4.6 x86_64-redhat-linux-gnu [Fedora EPEL patched] [SSL (OpenSSL)] [LZO] [LZ4] [EPOLL] [PKCS11] [MH/PKTINFO] [AEAD] built on Apr 26 2018 2.复制服务端配置文件到配置文件目录 [root@openvpn ~]# cp /usr/share/doc/openvpn-2.4.6/sample/sample-config-files/server.conf /etc/openvpn/ 服务端证书 ls /usr/share/easy-rsa/3.0.3/ #easy

Reverse proxy OpenVpn using Haproxy or Nginx

吃可爱长大的小学妹 提交于 2020-01-25 07:37:06
问题 i was wondering how it is possible to reverse proxying an openvpn connection using the SNI, i've read so much about that: HERE and HERE I've tried any kind of solution, using haproxy and using nginx, but it seems that my client (i've tried Tunnelblick and a simple openvpn client on linux) does not send the SNI information Basically, this is the result that i want to achieve: vpn1.app.com ─┬─► *.app.com dns -> nginx at my public ip ─┬─► vpn1 at 10.0.0.3 vpn2.app.com ─┤ ├─► vpn2 at 10.0.0.4

Bash Script for automated OpenVPN logon

倾然丶 夕夏残阳落幕 提交于 2020-01-23 12:50:14
问题 I am very new to bash scripting, so I apologize in advance for being vague. I have a varied number of OpenVPN configuration profiles I need to connect too on a daily basis, and would like to make this a little easier by introducing automation. So I am able to get to the authorization part of the process and that's where I get stuck: Your IP is xx.xx.xx.xx Mon Oct 13 09:57:14 2014 OpenVPN 2.2.1 i486-linux-gnu [SSL] [LZO2] [EPOLL] [PKCS11] [eurephia] [MH] [PF_INET6] [IPv6 payload 20110424-2 (2

OpenVPN Api generating ovpn file

大憨熊 提交于 2020-01-22 16:15:50
问题 I need to generate a ovpn file using the OpenVPN API in a Java application, however I can't seem to find any information on this API. Does anyone have any experience or information that can get me started? Thanks 回答1: Okay, I found this information for anyone else struggeling with this: OpenVPN-AS REST API ------------------- The OpenVPN Access Server supports a Web Services API that can be used to fetch a client configuration file from the Access Server. The curl command can be used to

Samba Share Over OpenVPN, Split Tunneling? [closed]

泄露秘密 提交于 2020-01-13 07:16:13
问题 Closed. This question is off-topic. It is not currently accepting answers. Want to improve this question? Update the question so it's on-topic for Stack Overflow. Closed 2 years ago . I would like my PC to connect to a server running OpenVPN + Samba + file management software. How would I setup so that the PC only connects to the server without tunneling all the internet traffic to the VPN? I would like to keep the Samba Share connection encrypted. 回答1: You shouldn't push the default route

VPN clients to resolve private DNS hostnames in AWS [closed]

只谈情不闲聊 提交于 2019-12-31 22:49:34
问题 Closed. This question is off-topic. It is not currently accepting answers. Want to improve this question? Update the question so it's on-topic for Stack Overflow. Closed last year . I've recently setup OpenVPN server on an AWS EC2 instance in order to connect my office to the AWS VPC environment. I'm using TunnelBlick as the VPN client and all is good! I can ssh to the private IPs in the VPC. However, resolving the DNS VPC names from my office hosts( which I could if i'd run it from an EC2

How to generate openvpn client key dynamically with php and pass variables to shell command?

左心房为你撑大大i 提交于 2019-12-31 02:40:06
问题 I want to generate clients key with PHP. When a client key generated it should give me the expiry date of the key. root@zohaib-VirtualBox:/etc/openvpn/easy-rsa# ./build-key client1 Generating a 2048 bit RSA private key .............................................................+++ ............................+++ writing new private key to 'client1.key' You are about to be asked to enter information that will be incorporated into your certificate request. What you are about to enter is what

How to generate openvpn client key dynamically with php and pass variables to shell command?

孤街醉人 提交于 2019-12-31 02:40:05
问题 I want to generate clients key with PHP. When a client key generated it should give me the expiry date of the key. root@zohaib-VirtualBox:/etc/openvpn/easy-rsa# ./build-key client1 Generating a 2048 bit RSA private key .............................................................+++ ............................+++ writing new private key to 'client1.key' You are about to be asked to enter information that will be incorporated into your certificate request. What you are about to enter is what