I was redirected to this StackExchange, it is my first time here. The extent of experience I have with SSH keys begins and ends with the one time I setup the ability to push code to GitHub.
I need to access a FTP server via Cyberduck. I am in SFTP and need to "Choose..." a SSH Private Key. I have the TEXT for the private key that was messaged to me. So I can copy and paste it into a file? I'm not sure how to proceed and every resource I find is to generate a key rather than save a file to upload.
Guidance and resources are appreciated.
52 Answers
You can save the text that was sent to you as a file and use the built in "Choose..." feature on Cyberduck. I am on a Windows machine so I used the Notepad app. I assume TextEdit on a Mac would have similar results. Here are the steps:
- Open Notepad
- Paste the text that was provided for your SSH key
- Save the file (I named mine
key.txt) - Open Cyberduck
- Select Open Connection
- Select SFTP (SSH File Transfer Protocol) for the connection type
- Enter server, port (22), username
- You can skip password - it will use the SSH key
- For SSH Private Key, select Choose... and find the save location of your file
- Click Connect
- The Unknown Fingerprint prompt will appear, click Allow (and you can select Always if this is a connection you trust and will often use)
- You should see your files and/or your assigned folder location!
if you use an sftp to connect to an sftp server, you should generate an ssh keypair (ie on unix: ssh-keygen) and provide your the public key (ie .ssh/id_rsa.pub or .ssh/id_ed25519.pub) to the sftp-server-admin.
if your ssh private key is in the default directory, the software may find it automatically.
if you use openssh (sftp is a part of it), you can use
sftp -i <privateKey> to connect to the sftp server, once the sftp-server-admin has put your ssh public key to the right location (depends on the setup and the ssh server used).