Re: scp scripting question

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]



On 12.10.2012 21:30, m.roth@xxxxxxxxx wrote:
> Les Mikesell wrote:
>> On Fri, Oct 12, 2012 at 2:48 PM,  <m.roth@xxxxxxxxx> wrote:
>>>>>
>>>> So, my manager, in zsh, can do the following:
>>>> scp -i =(ssh -qnx <snip> cat /etc/ks/ks_dsa) localfile
>>>> server:/whereitgoes
> <snip>
>> I think you'll have to drop the key in a tmp file yourself.  Poking
>> around with strace a bit it looks like that is what zsh actually 
>> does
>> while bash gives what is essentially a named pipe where scp or ssh
>> will attempt a seek (???) and then fail to read.   The subsequent
>> prompt for a passphrase in nonsense - it has already given up and
>> closed it  by then.

Yep, exactly right. People in #openssh confirmed -i HAS to be a real 
path to a file.

>
> THANK YOU, Les. I hadn't gotten to thinking about using strace
> (admittedly, I'd been busy with other stuff, too).
>
> So either I write a tiny script, do it from the server with the 
> actually
> key, or run it as a zsh command.

Yes. You can also look at ssh-add.


-- 
Sent from the Delta quadrant using Borg technology!

Nux!
www.nux.ro
_______________________________________________
CentOS mailing list
CentOS@xxxxxxxxxx
http://lists.centos.org/mailman/listinfo/centos


[Index of Archives]     [CentOS]     [CentOS Announce]     [CentOS Development]     [CentOS ARM Devel]     [CentOS Docs]     [CentOS Virtualization]     [Carrier Grade Linux]     [Linux Media]     [Asterisk]     [DCCP]     [Netdev]     [Xorg]     [Linux USB]
  Powered by Linux