我无法通过vscode连接大学服务器。问题在于,连接要求输入一个OTP,然后才重定向到请求的门(然后要求另一个密码)。
似乎Vs对OTP给出了肯定的答案后,它立即进入了另一个阶段(假设连接已经成功)。 是否可以将其配置为等待另一个密码?
如果没有,扩展的来源在哪里? (似乎这是正确的存储库:2,但其中不包含任何逻辑文件)。 谢谢。
我的配置文件:
Host gw.cs.huji.ac.il
HostName gw.cs.huji.ac.il
User davidponar%river
NumberOfPasswordPrompts 6
RequestTTY force
Compression yes
跟踪:
[18:21:20.487] Log Level: 1
[18:21:20.492] remote-ssh@0.51.0
[18:21:20.492] win32 x64
[18:21:20.494] SSH Resolver called for "ssh-remote+gw.cs.huji.ac.il", attempt 1
[18:21:20.494] SSH Resolver called for host: gw.cs.huji.ac.il
[18:21:20.494] Setting up SSH remote "gw.cs.huji.ac.il"
[18:21:20.515] Using commit id "5763d909d5f12fe19f215cbfdd29a91c0fa9208a" and quality "stable" for server
[18:21:20.517] Install and start server if needed
[18:21:22.839] Checking ssh with "ssh -V"
[18:21:22.878] > OpenSSH_for_Windows_7.7p1, LibreSSL 2.6.5
[18:21:22.881] Running script with connection command: ssh -T -D 56087 gw.cs.huji.ac.il bash
[18:21:22.885] Terminal shell path: C:\WINDOWS\System32\cmd.exe
[18:21:23.068] "install" terminal received data: "[2J[?25l[m[H
[H]0;C:\WINDOWS\System32\cmd.exe[?25h"
[18:21:23.068] Got some output, clearing connection timeout
[18:21:23.075] "install" terminal received data: "[?25l[80X[80C
[80X[80C
[80X[80C
[80X[80C
[80X[80C
[80X[80C
[80X[80C
[80X[80C
[80X[80C
[80X[80C
[80X[80C
[80X[80C
[80X[80C
[80X[80C
[80X[80C
[80X[80C
[80X[80C
[80X[80C
[80X[80C
[80X[80C
[80X[80C
[80X[80C
[80X[80C
[80X[80C[H[?25h"
[18:21:23.538] "install" terminal received data: "[?25l[133X[133C
[133X[133C
[133X[133C
[133X[133C
[133X[133C
[133X[133C
[133X[133C
[133X[133C
[133X[133C
[133X[133C
[133X[133C
[133X[133C
[133X[133C
[133X[133C
[133X[133C
[133X[133C
[133X[133C
[133X[133C
[133X[133C
[133X[133C
[133X[133C
[133X[133C
[133X[133C[H[?25h"
[18:21:23.702] "install" terminal received data: "[?25l(OTP) Password: [?25h"
[18:21:28.956] "install" terminal received data: "2"
[18:21:29.712] "install" terminal received data: "0"
[18:21:30.443] "install" terminal received data: "6"
[18:21:33.438] "install" terminal received data: "5"
[18:21:33.972] "install" terminal received data: "1"
[18:21:34.335] "install" terminal received data: "5"
[18:21:36.001] "install" terminal received data: "[?25l
[?25h"
[18:21:36.250] "install" terminal received data: "[?25lPseudo-terminal will not be allocated because stdin is not a terminal.
[?25h"
[18:21:42.800] "install" terminal received data: "[?25lPermission denied (publickey,keyboard-interactive).
[?25h"
[18:21:43.107] "install" terminal command done
[18:21:43.107] Install terminal quit with output: Permission denied (publickey,keyboard-interactive).
[18:21:43.107] Received install output: Permission denied (publickey,keyboard-interactive).
[18:21:43.109] Resolver error: Permission denied (publickey,keyboard-interactive).
[18:21:43.112] TELEMETRY: {"eventName":"resolver","properties":{"outcome":"failure","reason":"PermissionDenied","askedPw":"0","askedPassphrase":"0","asked2fa":"0","askedHostKey":"0","gotUnrecognizedPrompt":"0","remoteInConfigFile":"1"},"measures":{"resolveAttempts":1,"retries":1}}
[18:21:43.114] ------
答案 0 :(得分:1)
花了我一段时间,通过隧道连接解决了这个问题。
尝试ssh -CL 22222:river:22 user%river@gw.cs.huji.ac.il
并确保您的ssh设置文件如下所示:
HostName localhost
User username
Port 22222
NumberOfPasswordPrompts 6
RequestTTY force
Compression yes
答案 1 :(得分:1)
我遇到了同样的问题,这里是一个解决方案:
ssh
到远程机器,并远程 vscode-server-insiders
目录。
cd ~
rm -r .vscode-server-insiders
那么它应该可以工作了。
答案 2 :(得分:0)
我也无法弄清楚。
如果任何人确实需要解决方法,您可以: