Loading Key Invalid Format
See original GitHub issueHi guys,
Doing something slightly unconventional - running this on Windows. I already resolved one issue (subprocess.run
needs shell=True
added or it fails to load files. However, now I’m having issues with key format. I’ve uploaded my private key and the file name as described, but unfortunately I’m getting this error:
DEBUG:root:Running ssh-add
Error loading key "(stdin)": invalid format
WARNING:root:Could not add key to the SSH agent
It appears it fails somewhere in the subprocess.run
for SSH add, maybe the input
? I’m not sure the best thing to look for to debug this problem. Any thoughts or direction would be appreciated!
Thanks, Brandin.
Issue Analytics
- State:
- Created a year ago
- Comments:5 (3 by maintainers)
Top Results From Across the Web
SSH Suddenly returning Invalid format - Server Fault
Check the contents of key_name , if the agent says invalid format , then there's something wrong with the key - like .....
Read more >31 - Super User
Your OpenSSL version refuses to load this key format. ... It worked but complained with 'invalid format' each time I did server operations....
Read more >SSH Key Format Issues and Fixing the “invalid format” Error
In this tutorial, we talk about issues with the format of keys when establishing an SSH session. First, we generate a sample key...
Read more >Google Groups
Load key "/.ssh/identity/id_rsa": invalid format. (filename depends on what id I select). The id file (without .pub) is just:.
Read more >'Invalid Format' Error Connecting to Server with SSH and ...
If you get an 'invalid format' error when trying to SSH in to a remote server using a private key file that you...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
I’m thinking it could be an issue with the API and the data being returned to the CLI. I’ve reached out to Bitwarden and will report back with my findings. Right now I’m getting a 404 for the attachment, so I think what was being retrieved was old data despite the vault saying its up to date.
@Brandin - Try generating an SSH key using the below script:
https://github.com/modem7/public_scripts/blob/master/Batch + Powershell/ed25519gen.bat
I’ve not had any problems with keys generated in this method (except for WinSCP which doesn’t like anything not PuTTY based).
Make sure ssh-keygen is installed. I’ve installed OpenSSH via Powershell, unsure if that’ll help any.