Skip to content
No description or website provided.
C Shell Other
Find file
Failed to load latest commit information.
contrib Pristine OpenSSH 5.2 portable sources Jun 29, 2009
openbsd-compat Pristine OpenSSH 5.2 portable sources Jun 29, 2009
regress Pristine OpenSSH 5.2 portable sources Jun 29, 2009
scard Pristine OpenSSH 5.2 portable sources Jun 29, 2009
.gitignore List of files to ignore Jun 29, 2009
CREDITS Pristine OpenSSH 5.2 portable sources Jun 29, 2009
ChangeLog Pristine OpenSSH 5.2 portable sources Jun 29, 2009
INSTALL Pristine OpenSSH 5.2 portable sources Jun 29, 2009
LICENCE Pristine OpenSSH 5.2 portable sources Jun 29, 2009
Makefile.in Obfuscated handshake implementation Jun 29, 2009
OVERVIEW Pristine OpenSSH 5.2 portable sources Jun 29, 2009
PROTOCOL Pristine OpenSSH 5.2 portable sources Jun 29, 2009
PROTOCOL.agent Pristine OpenSSH 5.2 portable sources Jun 29, 2009
README Some documentation improvements Jul 1, 2009
README.dns Pristine OpenSSH 5.2 portable sources Jun 29, 2009
README.obfuscation Some documentation improvements Jul 1, 2009
README.platform Pristine OpenSSH 5.2 portable sources Jun 29, 2009
README.privsep Pristine OpenSSH 5.2 portable sources Jun 29, 2009
README.smartcard Pristine OpenSSH 5.2 portable sources Jun 29, 2009
README.tun Pristine OpenSSH 5.2 portable sources Jun 29, 2009
TODO Pristine OpenSSH 5.2 portable sources Jun 29, 2009
WARNING.RNG Pristine OpenSSH 5.2 portable sources Jun 29, 2009
aclocal.m4 Pristine OpenSSH 5.2 portable sources Jun 29, 2009
acss.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
acss.h Pristine OpenSSH 5.2 portable sources Jun 29, 2009
addrmatch.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
atomicio.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
atomicio.h Pristine OpenSSH 5.2 portable sources Jun 29, 2009
audit-bsm.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
audit.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
audit.h Pristine OpenSSH 5.2 portable sources Jun 29, 2009
auth-bsdauth.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
auth-chall.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
auth-krb5.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
auth-options.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
auth-options.h Pristine OpenSSH 5.2 portable sources Jun 29, 2009
auth-pam.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
auth-pam.h Pristine OpenSSH 5.2 portable sources Jun 29, 2009
auth-passwd.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
auth-rh-rsa.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
auth-rhosts.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
auth-rsa.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
auth-shadow.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
auth-sia.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
auth-sia.h Pristine OpenSSH 5.2 portable sources Jun 29, 2009
auth-skey.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
auth.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
auth.h Pristine OpenSSH 5.2 portable sources Jun 29, 2009
auth1.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
auth2-chall.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
auth2-gss.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
auth2-hostbased.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
auth2-jpake.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
auth2-kbdint.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
auth2-none.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
auth2-passwd.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
auth2-pubkey.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
auth2.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
authfd.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
authfd.h Pristine OpenSSH 5.2 portable sources Jun 29, 2009
authfile.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
authfile.h Pristine OpenSSH 5.2 portable sources Jun 29, 2009
bufaux.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
bufbn.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
buffer.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
buffer.h Pristine OpenSSH 5.2 portable sources Jun 29, 2009
buildpkg.sh.in Pristine OpenSSH 5.2 portable sources Jun 29, 2009
canohost.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
canohost.h Pristine OpenSSH 5.2 portable sources Jun 29, 2009
channels.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
channels.h Pristine OpenSSH 5.2 portable sources Jun 29, 2009
cipher-3des1.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
cipher-acss.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
cipher-aes.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
cipher-bf1.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
cipher-ctr.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
cipher.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
cipher.h Pristine OpenSSH 5.2 portable sources Jun 29, 2009
cleanup.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
clientloop.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
clientloop.h Pristine OpenSSH 5.2 portable sources Jun 29, 2009
compat.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
compat.h Pristine OpenSSH 5.2 portable sources Jun 29, 2009
compress.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
compress.h Pristine OpenSSH 5.2 portable sources Jun 29, 2009
config.guess Pristine OpenSSH 5.2 portable sources Jun 29, 2009
config.h.in Pristine OpenSSH 5.2 portable sources Jun 29, 2009
config.sub Pristine OpenSSH 5.2 portable sources Jun 29, 2009
configure Pristine OpenSSH 5.2 portable sources Jun 29, 2009
configure.ac Pristine OpenSSH 5.2 portable sources Jun 29, 2009
crc32.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
crc32.h Pristine OpenSSH 5.2 portable sources Jun 29, 2009
deattack.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
deattack.h Pristine OpenSSH 5.2 portable sources Jun 29, 2009
defines.h Pristine OpenSSH 5.2 portable sources Jun 29, 2009
dh.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
dh.h Pristine OpenSSH 5.2 portable sources Jun 29, 2009
dispatch.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
dispatch.h Pristine OpenSSH 5.2 portable sources Jun 29, 2009
dns.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
dns.h Pristine OpenSSH 5.2 portable sources Jun 29, 2009
entropy.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
entropy.h Pristine OpenSSH 5.2 portable sources Jun 29, 2009
fatal.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
fixpaths Pristine OpenSSH 5.2 portable sources Jun 29, 2009
fixprogs Pristine OpenSSH 5.2 portable sources Jun 29, 2009
groupaccess.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
groupaccess.h Pristine OpenSSH 5.2 portable sources Jun 29, 2009
gss-genr.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
gss-serv-krb5.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
gss-serv.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
hostfile.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
hostfile.h Pristine OpenSSH 5.2 portable sources Jun 29, 2009
includes.h Pristine OpenSSH 5.2 portable sources Jun 29, 2009
install-sh Pristine OpenSSH 5.2 portable sources Jun 29, 2009
jpake.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
jpake.h Pristine OpenSSH 5.2 portable sources Jun 29, 2009
kex.c Obfuscated handshake implementation Jun 29, 2009
kex.h Pristine OpenSSH 5.2 portable sources Jun 29, 2009
kexdh.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
kexdhc.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
kexdhs.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
kexgex.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
kexgexc.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
kexgexs.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
key.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
key.h Pristine OpenSSH 5.2 portable sources Jun 29, 2009
log.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
log.h Pristine OpenSSH 5.2 portable sources Jun 29, 2009
loginrec.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
loginrec.h Pristine OpenSSH 5.2 portable sources Jun 29, 2009
logintest.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
mac.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
mac.h Pristine OpenSSH 5.2 portable sources Jun 29, 2009
match.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
match.h Pristine OpenSSH 5.2 portable sources Jun 29, 2009
md-sha256.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
md5crypt.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
md5crypt.h Pristine OpenSSH 5.2 portable sources Jun 29, 2009
mdoc2man.awk Pristine OpenSSH 5.2 portable sources Jun 29, 2009
misc.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
misc.h Pristine OpenSSH 5.2 portable sources Jun 29, 2009
mkinstalldirs Pristine OpenSSH 5.2 portable sources Jun 29, 2009
moduli Pristine OpenSSH 5.2 portable sources Jun 29, 2009
moduli.0 Pristine OpenSSH 5.2 portable sources Jun 29, 2009
moduli.5 Pristine OpenSSH 5.2 portable sources Jun 29, 2009
moduli.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
monitor.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
monitor.h Pristine OpenSSH 5.2 portable sources Jun 29, 2009
monitor_fdpass.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
monitor_fdpass.h Pristine OpenSSH 5.2 portable sources Jun 29, 2009
monitor_mm.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
monitor_mm.h Pristine OpenSSH 5.2 portable sources Jun 29, 2009
monitor_wrap.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
monitor_wrap.h Pristine OpenSSH 5.2 portable sources Jun 29, 2009
msg.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
msg.h Pristine OpenSSH 5.2 portable sources Jun 29, 2009
mux.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
myproposal.h Pristine OpenSSH 5.2 portable sources Jun 29, 2009
nchan.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
nchan.ms Pristine OpenSSH 5.2 portable sources Jun 29, 2009
nchan2.ms Pristine OpenSSH 5.2 portable sources Jun 29, 2009
obfuscate.c Obfuscated handshake implementation Jun 29, 2009
obfuscate.h Obfuscated handshake implementation Jun 29, 2009
openssh.xml.in Pristine OpenSSH 5.2 portable sources Jun 29, 2009
opensshd.init.in Pristine OpenSSH 5.2 portable sources Jun 29, 2009
packet.c Obfuscated handshake implementation Jun 29, 2009
packet.h Obfuscated handshake implementation Jun 29, 2009
pathnames.h Pristine OpenSSH 5.2 portable sources Jun 29, 2009
platform.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
platform.h Pristine OpenSSH 5.2 portable sources Jun 29, 2009
progressmeter.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
progressmeter.h Pristine OpenSSH 5.2 portable sources Jun 29, 2009
readconf.c Obfuscated handshake implementation Jun 29, 2009
readconf.h Obfuscated handshake implementation Jun 29, 2009
readpass.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
rijndael.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
rijndael.h Pristine OpenSSH 5.2 portable sources Jun 29, 2009
rsa.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
rsa.h Pristine OpenSSH 5.2 portable sources Jun 29, 2009
scard-opensc.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
scard.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
scard.h Pristine OpenSSH 5.2 portable sources Jun 29, 2009
schnorr.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
scp.0 Pristine OpenSSH 5.2 portable sources Jun 29, 2009
scp.1 Pristine OpenSSH 5.2 portable sources Jun 29, 2009
scp.c Command line options to enable handshake obfuscation Jun 30, 2009
servconf.c Obfuscated handshake implementation Jun 29, 2009
servconf.h Obfuscated handshake implementation Jun 29, 2009
serverloop.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
serverloop.h Pristine OpenSSH 5.2 portable sources Jun 29, 2009
session.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
session.h Pristine OpenSSH 5.2 portable sources Jun 29, 2009
sftp-client.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
sftp-client.h Pristine OpenSSH 5.2 portable sources Jun 29, 2009
sftp-common.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
sftp-common.h Pristine OpenSSH 5.2 portable sources Jun 29, 2009
sftp-glob.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
sftp-server-main.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
sftp-server.0 Pristine OpenSSH 5.2 portable sources Jun 29, 2009
sftp-server.8 Pristine OpenSSH 5.2 portable sources Jun 29, 2009
sftp-server.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
sftp.0 Pristine OpenSSH 5.2 portable sources Jun 29, 2009
sftp.1 Pristine OpenSSH 5.2 portable sources Jun 29, 2009
sftp.c Command line options to enable handshake obfuscation Jul 1, 2009
sftp.h Pristine OpenSSH 5.2 portable sources Jun 29, 2009
ssh-add.0 Pristine OpenSSH 5.2 portable sources Jun 29, 2009
ssh-add.1 Pristine OpenSSH 5.2 portable sources Jun 29, 2009
ssh-add.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
ssh-agent.0 Pristine OpenSSH 5.2 portable sources Jun 29, 2009
ssh-agent.1 Pristine OpenSSH 5.2 portable sources Jun 29, 2009
ssh-agent.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
ssh-dss.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
ssh-gss.h Pristine OpenSSH 5.2 portable sources Jun 29, 2009
ssh-keygen.0 Pristine OpenSSH 5.2 portable sources Jun 29, 2009
ssh-keygen.1 Pristine OpenSSH 5.2 portable sources Jun 29, 2009
ssh-keygen.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
ssh-keyscan.0 Pristine OpenSSH 5.2 portable sources Jun 29, 2009
ssh-keyscan.1 Pristine OpenSSH 5.2 portable sources Jun 29, 2009
ssh-keyscan.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
ssh-keysign.0 Pristine OpenSSH 5.2 portable sources Jun 29, 2009
ssh-keysign.8 Pristine OpenSSH 5.2 portable sources Jun 29, 2009
ssh-keysign.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
ssh-rand-helper.0 Pristine OpenSSH 5.2 portable sources Jun 29, 2009
ssh-rand-helper.8 Pristine OpenSSH 5.2 portable sources Jun 29, 2009
ssh-rand-helper.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
ssh-rsa.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
ssh.0 Pristine OpenSSH 5.2 portable sources Jun 29, 2009
ssh.1 Pristine OpenSSH 5.2 portable sources Jun 29, 2009
ssh.c Obfuscated handshake implementation Jun 29, 2009
ssh.h Pristine OpenSSH 5.2 portable sources Jun 29, 2009
ssh1.h Pristine OpenSSH 5.2 portable sources Jun 29, 2009
ssh2.h Pristine OpenSSH 5.2 portable sources Jun 29, 2009
ssh_config Pristine OpenSSH 5.2 portable sources Jun 29, 2009
ssh_config.0 Pristine OpenSSH 5.2 portable sources Jun 29, 2009
ssh_config.5 Pristine OpenSSH 5.2 portable sources Jun 29, 2009
ssh_prng_cmds.in Pristine OpenSSH 5.2 portable sources Jun 29, 2009
sshconnect.c Obfuscated handshake was not correctly enabled when connecting throug… Apr 6, 2010
sshconnect.h Pristine OpenSSH 5.2 portable sources Jun 29, 2009
sshconnect1.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
sshconnect2.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
sshd.0 Pristine OpenSSH 5.2 portable sources Jun 29, 2009
sshd.8 Pristine OpenSSH 5.2 portable sources Jun 29, 2009
sshd.c Don't call strlen() on the encrypted banner. Jun 30, 2009
sshd_config Pristine OpenSSH 5.2 portable sources Jun 29, 2009
sshd_config.0 Pristine OpenSSH 5.2 portable sources Jun 29, 2009
sshd_config.5 Pristine OpenSSH 5.2 portable sources Jun 29, 2009
sshlogin.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
sshlogin.h Pristine OpenSSH 5.2 portable sources Jun 29, 2009
sshpty.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
sshpty.h Pristine OpenSSH 5.2 portable sources Jun 29, 2009
sshtty.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
survey.sh.in Pristine OpenSSH 5.2 portable sources Jun 29, 2009
ttymodes.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
ttymodes.h Pristine OpenSSH 5.2 portable sources Jun 29, 2009
uidswap.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
uidswap.h Pristine OpenSSH 5.2 portable sources Jun 29, 2009
umac.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
umac.h Pristine OpenSSH 5.2 portable sources Jun 29, 2009
uuencode.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
uuencode.h Pristine OpenSSH 5.2 portable sources Jun 29, 2009
version.h Pristine OpenSSH 5.2 portable sources Jun 29, 2009
xmalloc.c Pristine OpenSSH 5.2 portable sources Jun 29, 2009
xmalloc.h Pristine OpenSSH 5.2 portable sources Jun 29, 2009

README

Handshake Obfuscation
---------------------

Handshake obfuscation strengthens the initial SSH handshake against systems
that identify or classify various network protocols by examining data in 
transit for static signatures.  Such automatic classification of traffic is 
often used to provide different levels of network service for each protocol
and sometimes used to implement policies which prohibit certain uses of a
network.

When an SSH connection is initiated, the client and server exchange several
packets to configure the cryptographic parameters for the session.  Since
the encryption algorithms and keys have not yet been determined, this exchange
of messages is not encrypted and is vulnerable to analysis which can conclusively
identify the connection as SSH protocol traffic no matter what port the server
is listening on.  For most users this is of no concern, because merely being
able to identify a connection as an SSH session does not introduce any security
vulnerabilities in the protocol itself.

Some users may have special security needs where they would prefer not to 
disclose that they are using the SSH protocol to somebody who may be monitoring
the network.  Handshake obfuscation prevents automatic identification of SSH
protocol traffic by encrypting the entire handshake with a stream cipher, and 
is designed to make it difficult to implement an automated analysis tool even
understanding how the obfuscation protocol works. 

The obfuscation encryption key is generated in a way which is deliberately 
slow to make it difficult to implement on the type of high performance network
hardware which is usually used for classifying protocol traffic.  Additionally
an option is provided for the client and server to share a 'keyword' which is
a simple kind of password that is used only for securing the handshake.  No
connection can be initiated to a server which has keyword obfuscation enabled 
without knowing the keyword, and the obfuscation keyword is used to derive the
keys that encrypt the handshake in order prevent decrypting the handshake 
traffic without knowing the keyword.



Configuration
-------------

Server:

The server configuration for obufscated handshakes adds two new keywords which may
be used in a sshd_config file to enable obfuscation.

    ObfuscatedPort
           This option is similar to the Port option and specifies one or more ports
           on which to listen for obfuscated handshake connections.  Both this option
           and the Port option may be used in the same configuration file to create a
           configuration with both regular and obfuscated listening ports.

    ObfuscateKeyword
           Enables the keyword protected obfuscated handshake which prevents initiating
           a handshake to the server without knowing the keyword.

Client:

The OpenSSH client can be configured to use the obfuscated handshake protocol by passing
command line options as well as through configuration file options.

    -z             Initiate an obfuscated handshake to the remote server.
    -Z keyword     Initiate a keyword protected obfuscated handshake to the remote server.

Two new client configuration file options hve been added.

    ObfuscateHandshake
           Requests that the client use the obfuscated handshake protocol.  The default is 'no'

    ObfuscateKeyword
           Enables keyword protected obfuscated handshake.  The server and client must be
           configured with the same keyword in order to initiate a connection.

Protocol Description
--------------------

The first step in the obfuscation protocol is that the client connects to a port
running the protocol and sends a seed message which is used to derive the keys
for obfuscating the handshake.

#define OBFUSCATE_MAGIC_VALUE        0x0BF5CA7E
#define OBFUSCATE_SEED_LENGTH        16
#define OBFUSCATE_MAX_PADDING        8192


[     16 byte random seed           ][  magic  ][ plength ][ .. plength bytes of random padding ... ]
|___________________________________||______________________________________________________________|
                |                                                   |
            Plaintext                                Encrypted with key derived from seed 

To create the seed message the client first generates 16 pseudo random bytes from which
the handshake obfuscation keys will be derived.  The client also runs the key derivation algorithm
(described below) to initialize the obfuscation cipher.

The 'magic' field and the 'plength' field are 32 bit unsigned values transfered in network byte order (MSB first).

The magic field must contain the constant OBFUSCATE_MAGIC_VALUE and the 'plength' field must
contain a randomly selected value between 0 and OBFUSCATE_MAX_PADDING.  Then 'plength' bytes of
pseudo randomly generated data is appended after the length field.

The purpose of the padding is to prevent a trivial traffic analysis attack which allows the protocol
to be identified my merely observing the size of the first message.

Upon receiving the seed message from the client, the server must extract the seed bytes
and perform the key derivation algorithm (described below) before decrypting the rest of the
message.  Then the server must verify that the magic value is correct and also that the padding length
is below OBFUSCATE_MAX_PADDING.

If these checks fail the server will continue reading and discarding all data until
the client closes the connection without sending anything in response.

Key Derivation
--------------

The key derivation produces a pair of keys (one for each direction) by performing an iterated 
hash function over the random seed value concatenated with a constant value.

A different constant value is used for each direction to guarantee that the two stream ciphers
instances are initialized with unique keys.

#define OBFUSCATE_HASH_ITERATIONS     6000
#define OBFUSCATE_KEY_LENGTH          16

    h = SHA1(seed || constant)

    for(i = 0; i < OBFUSCATE_HASH_ITERATIONS; i++)
        h = SHA1(h);

    key = [first OBFUSCATE_KEY_LENGTH bytes of h]

For traffic from the client to the server the constant is the string "client_to_server"

For traffic from the server to the client the constant is the string "server_to_clint"

Passworded Key Derivation
-------------------------

A configuration option is provided which allows specification of a password which must be specified by a client in order
to initiate a handshake with the server.  This feature should not be considered as strong authentication as it is only
for preventing casual portscanning and fingerprinting of your ssh server.

    h = SHA1(seed || password || constant)


Something went wrong with that request. Please try again.