Solved

Putty SFTP: one line command to access an SFTP server

Posted on 2008-10-08
4
5,554 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

Free Gift Card with Acronis Backup Purchase!

Backup any data in any location: local and remote systems, physical and virtual servers, private and public clouds, Macs and PCs, tablets and mobile devices, & more! For limited time only, buy any Acronis backup products and get a FREE Amazon/Best Buy gift card worth up to $200!

Join & Write a Comment

Problem: Windows 32bit running out of paging space. Solution: Add additional page files on separate partitions. Background: By default Windows creates only one page file on the partition you install Windows on. You may know that the maximu…
Introduction People like FTP.  It's a solid, stable, robust protocol for quickly transferring files between two hosts using TCP/IP.  In most cases it's much faster than SMB or CIFS, and certainly much easier to set up between organizations.  This…
Here's a very brief overview of the methods PRTG Network Monitor (https://www.paessler.com/prtg) offers for monitoring bandwidth, to help you decide which methods you´d like to investigate in more detail.  The methods are covered in more detail in o…
You have products, that come in variants and want to set different prices for them? Watch this micro tutorial that describes how to configure prices for Magento super attributes. Assigning simple products to configurable: We assigned simple products…

758 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

Need Help in Real-Time?

Connect with top rated Experts

21 Experts available now in Live!

Get 1:1 Help Now