手机升级到Android 6以后,以前正常使用的L2TP VPN却无法连接了。服务器端日志:

"vpnpsk"[119] 114.249.245.192 #240: no acceptable Proposal in IPsec SA
"vpnpsk"[119] 114.249.245.192 #240: sending encrypted notification NO_PROPOSAL_CHOSEN to 114.249.245.192:4500

看起来应该是在加密环节出现了问题。在Libreswan的bugzilla上找到了一段说明:

Android 6.0 appears to be stubborn and only wants to use
AES_256-HMAC_SHA2_256 (needing sha2-truncbug=yes)

phase2alg=aes_gcm-null,aes256-sha1,aes256-sha2_256

and other variations including aes_gcm-null have no positive effect.

The Android 5.1.1 version I am using (Cyanogenmod 12.1) happily runs with SHA1 both with sha2-truncbug=yes or no, so the configuration for now with these two Android versions are

phase2alg=aes_gcm-null,aes256-sha1,aes256-sha2_256
sha2-truncbug=yes

尝试对服务器上的/etc/ipsec.conf文件进行修改:

#修改以下两行配置,在行尾加入“aes256-sha2_256”,以此增加对sha2的支持ike=3des-sha1,aes-sha1,aes256-sha1,aes256-sha2_256
phase2alg=3des-sha1,aes-sha1,aes256-sha1,aes256-sha2_256
#新增一行配置
sha2-truncbug=yes

保存配置文件后重启IPSEC服务,Android 6手机连接恢复正常!

服务器环境:Ubuntu 12.04 LTS + Libreswan

Andorid 6连接Libreswan L2TP VPN的更多相关文章

  1. Win10 连接L2TP VPN 失败解决方法

    Win10 连接L2TP VPN 失败解决方法 iOS系统不知道在什么时候,已经不支持PPTP VPN.偶尔的机会刚好看到github上的一键式VPN服务器部署脚本setup-ipsec-vpn,就在 ...

  2. 如何在Ubuntu 11.10上连接L2TP VPN

    要在家继续项目的开发,但架设的GitLab只能校内访问,更悲催的是学校架设的SSL VPN不支持Linux,好在想起学校以前架设的L2TP VPN,应该可以支持Linux,于是便一通谷歌百度,然而发现 ...

  3. Centos6一键搭建L2TP VPN服务器

    用VPS在墙上打洞还有一种叫L2TP,也是常见的一种方式.本脚本结合了L2TP(Layer Tunneling Protocol)和IPSec(Internet Protocol Security), ...

  4. CentOS Linux VPS安装IPSec+L2TP VPN

    CentOS Linux VPS安装IPSec+L2TP VPN 时间 -- :: 天使羊波波闪耀光芒 相似文章 () 原文 http://www.live-in.org/archives/818.h ...

  5. How to: Set up Openswan L2TP VPN Server on CentOS 6

    Have you ever wanted to set up your own VPN server? By following the steps below, you can set up you ...

  6. juniper防火墙 L2TP VPN配置

    juniper防火墙 L2TP  VPN配置 建立L2TP_POOL 创建连接的用户: 创建用户组: 更改L2TP的连接池: 更改L2TP的隧道: 设置防火墙的策略: Win7连接:

  7. setting up a IPSEC/L2TP vpn on CentOS 6 or Red Hat Enterprise Linux 6 or Scientific Linux

    This is a guide on setting up a IPSEC/L2TP vpn on CentOS 6 or Red Hat Enterprise Linux 6 or Scientif ...

  8. 浙大玉泉ubuntu L2TP VPN连接设置

    网络连接设置 1.内网有线 如果是笔记本且只用无线,剩下的就不需要看了.实验室台式机没有无线网卡不得不折腾-- 玉泉有线都是要绑定固定ip的,实验室无需和mac地址绑定,命令如下sudo gedit ...

  9. 远程连接实验室的VPN

    Windows 7 (win8类似)的用户请按以下步骤进行操作:1.点击“开始”菜单,然后点击“控制面板”,然后点击“查看网络和任务”.2.点击“设置新连接或网络”.3.点击“连接到工作区”,然后点击 ...

随机推荐

  1. 粒子动画Particleground.js

    <!DOCTYPE html> <html> <head> <meta charset="UTF-8"> <title> ...

  2. 05Mybatis_入门程序——根据id查询用户

    这篇文章我们来做一个入门的案例: 建表: /* SQLyog v10.2 MySQL - 5.1.72-community : Database - mybatis ***************** ...

  3. 灵感来自 Google & YouTube 的苗条的进度栏效果

    NProgress.js 是纳米级的进度条插件.拥有逼真的的涓涓细流动画效果来告诉你的用户,某些事情正在发生.它的灵感来自于谷歌,YouTube,应用了,这款苗条的进度条是完美的,适用于 Turbol ...

  4. 使用gulp来构建一个前端项目

    什么是gulp? gulp是一个前端项目构建工具,是自动化项目的构建利器,它不仅能对网站资源进行优化,而且在开发过程中很多重复的任务能够使用正确的工具自动完成.你可以使用gulp及其插件对你的项目代码 ...

  5. [deviceone开发]-do_Socket组件示例

    一.简介 do_Socket只实现了socket的客户端的功能,这个示例完整了展示了组件的基本用法,需要和sockettest3工具配合使用,sockettest3做为一个socket server来 ...

  6. JS常用的设计模式

    单例模式 只创建类的唯一一个实例.我们看了好几种可以不通过构造函数和类Java语法达成单例的方法.从另一方面来说,JavaScript中所有的对象都是单例.有时候开发者说的单例是指通过模块化模式创建的 ...

  7. Ubuntu开机黑屏,无法进入系统

    今天早上起来开机发现Ubuntu进不去了,启动项选择之后长时间的black of screen,击键盘.点鼠标毫无反应,后来实在等不下去了就按了一下电源键,以平时的性格就是强制关机的,这次轻轻碰一下就 ...

  8. putty不能连接linxu,报:connection refused

    用putty连接新装的centos6.5,出现了connection refused问题, 后参考http://blog.sina.com.cn/s/blog_60d2d62a0100tq2l.htm ...

  9. [javascript svg fill stroke stroke-width rx ry ellipse 属性讲解] svg fill stroke stroke-width ellipse 绘制椭圆属性讲解

    <!DOCTYPE html> <html lang='zh-cn'> <head> <title>Insert you title</title ...

  10. Eclipse CDT Linux下内存分析 补记

    常用工具汇总 http://www.ibm.com/developerworks/cn/linux/l-cn-memleak/ 常用的内存分析工具 http://en.wikipedia.org/wi ...