ssh-keys

Best way to use multiple ssh private keys on one client

Hi guys, I'm working on Ubuntu and want to use multiple private keys to connect to different servers or different portions of the same server (My uses are admin of server, admin of git, and normal git usage within the same server). I tried simply stacking the keys in the id_rsa files to no avail. Apparently the way to do this is use t...

How to generate SSH key pairs with Python

Hello, I'm attempting to write a script to generate SSH Identity key pairs for me. from M2Crypto import RSA key = RSA.gen_key(1024, 65337) key.save_key("/tmp/my.key", cipher=None) The file /tmp/my.key looks great now. By running ssh-keygen -y -f /tmp/my.key > /tmp/my.key.pub I can extract the public key. My question is how can I ext...

ssh-rsa public key validation using a regular expression.

What regular expression can I use (if any) to validate that a given string is a legal ssh rsa public key? I only need to validate the actual key - I don't care about the key type the precedes it or the username comment after it. Ideally, someone will also provide the python code to run the regex validation. Thanks. ...

Running ssh-keygen without human interaction?

Would it be possible to run ssh-keygen without human interaction? I have a shell script that takes care of server deployment from start to finish, but ssh-keygen is the only remaining piece that still requires my input. Would it be possible to feed the parameters to it? Or is there something similar to debconf-set-selections that could...

Is SSH public key need to be the same each time I do push/pull with git repository?

I am just started using Git, so I apologize if it is a newbie question. I am using two different machines to commit changes to remote Git repository on github.com. Do I need to use the same SSH public key (the one I mentioned for my repository on Github)? ...

ssh-keygen accepting stdin

I am trying to call ssh-keygen using a variable through bash as an input instead of a file to get a fingerprint of a public key. I am aware that I could use a temp file to get around this issue, but for reasons out of scope of this question, I do not want to. This method does not work as it says the key file is invalid (it's correct fo...

Can Maven Wagon plugin use a private key for scp?

Can Maven Wagon plugin be configured to use a private key for ssh/scp? Everything I've tried still leaves maven to ask me for a password when it gets to the point of scp-ing. ...

heroku complaining about my public key created by ssh-keygen2

I am trying to access my heroku app from work (windows machine). I installed cygwin on the machine and generated ssh-key as well. However, I get the below error: C:>heroku keys:add "C:\cygwin\home\4541450\[email protected]" Uploading ssh public key C:\cygwin\home\4541450\[email protected] Enter your Heroku credentia...

Has anyone successfully deployed on heroku from a windows platform ?

I've been reading all kinds of tutorials on how to deploy rails apps on heroku from windows. I've tried installing git, heroku gem, generating ssh keys and setting paths and everything... I get either public key error (without putty) or fatal no auth found (with putty)... ...

Can I use my ssh-public-key to decrypt a file?

I'm trying to find a way to decrypt an encrypted file on a 'virgin' EC2-instance. These EC-instances I use (Ubuntu Lucid) only hold my AWS-created public ssh-key. If can use this to decrypt a file, I can feed it encrypted files (for example a bash-script holding a password to my subversion-repository). So, my question, can I use my ssh-...

SSH is looking in the wrong place for the public/private key pair on Windows

I'm trying to configure GIT on my Windows XP machine, but SSH keeps creating and looking for the public/private key pair in non-sensical places, e.g. /.ssh/id_rsa Is there a configuration file in the GIT Installation for Windows where I can switch this to my home directory, or another user defined place? By default, it offers to create ...

Passwordless SSH using cgi-perl script

Hello, This is my first shot at trying out cgi-perl scripts. I have SSH keys set up between my (root user) local machine and a remote machine. I'm trying to run a command on the remote box and display the output on a webpage hosted from my local machine. The script runs fine from command line however, it throws SSH key error when called...

ssh many users to one home

Hiya, I want to allow some trusted users to scp files into my server (to an specific user), but I do not want to give these users a home, neither ssh login. I'm having problems to understand the correct settings of users/groups I have to create to allow this to happen. I will put an example; Having: MyUser@MyServer MyUser belongs t...

How to authenticate passkey from a Tcl script calling bash?

I have a tcl script that calls a lot of functions from bash including ssh. The part I'm struggling with looks like this: proc connect {where} { set bash c:/cygwin/bin/bash catch {exec $bash -c "ssh $where"} result puts $result } connect user@localhost I get the authentication failed message: Pseudo-terminal will not be al...

ssh key fingerprint error when trying to switch heroku accounts

hey out there! i often need to switch heroku accounts and use a script which does the following: heroku keys:clear && rm ~/.heroku/credentials && heroku list after which i need to enter my credentials for the account i want to switch to: Enter your Heroku credentials. Email: [email protected] Password: Uploading ssh public key /Users/f...

Re-Adding Keys to Github..

I removed my SSH Keys in an effort to backtrack a little bit. When I went to re-add them I got "Oops! The key has already been taken. " Even though I obviously just removed the key it was referring to. It seems the system just doesn't update itself right away. Anyone know how long it takes to remove the keys from my account so that I ca...

Browser based (free to use) SSH

I have a commercial product that allows users to connect to various SSH end-points. Currently these users are forced to download and use Putty... Seems pretty straightforward, except that my SSH end-points require RSA/Private Key authentication. So now connectivity to these end-points is becoming a pain, because I need to explain to my u...

Multiple GitHub Accounts & SSH Config

I'm having some trouble getting two different SSH keys/GitHub accounts to play well together. I have the following setup: Repos accessible from one account using [email protected]:accountname Repos accessible from another account using [email protected]:anotheraccount Each account has its own SSH key. Both SSH keys have been added and I ha...

Capistrano asks for password when deploying, despite SSH keys

My ssh keys are definitely set up correctly, as I'm never prompted for the password when using ssh. But capistrano still asks for a password when deploying with cap deploy. It doesn't ask for the password when I setup with cap deploy:setup though, strangely enough. It would make the deployment cycle so much smoother without a password pr...

Cakephp - fighting with 'thechaw' on git

I feel like I tried everything to clone http://thechaw.com/source from git with no success. I have a create SSH keys in order to access this git and I believe I followed the directions but I'm missing something easy. I followed all the instructions (http://thechaw.com/wiki/guides/setup). Can someone tell me what I'm going wrong? Fir...