ssh and passwords
jason at jasonfharris.com
Fri Mar 25 17:11:11 CDT 2011
I just saw the commit by Matt about not being able to handling passwords for ssh which are embedded in the URL.
I have had a glance over the code in sshrepo.py and looking at it one can see that we currently have bugs like:
hg identify --noninteractive ssh://firstname.lastname@example.org/tests/mytestrepo
and running this command prompts me interactively for my password (when I of course explicitly asked for non-interactive.)
Also looking around it appears that although you can set up default usernames and passwords in the [auth] section of the hgrc files, but you can only do this for http and https. Ie you can't do this for ssh.
I just became aware of this since previously all of my ssh connections were passwordless, and I had access to all my servers as one normally would so I was a bit surprised to find that ssh protocol didn't handle passwords in its URL... See https://bitbucket.org/jfh/machg/issue/218
I have a rough understanding of this and the fact that ssh is asking for these things outside the normal stdin, stdout, stderr. Would there be interest in fixing this by using eg http://www.lag.net/paramiko/ or something similar. Or is there a better way to fix this?
More information about the Mercurial-devel