Mountain Lion 配置 Obfuscated ssh

/

Obfuscated ssh 可以让 ssh 在握手过程中加密,对于 Anti-GFW 理论上是有一定作用的,虽然作者的本意不在此(作者于2009年提交 Obfuscated ssh 补丁,未被 openssh 官方接受),但是谁曾想到若干年后在中国这样的网络大环境下着实火了一把。

Linux 服务端和 Windows 客户端下的配置可以参考 DZF’s Blog 的文章,Mountain Lion 下的配置需要先安装 Xcode

两个版本:

https://github.com/brl/obfuscated-openssh #for openssh 5.2
https://github.com/aligo/obfuscated-openssh #for openssh 6.1p1

下载 opens with Obfuscated ssh 编译

git clone git@github.com:aligo/obfuscated-openssh.git
cd obfuscated-openssh
./configure

可能会出现 “Your OpenSSL headers do not match your library” 的错误,例如

checking OpenSSL header version... 90812f (OpenSSL 0.9.8r 8 Feb 2011)
checking OpenSSL library version... 90818f (OpenSSL 0.9.8x 10 May 2012)
checking whether OpenSSL's headers match the library... no
configure: error: Your OpenSSL headers do not match your library. Check config.log for details.

加以解决

brew install openssl
export LDFLAGS=-L/usr/local/opt/openssl/lib
export CPPFLAGS=-I/usr/local/opt/openssl/include

重新编译安装

./configure
sudo make
sudo make install

尝试 ssh 连接

/usr/local/bin/ssh user@123.123.123.123 -p 1234 -Z keyword

Comments