Results 1 to 3 of 3
  1. #1

    Default Using PSCP to transfer files securely In Windows

    Hello,

    PSCP, the PuTTY Secure Copy client (for Windows), is a tool for transferring files securely between computers using an SSH connection. PSCP is a command line application.

    To start PSCP it will need either to be on your PATH or in your current directory. To add the directory containing PSCP to your PATH environment variable, type into the console window:

    Code:
    set PATH=C:\path\to\putty\directory;%PATH%
    This will only work for the lifetime of that particular console window.

    Once you've got a console window to type into, you can just type pscp on its own to bring up a usage message. This tells you the version of PSCP you're using, and gives you a brief summary of how to use PSCP:

    Code:
    Z:\owendadmin>pscp
    PuTTY Secure Copy client
    Release 0.60
    Usage: pscp [options] [user@]host:source target
           pscp [options] source [source...] [user@]host:target
           pscp [options] -ls [user@]host:filespec
    Options:
      -V        print version information and exit
      -pgpfp    print PGP key fingerprints and exit
      -p        preserve file attributes
      -q        quiet, don't show statistics
      -r        copy directories recursively
      -v        show verbose messages
      -load sessname  Load settings from saved session
      -P port   connect to specified port
      -l user   connect with specified username
      -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
      -unsafe   allow server-side wildcards (DANGEROUS)
      -sftp     force use of SFTP protocol
      -scp      force use of SCP protocol
    (PSCP's interface is much like the Unix scp command, if you're familiar with that.)


    So to copy the local file c:\documents\foo.txt to the server example.com as user fred to the file /tmp/foo you would type:

    Code:
    pscp c:\documents\foo.txt fred@example.com:/tmp/foo

    You can use wildcards to transfer multiple files in either direction, like this:

    Code:
    pscp c:\documents\*.doc fred@example.com:docfiles
    pscp fred@example.com:source/*.c c:\source
    You can also use public key authentication with PSCP.

    Regards,
    Silvester J.

  2. #2
    Join Date
    Dec 2011
    Location
    Oregon, USA
    Posts
    1

    Default Automating the process

    My web designer came to me and wanted to use cfftp to transfer files from our hosted website to the internal network. I wanted a secure solution as we are highly regulated and FTP is not an allowed protocol, SFTP is though. I have used PSCP and would love to have this as a solution. She is writing in coldfusion and both locations are windows boxes.

    Is there anyway to automate PSCP for this transfer (it will be both ways - to and from the website)?

  3. #3

    Default

    Hello,

    I guess for that you may need to write some script kind of thing.. batch file and set it in your Schedule task to run as per your requirement.

    Silvester J

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •