Android Studio 3.4.1
Windows 10
git 2.22.0
使用 Git Gui 创建公钥。 在我的 git 账户中共享密钥。
当我尝试在 Android Studio 中使用 VCS->Git->Push 时,出现错误。
本机。
Push failed
Invocation failed Unexpected Response from Server: Unauthorized
java.lang.RuntimeException: Invocation failed Unexpected Response from Server: Unauthorized
at org.jetbrains.git4idea.nativessh.GitNativeSshAskPassXmlRpcClient.handleInput(GitNativeSshAskPassXmlRpcClient.java:34)
at org.jetbrains.git4idea.nativessh.GitNativeSshAskPassApp.main(GitNativeSshAskPassApp.java:30)
Caused by: java.io.IOException: Unexpected Response from Server: Unauthorized
at org.apache.xmlrpc.LiteXmlRpcTransport.sendRequest(LiteXmlRpcTransport.java:231)
at org.apache.xmlrpc.LiteXmlRpcTransport.sendXmlRpc(LiteXmlRpcTransport.java:90)
at org.apache.xmlrpc.XmlRpcClientWorker.execute(XmlRpcClientWorker.java:72)
at org.apache.xmlrpc.XmlRpcClient.execute(XmlRpcClient.java:194)
at org.apache.xmlrpc.XmlRpcClient.execute(XmlRpcClient.java:185)
at org.apache.xmlrpc.XmlRpcClient.execute(XmlRpcClient.java:178)
at org.jetbrains.git4idea.nativessh.GitNativeSshAskPassXmlRpcClient.handleInput(GitNativeSshAskPassXmlRpcClient
内置
Push failed
Java.io.IOException: Authentication failed:
at org.jetbrains.git4idea.ssh.SSHMain.authenticate(SSHMain.java:288)
at org.jetbrains.git4idea.ssh.SSHMain.start(SSHMain.java:162)
at org.jetbrains.git4idea.ssh.SSHMain.main(SSHMain.java:125)
Caused by: java.io.IOException: Publickey authentication failed.
at com.trilead.ssh2.auth.AuthenticationManager.authenticatePublicKey(AuthenticationManager.java:291)
at com.trilead.ssh2.Connection.authenticateWithPublicKey(Connection.java:483)
at org.jetbrains.git4idea.ssh.SSHMain.tryPublicKey(SSHMain.java:341)
at org.jetbrains.git4idea.ssh.SSHMain.authenticate(SSHMain.java:221)
... 2 more
Caused by: java.io.IOException: PEM problem: it is of unknown type
at com.trilead.ssh2.crypto.PEMDecoder.decodeKeyPair(PEMDecoder.java:500)
at com.trilead.ssh2.auth.AuthenticationManager.authenticatePublicKey(AuthenticationManager.java:225)
... 5 more
Could not read from remote repository.
Please make sure you have the correct access rights
and the repository exists.