if you're trying to connect to an ssh server in an environment where the ssh2 extension cannot be installed this pure-php implementation may be helpful:
http://phpseclib.sourceforge.net/documentation/net.html安全な暗号化通信を使用したリモートマシン上にあるリソースへのアクセス手段 (シェル、リモート実行、トンネリング、ファイル転送) を提供する » libssh2 のバインディングです。
if you're trying to connect to an ssh server in an environment where the ssh2 extension cannot be installed this pure-php implementation may be helpful:
http://phpseclib.sourceforge.net/documentation/net.html