error:1407742E:SSL routines:SSL23_GET_SERVER_HELLO:tlsv1 alert protocol version
webstormから起動するgitの調子が最近悪くて
error:1407742E:SSL routines:SSL23_GET_SERVER_HELLO:tlsv1 alert protocol version
とか言われてた。
は?という感じなのだが、DoS上からなら一応pull/pushはできたので(逐一パスワード入力は必要だったが)
まあいいか、と放置していた…のだが、流石に面倒になったのでいろいろググって対処。
なんでこんなのが出るのか
Update on SSH Access to GitHub in IntelliJ-based IDEs | Company Blog
GitHub introduced a change last week that drops support for weak cryptographic keys. This has resulted in connectivity issues for some users who are connecting to GitHub using SSH and the built-in client SSH Executable.
Weak cryptographic standards removed | The GitHub Blog
Earlier today we permanently removed support for the following weak cryptographic standards on github.com and api.github.com:
ということらしい。
要は、昔のプロトコルを廃止したら対応しきれてないwebstormが煽りを喰らったと。
とりあえずアプデ
To recap, your options right now are: Use 2018.1 EAP
と言われたのでEAPを有効にして2017.3から2018.1にアプデ。
それでも治らない。
ただプログラム方面での対策はされたはずなので、今の設定を消し飛ばすことに。
SSHキーを再生成
git for windows だけで出来る ssh - himadatenodeの日記
ここを参考に。
git bash上で実行すること。そうしないとevalが実行できない。
ssh-keygen.exe -t rsa -C "メールアドレス"
Generating public/private rsa key pair.
Enter file in which to save the key (/c/Users/username/.ssh/id_rsa): #左のパスで良ければ[Enter]。
Created directory '/c/Users/username/.ssh'.
Enter passphrase (empty for no passphrase): #パスフレーズを打つ
Enter same passphrase again: #もう一度確認でパスフレーズ
eval `ssh-agent`
ssh-add ~/.ssh/id_rsa
Enter passphrase for /c/Users/username/.ssh/id_rsa: #パスフレーズを入れる
Identity added: /c/Users/username/.ssh/id_rsa (/c/Users/username/.ssh/id_rsa)
## Github上でSetting → Deploy keys → 追加(Write許可)
git pull #success?
お疲れ様でした。