[PATCH] Branch and pull-- now with remote
John A Meinel
john at arbash-meinel.com
Wed Jun 8 03:06:28 BST 2005
John A Meinel wrote:
> Erik Bågfors wrote:
>
...
>>
>>I just took a look at it and it looks very good. The one problem I
>>saw is that I have a private key, and this key is locked. But I have
>>it unlocked in my ssh-agent.
>>
>>I could see no way (if there even is one) to get to the key without
>>entering my password again. Is there such a thing?
>>
>>If so, this is ideal :)
>>
>
>
> I think it just requires having paramiko support communicating with
> ssh-agent. I don't think the ssh-agent protocol is very formally
> defined, but it probably isn't very hard to understand.
>
Just to follow up on this, I'm looking through the ssh-agent source code
and the protocol seems rather simple.
Every request is prefixed by the message length in a unsigned 32-bit
big-endian number. The total length must be < 256k. The length does
*not* include the 4-byte length portion.
The first byte of the message is the specific request, which can be one
of about 30 possibilities.
For a given request, it expects certain data. All integers are 32-bit
unsigned big-endian integers. Strings are prefixed with an integer
length, and can also be no longer than 256k.
There are some tricky bits, because certain functions expect BIGNUMs.
But BIGNUM is an openssl data format, and since paramiko is already
using pycrypto, I'm guessing they have access to a BIGNUM converter.
Anyway, I think all it would take is to analyze the protocol a little
bit, and then paramiko could support ssh-agent pretty easily.
John
=:->
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 251 bytes
Desc: OpenPGP digital signature
Url : https://lists.ubuntu.com/archives/bazaar/attachments/20050607/3853e383/attachment.pgp
More information about the bazaar
mailing list