プロバの鯖がtelnetでしか入れないので、ユーザ権限でsshdを動かしたいです。 環境はsolaris。バイナリのssh、sshd、ssh-keygenがあります。 SSH Version 1.2.27 [sparc-sun-solaris2.5.1], protocol version 1.5. ちと古くてアレなんですが、コンパイルする環境がないので、これより新しいのは用意できません。
#これは余談ですが、x86のLinux/FreeSolaris上でクロスコンパイルとかできます?
現状:パスワード認証不可、RSA認証も不可です。
$ ssh -v -p 22222 nanashi@solaris.puge.ne.jp SSH Version OpenSSH-1.2.3, protocol version 1.5. Compiled with SSL. debug: Reading configuration data /home/nanashi/.ssh/config debug: Reading configuration data /etc/ssh/ssh_config debug: Applying options for * debug: ssh_connect: getuid 1000 geteuid 1000 anon 1 debug: Connecting to solaris.puge.ne.jp [2xx.xxx.xxx.xxx] port 22222. debug: Connection established. debug: Remote protocol version 1.5, remote software version 1.2.27 debug: Waiting for server public key. debug: Received server public key (768 bits) and host key (1024 bits). debug: Host 'solaris.puge.ne.jp' is known and matches the host key. debug: Encryption type: 3des debug: Sent encrypted session key. debug: Installing crc compensation attack detector. debug: Received encrypted confirmation. debug: Trying RSA authentication with key 'nanashi@hoge.com' debug: Server refused our key. debug: Doing password authentication. nanashi@solaris.puge.ne.jp's password: Permission denied, please try again. nanashi@solaris.puge.ne.jp's password:
>>437 $ ./sshd -d -f sshd_config debug: sshd version 1.2.27 [sparc-sun-solaris2.5.1] debug: Initializing random number generator; seed file /etc/ssh_random_seed log: Server listening on port 22222. log: Generating 768 bit RSA key. Generating p: ..++ (distance 52) Generating q: ...++ (distance 16) Computing the keys... Testing the keys... Key generation complete. log: RSA key generation complete. debug: Server will not fork when running in debugging mode. log: Connection from 2xx.xxx.xxx.xxx port 4854 log: Could not reverse map address 2xx.xxx.xxx.xxx. debug: Client protocol version 1.5; client software version OpenSSH-1.2.3 debug: Sent 768 bit public key and 1024 bit host key. debug: Encryption type: 3des debug: Received session key; encryption turned on. debug: Installing crc compensation attack detector. debug: Can't find nanashi's shadow - access denied.
Important Changes(重要な変更点): ================================== ・ホスト認証鍵や設定ファイルなどのディレクトリのデフォルトが /etc/ssh に 変更された。 ・ssh-keygen コマンドは、もはや特定の鍵タイプ(すなわちrsa1)をデフォルト とはしないようになった。すなわち、ユーザは必ず -t オプションで作成したい 鍵のタイプ(rsa,dsa,rsa1のいずれか)を指定しなければならない。 ・sshdのX転送機能は、デフォルトではローカルホストをlistenするようになった。 もし、X11クライアントアプリケーションがこの変更により動作しなくなった場合、 sshdの設定ファイル(訳注:sshd_configのこと)の X11UseLocalhost オプショ ンを変更して以前の動作に戻せばよい。 原文:sshd x11 forwarding listens on localhost by default; see sshd X11UseLocalhost option to revert to prior behaviour if your older X11 clients do not function with this configuration
Other Changes(その他の変更点): ================================ ・sshクライアントのエスケープ文字の1つ~&が両方のバージョンのSSHプロトコル で動作するようになった。 ・sshdの ReverseMappingCheck オプションは、意味がより分かりやすい VerifyReverseMapping と いう名前のオプションになった。従来通り、 ReverseMappingCheck という名前 で設定することも可能である。 ・使用された公開鍵(訳注:ユーザ認証鍵の公開鍵)の指紋が LogLevel=VERBOSE の ときにログとして記録されるようになった。 ・シェルが存在しないなどの理由でログインが許可されなかった場合、その理由が ログとして記録されるようになった。 ・X転送におけるエラー処理を強化した。 ・……意味不明 (T_T) …… 原文:improved packet/window size handling in ssh2 ・regex(3)を使用しなくなった。 ・sshdで SIGCHLD races が発生するという現象(Solarisで発生する)を 対策???……意味不明 (T_T) …… 原文:fix SIGCHLD races in sshd (seen on Solaris) ・sshdに -o オプションが新設された。 ・sftpに -B, -R, -P オプションが新設された。 ・ssh-add コマンドは、3つのデフォルトのユーザ認証鍵すべてを認証エージェント に登録する追加する 原文:ssh-add now adds all 3 default keys ・ssh-keyscan コマンドのバグフィックス ・……意味不明 (T_T) …… 原文:ssh-askpass for hostkey dialog ・……意味不明 (T_T) …… 原文:fix fd leak in sshd on SIGHUP ・……意味不明 (T_T) …… 原文:TCP_NODELAY set on X11 and TCP forwarding endpoints
セキュリティ関係の変更点(adv.channelalloc): 1.影響を受けるシステム バージョン2.0から3.0.2までのすべてのリリースには channel code に off-by-one エラーが含まれています。 原文:All versions of OpenSSH between 2.0 and 3.0.2 contain an off-by-one error in the channel code.
3.1以降のバージョンではこの問題は解決されています。 2.影響 この脆弱性を持ったSSHサーバにログインしている正規のユーザによって、 SSHサーバに…(不明)…。また、この脆弱性を持ったSSHクライアントに 悪意を持ったSSHサーバがattackすることによっても同様の…(不明)…。 原文:This bug can be exploited locally by an authenticated user logging into a vulnerable OpenSSH server or by a malicious SSH server attacking a vulnerable OpenSSH client. 3.解決方法 次のパッチ(訳注:省略させていただきました)を適用するか、バージョン3.1 以降を使用することによってこの問題は解決されます。 4.Credits このバグは Joost Pol <joost@pine.nl> 氏によって発見されました。
> This bug can be exploited locally by an authenticated user > logging into a vulnerable OpenSSH server or by a malicious > SSH server attacking a vulnerable OpenSSH client.