Solved

Putty SFTP: one line command to access an SFTP server

Posted on 2008-10-08
4
5,565 Views
Last Modified: 2013-12-02
Is it possible to specify a one line command in putty sftp that handles connecting to a host and username/password authentication? I have tried the following command and it fails:

psftp user@212.x.x.52 -pw password12345

We are using global scape FTP secure server 3.3 as the destination FTP server to conenct to (is there a setting that needs to be enabled to allow command line sftp connections). The FTP login details are correct. Any information appreciated.
0
Comment
Question by:rmullins83
  • 2
4 Comments
 
LVL 10

Expert Comment

by:kukno
ID: 22669519
did you try the option -pw ?


PuTTY Secure File Transfer (SFTP) client
Release 0.60
Usage: psftp [options] [user@]host
Options:
  -V        print version information and exit
  -pgpfp    print PGP key fingerprints and exit
  -b file   use specified batchfile
  -bc       output batchfile commands
  -be       don't stop batchfile processing if errors
  -v        show verbose messages
  -load sessname  Load settings from saved session
  -l user   connect with specified username
  -P port   connect to specified port
  -pw passw login with specified password
  -1 -2     force use of particular SSH protocol version
  -4 -6     force use of IPv4 or IPv6
  -C        enable compression
  -i key    private key file for authentication
  -noagent  disable use of Pageant
  -agent    enable use of Pageant
  -batch    disable all interactive prompts

Regards
Kurt
0
 

Author Comment

by:rmullins83
ID: 22669610
I did include the pw parameter in the question:

psftp user@212.x.x.52 -pw password12345

But it fails if I try to connect using the -pw paraneter. If use the psftp user@212.x.x.52 then it will request a password and connect successfully. I need a 1 line command to do all of this in one go and connect to the sftp server.
0
 
LVL 40

Expert Comment

by:omarfarid
ID: 22669692
0
 
LVL 10

Accepted Solution

by:
kukno earned 500 total points
ID: 22673976
>I did include the pw parameter in the question:
>
>psftp user@212.x.x.52 -pw password12345

Oops, sorry :-) However -pw should work, BTW: You'll have to place the options (-pw) in front of the user@server part!

0

Featured Post

PRTG Network Monitor: Intuitive Network Monitoring

Network Monitoring is essential to ensure that computer systems and network devices are running. Use PRTG to monitor LANs, servers, websites, applications and devices, bandwidth, virtual environments, remote systems, IoT, and many more. PRTG is easy to set up & use.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Hello, As I have seen there a lot of requests regarding monitoring and reporting for exchange 2007 / 2010 / 2013 I have decided to post some thoughts together and link to articles that have helped me. Of course a lot of information you can get…
If, like me, you have a lot of Dell servers in the estate you manage this article should save you a little time. When attempting to login to iDrac on any server I would be presented with two errors. The first reads "Do you want to run this applicati…
Microsoft Active Directory, the widely used IT infrastructure, is known for its high risk of credential theft. The best way to test your Active Directory’s vulnerabilities to pass-the-ticket, pass-the-hash, privilege escalation, and malware attacks …
This video shows how to quickly and easily add an email signature for all users on Exchange 2016. The resulting signature is applied on a server level by Exchange Online. The email signature template has been downloaded from: www.mail-signatures…

856 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question