Getting "publickey: no more keys to try" error with Eclipse Git Integration

572 views Asked by At

Eclipse IDE gives this error when trying to push a commit into a gitlab repository:

Can't connect to any repository: [email protected]:redacted/name.git ([email protected]:redacted/name.git: Cannot log in at gitlab.com:22
publickey: trying ssh-rsa key SHA256:em+KoqJtfIysPRvugiGRHI702T+k4waTv9rh19U5TmM from SSH agent with signature type rsa-sha2-512
publickey: trying ssh-rsa key ~/.ssh/id_rsa with signature type rsa-sha2-512
publickey: trying ssh-rsa key ~/.ssh/id_rsa with signature type rsa-sha2-512
publickey: no more keys to try)

My key pair for gitlab access is stored under the name gitlab and gitlab.pub. And if I understood the error message correctly, Eclipse did not find these files and failed to authenticate with the server. I had already done ssh-add gitlab and ssh -T [email protected] works as expected. Git CLI is also able to push local changes. The field "private keys" in my Eclipse IDE configuration under General>Network Configuration>SSH2 also has gitlab included. How should I fix this?

1

There are 1 answers

1
shawn_xu On

After some additional testing. I can conclude that eclipse is having trouble with large RSA keys. Using a new key length of 4096 solves the issue.