Operating System - HP-UX
1834499 Members
2763 Online
110068 Solutions
New Discussion

scp with no passwd from HP to Windows

 
Eitan_4
Occasional Contributor

scp with no passwd from HP to Windows

Hi All

I'm doing scp/ssh between hpux to windowsNT
and its working , but when i want this commands without passwd for a specify user its not working .

My tasks where :
1. ssh-keygen2 (on the users home dir)
2. Ive created file named "identification" with the following input "idKey id_dsa_1024_b"
3 .On the SSH2 server (NT) :
Ive created file named "~/.ssh2/slave-name.username.put" contains the input of my key .
4.on the server Ive created a file named "authorization" contains the following line :"Key Slave-name.username.pub"
5. Ive copy the files "authorization" and slave-name.username.pub to the server

Thanks
3 REPLIES 3
Steven E. Protter
Exalted Contributor

Re: scp with no passwd from HP to Windows

If you can figur out how to generate public keys in Windows(which I have not) the attached document will work just fine. You don't need X, the cat command will work just fine.

SEP
Steven E Protter
Owner of ISN Corporation
http://isnamerica.com
http://hpuxconsulting.com
Sponsor: http://hpux.ws
Twitter: http://twitter.com/hpuxlinux
Founder http://newdatacloud.com
generic_1
Respected Contributor

Re: scp with no passwd from HP to Windows

google putty. You can use keys with putty and I think they are even conversion tools out there for your tools. Also putty is free :)/
rmueller58
Valued Contributor

Re: scp with no passwd from HP to Windows

Why not just use an expect script with SFTP put? If you have a job that needs to run periodically, say for batch processing download expect and put or get depending on the direction, uses "secure" mechanism, based on your Unix security.

See below:
#!/usr/bin/expect
spawn sftp user@host
expect "Name"
send "user\r"
expect "Password:"
send "#########\r"
expect "sftp> "
send "lcd /root\r"
expect "sftp> "
send "cd /\r"
expect "sftp> "
send "ascii\r"
expect "sftp> "
send "prompt\r"
expect "sftp>"
send "mget *log\r"
expect "sftp>"
send "quit\r"