Solved

Putty SFTP: one line command to access an SFTP server

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

Simplifying Server Workload Migrations

This use case outlines the migration challenges that organizations face and how the Acronis AnyData Engine supports physical-to-physical (P2P), physical-to-virtual (P2V), virtual to physical (V2P), and cross-virtual (V2V) migration scenarios to address these challenges.

Question has a verified solution.

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

Goal:  To set up a secure SSH server for your home computer to make it accessible anywhere AND to use it as a port forwarding proxy. Steps 1.  WinSSHD version 5 is free for personal use.  So download and install it.  You can download it from the…
Today it’s fairly well known that high-performing websites and applications bring in more visitors, higher SEO, and ultimately more sales. By the same token, downtime is disastrous for companies and can lead to major hits on a brand, reputation, an…
The Email Laundry PDF encryption service allows companies to send confidential encrypted  emails to anybody. The PDF document can also contain attachments that are embedded in the encrypted PDF. The password is randomly generated by The Email Laundr…
Finding and deleting duplicate (picture) files can be a time consuming task. My wife and I, our three kids and their families all share one dilemma: Managing our pictures. Between desktops, laptops, phones, tablets, and cameras; over the last decade…

726 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